Skip to content

Commit

Permalink
IBX-3681 - Added selectedLanguage update on location change in UDW (#…
Browse files Browse the repository at this point in the history
…2065)

* Added selectedLanguage update on location change in UDW

* Update src/bundle/ui-dev/src/modules/universal-discovery/components/content-create-widget/content.create.widget.js

Co-authored-by: Michał Grabowski <[email protected]>

Co-authored-by: Michał Grabowski <[email protected]>
  • Loading branch information
mateuszbieniek and GrabowskiM authored Aug 23, 2022
1 parent 1e0ce8c commit 583a04a
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,10 @@ const ContentCreateWidget = () => {
'c-content-create--hidden': !createContentVisible,
});

useEffect(() => {
setSelectedLanguage(preselectedLanguage || firstLanguageCode)
}, [preselectedLanguage, firstLanguageCode]);

useEffect(() => {
window.eZ.helpers.tooltips.parse(refContentTree.current);
}, []);
Expand Down

0 comments on commit 583a04a

Please sign in to comment.