Merge pull request #2532 from nextcloud/token-dropdown
Fix apppassword dropdown issues
This commit is contained in:
commit
0b0f27358f
|
@ -263,6 +263,11 @@ table.nostyle td { padding: 0.2em 0; }
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#sessions .token-list div.configure:after,
|
||||||
|
#apppasswords .token-list div.configure:after {
|
||||||
|
right: 13px;
|
||||||
|
}
|
||||||
|
|
||||||
#sessions .token-list tr.active div.configure > *,
|
#sessions .token-list tr.active div.configure > *,
|
||||||
#apppasswords .token-list tr.active div.configure > *{
|
#apppasswords .token-list tr.active div.configure > *{
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
|
|
|
@ -217,6 +217,10 @@
|
||||||
}));
|
}));
|
||||||
|
|
||||||
var $el = $(el);
|
var $el = $(el);
|
||||||
|
$('body').on('click', _.bind(_this._hideConfigureToken, _this));
|
||||||
|
$el.on('click', '.popovermenu', function(event) {
|
||||||
|
event.stopPropagation();
|
||||||
|
});
|
||||||
$el.on('click', 'a.icon-delete', _.bind(_this._onDeleteToken, _this));
|
$el.on('click', 'a.icon-delete', _.bind(_this._onDeleteToken, _this));
|
||||||
$el.on('click', '.icon-more', _.bind(_this._onConfigureToken, _this));
|
$el.on('click', '.icon-more', _.bind(_this._onConfigureToken, _this));
|
||||||
$el.on('change', 'input.filesystem', _.bind(_this._onSetTokenScope, _this));
|
$el.on('change', 'input.filesystem', _.bind(_this._onSetTokenScope, _this));
|
||||||
|
@ -355,12 +359,18 @@
|
||||||
},
|
},
|
||||||
|
|
||||||
_onConfigureToken: function (event) {
|
_onConfigureToken: function (event) {
|
||||||
|
event.stopPropagation();
|
||||||
|
this._hideConfigureToken();
|
||||||
var $target = $(event.target);
|
var $target = $(event.target);
|
||||||
var $row = $target.closest('tr');
|
var $row = $target.closest('tr');
|
||||||
$row.toggleClass('active');
|
$row.toggleClass('active');
|
||||||
var id = $row.data('id');
|
var id = $row.data('id');
|
||||||
},
|
},
|
||||||
|
|
||||||
|
_hideConfigureToken: function() {
|
||||||
|
$('.token-list tr').removeClass('active');
|
||||||
|
},
|
||||||
|
|
||||||
_onDeleteToken: function (event) {
|
_onDeleteToken: function (event) {
|
||||||
var $target = $(event.target);
|
var $target = $(event.target);
|
||||||
var $row = $target.closest('tr');
|
var $row = $target.closest('tr');
|
||||||
|
|
Loading…
Reference in New Issue