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

:target css selector not working #2440

Closed
Nemo64 opened this issue Mar 4, 2016 · 3 comments
Closed

:target css selector not working #2440

Nemo64 opened this issue Mar 4, 2016 · 3 comments

Comments

@Nemo64
Copy link
Contributor

Nemo64 commented Mar 4, 2016

I noticed that the :target css selector is not working on amp-page.
I honestly don't know why since the url is updated correctly like on a none-amp page.

It can be used for some css tricks like described in #827

@dvoytenko
Copy link
Contributor

I'm not entirely sure why the :target selector is not working - from what I understand it should work, but most probably it's because with preventDefault on the click event. This, in turn, is necessary because iframe navigation breaks the parent page's history state, hence we were forced to implement it ourselves directly.

@Nemo64
Copy link
Contributor Author

Nemo64 commented Mar 4, 2016

Possible. Accessing the page with #headline already in the url does work fine.

@dvoytenko
Copy link
Contributor

The fix has been merged. It should be in canary tomorrow (Thur).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants