Invalid attribute value
The attribute is one the shortcut takes, but its value isn't one the attribute accepts. The build warns, and the attribute's default stands in; it stops when the attribute is required and has nothing to stand in.
What it looks like
::: {.vspace size="banana"}
:::
::: {.aside type="todo"}
A callout whose type is not one of the defined kinds.
:::
::: {.multicol cols="9"}
Text that was meant to flow across columns.
:::
ERROR: shortcut 'vspace' rejects size 'banana'
│ ::: {.vspace size="banana"}
It takes a length in cm, em, in, mm or pt, or one of the values listed.
The attribute is required, and nothing stands in for the value.
Valid: huge, large, medium, none, small, tiny
See https://keystone.knight-owl.dev/errors/invalid-value/
WARN: shortcut 'aside' rejects type 'todo'
│ ::: {.aside type="todo"}
│ A callout whose type is not one of the d…
It takes one of the values listed.
The default 'note' stands in.
Valid: example, note, tip, warning
See https://keystone.knight-owl.dev/errors/invalid-value/
WARN: shortcut 'multicol' rejects cols '9'
│ ::: {.multicol cols="9"}
│ Text that was meant to flow across colum…
It takes an integer from 2 to 4.
The default '2' stands in.
See https://keystone.knight-owl.dev/errors/invalid-value/
What it means
A value you write is judged as written, an empty one included. One the attribute doesn't accept is dropped, and in its place stands:
- the attribute's default —
multicolfalls back to two columns,asideto a note — and the build warns; - without a default, whatever the shortcut's own markup has there, else nothing, and the build warns;
- nothing, on an attribute the shortcut requires —
vspace'ssizehas no default — and the build stops.
The message names the shortcut and attribute as you wrote them, your own shortcut's included, and what the attribute takes. A strict build stops on the warning too.
Take a value from the shortcut's reference entry
Each entry in the
system shortcut reference lists what its
attributes accept. A shortcut of your own takes what the shortcut it builds
on does, or what its accepts
narrows that to. A font family comes from the
fonts the image carries, or
your own.
Related
- An accepted value — a value your
shortcuts.yamlwrites, adefault, aconstor a template's, refused as the build compiles it. - Undeclared mark — a
set marknaming a mark you never declared. - Unrecognized attribute — the attribute name itself isn't accepted.