| round: decimals
A number rounded, to 0 decimals unless given: 21.456 | round: 1 → 21.5.
A filter after a | turns a value into what the tile shows: {{ cap.measure_power.value | unit: 'W' }} writes 1.82 kW.
Made for readings: units, temperatures, times.
| round: decimalsA number rounded, to 0 decimals unless given: 21.456 | round: 1 → 21.5.
| decimals: nA number as text with exactly n decimals (0–3): 21 | decimals: 1 → "21.0"; — when empty.
| percentA 0–1 value as a percentage: 0.62 | percent → "62 %".
| unit: 'W', capability?A value with its unit, scaled: 1820 | unit: 'W' → "1.82 kW".
| temp: decimalsA temperature with a degree sign: 21.46 | temp → "21.5°".
| on_offtrue or false as "On" or "Off".
| relative_timeA time as how long ago: cap.onoff.lastUpdated | relative_time → "4 min ago".
| quotePuts a value into a handler as one quoted text, so it can never add steps.
| durationSeconds as a duration: 5400 | duration → "1 h 30 min".
The standard ones that read well in a widget.
| default: valueThe value, or this one when it is empty, false or null.
| append: 'text'Adds text after it.
| prepend: 'text'Adds text before it.
| upcaseIn capitals.
| downcaseIn small letters.
| capitalizeWith a capital first letter.
| truncate: lengthCut to this many characters, ending in “...”.
| replace: 'a', 'b'Every a replaced with b.
| remove: 'text'Every occurrence of the text taken out.
| stripWithout spaces at its start and end.
| split: ','Text cut into a list at each separator.
| join: ', 'A list as one text, joined with the separator.
| sizeHow many items a list has, or characters a text.
| firstThe first item of a list.
| lastThe last item of a list.
| sortA list sorted.
| map: 'key'Each item’s key, as a list.
| where: 'key', valueThe items whose key has that value.
| plus: nAdds a number.
| minus: nTakes a number off.
| times: nMultiplied by a number.
| divided_by: nDivided by a number (whole numbers stay whole).
| modulo: nWhat is left after dividing by a number.
| absWithout its minus sign.
| ceilRounded up to a whole number.
| floorRounded down to a whole number.
| at_least: nThis number at the least.
| at_most: nThis number at the most.
| date: '%H:%M'A time written out: %H:%M is 14:05, %a %e %b is Fri 9 Oct.
| escapeHTML characters escaped (output is escaped anyway).
| url_encodeMade safe for a link’s address.