Skip to content

hd-frame

Attributes and example

hd-frame

Not written in templates (83.10): Tiledash draws it around a widget with a script, as the sandboxed frame over the whole tile that draws the template and style and runs the script. What is inside it shows where the frame doesn’t run.

AttributeWhat it is
fillLays the frame over the whole tile and leaves the layout of what is inside the tag alone.
<hd-frame><p>{{ device.name }}</p></hd-frame>

Styling

Set CSS variables on the component element. Its internal elements live in Shadow DOM; only the exposed named parts can be styled with ::part.

--hd-font
CSS input read by hd-frame.
--hd-frame-bleed-block
CSS input read by hd-frame.
--hd-frame-bleed-inline
CSS input read by hd-frame.
--hd-surface
A tile’s colour.
--hd-text-muted
Labels and secondary text.

Exposed parts

hd-frame::part(off-note) {  /* Your styles */}

Style the host

hd-frame {  --hd-accent: #2563eb;  max-width: 100%;}
Theme variables