Centralize CSS for confirm delete buttons and grab handles

This commit is contained in:
djmaze 2021-01-18 17:11:53 +01:00
parent 267b744ef3
commit a80b17e011
11 changed files with 26 additions and 129 deletions

View file

@ -47,3 +47,22 @@ html.mobile *, html.rl-mobile * {
input[type="search"]{ input[type="search"]{
box-sizing: content-box; box-sizing: content-box;
} }
.button-confirm-delete {
margin-right: 15px;
opacity: 0;
visibility: hidden;
}
.button-confirm-delete.delete-access {
margin-right: 0;
opacity: 1;
visibility: visible;
}
.drag-handle {
color: #eee;
cursor: grab;
}
tr:hover .drag-handle {
color: #aaa;
}

View file

@ -20,14 +20,6 @@
line-height: 30px; line-height: 30px;
} }
.drag-handle {
color: #eee;
}
tr:hover .drag-handle {
color: #aaa;
}
.account-img, .identity-img { .account-img, .identity-img {
font-size: 12px; font-size: 12px;
margin-right: 5px; margin-right: 5px;
@ -68,26 +60,6 @@
cursor: pointer; cursor: pointer;
} }
.drag-handle {
cursor: pointer;
cursor: all-scroll;
}
.button-delete {
margin-right: 15px;
margin-top: 5px;
visibility: hidden;
opacity: 0;
}
.delete-access {
&.button-delete {
visibility: visible;
margin-right: 0;
opacity: 1;
}
}
.delete-account { .delete-account {
cursor: pointer; cursor: pointer;
opacity: 0.5; opacity: 0.5;
@ -102,21 +74,6 @@
cursor: pointer; cursor: pointer;
} }
.button-delete {
margin-right: 15px;
margin-top: 5px;
visibility: hidden;
opacity: 0;
}
.delete-access {
&.button-delete {
visibility: visible;
margin-right: 0;
opacity: 1;
}
}
.delete-identity { .delete-identity {
cursor: pointer; cursor: pointer;
opacity: 0.5; opacity: 0.5;

View file

@ -24,14 +24,6 @@
} }
} }
.drag-handle {
color: #eee;
}
tr:hover .drag-handle {
color: #aaa;
}
.filter-img { .filter-img {
font-size: 12px; font-size: 12px;
margin-right: 5px; margin-right: 5px;
@ -64,26 +56,6 @@
cursor: pointer; cursor: pointer;
} }
.drag-handle {
cursor: pointer;
cursor: all-scroll;
}
.button-delete {
margin-right: 15px;
margin-top: 5px;
visibility: hidden;
opacity: 0;
}
.delete-access {
&.button-delete {
visibility: visible;
margin-right: 0;
opacity: 1;
}
}
.delete-filter { .delete-filter {
cursor: pointer; cursor: pointer;
opacity: 0.5; opacity: 0.5;

View file

@ -82,14 +82,6 @@
opacity: 0; opacity: 0;
} }
.delete-access {
&.button-delete {
visibility: visible;
margin-right: 0;
opacity: 1;
}
}
.delete-folder, .subscribe-folder, .unsubscribe-folder, .check-folder, .uncheck-folder { .delete-folder, .subscribe-folder, .unsubscribe-folder, .check-folder, .uncheck-folder {
cursor: pointer; cursor: pointer;
opacity: 0.6; opacity: 0.6;

View file

@ -41,21 +41,6 @@
.open-pgp-key-item { .open-pgp-key-item {
.button-delete {
margin-right: 15px;
margin-top: 5px;
visibility: hidden;
opacity: 0;
}
.delete-access {
&.button-delete {
visibility: visible;
margin-right: 0;
opacity: 1;
}
}
.delete-open-pgp-key, .view-open-pgp-key { .delete-open-pgp-key, .view-open-pgp-key {
cursor: pointer; cursor: pointer;
opacity: 0.7; opacity: 0.7;

View file

@ -20,14 +20,6 @@
line-height: 30px; line-height: 30px;
} }
.drag-handle {
color: #eee;
}
tr:hover .drag-handle {
color: #aaa;
}
.template-img { .template-img {
font-size: 12px; font-size: 12px;
margin-right: 5px; margin-right: 5px;
@ -53,26 +45,6 @@
cursor: pointer; cursor: pointer;
} }
.drag-handle {
cursor: pointer;
cursor: all-scroll;
}
.button-delete {
margin-right: 15px;
margin-top: 5px;
visibility: hidden;
opacity: 0;
}
.delete-access {
&.button-delete {
visibility: visible;
margin-right: 0;
opacity: 1;
}
}
.delete-template { .delete-template {
cursor: pointer; cursor: pointer;
opacity: 0.5; opacity: 0.5;

View file

@ -32,7 +32,7 @@
<span class="account-name" data-bind="text: email"></span> <span class="account-name" data-bind="text: email"></span>
</td> </td>
<td> <td>
<a class="btn btn-small btn-small-small btn-danger pull-right button-delete button-delete-transitions" data-bind="visible: canBeDeleted, css: {'delete-access': deleteAccess}, click: function(oAccount) { $root.deleteAccount(oAccount); }"> <a class="btn btn-small btn-small-small btn-danger pull-right button-confirm-delete button-delete-transitions" data-bind="visible: canBeDeleted, css: {'delete-access': deleteAccess}, click: function(oAccount) { $root.deleteAccount(oAccount); }">
<span class="i18n" data-i18n="SETTINGS_ACCOUNTS/DELETING_ASK"></span> <span class="i18n" data-i18n="SETTINGS_ACCOUNTS/DELETING_ASK"></span>
</a> </a>
</td> </td>
@ -82,7 +82,7 @@
</span> </span>
</td> </td>
<td> <td>
<a class="btn btn-small btn-small-small btn-danger pull-right button-delete button-delete-transitions" data-bind="visible: canBeDeleted, css: {'delete-access': deleteAccess}, click: function(oIdentity) { $root.deleteIdentity(oIdentity); }"> <a class="btn btn-small btn-small-small btn-danger pull-right button-confirm-delete button-delete-transitions" data-bind="visible: canBeDeleted, css: {'delete-access': deleteAccess}, click: function(oIdentity) { $root.deleteIdentity(oIdentity); }">
<span class="i18n" data-i18n="SETTINGS_ACCOUNTS/DELETING_ASK"></span> <span class="i18n" data-i18n="SETTINGS_ACCOUNTS/DELETING_ASK"></span>
</a> </a>
</td> </td>

View file

@ -87,7 +87,7 @@
<span class="filter-sub-name" data-bind="text: nameSub()"></span> <span class="filter-sub-name" data-bind="text: nameSub()"></span>
</td> </td>
<td> <td>
<a class="btn btn-small btn-small-small btn-danger pull-right button-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function(oFilter) { $root.deleteFilter(oFilter); }"> <a class="btn btn-small btn-small-small btn-danger pull-right button-confirm-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function(oFilter) { $root.deleteFilter(oFilter); }">
<span class="i18n" data-i18n="SETTINGS_FILTERS/DELETING_ASK"></span> <span class="i18n" data-i18n="SETTINGS_FILTERS/DELETING_ASK"></span>
</a> </a>
</td> </td>

View file

@ -8,7 +8,7 @@
autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"
data-bind="value: nameForEdit, visible: edited, hasfocus: edited, onEnter: function () { $root.folderEditOnEnter($data); }, onEsc: function () { $root.folderEditOnEsc($data); }" /> data-bind="value: nameForEdit, visible: edited, hasfocus: edited, onEnter: function () { $root.folderEditOnEnter($data); }, onEsc: function () { $root.folderEditOnEsc($data); }" />
<a class="btn btn-small btn-small-small btn-danger pull-right button-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function() { $root.deleteFolder($data); }"> <a class="btn btn-small btn-small-small btn-danger pull-right button-confirm-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function() { $root.deleteFolder($data); }">
<span class="i18n" data-i18n="SETTINGS_FOLDERS/DELETING_ASK"></span> <span class="i18n" data-i18n="SETTINGS_FOLDERS/DELETING_ASK"></span>
</a> </a>
</td> </td>

View file

@ -49,7 +49,7 @@
<div class="open-pgp-key-user-address" data-bind="text: $data"></div> <div class="open-pgp-key-user-address" data-bind="text: $data"></div>
<!-- /ko --> <!-- /ko -->
</span> </span>
<a class="btn btn-small btn-small-small btn-danger pull-right button-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function(openPgpKey) { $root.deleteOpenPgpKey(openPgpKey); }"> <a class="btn btn-small btn-small-small btn-danger pull-right button-confirm-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function(openPgpKey) { $root.deleteOpenPgpKey(openPgpKey); }">
<span class="i18n" data-i18n="SETTINGS_OPEN_PGP/DELETING_ASK"></span> <span class="i18n" data-i18n="SETTINGS_OPEN_PGP/DELETING_ASK"></span>
</a> </a>
</td> </td>
@ -78,7 +78,7 @@
</div> </div>
<!-- /ko --> <!-- /ko -->
</span> </span>
<a class="btn btn-small btn-small-small btn-danger pull-right button-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function(oOpenPGP) { $root.deleteOpenPgpKey(oOpenPGP); }"> <a class="btn btn-small btn-small-small btn-danger pull-right button-confirm-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess()}, click: function(oOpenPGP) { $root.deleteOpenPgpKey(oOpenPGP); }">
<span class="i18n" data-i18n="SETTINGS_OPEN_PGP/DELETING_ASK"></span> <span class="i18n" data-i18n="SETTINGS_OPEN_PGP/DELETING_ASK"></span>
</a> </a>
</td> </td>

View file

@ -31,7 +31,7 @@
<span class="template-name" data-bind="text: name"></span> <span class="template-name" data-bind="text: name"></span>
</td> </td>
<td> <td>
<a class="btn btn-small btn-small-small btn-danger pull-right button-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess}, click: function(oTemplate) { $root.deleteTemplate(oTemplate); }"> <a class="btn btn-small btn-small-small btn-danger pull-right button-confirm-delete button-delete-transitions" data-bind="css: {'delete-access': deleteAccess}, click: function(oTemplate) { $root.deleteTemplate(oTemplate); }">
<span class="i18n" data-i18n="SETTINGS_TEMPLATES/DELETING_ASK"></span> <span class="i18n" data-i18n="SETTINGS_TEMPLATES/DELETING_ASK"></span>
</a> </a>
</td> </td>