
* tests/e2e: add test for authentication flow in compatibility mode Signed-off-by: Jens Langhammer <jens@goauthentik.io> * web: Add prefix class to CSS for easier debugging of constructed stylesheets. - Use CSS variables for highlighter. * web: Fix issue where MDX components apply styles out of order. * web: Fix hover color. * web: Fix CSS module types. Clean up globals. * web: Fix issues surrounding availability of shadow root in compatibility mode. * web: Fix typo. * web: Partial fixes for storybook dark theme. * web: Fix overflow. * web: Fix issues surrounding competing interfaces attempting to apply styles. * fix padding in ak-alert in. markdown Signed-off-by: Jens Langhammer <jens@goauthentik.io> * web: Minimize use of sub-module exports. --------- Signed-off-by: Jens Langhammer <jens@goauthentik.io> Co-authored-by: Teffen Ellis <teffen@sister.software>
39 lines
921 B
JavaScript
39 lines
921 B
JavaScript
/**
|
|
* @file Storybook manager configuration.
|
|
*
|
|
* @import { ThemeVarsPartial } from "storybook/internal/theming";
|
|
*/
|
|
import { createUIThemeEffect, resolveUITheme } from "@goauthentik/web/common/theme.ts";
|
|
import { addons } from "@storybook/manager-api";
|
|
import { create } from "@storybook/theming/create";
|
|
|
|
/**
|
|
* @satisfies {Partial<ThemeVarsPartial>}
|
|
*/
|
|
const baseTheme = {
|
|
brandTitle: "authentik Storybook",
|
|
brandUrl: "https://goauthentik.io",
|
|
brandImage: "https://goauthentik.io/img/icon_left_brand_colour.svg",
|
|
brandTarget: "_self",
|
|
};
|
|
|
|
const uiTheme = resolveUITheme();
|
|
|
|
addons.setConfig({
|
|
theme: create({
|
|
...baseTheme,
|
|
base: uiTheme,
|
|
}),
|
|
enableShortcuts: false,
|
|
});
|
|
|
|
createUIThemeEffect((nextUITheme) => {
|
|
addons.setConfig({
|
|
theme: create({
|
|
...baseTheme,
|
|
base: nextUITheme,
|
|
}),
|
|
enableShortcuts: false,
|
|
});
|
|
});
|