-
Notifications
You must be signed in to change notification settings - Fork 13
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
EZP-31417: Added tooltips to UDW #278
EZP-31417: Added tooltips to UDW #278
Conversation
9da4564
to
99e1b5d
Compare
useEffect(() => { | ||
window.eZ.helpers.tooltips.parse(window.document.querySelector('.c-selected-locations')); | ||
window.eZ.helpers.tooltips.hideAll(); | ||
window.document.querySelector('.c-selected-locations__toggle-button').dataset.originalTitle = togglerLabel; |
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.
ref
@@ -10,6 +10,10 @@ const ContentTable = ({ count, itemsPerPage, items, activePageIndex, title, onPa | |||
const modifiedLabel = Translator.trans(/*@Desc("Modified")*/ 'content_table.modified', {}, 'universal_discovery_widget'); | |||
const contentTypeLabel = Translator.trans(/*@Desc("Content Type")*/ 'content_table.content_type', {}, 'universal_discovery_widget'); | |||
|
|||
useEffect(() => { | |||
window.eZ.helpers.tooltips.parse(window.document.querySelector('.c-content-table')); |
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.
ref?
@lucasOsti please watch the gif and fix the issues |
42e7897
to
d61f3a5
Compare
const widgetClassName = createCssClassNames({ | ||
'c-content-create': true, | ||
'c-content-create--hidden': !createContentVisible, | ||
}); | ||
|
||
useEffect(() => { | ||
window.eZ.helpers.tooltips.parse(window.document.querySelector('.c-content-create')); |
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.
Could it be done with ref instead of querySelector?
useEffect(() => { | ||
window.eZ.helpers.tooltips.hideAll(window.document.querySelector('.c-udw-tab')); | ||
|
||
if (refToggleSelectionButton.current.getAttribute('data-original-title')) { |
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.
I would add some comment here explaining what's happening here
Added tooltips to UDW
Checklist:
$ composer fix-cs
)