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

Add test for :has(:target) change #33890

Merged
merged 3 commits into from May 11, 2022
Merged

Conversation

muan
Copy link
Contributor

@muan muan commented May 1, 2022

When :target changes, CSS properties via :has(:target) don't seem to be applied.

Here's a video demonstrating the problem in Safari Version 15.4 (17613.1.17.1.13).

has-target.mov

As shown, the rules are there, but the page only updates when I manually edit the stylesheet via inspector.


It does not work on the following browser/versions I've tested with:

  • Safari Version 15.4 (17613.1.17.1.13)
  • Safari Technology Preview, Release 143 (Safari 15.4, WebKit 17614.1.7.7)
  • Chrome Beta Version 102.0.5005.27 with Experimental Web Platform features enabled

Worth noting–on the test page, if I manually click the fragment links, the text colors would not update (which is what this test is for); but while running the automatic test, the text color is updated on :target change, even though the assertion does still fail.

@nt1m nt1m enabled auto-merge (squash) May 11, 2022 20:25
@nt1m nt1m merged commit de625be into web-platform-tests:master May 11, 2022
@muan muan deleted the has-target branch May 12, 2022 23:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants