-
Notifications
You must be signed in to change notification settings - Fork 12
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
Introduced info text for dropdown #619
Conversation
8409634
to
a199ea1
Compare
a41fed6
to
86686cf
Compare
@@ -33,6 +33,8 @@ define([], function() { | |||
shadow: true, // if box-shadow should be shown | |||
toggleClassOn: null, // container to set is-active class | |||
valueName: 'name', // name of text property | |||
infoName: 'info', // name of info property (used to display hover info) | |||
clickedName: 'clickedInfo', // name of info property (used to display clicked info) |
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.
Why name? What is this actually doing? Are these the translations?
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.
they are property names
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.
And what do these properties contain?
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.
a info for a hover and the info when you click on the item
86686cf
to
c1d4958
Compare
&& !( | ||
$(event.target).hasClass('husky-dropdown-item') | ||
|| $(event.target).parents().hasClass('husky-dropdown-item') | ||
) |
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.
Can't the previous two &&
be connected to one? Maybe some filter that checks if the element has one class and doesn't have another one? Maybe also the two next statements can somehow be included like this.
c1d4958
to
f89aa9b
Compare
// reapply the hide listener | ||
if (!!event | ||
&& ($(event.target).is('.husky-dropdown-trigger:not(.husky-dropdown-item), .highlight-animation') | ||
|| $(event.target).parents().is('.husky-dropdown-trigger:not(.husky-dropdown-item), .highlight-animation') |
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.
Didn't you put the result of $(event.target)
into its own variable.
f89aa9b
to
91ad1c1
Compare
This PR added info texts for dropdown items. Additionally the stopPropagation is removed to use this event outside of the dropdown (sulu for copy to clipboard sulu/sulu#2155).