mirror of
https://github.com/umap-project/umap.git
synced 2025-04-28 11:32:38 +02:00
fix: do not cut kbd in tooltip
Co-authored-by: David Larlet <david@larlet.fr>
This commit is contained in:
parent
55babfde34
commit
e1272ec6cd
3 changed files with 6 additions and 1 deletions
|
@ -203,6 +203,10 @@ dt {
|
|||
/* Various */
|
||||
/* *********** */
|
||||
|
||||
.nobr {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.text {
|
||||
word-break: break-word;
|
||||
white-space: pre-line;
|
||||
|
|
|
@ -196,7 +196,7 @@ export default class Help {
|
|||
.split('+')
|
||||
.map((el) => `<kbd>${el}</kbd>`)
|
||||
.join('+')
|
||||
label += ` ${shortcut}`
|
||||
label += ` <span class="nobr">${shortcut}</span>`
|
||||
} else {
|
||||
label += ` (${shortcut})`
|
||||
}
|
||||
|
|
|
@ -126,6 +126,7 @@ export function escapeHTML(s) {
|
|||
'frameborder',
|
||||
'scrolling',
|
||||
'controls',
|
||||
'class',
|
||||
],
|
||||
ALLOWED_ATTR: ['href', 'src', 'width', 'height', 'style', 'dir', 'title', 'type'],
|
||||
// Added: `geo:` URL scheme as defined in RFC5870:
|
||||
|
|
Loading…
Reference in a new issue