Merge branch 'master' into htmlserialize
This commit is contained in:
@@ -150,6 +150,7 @@ if (document.location.pathname === '/test') {
|
||||
document.getElementById('htmlserialize').addEventListener('click', htmlSerializeButtonHandler);
|
||||
document.getElementById('custom-glyph').addEventListener('click', writeCustomGlyphHandler);
|
||||
document.getElementById('load-test').addEventListener('click', loadTest);
|
||||
document.getElementById('add-decoration').addEventListener('click', addDecoration);
|
||||
}
|
||||
|
||||
function createTerminal(): void {
|
||||
@@ -541,3 +542,12 @@ function loadTest() {
|
||||
term._core._onData.fire('\x03');
|
||||
});
|
||||
}
|
||||
|
||||
function addDecoration() {
|
||||
const marker = term.addMarker(1);
|
||||
const decoration = term.registerDecoration({ marker });
|
||||
term.write('');
|
||||
decoration.onRender(() => {
|
||||
decoration.element.style.backgroundColor = 'red';
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user