mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-02 17:20:53 +02:00
Fix dropdown delegating and some UI problems (#34014)
The old logic is incomplete. See the comment for the improved logic. Fix #34011 And more fixes: 1. use empty "alt" for images, otherwise the width is not right when the image fails to load 2. remove the "dropdown icon" patch, because it has been clearly done in "dropdown.js" now 3. remove the "dropdown filtered item" patch, added a clear callback, and improve the logic 4. fix global init when a node is removed and added back gain (eg: the "cherry pick" dialog with a dropdown)
This commit is contained in:
1 parent
2089401653
commit
d28a7f9fea
6 files changed
+64
-47
No files matched your search
@@ -752,6 +752,7 @@ $.fn.dropdown = function(parameters) {
|
||||
if(module.is.searchSelection() && module.can.show() && module.is.focusedOnSearch() ) {
|
||||
module.show();
|
||||
}
|
||||
settings.onAfterFiltered.call(element); // GITEA-PATCH: callback to correctly handle the filtered items
|
||||
}
|
||||
;
|
||||
if(settings.useLabels && module.has.maxSelections()) {
|
||||
@@ -3992,6 +3993,8 @@ $.fn.dropdown.settings = {
|
||||
onShow : function(){},
|
||||
onHide : function(){},
|
||||
|
||||
onAfterFiltered: function(){}, // GITEA-PATCH: callback to correctly handle the filtered items
|
||||
|
||||
/* Component */
|
||||
name : 'Dropdown',
|
||||
namespace : 'dropdown',
|
||||
|
||||
Reference in new issue
Block a user