Add minimal CSS for kbd tag

This commit is contained in:
Yohan Boniface 2023-12-11 11:32:37 +01:00
parent 5a6cd9a5b5
commit 2f89a76e08
2 changed files with 11 additions and 1 deletions

View file

@ -47,6 +47,16 @@ p {
margin-top: 14px; margin-top: 14px;
margin-bottom: 14px; margin-bottom: 14px;
} }
kbd {
border: 1px solid #b4b4b4;
box-shadow:
0 1px 1px rgba(0, 0, 0, 0.2),
0 2px 0 0 rgba(255, 255, 255, 0.7) inset;
border-radius: 3px;
padding: 1px 4px;
display: inline-block;
white-space: nowrap;
}
/* /*
* List * List

View file

@ -488,7 +488,7 @@ L.U.Help = L.Class.extend({
shortcut = shortcut.split('+').map((el) => `<kbd>${el}</kbd>`).join('+') shortcut = shortcut.split('+').map((el) => `<kbd>${el}</kbd>`).join('+')
} }
const modifier = this.isMacOS ? 'Cmd' : 'Ctrl' const modifier = this.isMacOS ? 'Cmd' : 'Ctrl'
label += ` (${shortcut.replace('Modifier', modifier)})` label += ` ${shortcut.replace('Modifier', modifier)}`
return label return label
}, },