From 7f3364a468f7dcfd8c9c84e5737fe5699f0e3a93 Mon Sep 17 00:00:00 2001 From: Ogulcan Celik Date: Mon, 13 Jul 2026 02:24:09 +0300 Subject: docs: add versioned config reference --- website/src/components/ConfigReference.astro | 195 +++++++++++++++++++++++++++ 1 file changed, 195 insertions(+) create mode 100644 website/src/components/ConfigReference.astro (limited to 'website/src/components/ConfigReference.astro') diff --git a/website/src/components/ConfigReference.astro b/website/src/components/ConfigReference.astro new file mode 100644 index 00000000..d951f1cc --- /dev/null +++ b/website/src/components/ConfigReference.astro @@ -0,0 +1,195 @@ +--- +import stableReference from '../data/config-reference.json'; +import previewReference from '../data/config-reference-preview.json'; + +interface Props { + placeholder?: string; + noMatches?: string; + keyCountLabel?: string; +} + +const { + placeholder = 'filter keys, e.g. sidebar, prefix, sound…', + noMatches = 'No keys match this filter.', + keyCountLabel = 'keys', +} = Astro.props; + +const reference = Astro.url.pathname.includes('/docs/preview/') + ? previewReference + : stableReference; +const totalKeys = reference.sections.reduce((sum, section) => sum + section.keys.length, 0); +--- + +
+
+ +

{totalKeys} {keyCountLabel}

+
+ + {reference.sections.map((section) => ( +
+

{section.title}

+
    + {section.keys.map((entry) => ( +
  • +
    + {entry.key} + {entry.type} + {entry.default && ( + + default {entry.default} + + )} +
    +

    + {entry.description} + {entry.values && ( + + {entry.values.map((value) => ( + {value} + ))} + + )} +

    +
  • + ))} +
+
+ ))} + + +
+ + + + -- cgit v1.2.3