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

Replace css_browser_selector with our own implementation #2854

Merged
merged 4 commits into from
Nov 30, 2023

Conversation

abdnh
Copy link
Collaborator

@abdnh abdnh commented Nov 29, 2023

Closes #2846

The classes are actually added to the root element rather than body. css_browser_selector adds the following classes in my Windows device for example: webkit chrome chrome112 win win8 js non-retina orientation_landscape maxw_1920. Only win and chrome are supported by this basic implementation.

MDN reference: https://developer.mozilla.org/en-US/docs/Web/HTTP/Browser_detection_using_the_user_agent

@dae
Copy link
Member

dae commented Nov 30, 2023

Thanks Abdo! Always nice when we can drop a trivial dependency :-) I don't recall seeing any of those other classes in use in card templates, so there should hopefully be minimal impact to existing templates.

@dae dae merged commit dc3bd3e into ankitects:main Nov 30, 2023
@abdnh abdnh deleted the browser-selector branch November 30, 2023 01:24
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.

Write our own css_browser_selector implemetation
2 participants