Files
authentik/web/.storybook/preview.js
Teffen Ellis 388f4262b5 web: Captcha Refinements, Part 2 (#19757)
* Move inline styles into separate file.

* Fix preferred order of captcha vendor discovery.

* Clean up mutation and resize observer lifecycle.

* Flesh out controllers.

* Tidy refresh.

* Fix incompatibilities with Storybook.

* Flesh out captcha stories.

* Bump package.

* Flesh out stories.

* Move inline styles into separate file.

* Fix preferred order of captcha vendor discovery.

* Clean up mutation and resize observer lifecycle.

* Flesh out controllers.

* Tidy refresh.

* Remove unused.

* Bump package.
2026-01-30 16:18:24 +01:00

55 lines
1.1 KiB
JavaScript

/**
* @file Storybook manager configuration.
*
* @import { Preview } from "@storybook/web-components";
*/
import "#styles/authentik/interface.global.css";
import "#styles/authentik/static.global.css";
import "#styles/authentik/storybook.css";
import { ThemedDocsContainer } from "./DocsContainer.tsx";
import { extendStorybookTheme } from "./theme.js";
import {
applyDocumentTheme,
createUIThemeEffect,
resolveUITheme,
} from "@goauthentik/web/common/theme.ts";
const base = resolveUITheme();
const theme = extendStorybookTheme(base);
applyDocumentTheme(base);
createUIThemeEffect(applyDocumentTheme);
/**
* @satisfies {Preview}
*/
const preview = {
tags: ["autodocs"],
parameters: {
docs: {
theme,
container: ThemedDocsContainer,
},
options: {
storySort: {
method: "alphabetical",
},
},
actions: { argTypesRegex: "^on[A-Z].*" },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
},
},
};
export default preview;