Skip to content

Commit 9cfee74

Browse files
authored
fix(schema): escape tooltip label to make sure samples are shown correctly COMPASS-10814 (#8222)
fix(schema): escape tooltip label to make sure samples are shown correctly
1 parent c9082d5 commit 9cfee74

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

packages/compass-schema/src/modules/shared.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ const minicharts_d3fns_shared = {
4343
},
4444

4545
tooltip: function (label, count) {
46+
label = label.replaceAll(/</g, '&lt;').replaceAll(/>/g, '&gt;');
4647
return `
4748
<div class="tooltip-wrapper">
4849
<div class="tooltip-label">${label}</div>

0 commit comments

Comments
 (0)