Components
Every hd-* element a widget template can use, with what each takes and an example.
Basics
hd-iconAn icon from the icon registry, by semantic name, or any Phosphor icon.
hd-imageA picture: a web address (`src`, http or https only), one of the device’s own images by name (`image`, e.g. album art as `albumart`, a camera’s `snapshot`) a picture the user uploaded (`upload`, its id) or a person’s (`person`, their id: `settings.who.id`, `people[0].id`). It is fetched without referrer or cookies, loads lazily, fades in, and shows the `fallback` icon while it loads, when there is none and when it fails; grey on e-ink. It fills its parent, so size the element (or its parent) in CSS.
hd-valueA live number that counts to new values (or snaps, on e-ink).
hd-relative-timeTime since a moment, kept up to date (“4 min ago”).
hd-clockThe time or the date, ticking on its own. AM/PM and seconds are parts: ::part(period), ::part(seconds).
hd-analog-clockThe time on a clock face, ticking on its own: square, as big as its parent allows. No second hand on e-ink or without motion (it then moves once a minute). Coloured by --hd-clock-face, --hd-clock-rim, --hd-clock-marks, --hd-clock-hours, --hd-clock-numbers, --hd-clock-hands and --hd-clock-second; parts: ::part(face), ::part(marks), ::part(numbers), ::part(hand), ::part(second), ::part(pin).
hd-slideshowPictures from the web, one after the other, filling the element: each fades over the one before (quickly with less motion, at once without; on e-ink each stays at least five minutes). A picture that doesn’t load is skipped. Colour behind whole pictures: --hd-slideshow-back. E.g. <hd-slideshow src="{{ settings.photos }}" every="10"></hd-slideshow>, with a text setting of addresses one per line.
hd-progressHow far a track is: a thin bar with the time played and the time left, counting on every second while it plays (players report their position only now and then). Parts: ::part(bar), ::part(times).
hd-tipExplains what it wraps in a small bubble in the theme’s colours, instead of the browser’s own title tooltip: on hover, on focus and on a tap (a tap on it never reaches the tile’s own tap). The bubble stays inside the window and isn’t cut off by the tile. E.g. <hd-tip text="{{ m.estimatedText }}">≈</hd-tip>.
Controls
hd-toggleAn on/off switch bound to a boolean capability with bind (or the explicit form: value with data-hd-on-change).
hd-sliderA slider bound to a numeric capability (dim, target temperature, volume…) with bind (or the explicit form: value with data-hd-on-change). It sends the value once, on release. With `fill` it is the whole tile: put it in the tile and the template’s own content inside it (`<hd-slider fill bind="…">name and value</hd-slider>`); its value is a wash rising from the bottom (or growing from the left) with a grip on its edge, dragged anywhere by how far it moves; a tap glides it to the tapped spot, or with `tap="tile"` is the tile’s own tap. A fill slider’s colours are CSS properties, any colour or gradient: `--hd-slider-tone` (the edge and grip), `--hd-slider-fill` (the wash, laid across the whole tile and uncovered as it grows) and `--hd-slider-track` (the rest).
hd-stepper− and + beside a value, for what is set in steps: a setpoint, a volume, a fan speed. Bound to a numeric capability with bind (or the explicit form: value with data-hd-on-change). A press steps once; held, it keeps stepping. The value shows at once, and the steps go out as one command once the presses stop, shown as on their way until the Homey reports back. − and + grey out at the ends. The buttons’ colours are CSS properties: `--hd-stepper-button`, `--hd-stepper-button-text` and `--hd-stepper-button-hover`; parts: ::part(button), ::part(minus), ::part(plus).
hd-segmentedOne of a few choices side by side, the chosen one filled: a thermostat’s mode, a fan’s speed, a house mode. Bound with bind to a capability with choices (an enum), they come from it, in its order and named as Homey names them; otherwise `options` lists them. The choice shows at once and is sent, shown as on its way until the Homey reports it back. More than fit scroll sideways, the chosen one kept in view. With value and data-hd-on-change a handler decides what a choice does (`setState`, `setVariable`).
hd-color-wheelA light’s colour on a wheel (hue round the edge, saturation from the white middle out) and its whites on a disk from cool at the top to warm at the bottom; a light with both shows Colour and White above it. Bound to the light’s light_hue (or light_temperature for a light with whites only), it reads the light’s saturation, temperature and mode itself, and sends the colour on release (with `live` also while it is dragged). Below it the account’s favourite colours, up to 15: a tap sets one, + keeps the colour shown, holding one or right-clicking it offers to remove it. On a paired screen or a share link they are shown, not changed. With hue, saturation, temperature and mode and a data-hd-on-change handler, the handler gets { mode: "color", hue, saturation } or { mode: "temperature", temperature }.
hd-keypadA PIN pad: dots, the keys 1–9, ⌫, 0 and ✓. The digits go to the server and nowhere else; the template never sees them. A right PIN (the account’s, set in Account) runs data-hd-on-unlock, whose event carries nothing; a wrong one shakes, and after 5 wrong in a row every keypad of the account waits 5 minutes. Works on a keyboard too (digits, Backspace, Enter, Escape). E.g. <hd-keypad label="Disarm" data-hd-on-unlock="set('homealarm_state', 'disarmed', settings.alarm.id)"></hd-keypad>.
hd-dialA 270° dial you drag to set a numeric capability (target temperature): the knob is the value, an optional dot shows a second value (the room), and the value sits large in the middle. A value changed from elsewhere (the − and + buttons, the Homey, another screen) springs into place with one small overshoot; under your finger it follows exactly. Reduced motion and e-ink: it moves at once.
hd-triggerStarts a flow or sets a mood when tapped, and shows how it went: its `phase` attribute is idle, running, done or failed, so the template can style each moment. It also plays the motion kit on itself: a pop when it worked, a shake when it failed (reduced motion fades, e-ink shows nothing). Its content is whatever the template puts inside.
Charts and gauges
hd-sparklineA small history line with live updates, an hd-series inside per line (up to 3, any devices, also for one line); no axes, legend or tooltip, so label the lines around it. Lines with the same unit share a scale.
hd-chartA history chart with an hd-series inside per line (up to 8, any devices, also for one line); can sit behind the widget content as a background. Lines with the same unit share an axis, a second unit goes on the right; from two lines on it has a legend, and its tooltip lists every line at that moment.
hd-graphA chart of any data, not only recorded readings: over time or categories as lines, areas, columns, stacked columns, steps, a scatter or a heatmap; or the shares of a whole as a pie, donut, rose, bar list, treemap, funnel or radar. The data comes from a data setting (source="{{ settings.source }}": a data feed, typed JSON, a text variable or Homey values, kept current) or as JSON in data (data="{{ list | json }}", at most 64 KB). Without paths it finds the numbers itself: a number list, [time, value] pairs, { "name": number } objects, or lists of objects. A list drawn as lines runs along its labels; lines drawn as a pie give each line’s latest value. Colours follow the theme’s chart colours; on e-ink the slices are named instead of coloured. What you put inside it (a donut’s total) is centred on the chart. Part: ::part(middle).
hd-seriesOne line of an hd-chart (up to 8) or hd-sparkline (up to 3), written inside it, also for a chart of one line; draws nothing itself. Lines with the same unit share an axis, a different unit goes on the right (two axes at most); from two lines on the chart has a legend, and its tooltip lists every line at that moment with its unit. A line whose device is unavailable steps back and says so; lines over the limit are left out (the editor’s preview and its problems say so, a dashboard doesn’t). A readings setting fills them with a {% for %}: <hd-series bind="{{ r.cap }}" label="{{ r.label }}">.
hd-historyThe history of one or more readings as a tile of its own: a chart with range chips (6 hours to a year), what to show (a meter’s usage, or the average, lowest or highest), detail, and with several readings a total, an average or a line each, and the totals under it. It shows what fits its size, keeps up to date (every minute while visible, every five on e-ink) and says so when a reading isn’t recorded or the plan keeps less than the range. What it is shown with (range, what to show, detail) can be changed on the tile and is kept only while the page is open. Its content (an icon, a name, the readings’ names) becomes its heading; the attributes only say what it starts with.
hd-heatmapA reading’s history as a grid, a row per day and a column per hour, each cell coloured from --hd-heatmap-low to --hd-heatmap-high (the accent) by its value; hovering a cell names its time and value. Reads the history again every ten minutes and says so when the reading isn’t recorded. Parts: ::part(cell), ::part(axis).
hd-sankeyWhere something goes, as bands as wide as how much, from left to right: an hd-flow inside per flow (energy from the grid, solar and the battery to the house and its devices). Each node is named with what passes through it. A node takes the colour of the first flow from it that has one, else the theme’s chart colours in turn. Bands can be hovered for their amount; nothing moves. Parts: ::part(band), ::part(node), ::part(label).
hd-flowOne flow of an hd-sankey, written inside it (often in a {% for %}); draws nothing itself. A flow of 0 or less is left out.
hd-gaugeA 270° dial filled up to a value within a range (target temperature, battery, power); what you put inside it (the value in words) sits a little below the dial’s centre (move it with middle-y), or stands on the base line of a half circle. Part: ::part(middle).
hd-meterA straight bar filled up to a value within a range: progress, a level, how full a tank or bin is. Sideways, or filling from the bottom up with orientation="vertical". It draws only the bar; write the value next to it. Its thickness is the CSS variable --hd-meter-size (10px sideways; the full width upright), its rounding --hd-meter-round. Parts: ::part(bar), ::part(fill).
hd-ringA progress ring for a fraction (battery, solar share, cover position).
hd-barsA period as bars against the previous one: each value a bar in its colour with a soft glow, the previous period’s value behind it as an outline, the running bar (`current`) drawn as “so far”, values below zero hanging under the line. Hover or tap a bar to read both. Bars grow in at full motion only; flat on e-ink. For any series of numbers: an hour by hour day, a week, a month.
Animated devices
hd-bulbA light bulb that blooms on and fades off, and spills its light around it, wider and stronger the brighter it is (the tile clips it). Reduced motion fades; e-ink snaps without a glow.
hd-socketA plug and socket that snap together when it switches on and pull apart when it switches off, with a short pulse from the joint when power starts to flow. Reduced motion fades; e-ink snaps.
hd-lockA lock that locks and unlocks with a springy motion (the shackle drops in and bounces, swings open). While busy the shackle wiggles; when a busy lock ends where it began (refused, or never answered) it shakes.
hd-motionThe motion kit around anything: plays a motion when `value` changes, wiggles while `busy`, and shakes when a command ends with `value` where it began (refused, or never answered). Follows the motion level: reduced motion only fades (a pulse while busy), e-ink shows nothing.
hd-doorA door in its frame for a contact sensor: it swings open on its hinge (past where it stops, and back) with the light of the room beyond showing through, and swings shut with a small bounce. Its colour is the text colour around it. Reduced motion: no swing; e-ink snaps.
hd-coverA window with blinds or curtains, or a garage door, that moves: blinds roll up into the top, curtains bunch at the sides, a sectional garage door rolls up with its light blinking. A new position springs into place (a garage door settles with a thud as it closes); while the motor runs the slats travel, the curtains sway, the garage light blinks. Reduced motion: no travel; e-ink snaps.
hd-alertA sensor or alarm that says it went off, with its own icon: motion pings like a radar (then calmly while it still sees movement), smoke, CO and the siren shake and pulse while on, water ripples under a bobbing drop, a doorbell swings and rings twice. Its colour is the text colour around it. Reduced motion: a still halo; e-ink snaps.
hd-machineA heat pump, heater, pump, fan or air conditioner that answers being switched (a fan spins up or winds down, a pump hums, a heater’s flame blooms), then rests. While it works it shows it in colour with a soft glow (warm heating, cool cooling, accent running) and keeps a calm motion going: a fan turns with its speed, a heat pump’s fan turns, a heater’s flame flickers, a pump pulses, an air conditioner breathes. Reduced motion: no motion; e-ink snaps.
hd-applianceA washing machine, dryer or dishwasher whose own moving part shows it works: a washer’s drum turns and returns, a dryer’s tumbles on, a dishwasher’s spray bobs. Done it rests in the good colour; off it is dimmed. Reduced motion: still; e-ink snaps.
hd-ambienceA living background for a tile that heats or cools: soft reds and ambers rising like warm air, or ice blues sinking and drifting. Stronger the harder it works. Position it behind the content; it never takes a tap. Reduced motion: still colour; e-ink: nothing.
hd-batteryA battery whose charge fills it from the bottom: while it charges a wave rolls on the surface, while it gives power a shimmer runs down through it; low (under 20%) it turns warn. Reduced motion: still; e-ink snaps.
hd-chargeAn EV charger’s bolt: rings pulse out while it charges (faster with more power), in while the car gives power back; paused or plugged in it rests. Reduced motion: still; e-ink snaps.
hd-equalizerSmall equaliser bars that dance while a media player plays and settle low when it pauses. Reduced motion and e-ink: still, at play heights.
hd-playpauseA play/pause button face that turns from one into the other; it shows what a tap does. Reduced motion: a fade; e-ink snaps.
Energy
hd-energy-flowWhere power goes right now: solar, the grid, the home battery and the car around the house, with dots flowing along the lines (arrows on e-ink and with reduced motion). A part left empty is not drawn.
hd-energy-houseThe home as a picture of a house, with its energy pointed out on it: solar on the roof, the grid’s box, the house, the home battery and the car in the garage. A part left empty has no value. Other readings are its hd-house-value children. Values sit beside the house on a wide tile, above and below it on a tall one. The house is one of Tiledash’s (preset), or the owner’s own: its sides as hd-house-side children, which move with navigation and can turn by themselves (rotate); a value shows on the sides its spot is placed on. E-ink shows the first side only, the other sides’ values pointing at its house.
hd-house-valueOne reading pointed out on an hd-energy-house, written inside it; draws nothing itself. A house setting’s values (settings.house.values, what the house shows) or a values setting with the house’s places fill them with a {% for %}: <hd-house-value spot="{{ v.spot }}" label="{{ v.label }}" value="{{ v.text }}" unit="{{ v.unit }}">.
hd-house-sideOne side of the owner’s house on an hd-energy-house, written inside it, up to six; draws nothing itself. A house setting fills them with a {% for %}.
hd-price-barsElectricity prices as bars in their colours, cheap to expensive on each day’s own range (cheap, normal, expensive; below zero its own colour, drawn under the zero line), the slot now marked and the past dimmed. A band can mark the cheapest hours (`highlight-*`), a bracket another stretch, like a car’s charging (`mark-*`); slots not published yet (tomorrow before ~13:00) wait as a dashed outline with `pending` on it. Hover or tap a bar to read its price. The colours follow the theme (`--hd-price-*`), as greys on e-ink. Bars grow in at full motion only. For today and tomorrow: values="{{ prices.bars.values }}" start="{{ prices.bars.start }}" step="{{ prices.bars.step }}" now="{{ prices.now.start }}".
hd-flow-rateA live flow as a small moving glyph: water drops falling, a gas flame flickering, power pulsing, quicker and fuller as more flows; still and faint at zero. Reduced motion and e-ink: still, with its fullness shown.
Maps, plans, weather and cameras
hd-mapA map with a pin for each hd-map-pin inside it; pins glide when they move and the map follows them, framing all or one. Light or dark with the theme. Reduced motion jumps; e-ink is a still map in greys. Lists the places where maps can’t be drawn.
hd-map-pinOne place on an hd-map, written inside it; draws nothing itself.
hd-floorplanOne level of one of your floor plans (drawn under Floor plans), from above and fitted to the tile, in the theme’s colours (white floors and black walls on Paper). room focuses on one room: it fills the tile and the rooms around it fade. An hd-room inside gives a room its values, shown under its name where the room has space; a small tile shows the shapes only. Touching a room does what the plan’s room panel set (tap, hold, double tap: a dashboard, a flow, a mood, a variable); a tap also passes the room’s id to data-hd-on-change. Says so when the plan is loading, paused, gone or its level is. Nothing moves by itself. look="picture" shows a picture of the level made in the floor planner instead (F20). Parts: ::part(room), ::part(wall), ::part(label), ::part(notice), ::part(picture), ::part(ring), ::part(switch).
hd-roomWhat one room of an hd-floorplan says, written inside it (often in a {% for room in settings.plan.rooms %}); draws nothing itself.
hd-sceneA mood or flow on a room’s card (F22), written inside its hd-room (often in a {% for scene in room.scenes %}); draws nothing itself. The card shows them as buttons in this order.
hd-modelOne model of your library on its own, filling its box: a piece of Tiledash’s furniture, one of your own models or one you installed from the Community. In 2.5D from a fixed angle, or in 3D turned any way round (from below, upside down, rolled) by a camera set in the tile’s settings. With a device, a lamp’s shade lights up in the light’s colour while it is on and any other model glows softly around itself. rotate lets people turn it on the dashboard; a drag never counts as a tap. One renderer draws every model on the page; Paper and screens without WebGL 2 show its top view. Says so when no model is picked, it is loading, it couldn’t be loaded or it is gone. Parts: ::part(notice).
hd-map-backdropA still, faded map behind a tile’s content (A.1), centred on a place, with the hd-map-pin children as small marks; the place moves over the picture and a new picture is drawn once it leaves the middle. A picture, not a live map: no WebGL per tile. E-ink: grey. Reduced motion: no fades or gliding.
hd-weather-iconThe weather, drawn from registry icons and moving calmly: the sun turning, the moon under twinkling stars, clouds drifting, rain falling, snow fluttering, lightning striking, fog sliding. Reduced motion and e-ink: still.
hd-weather-skyA living sky that fills its tile, under the content: the condition’s sky by day or night, toned to the theme, with the sun, stars, drifting clouds, rain, snow, lightning or fog moving in it. Reduced motion: still; e-ink: none.
hd-cameraA camera: its latest snapshot as the picture, live video over it while the tile is on screen (the host signals WebRTC with its own session, so the template never sees a token), a status pill (Live, Connecting…, Paused, Snapshot with its age, Unavailable) and, when asked, the camera’s name, a motion badge and an expand mark, over soft scrims. It streams only while visible, while the page is visible and the host allows it, never on e-ink (the snapshot only, refreshed), at most four at a time per page, and retries with backoff when a stream can’t start, showing the snapshot meanwhile. A video a browser can’t play (RTSP) isn’t tried: it shows the snapshot with a note saying so. It fills its parent and sets `data-state` on itself: connecting, live, paused, failed, snapshot or unavailable.
Layout
hd-sectionA part of the widget that folds open and closed under a heading, like the sections of the widget settings; while closed it shows `summary`. To remember it per screen, bind `open` to the widget’s state and keep each change: `open="{{ state.schedule }}" data-hd-on-change="setState('schedule', event.value)"`. Without that it still folds, but starts over when the widget is drawn anew.
hd-tabsPanes (`hd-tab`) of which one shows at a time, switched by tapping the tab bar, swiping across the pane or the arrow keys. To remember the choice per screen, bind `selected` to the widget’s state and keep each change: `selected="{{ state.period }}" data-hd-on-change="setState('period', event.value)"`.
hd-tabOne pane of `hd-tabs`, directly inside it.
hd-placePuts what is inside it (an `hd-icon`, an `hd-image`, anything) at a spot and size of its own, over or behind the rest, relative to the widget (or the nearest element with `position: relative`). What is inside fills its box.
hd-widgetDraws another widget inside this one, filling its box, as a full tile with its own frame, style, taps and history. Name what it shows with `device`, `flow` or `mood`, with the built-in `type` or, left out, the best fit. Only this tile’s own device, and devices, flows and moods its settings chose, are drawn; anything else draws nothing. It is one level deep (a child draws no widgets of its own), and drawn and kept live only while on screen.
hd-dashboardDraws another dashboard of the same Homey inside this widget, live and tappable, filling its box (73). Name it with `dashboard`, the value of a dashboard setting (e.g. {{ settings.dashboard.id }}): a dashboard id written out in the template draws nothing. A narrow box gets its Phone arrangement, a wide one Desktop’s. Drawn and kept live only while on screen; at most 2 per widget, and three dashboards deep. The dashboard it is on, a loop or another Homey’s dashboard show a note instead. Where no dashboard can be drawn (the gallery, the editor’s preview) it is a sketch.
hd-summariesThe summaries of a summaries setting (81): live chips like “3 lights on”, a total, a temperature, an alert or a Homey value, each with its taps, the details of the devices behind it and switching them all. The host works them out over what the tile covers (the whole dashboard, or a Stack page’s tiles) and draws them as the dashboard’s title always had them; more than fit scroll sideways. Nothing where the host draws no summaries (the gallery, the editor’s preview).
hd-frameNot 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.