Centralize shared WebUI structural primitives

This commit is contained in:
2026-08-18 13:17:31 +02:00
parent ee5c881df9
commit 7685a103e8
26 changed files with 767 additions and 81 deletions
+5 -1
View File
@@ -3,13 +3,15 @@ import { usePlatformLanguage } from "../i18n/LanguageContext";
import type { PlatformInterfaceIdentityProps } from "../types";
export type ActionToolbarDensity = "compact" | "default";
export type ActionToolbarSurface = "plain" | "subtle";
export type ActionToolbarSurface = "plain" | "subtle" | "panel-header" | "section-header";
export type ActionToolbarWrap = "responsive" | "always" | "never";
export type ActionToolbarJustify = "start" | "between" | "end";
export type ActionToolbarProps = PlatformInterfaceIdentityProps & Omit<HTMLAttributes<HTMLDivElement>, "children"> & {
children: ReactNode;
label?: string;
density?: ActionToolbarDensity;
justify?: ActionToolbarJustify;
surface?: ActionToolbarSurface;
wrap?: ActionToolbarWrap;
};
@@ -18,6 +20,7 @@ export default function ActionToolbar({
children,
label,
density = "default",
justify = "start",
surface = "plain",
wrap = "responsive",
className = "",
@@ -38,6 +41,7 @@ export default function ActionToolbar({
className={[
"action-toolbar",
`action-toolbar-density-${density}`,
`action-toolbar-justify-${justify}`,
`action-toolbar-surface-${surface}`,
`action-toolbar-wrap-${wrap}`,
className