Skip to content

Commit 8215379

Browse files
committed
update custom button separator and shortcut indicator always
1 parent 4edaa3b commit 8215379

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

popup-page-scripts/popup-page-customButtons.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ function createButtonElement(button, index) {
2020

2121
if (button.separator) {
2222
buttonItem.classList.add('separator-item');
23-
// Updated separator with labeled text
2423
buttonItem.innerHTML = `
2524
<div class="separator-line"></div>
2625
<span class="separator-text">Separator</span>
@@ -35,7 +34,10 @@ function createButtonElement(button, index) {
3534
<label class="checkbox-row">
3635
<input type="checkbox" class="autosend-toggle" ${button.autoSend ? 'checked' : ''}>
3736
<span>Auto-send</span>
38-
<span class="shortcut-indicator">Ctrl+${index + 1}</span>
37+
${ index < 10
38+
? `<span class="shortcut-indicator">[Ctrl+${index === 9 ? 0 : index + 1}]</span>`
39+
: ''
40+
}
3941
</label>
4042
<button class="delete-button danger">Delete</button>
4143
`;
@@ -45,6 +47,7 @@ function createButtonElement(button, index) {
4547
}
4648

4749

50+
4851
/**
4952
* Updates the list of custom buttons in the interface.
5053
*/

0 commit comments

Comments
 (0)