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

don't apply watching focus if focus active #402

Merged
merged 1 commit into from
Feb 29, 2024

Conversation

faebiedev
Copy link
Contributor

i have very little experience with javascript so if there's some bad practice/ugly code stuff that needs fixed pls lmk

this should solve #372, sets a MutationObserver to check if focus is on the ui element classlist or not. If focus is added or removed, sets watching-focus state accordingly

@faebiedev faebiedev force-pushed the watching-focus-observer branch 3 times, most recently from 845a84b to d3dee44 Compare January 15, 2024 09:06
Copy link
Contributor

@11k 11k left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think any JS is necessary. This is more a CSS specificity issue. Styles for the .focus selector should override styles for the .watching-focus selector.

@faebiedev faebiedev changed the title Make watching focus active state dependent on user focus don't apply watching focus if focus active Feb 25, 2024
@faebiedev
Copy link
Contributor Author

I don't think any JS is necessary. This is more a CSS specificity issue. Styles for the .focus selector should override styles for the .watching-focus selector.

i'm very dumb, updated code

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.

Focusing a user while watching mode is active seems like it does nothing
2 participants