add overview options to decoration in demo

This commit is contained in:
meganrogge
2022-03-15 21:05:14 -04:00
parent c277fb742d
commit a0a7abbf49
+1 -2
View File
@@ -547,13 +547,12 @@ function loadTest() {
function addDecoration() {
term.options['overviewRulerWidth'] = 15;
const marker = term.addMarker(1);
const decoration = term.registerDecoration({ marker });
const decoration = term.registerDecoration({ marker, overviewRulerOptions: { color: '#ef2929'} });
decoration.onRender((e) => {
if (e.classList.value === 'xterm-decoration') {
e.style.backgroundColor = '#ef2929';
}
});
term.registerDecoration({marker, overviewRulerOptions: { color: '#ef2929'}})
}
function addOverviewRuler() {