-
-
Notifications
You must be signed in to change notification settings - Fork 78.9k
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
Simplify Modal Config #33249
Simplify Modal Config #33249
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @GeoSot ❤️
js/src/modal.js
Outdated
|
||
data = new Modal(target, config) | ||
} | ||
const data = Data.get(target, DATA_KEY) || new Modal(target, Manipulator.getDataAttributes(this)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not mentioned anywhere in the docs that the data API reads the configuration from the data attributes of the toggle button also 🤯
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not either tested. I am in favor to omit it. If you agree so. To my eyes it's not a valid behavior
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be omitted IMO if it is not a breaking change 🤔
1468786
to
fd77b4f
Compare
65144da
to
a625763
Compare
a625763
to
4415d54
Compare
4415d54
to
3c31e40
Compare
3c31e40
to
0bc4695
Compare
0bc4695
to
0801f13
Compare
No description provided.