add visibility control buttons for models

This commit is contained in:
Stewart Allen 2022-04-19 20:56:36 -04:00
commit 7278705096
3 changed files with 54 additions and 22 deletions

View file

@ -16,7 +16,10 @@ function build(data, context) {
}
return html;
}
let { type, attr, innr } = data;
let { type, attr, innr, raw } = data;
if (raw) {
return [ raw ];
}
// auto text content
if (typeof attr === 'string') {
attr = { _: attr };
@ -93,6 +96,10 @@ let h = exports({
attr = {};
}
return { type, attr, innr };
},
raw: ( text ) => {
return { raw: text }
}
});