Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify: are gradients considered contentful? #61

Closed
noamr opened this issue Mar 5, 2020 · 9 comments
Closed

Clarify: are gradients considered contentful? #61

noamr opened this issue Mar 5, 2020 · 9 comments

Comments

@noamr
Copy link
Contributor

noamr commented Mar 5, 2020

Currently according to the spec, background images are considered contentful in terms of measuring FCP. The definition of images in CSS also includes gradients. I'm not sure they should be - they're more similar to background colors than they are to images in terms of what "content" is - but in any case the spec should maybe clarify this.

@npm1
Copy link
Contributor

npm1 commented Mar 5, 2020

I tend to agree that gradients are not very contentful (given that colors aren't). I did a quick test, Chrome currently does consider them as contentful. But I'm open to changing it, and we can mention this in the spec either way.

@rniwa
Copy link

rniwa commented Mar 5, 2020

Related, we really need to more rigorously define what it means for an image to be rendered, or even what an image means in this context.

For example, [https://drafts.csswg.org/css-images-4/#image-values]( type) defines the CSS syntax for specifying images in places like background-image, and one of the concepts defined there is of an invalid image where url is pointing to a non-existent image. We need to define under which scenarios, anything specified by type is considered as an image and is rendered.

And then for each one of those properties, we need to define under what condition a specified image is considered as rendered. For example, background-image has an associated background painting area. What happens when this background painting area is 0px by 0px?

A border image with border-image-width set to 0px presumably doesn't count?

All these things need to precisely defined.

@noamr
Copy link
Contributor Author

noamr commented Mar 8, 2020

I tried to address this here: #66

@noamr
Copy link
Contributor Author

noamr commented Mar 11, 2020

I believe that #66 addresses this, closing.

@noamr noamr closed this as completed Mar 11, 2020
@npm1
Copy link
Contributor

npm1 commented Mar 11, 2020

@noamr so they will not be considered contentful, correct? Once you confirm I can add a test (Chrome will fail it at the moment).

@noamr
Copy link
Contributor Author

noamr commented Mar 11, 2020

@noamr so they will not be considered contentful, correct? Once you confirm I can add a test (Chrome will fail it at the moment).

Correct. Only loaded images will be considered contentful.

@rniwa
Copy link

rniwa commented Mar 12, 2020

Please don't close an issue until the relevant PR is landed. It's very confusing.

@rniwa rniwa reopened this Mar 12, 2020
@noamr
Copy link
Contributor Author

noamr commented Mar 12, 2020

Please don't close an issue until the relevant PR is landed. It's very confusing.

OK, sorry :)

@noamr
Copy link
Contributor Author

noamr commented Mar 20, 2020

Closing now that the PR is landed. https://w3c.github.io/paint-timing/

@noamr noamr closed this as completed Mar 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants