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

Make fully-transparent text non-contentful #76

Closed
wants to merge 2 commits into from
Closed

Conversation

noamr
Copy link
Contributor

@noamr noamr commented Mar 24, 2020

Based on a request from Mozilla in #58 (comment).

See #75


Preview | Diff

@noamr noamr requested review from rniwa, yoavweiss and npm1 March 24, 2020 18:03

A [=CSS image=] |img| is a <dfn>contentful image</dfn> when all of the following apply:
* |img| is [=url valued=].
* |img| is [=available=].

A {{DOMString}} is <dfn>non-empty</dfn> if it contains at least one character excluding [=document white space characters=].

A style |s| <dfn>may display text</dfn> if one of the following apply:
* The [=foreground color=] of |s| is not [=fully transparent=].
* The [=text-shadow=] of |s| contains at least one value that is not [=fully transparent=] and its [=length=] is greater than 0.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about colors of text decoration and text emphasis?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I deliberately excluded them - I feel that a page that shows transparent text and colored underlines/emphasis should not be considered contentful. But this is open for discussion.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That doesn't seem right. Text emphases and decorations aren't like borders or background colors. They're part of the text.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They are part of the text - but if they are visible and the text isn't, is it still content rather than a mere decoration? @npm1 wdyt?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whipped up a quick test page, and I agree that while text-shadow is content, decoration and emphasis isn't.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe the problem is with the name "may display text"? It could be "may display contentful text". or "may display glyphs".

Copy link
Contributor

@npm1 npm1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine to me, thanks!

painttiming.bs Outdated Show resolved Hide resolved
painttiming.bs Outdated Show resolved Hide resolved
@noamr
Copy link
Contributor Author

noamr commented Mar 27, 2020

Closing after discussion.

@noamr noamr closed this Mar 27, 2020
@yoavweiss yoavweiss deleted the trans-text branch February 3, 2021 14:21
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

Successfully merging this pull request may close these issues.

4 participants