-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Incorrect test added for text-transform #46490
Comments
@frivoal Thanks. I believe this was discussed elsewhere (probably w3c/csswg-drafts#3775), but chromium's implementation purposely disagrees with the spec and AFAIK there is no plan to change the implementation. So indeed this shouldn't have landed into the official repo but we need to keep this and probably similar tests for Chromium. So probably the plan forward is to move these tests into |
cc @bkardell |
Note: It passes in its current form in WebKit as well, so it seems that by far the vast, vast majority of users currently experience the opposite of what the spec says? I'm curious if there are bugs from users suggesting that it's wrong? |
Firefox does what the spec say, and as far as I know it doesn't have bugs reported against it. In any case, I know where I stand in this debate, but if disagreement persists, we should argue about it and about what the spec should say, not introduce test that encourage others to ignore the spec and do something else. |
I assume you didn't mean to suggest that this was our intention when we introduced these tests, but just repeating myself: this is a mistake and such a test should really be kept in the internal ones (and it is important for chromium to ensure copying text-transformed text is not broken). |
Coincidentally, I added a similar WPT test a couple days ago to investigate the effect of The bleeding of All the while, I was unaware of this similar WPT issue and all the discourse around the expectations for this feature. 😅 I suppose I don’t have anything new to add here, but will be watching this issue as I consider whether I need to remove my own WPT test or invert their expectations. |
I did not, and I apologize for the phrasing. |
Please note: Chrome changed the behavior of copying to the clipboard a while ago, and now text-transform does not affect the actual text copied to the clipboard. |
@adampage @yisibl Thanks for the context information, it seems we should keep an eye on this. It seems the copy-and-paste thing is still experimented under a flag and the a11y part is to be discussed again. There are a few text-transform tests using selection/copy. As I see
|
@yisibl I noticed you commented there are more cases where the transformed text is used instead of the original text: https://issues.chromium.org/issues/40343523#comment32 ; |
So checking again Instead, it returns a string with the result of https://w3c.github.io/selection-api/#dom-selection-stringifier :
I'm not sure what is referred to by "rendered text" but it looks like it should have the transform applied and so Chromium's behavior aligns with the spec. |
cc: @fred-wang, @mrego , @xiaochengh (as authors / reviewers)
As far as I can tell, https://github.com/web-platform-tests/wpt/blob/master/css/css-text/text-transform/text-transform-upperlower-107.html is in direct contradiction with the spec text.
https://drafts.csswg.org/css-text/#text-transform-property says:
But the test checks the opposite: that the copied text is affected by the transform.
Please be careful when writing / reviewing tests to look at the specification and confirm that it matches the behavior you expect, otherwise this can be very misleading / confusing for other people later on.
In this case, should we simply revert the test (and the corresponding implementation change), or do you want to open a bug against the spec to argue that it should be changed?
cc: @fantasai (as co-editor)
The text was updated successfully, but these errors were encountered: