-
Notifications
You must be signed in to change notification settings - Fork 16
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
IBX-6398: Adjust admin-ui for Image Picker component #956
Conversation
'adminUiConfig.universalDiscoveryWidget.tabs', | ||
[ | ||
{ | ||
id: 'image_picker', |
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.
adding the same tab with a different id? could you explain why?
additionally: admin-ui should not have any knowledge about image-picker
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 removed it. The backend part for overwriting config will be done in a separate PR.
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.
Except Darek's comment (and possibly mine about memo)
@@ -137,7 +137,23 @@ export const SearchTextContext = createContext(); | |||
export const DropdownPortalRefContext = createContext(); | |||
|
|||
const UniversalDiscoveryModule = (props) => { | |||
const { tabs } = ibexa.adminUiConfig.universalDiscoveryWidget; | |||
const { tabs: tabsWithPriority } = ibexa.adminUiConfig.universalDiscoveryWidget; | |||
const tabs = tabsWithPriority.reduce((tabsPrioritized, tabToAdd) => { |
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.
maybe put it in memo? Not sure if it's easy as you have to pass array
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 removed this approach.
5af47c7
to
d49ad07
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
Checklist:
$ composer fix-cs
)