Fixed dropdown lazy initialization for dynamically populated translation selects#1834
Open
mikadamczyk wants to merge 1 commit intomainfrom
Open
Fixed dropdown lazy initialization for dynamically populated translation selects#1834mikadamczyk wants to merge 1 commit intomainfrom
mikadamczyk wants to merge 1 commit intomainfrom
Conversation
|
tischsoic
approved these changes
Feb 24, 2026
albozek
approved these changes
Feb 24, 2026
dew326
approved these changes
Feb 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Related PRs:
Description:
This PR fixes an
ibexa.core.Dropdowninitialization edge case that caused empty option lists in dynamically populated translation modals (for example, the Content Tree “Add translation” modal).The regression appeared when a dropdown was initialized while its underlying
<select>had no options yet, and the options were added later by JavaScript. In that case, the dropdown instance was left in a partially initialized state and did not properly reflect later option updates.Root cause:
Dropdown.init()returned early when the source<select>had no options. This prevented full UI initialization (itemsPopover) and also blocked proper refresh behavior for options added later.As a result, consumers who dynamically rebuild
<select>options (like Content Tree translation modal) ended up with:<select>containing correct optionsWhat changed
ibexa.core.DropdowninitializeDropdownUI()recreateOptions()Why this fix is in admin-ui
The issue is in the shared dropdown component lifecycle, not in Content Tree logic itself. Fixing it in admin-ui removes the need for consumer-level workarounds (manual instance reset / re-init) and benefits any feature that uses dynamically populated dropdown options. If this fix is merged, then https://github.com/ibexa/content-tree/pull/113 should be closed.
Impact
For QA:
Documentation: