Re: [fxtf-drafts] [filter-effects-1] What is the visual effect of filter() on the document element?

@smfr

The default background is traditionally customizable (e.g., Firefox lets you set this as a user style).  

[CSS Backgrounds](https://drafts.csswg.org/css-backgrounds/#special-backgrounds) says:

> The document canvas is the infinite surface over which the document is rendered. ... If the canvas background is not opaque, what shows through is UA-dependent.

However, [WHATWG HTML says](https://html.spec.whatwg.org/multipage/rendering.html#phrasing-content-3):

> The initial value for the 'color' property is expected to be black. The initial value for the 'background-color' property is expected to be 'transparent'. The canvas's background is expected to be white.

Elsewhere, [CSS Backgrounds says](https://drafts.csswg.org/css-backgrounds/#root-background) that a background on the root element or HTML body element is propagated to the canvas.  So it is theoretically possible to insist that "the background that shows through from a transparent canvas" is white, while also allowing customization in the form of a `:root {background-color: <user-setting>}` style rule. The difference would be revealed if an author style sets a (semi-)transparent root background: does it override the user setting, or layer on top of it? 

Firefox implements it using the layered approach: the user-defined color is applied underneath any background set on the root element.

-- 
GitHub Notification of comment by AmeliaBR
Please view or discuss this issue at https://github.com/w3c/fxtf-drafts/issues/282#issuecomment-385460652 using your GitHub account

Received on Monday, 30 April 2018 16:57:36 UTC