mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-01-24 15:26:46 -06:00
Do not close the menu, when clicking on the menu with checkbox.
Introduced a class 'noclose'. Then - menu-item having this class will not propograte the events to its parent, hence - it will not be closed. Some of the CSS applicable only to the immediate buttons only, and not the grand-children.
This commit is contained in:
parent
26e9ceaf48
commit
9dd3aeadb5
@ -351,15 +351,15 @@ iframe {
|
||||
border-left-style: solid
|
||||
}
|
||||
|
||||
.pg-prop-btn-group button {
|
||||
.pg-prop-btn-group > button {
|
||||
margin: 2px 3px 2px 0px;
|
||||
}
|
||||
|
||||
.pg-prop-btn-group button:first-child {
|
||||
.pg-prop-btn-group > button:first-child {
|
||||
margin-left: 3px;
|
||||
}
|
||||
|
||||
.pg-prop-btn-group button:last-child {
|
||||
.pg-prop-btn-group > button:last-child {
|
||||
margin-right: 3px;
|
||||
}
|
||||
|
||||
|
@ -159,6 +159,7 @@ define(
|
||||
"click #btn-auto-commit": "on_auto_commit",
|
||||
"click #btn-auto-rollback": "on_auto_rollback",
|
||||
"click #btn-clear-history": "on_clear_history",
|
||||
"click .noclose": 'do_not_close_menu',
|
||||
"change .limit": "on_limit_change"
|
||||
},
|
||||
|
||||
@ -217,13 +218,13 @@ define(
|
||||
'</button>',
|
||||
'<ul class="dropdown-menu dropdown-menu">',
|
||||
'<li>',
|
||||
'<a id="btn-auto-commit" href="#">',
|
||||
'<a id="btn-auto-commit" href="#" class="noclose">',
|
||||
'<i class="auto-commit fa fa-check" aria-hidden="true"></i>',
|
||||
'<span> {{ _('Auto-Commit') }} </span>',
|
||||
'<span> {{ _('Auto Commit') }} </span>',
|
||||
'</a>',
|
||||
'<a id="btn-auto-rollback" href="#">',
|
||||
'<a id="btn-auto-rollback" href="#" class="noclose">',
|
||||
'<i class="auto-rollback fa fa-check visibility-hidden" aria-hidden="true"></i>',
|
||||
'<span> {{ _('Auto-Rollback') }} </span>',
|
||||
'<span> {{ _('Auto Rollback') }} </span>',
|
||||
'</a>',
|
||||
'</li>',
|
||||
'</ul>',
|
||||
@ -768,6 +769,9 @@ define(
|
||||
self,
|
||||
self.handler
|
||||
);
|
||||
},
|
||||
do_not_close_menu: function(ev) {
|
||||
ev.stopPropagation();
|
||||
}
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user