{# ============================================================================ #} {# Shared UI macros for the v3 web interface. #} {# #} {# Import at the top of a partial with: #} {# {% import 'v3/partials/_macros.html' as ui %} #} {# #} {# These power the settings tooltips and the settings search feature: #} {# - help_tip(text, label): the (i) info icon whose hover/focus tooltip #} {# explains a setting. This replaces the old always-visible

help. #} {# - fg_id(tab, key): stable anchor id for a .form-group so global search #} {# can scroll to it (e.g. "setting-display-brightness"). #} {# - settings_filter(): the per-tab filter box shown under a partial title. #} {# ============================================================================ #} {# Info (i) tooltip trigger placed next to a setting label. #} {# `text` supports "\n" line breaks (rendered via CSS white-space: pre-line). #} {# Renders nothing when `text` is empty so callers can pass through schema data. #} {% macro help_tip(text, label='') -%} {%- if text -%} {%- endif -%} {%- endmacro %} {# Stable anchor id for a settings field's .form-group wrapper. #} {% macro fg_id(tab, key) -%}setting-{{ tab }}-{{ key }}{%- endmacro %} {# Per-tab filter box. Place directly under a partial's

title block. #} {# The delegated handler in settings-search.js scopes to the enclosing tab. #} {% macro settings_filter(placeholder='Filter these settings…') -%}
{%- endmacro %}