Cleaner visual for adding and removing of new hotkeys
This commit is contained in:
parent
1e4b8f3870
commit
22b9b328a5
@ -133,7 +133,7 @@ hr {
|
||||
|
||||
.btn-enter {
|
||||
background-color: #00b1e2;
|
||||
margin-left: auto;
|
||||
margin: auto 4px;
|
||||
}
|
||||
|
||||
.reset-area {
|
||||
@ -209,8 +209,7 @@ hr {
|
||||
|
||||
.addHotkey {
|
||||
opacity: 0;
|
||||
margin-left: auto;
|
||||
margin-right: 4px;
|
||||
margin: auto 4px;
|
||||
transition: opacity 0.4s ease-out;
|
||||
}
|
||||
|
||||
@ -218,3 +217,7 @@ hr {
|
||||
opacity: 1;
|
||||
transition: opacity 0.2s linear;
|
||||
}
|
||||
|
||||
.setting > div:first-of-type {
|
||||
margin: auto 4px auto auto;
|
||||
}
|
||||
|
@ -70,8 +70,8 @@ function updateHotkey(element, newVal, index) {
|
||||
// remove the hotkey at the index provided
|
||||
newSettings.hotkeys.codes[parentSection.id].splice(index, 1);
|
||||
} else {
|
||||
// add the new hotkey to the end of the stored hotkeys
|
||||
newSettings.hotkeys.codes[parentSection.id].push(newVal);
|
||||
// add the new hotkey to the beginning of the stored hotkeys
|
||||
newSettings.hotkeys.codes[parentSection.id].unshift(newVal);
|
||||
}
|
||||
|
||||
chrome.storage.local.set({ "extension-settings": newSettings }, function () {
|
||||
|
Loading…
x
Reference in New Issue
Block a user