-
Notifications
You must be signed in to change notification settings - Fork 116
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
Validate value from data-sidebar-hidden #63
Comments
I think you do have a valid point. However, isn't this solvable using the built-in |
No I'm not using the built-in js, forgot to mention that. |
I will look more into this. I really do want the framework to me more usable with Vue/React/Angular/Svelte/whatever. In that regard, it needs a little more work and documentation. Till then, copying the |
I was just testing and ran into this same issue, I think. I'm not doing anything fancy, just trying to set the initial state of when loaded. I expected that if I set this value to something other than "hidden" it would show the sidebar -- nothing worked. data-sidebar-hidden="hidden" << sidebar initially hidden |
Problem
I'm trying to toggle sidebar with Vuejs:
It doens't work because on CSS you're not validating its value, only if the attribute exists (https://github.com/halfmoonui/halfmoon/blob/master/css/halfmoon-variables.css#L3228)
Proposed solution
I think it's better to just use normal classes for this, isn't it? Or check the value of the attribute (e.g. hidden/visible or true/false).
Obviously there's ways to workaround, but it's not intuitive. This is how you disable attributes/props on Vuejs in general.
Appreciate the work you put on Halfmoon, loving it.
The text was updated successfully, but these errors were encountered: