{#- The two authored fields shared by every maintenance set/edit form. The note — the pin's own text, `note` since ADR-0047's rename — is raw Markdown source, never rendered DOM round-tripped back into a control, so it is a textarea even when today's explanation happens to be one line. `prefix` keeps labels unique on the member page, which may carry hundreds of editors. The duration-or-expiry value deliberately stays one line, and the click-opened help makes its exact grammar discoverable without a hover gesture or a second client-side parser. What the expiry field holds is the caller's (ADR-0104 decision 5). A **new** pin's is empty, and blank keeps the ADR-0014 configured-default rule. An **edit** passes the stored expiry twice — as `duration`, which fills the field, and as `expiry_was`, which the form carries hidden — and the route keeps the stored instant while the two still agree. The sentence under the field says so only while it is true of what the field shows: a refusal's page may carry `expiry_was` beside text the admin typed. **A ringed check's fields** (`ending`, ADR-0142) are the same two, the second an end the acknowledgment may be given: blank, it has none, and ends as what it accepted changes. -#} {% macro kept_hint(maintenance_default, ending=false) -%} {%- if ending -%} Unchanged, it keeps this end; emptied, it has none, and ends as what it accepted changes. {%- else -%} Unchanged, the pin keeps this expiry; emptied, it runs for the default, {{ maintenance_default }}, from now. {%- endif -%} {%- endmacro %} {% macro maintenance_fields(note, duration, prefix, maintenance_default, maintenance_timezone, compact=false, expiry_was='', ending=false) -%}
Markdown is supported; raw HTML is shown as text.
{%- if expiry_was %} {%- if duration == expiry_was %}
{{ kept_hint(maintenance_default, ending) }}
{%- endif %} {%- endif %}
Timezone: {{ maintenance_timezone }} — used when the input has no Z or numeric offset.
Which formats can I use?
InputMeaning
2h, 3d, 1w, 17sDuration from now
2026-07-10 18:00Exact local date and time
2026-07-10T18:00+02:00Exact time with its own offset
07-10Next 10 July, at midnight
17Next 17th, at midnight
18:00Next 18:00
FridayNext Friday at 12:00
Fri 18:00Next Friday at 18:00
{%- endmacro %}