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

Implement some css function, most notably attr() #600

Merged
merged 5 commits into from
Sep 15, 2024

Conversation

Sharktheone
Copy link
Member

We now can use the attr() function, and it will be resolved during selector matching.

With this we can support the bgcolor attribute which is frequently used on the hacker news website.

After this PR https://news.ycombinator.com looks like this in gosub:
Screenshot_20240914_162112

Best notably is that if we wanted to load the website before, we were just seeing a black screen. If you changed the background color or the default text color, you could see text vertically stacked, so it wasn't even reassembling the layout of it.

We currently also don't support tables, so all the tables on the site are broken, but it still looks quite okay.

I've also started to begin implementing CSS variables, however I want to wait for #582 to be merged, because it changes so much about the node type.

Previously, we were skipping the user agent stylesheet, because it was so large and with an older version of the syntax matcher it took ages to validate.

@Sharktheone Sharktheone added the css3 Any issues related to CSS3 label Sep 14, 2024
@Sharktheone Sharktheone self-assigned this Sep 14, 2024
@Sharktheone Sharktheone merged commit 503c4fb into gosub-io:main Sep 15, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
css3 Any issues related to CSS3
Projects
Status: 🎯 Done
Development

Successfully merging this pull request may close these issues.

2 participants