Field types
Xplain reads each field's own settings, so its notes are about your field — the options you defined, the columns you named, the entry types you allowed.
| Field type | What Xplain reads | The Twig | Leading advice |
|---|---|---|---|
| Plain Text | multi-line, code, character limit | {{ entry.x }}, \|nl2br when multi-line | Twig escapes it; leave \|raw off |
| Email, URL | — | an <a> with mailto: or href | — |
| Link | allowed link types | {{ entry.x.link }}, .url, .label | .element for entry links |
| Number, Range | decimals, min/max, prefix/suffix | \|number | zero is falsy: is not null |
| Money | currency, min/max | \|money | .amount is in minor units |
| Lightswitch | default | {% if entry.x %} | plain boolean, no .value |
| Date, Time | date/time/time zone | \|date(…) with a <time> element | stored UTC, shown in site time |
| Color | — | .hex, .rgb, .hsl | .luma for text contrast |
| Country | — | .name, .countryCode | localised name |
| Icon | — | the icon name | Craft stores the name only |
| JSON | — | keys straight off the value | already decoded |
| Dropdown, Radio Buttons, Button Group | option values | {{ entry.x }}, == 'value', .label | compare the value, not the label |
| Checkboxes, Multi-select | option values | .contains('value'), loop for labels | .options has every option |
| Table | column handles | a <table> loop by column handle | rows are arrays keyed by handle |
| Addresses | — | \|address | formatted for the address's country |
| Entries, Categories, Tags, Users, Assets | max relations, sources, file kinds, hierarchy, per-site relations | .one() or .all() by limit | eager-load it |
| Matrix | entry types and their fields | a full {% switch block.type.handle %} | eager-load it, nested relations too |
| Content Block | its inner fields | its fields straight off the value | nothing to loop or eager-load |
| CKEditor, Redactor | — | {{ entry.x }} | already HTML, no \|raw |
| anything else | the value type Craft declares | {{ entry.x }} or a loop for queries | {{ dump(…) }} in devMode |
Every field also gets its translation method, whether it is searchable, whether it is required or conditional in the layout, and where it is used.