@k2b/ui 0.1.0-rc.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (136) hide show
  1. package/README.md +77 -312
  2. package/dist/types/actions/Button.d.ts +38 -0
  3. package/dist/types/actions/ContextMenu.d.ts +17 -0
  4. package/dist/types/actions/CopyButton.d.ts +20 -0
  5. package/dist/types/actions/Disclosure.d.ts +15 -0
  6. package/dist/types/actions/Dropdown.d.ts +100 -0
  7. package/dist/types/actions/FilterChip.d.ts +27 -0
  8. package/dist/types/actions/RemoveButton.d.ts +7 -0
  9. package/dist/types/actions/SegmentedControl.d.ts +20 -0
  10. package/dist/types/actions/SplitButton.d.ts +13 -0
  11. package/dist/types/actions/SpotlightSearch.d.ts +25 -0
  12. package/dist/types/actions/Tabs.d.ts +27 -0
  13. package/dist/types/actions/Toolbar.d.ts +23 -0
  14. package/dist/types/actions/index.d.ts +24 -0
  15. package/dist/types/chat/ChatComposer.d.ts +57 -0
  16. package/dist/types/chat/ChatPrimitives.d.ts +48 -0
  17. package/dist/types/chat/ChatRoot.d.ts +7 -0
  18. package/dist/types/chat/ChatTimeline.d.ts +52 -0
  19. package/dist/types/chat/chat-behavior.d.ts +29 -0
  20. package/dist/types/chat/index.d.ts +21 -0
  21. package/dist/types/chat/types.d.ts +62 -0
  22. package/dist/types/content/Calendar.d.ts +115 -0
  23. package/dist/types/content/Chart.d.ts +90 -0
  24. package/dist/types/content/CodeDisplay.d.ts +11 -0
  25. package/dist/types/content/DataTable.d.ts +113 -0
  26. package/dist/types/content/Docs.d.ts +52 -0
  27. package/dist/types/content/FileBrowser.d.ts +40 -0
  28. package/dist/types/content/FileTree.d.ts +29 -0
  29. package/dist/types/content/FileView.d.ts +59 -0
  30. package/dist/types/content/Lightbox.d.ts +16 -0
  31. package/dist/types/content/LogEntriesTable.d.ts +14 -0
  32. package/dist/types/content/MarkdownView.d.ts +46 -0
  33. package/dist/types/content/Pagination.d.ts +10 -0
  34. package/dist/types/content/PdfPreview.d.ts +11 -0
  35. package/dist/types/content/RangePicker.d.ts +29 -0
  36. package/dist/types/content/StructuredDataPreview.d.ts +20 -0
  37. package/dist/types/content/calendar-event-layout.d.ts +16 -0
  38. package/dist/types/content/calendar-pointer.d.ts +22 -0
  39. package/dist/types/content/chart-map-viewport.d.ts +5 -0
  40. package/dist/types/content/chart-state-timeline.d.ts +42 -0
  41. package/dist/types/content/code-highlight.d.ts +14 -0
  42. package/dist/types/content/file-tree.d.ts +41 -0
  43. package/dist/types/content/file-view-preview.d.ts +22 -0
  44. package/dist/types/content/index.d.ts +26 -0
  45. package/dist/types/feedback/InlineGuidance.d.ts +10 -0
  46. package/dist/types/feedback/Tooltip.d.ts +18 -0
  47. package/dist/types/feedback/dialog-core.d.ts +19 -0
  48. package/dist/types/feedback/index.d.ts +10 -0
  49. package/dist/types/feedback/prompts.d.ts +164 -0
  50. package/dist/types/feedback/toast.d.ts +25 -0
  51. package/dist/types/feedback/tooltip-position.d.ts +2 -0
  52. package/dist/types/index.d.ts +10 -0
  53. package/dist/types/inputs/AutocompleteEditor.d.ts +21 -0
  54. package/dist/types/inputs/AutocompleteSelect.d.ts +30 -0
  55. package/dist/types/inputs/Checkbox.d.ts +9 -0
  56. package/dist/types/inputs/CheckboxCard.d.ts +9 -0
  57. package/dist/types/inputs/ChoiceGroups.d.ts +13 -0
  58. package/dist/types/inputs/ChoiceInputs.d.ts +24 -0
  59. package/dist/types/inputs/Combobox.d.ts +18 -0
  60. package/dist/types/inputs/DatePicker.d.ts +31 -0
  61. package/dist/types/inputs/FileInputs.d.ts +31 -0
  62. package/dist/types/inputs/MultiSelectInput.d.ts +41 -0
  63. package/dist/types/inputs/NumberInput.d.ts +24 -0
  64. package/dist/types/inputs/Select.d.ts +50 -0
  65. package/dist/types/inputs/SelectChip.d.ts +25 -0
  66. package/dist/types/inputs/SpecialInputs.d.ts +21 -0
  67. package/dist/types/inputs/Switch.d.ts +7 -0
  68. package/dist/types/inputs/TagEditor.d.ts +35 -0
  69. package/dist/types/inputs/TagsInput.d.ts +11 -0
  70. package/dist/types/inputs/TemplateEditor.d.ts +28 -0
  71. package/dist/types/inputs/TextInput.d.ts +26 -0
  72. package/dist/types/inputs/choice.d.ts +32 -0
  73. package/dist/types/inputs/completion/behaviors.d.ts +13 -0
  74. package/dist/types/inputs/completion/engine.d.ts +54 -0
  75. package/dist/types/inputs/completion/index.d.ts +3 -0
  76. package/dist/types/inputs/completion/overlay.d.ts +11 -0
  77. package/dist/types/inputs/date-picker.d.ts +42 -0
  78. package/dist/types/inputs/editor-dom.d.ts +6 -0
  79. package/dist/types/inputs/field-contract.d.ts +24 -0
  80. package/dist/types/inputs/icon-options.d.ts +37 -0
  81. package/dist/types/inputs/image-crop.d.ts +44 -0
  82. package/dist/types/inputs/index.d.ts +45 -0
  83. package/dist/types/inputs/markdown/MarkdownEditor.d.ts +25 -0
  84. package/dist/types/inputs/markdown/Toolbar.d.ts +9 -0
  85. package/dist/types/inputs/markdown/actions.d.ts +8 -0
  86. package/dist/types/inputs/markdown/active-formats.d.ts +1 -0
  87. package/dist/types/inputs/markdown/behaviors.d.ts +3 -0
  88. package/dist/types/inputs/markdown/code-zone.d.ts +1 -0
  89. package/dist/types/internal/color.d.ts +4 -0
  90. package/dist/types/internal/field.d.ts +27 -0
  91. package/dist/types/internal/portal.d.ts +1 -0
  92. package/dist/types/intl/Format.d.ts +84 -0
  93. package/dist/types/intl/index.d.ts +4 -0
  94. package/dist/types/intl/locale.d.ts +42 -0
  95. package/dist/types/intl/messages.d.ts +375 -0
  96. package/dist/types/layout/AppOverview.d.ts +29 -0
  97. package/dist/types/layout/AppWorkspace.d.ts +254 -0
  98. package/dist/types/layout/DataPanel.d.ts +16 -0
  99. package/dist/types/layout/DetailPanel.d.ts +89 -0
  100. package/dist/types/layout/Discussion.d.ts +52 -0
  101. package/dist/types/layout/FloatingWindow.d.ts +19 -0
  102. package/dist/types/layout/PanelDialog.d.ts +72 -0
  103. package/dist/types/layout/PanelHeader.d.ts +10 -0
  104. package/dist/types/layout/Panes.d.ts +48 -0
  105. package/dist/types/layout/ScrollArea.d.ts +8 -0
  106. package/dist/types/layout/Settings.d.ts +72 -0
  107. package/dist/types/layout/SettingsCollection.d.ts +41 -0
  108. package/dist/types/layout/SettingsModal.d.ts +39 -0
  109. package/dist/types/layout/app-workspace-controller.d.ts +7 -0
  110. package/dist/types/layout/app-workspace-state.d.ts +57 -0
  111. package/dist/types/layout/floating-window-geometry.d.ts +11 -0
  112. package/dist/types/layout/index.d.ts +32 -0
  113. package/dist/types/layout/panes-layout.d.ts +63 -0
  114. package/dist/types/layout/stable-id.d.ts +3 -0
  115. package/dist/types/semantics.d.ts +4 -0
  116. package/dist/types/surfaces/Avatar.d.ts +14 -0
  117. package/dist/types/surfaces/DescriptionList.d.ts +17 -0
  118. package/dist/types/surfaces/LinkCard.d.ts +11 -0
  119. package/dist/types/surfaces/NotFoundState.d.ts +15 -0
  120. package/dist/types/surfaces/NoticeCard.d.ts +39 -0
  121. package/dist/types/surfaces/Paper.d.ts +13 -0
  122. package/dist/types/surfaces/Placeholder.d.ts +17 -0
  123. package/dist/types/surfaces/ProgressBar.d.ts +13 -0
  124. package/dist/types/surfaces/StatCell.d.ts +22 -0
  125. package/dist/types/surfaces/StatGrid.d.ts +21 -0
  126. package/dist/types/surfaces/StatusBadge.d.ts +12 -0
  127. package/dist/types/surfaces/Tag.d.ts +16 -0
  128. package/dist/types/surfaces/index.d.ts +24 -0
  129. package/dist/types/widgets/Widget.d.ts +12 -0
  130. package/dist/types/widgets/WidgetHero.d.ts +11 -0
  131. package/dist/types/widgets/WidgetList.d.ts +17 -0
  132. package/dist/types/widgets/WidgetPills.d.ts +14 -0
  133. package/dist/types/widgets/WidgetStat.d.ts +17 -0
  134. package/dist/types/widgets/WidgetStatus.d.ts +12 -0
  135. package/dist/types/widgets/index.d.ts +6 -0
  136. package/package.json +1 -1
@@ -0,0 +1,89 @@
1
+ import { type JSX } from "solid-js";
2
+ import { type ButtonLinkProps, type ButtonProps } from "../actions/Button";
3
+ import { type DropdownItem } from "../actions/Dropdown";
4
+ export type DetailPanelProps = {
5
+ children: JSX.Element;
6
+ class?: string;
7
+ };
8
+ type DetailPanelHeaderBaseProps = {
9
+ title: JSX.Element;
10
+ subtitle?: JSX.Element;
11
+ meta?: JSX.Element;
12
+ actions?: JSX.Element;
13
+ primaryActions?: JSX.Element;
14
+ class?: string;
15
+ };
16
+ export type DetailPanelHeaderProps = DetailPanelHeaderBaseProps & ({
17
+ leading?: JSX.Element;
18
+ icon?: never;
19
+ } | {
20
+ leading?: never;
21
+ icon?: string;
22
+ });
23
+ export type DetailPanelBodyProps = {
24
+ children: JSX.Element;
25
+ scrollPreserveKey?: string;
26
+ class?: string;
27
+ };
28
+ export type DetailPanelSummaryProps = {
29
+ title: JSX.Element;
30
+ children: JSX.Element;
31
+ actions?: JSX.Element;
32
+ class?: string;
33
+ };
34
+ export type DetailPanelGroupProps = {
35
+ children: JSX.Element;
36
+ label?: string;
37
+ class?: string;
38
+ };
39
+ export type DetailPanelTone = "accent" | "neutral" | "success" | "warning" | "danger";
40
+ type DetailPanelSectionBaseProps = {
41
+ title: JSX.Element;
42
+ icon?: string;
43
+ tone?: DetailPanelTone;
44
+ description?: JSX.Element;
45
+ meta?: JSX.Element;
46
+ class?: string;
47
+ };
48
+ type DetailPanelActionBaseProps = {
49
+ title: JSX.Element;
50
+ description?: JSX.Element;
51
+ leading?: JSX.Element;
52
+ trailing?: JSX.Element;
53
+ class?: string;
54
+ };
55
+ type DetailPanelActionMenuProps = {
56
+ menuItems?: never;
57
+ menuLabel?: never;
58
+ } | {
59
+ menuItems: readonly DropdownItem[];
60
+ menuLabel: string;
61
+ };
62
+ export type DetailPanelActionLinkProps = DetailPanelActionBaseProps & DetailPanelActionMenuProps & Omit<ButtonLinkProps, "children" | "class" | "size" | "title" | "variant"> & {
63
+ href: string;
64
+ };
65
+ export type DetailPanelActionButtonProps = DetailPanelActionBaseProps & DetailPanelActionMenuProps & Omit<ButtonProps, "children" | "class" | "size" | "title" | "variant"> & {
66
+ href?: never;
67
+ };
68
+ export type DetailPanelActionProps = DetailPanelActionLinkProps | DetailPanelActionButtonProps;
69
+ export type DetailPanelSectionProps = DetailPanelSectionBaseProps & ({
70
+ children?: JSX.Element;
71
+ actions?: JSX.Element;
72
+ collapsible?: false;
73
+ defaultOpen?: never;
74
+ } | {
75
+ children: JSX.Element;
76
+ actions?: never;
77
+ collapsible: true;
78
+ defaultOpen?: boolean;
79
+ });
80
+ type DetailPanelComponent = ((props: DetailPanelProps) => JSX.Element) & {
81
+ Header: (props: DetailPanelHeaderProps) => JSX.Element;
82
+ Body: (props: DetailPanelBodyProps) => JSX.Element;
83
+ Summary: (props: DetailPanelSummaryProps) => JSX.Element;
84
+ Group: (props: DetailPanelGroupProps) => JSX.Element;
85
+ Section: (props: DetailPanelSectionProps) => JSX.Element;
86
+ Action: (props: DetailPanelActionProps) => JSX.Element;
87
+ };
88
+ declare const DetailPanel: DetailPanelComponent;
89
+ export default DetailPanel;
@@ -0,0 +1,52 @@
1
+ import { type JSX } from "solid-js";
2
+ export type DiscussionProps = Omit<JSX.HTMLAttributes<HTMLElement>, "children" | "class"> & {
3
+ label: JSX.Element;
4
+ children: JSX.Element;
5
+ icon?: string | false;
6
+ count?: number;
7
+ actions?: JSX.Element;
8
+ as?: "h2" | "h3";
9
+ surface?: "default" | "bare";
10
+ class?: string;
11
+ };
12
+ export type DiscussionComposerProps = Omit<JSX.FormHTMLAttributes<HTMLFormElement>, "children" | "class" | "onSubmit"> & {
13
+ label: string;
14
+ onSubmit: (message: string) => boolean | void | Promise<boolean | void>;
15
+ initialValue?: string;
16
+ placeholder?: string;
17
+ submitLabel?: string;
18
+ cancelLabel?: string;
19
+ onCancel?: () => void;
20
+ lines?: number;
21
+ class?: string;
22
+ };
23
+ export type DiscussionListProps = {
24
+ children?: JSX.Element;
25
+ loading?: boolean;
26
+ loadingLabel?: string;
27
+ error?: string | null;
28
+ onRetry?: () => void | Promise<void>;
29
+ hasMore?: boolean;
30
+ loadingMore?: boolean;
31
+ loadMoreLabel?: string;
32
+ onLoadMore?: () => boolean | void | Promise<boolean | void>;
33
+ class?: string;
34
+ };
35
+ export type DiscussionItemProps = Omit<JSX.LiHTMLAttributes<HTMLLIElement>, "children" | "class"> & {
36
+ author: JSX.Element;
37
+ children: JSX.Element;
38
+ avatar?: JSX.Element;
39
+ timestamp?: JSX.Element;
40
+ meta?: JSX.Element;
41
+ replyContext?: JSX.Element;
42
+ actions?: JSX.Element;
43
+ actionVisibility?: "always" | "progressive";
44
+ class?: string;
45
+ };
46
+ type DiscussionComponent = ((props: DiscussionProps) => JSX.Element) & {
47
+ Composer: (props: DiscussionComposerProps) => JSX.Element;
48
+ List: (props: DiscussionListProps) => JSX.Element;
49
+ Item: (props: DiscussionItemProps) => JSX.Element;
50
+ };
51
+ declare const Discussion: DiscussionComponent;
52
+ export default Discussion;
@@ -0,0 +1,19 @@
1
+ import { type JSX } from "solid-js";
2
+ export { type FloatingWindowRect, fitFloatingWindowRect } from "./floating-window-geometry";
3
+ export type FloatingWindowProps = {
4
+ title: string;
5
+ icon?: string;
6
+ children: JSX.Element;
7
+ onClose: () => void;
8
+ initialWidth?: number;
9
+ initialHeight?: number;
10
+ minWidth?: number;
11
+ minHeight?: number;
12
+ accent?: string;
13
+ class?: string;
14
+ resolveScope?: () => HTMLElement | null | undefined;
15
+ };
16
+ export type OpenFloatingWindowOptions = Omit<FloatingWindowProps, "children" | "onClose">;
17
+ export type FloatingWindowClose = () => void;
18
+ export default function FloatingWindow(props: FloatingWindowProps): JSX.Element;
19
+ export declare const openFloatingWindow: (view: (close: FloatingWindowClose) => JSX.Element, options: OpenFloatingWindowOptions) => FloatingWindowClose;
@@ -0,0 +1,72 @@
1
+ import { type JSX } from "solid-js";
2
+ export type PanelDialogSurface = "contained" | "floating";
3
+ export type PanelDialogProps = {
4
+ children: JSX.Element;
5
+ surface?: PanelDialogSurface;
6
+ };
7
+ export type PanelDialogHeaderProps = {
8
+ title: JSX.Element;
9
+ subtitle?: JSX.Element;
10
+ icon?: string;
11
+ actions?: JSX.Element;
12
+ close?: () => void;
13
+ closeDisabled?: boolean;
14
+ closeLabel?: string;
15
+ };
16
+ export type PanelDialogBodyProps = {
17
+ children: JSX.Element;
18
+ scrollPreserveKey?: string;
19
+ };
20
+ export type PanelDialogFooterProps = {
21
+ children: JSX.Element;
22
+ };
23
+ export type PanelDialogSectionProps = {
24
+ title: JSX.Element;
25
+ subtitle?: JSX.Element;
26
+ icon?: string;
27
+ actions?: JSX.Element;
28
+ children: JSX.Element;
29
+ };
30
+ export type PanelDialogTabOption<T extends string = string> = {
31
+ value: T;
32
+ label: JSX.Element;
33
+ icon?: string;
34
+ disabled?: boolean;
35
+ };
36
+ export type PanelDialogTabsProps<T extends string = string> = {
37
+ options: readonly PanelDialogTabOption<T>[];
38
+ value: T | (() => T);
39
+ onValueChange: (value: T) => void;
40
+ ariaLabel?: string;
41
+ label?: string;
42
+ };
43
+ type PanelDialogComponent = ((props: PanelDialogProps) => JSX.Element) & {
44
+ Header: (props: PanelDialogHeaderProps) => JSX.Element;
45
+ Body: (props: PanelDialogBodyProps) => JSX.Element;
46
+ Footer: (props: PanelDialogFooterProps) => JSX.Element;
47
+ Section: (props: PanelDialogSectionProps) => JSX.Element;
48
+ Tabs: <T extends string>(props: PanelDialogTabsProps<T>) => JSX.Element;
49
+ };
50
+ export declare const panelDialogPanelClass = "k2b-dialog k2b-panel-dialog-frame is-standard";
51
+ export declare const panelDialogOptions: {
52
+ panelClassName: string;
53
+ contentClassName: string;
54
+ };
55
+ export declare const panelDialogWidePanelClass = "k2b-dialog k2b-panel-dialog-frame is-wide";
56
+ export declare const panelDialogWideOptions: {
57
+ panelClassName: string;
58
+ contentClassName: string;
59
+ };
60
+ export declare const panelDialogFixedPanelClass = "k2b-dialog k2b-panel-dialog-frame is-fixed";
61
+ export declare const panelDialogFixedOptions: {
62
+ panelClassName: string;
63
+ contentClassName: string;
64
+ };
65
+ export declare const panelDialogWorkspacePanelClass = "k2b-dialog k2b-panel-dialog-frame is-workspace";
66
+ export declare const panelDialogWorkspaceOptions: {
67
+ panelClassName: string;
68
+ contentClassName: string;
69
+ };
70
+ export declare const confirmDiscardIfDirty: (dirty: boolean | (() => boolean)) => Promise<boolean>;
71
+ declare const PanelDialog: PanelDialogComponent;
72
+ export default PanelDialog;
@@ -0,0 +1,10 @@
1
+ import { type JSX } from "solid-js";
2
+ export type PanelHeaderProps = {
3
+ title: JSX.Element;
4
+ subtitle?: JSX.Element;
5
+ actions?: JSX.Element;
6
+ as?: "h1" | "h2" | "h3";
7
+ size?: "sm" | "md";
8
+ class?: string;
9
+ };
10
+ export declare function PanelHeader(props: PanelHeaderProps): JSX.Element;
@@ -0,0 +1,48 @@
1
+ import { type DndDroppableSnapshot } from "@k2b/stdlib/solid";
2
+ import { type JSX } from "solid-js";
3
+ import { type PanesDropTarget, type PanesLayout } from "./panes-layout";
4
+ export type PanesItem = {
5
+ id: string;
6
+ title: string;
7
+ icon?: string;
8
+ render: () => JSX.Element;
9
+ onClose?: () => void;
10
+ };
11
+ export type PanesProps = {
12
+ layout: PanesLayout;
13
+ onLayoutChange: (layout: PanesLayout) => void;
14
+ items: readonly PanesItem[];
15
+ movable?: boolean;
16
+ resizable?: boolean;
17
+ split?: false | "horizontal" | "vertical" | "both";
18
+ onAddItem?: (targetItemId: string | null) => void;
19
+ ariaLabel?: string;
20
+ class?: string;
21
+ };
22
+ type DropMeta = {
23
+ target: PanesDropTarget;
24
+ label: string;
25
+ };
26
+ type IndexedPanesDropTargets = {
27
+ tabs: ReadonlyMap<string | null, PanesDropTarget>;
28
+ body: readonly PanesDropTarget[];
29
+ };
30
+ type PanesSeparatorGeometry = {
31
+ coordinate: number;
32
+ crossStart: number;
33
+ crossEnd: number;
34
+ };
35
+ export declare const resolvePanesResizeSnap: (coordinate: number, source: PanesSeparatorGeometry, candidates: readonly PanesSeparatorGeometry[], options?: {
36
+ activeCoordinate?: number | null;
37
+ previousCoordinate?: number;
38
+ }) => {
39
+ coordinate: number;
40
+ snappedTo: number | null;
41
+ };
42
+ export declare const indexPanesDropTargets: (targets: readonly PanesDropTarget[]) => ReadonlyMap<string, IndexedPanesDropTargets>;
43
+ export declare const pointerHitsPanesDropTarget: (entry: Pick<DndDroppableSnapshot<DropMeta>, "containsPointer" | "meta" | "rect"> & Partial<Pick<DndDroppableSnapshot<DropMeta>, "element">>, pointer: {
44
+ x: number;
45
+ y: number;
46
+ }, hitElement?: Element | null) => boolean;
47
+ export default function Panes(props: PanesProps): JSX.Element;
48
+ export {};
@@ -0,0 +1,8 @@
1
+ import { type JSX } from "solid-js";
2
+ export type ScrollAreaProps = Omit<JSX.HTMLAttributes<HTMLDivElement>, "children" | "class"> & {
3
+ children: JSX.Element;
4
+ scrollPreserveKey?: string | false;
5
+ class?: string;
6
+ };
7
+ export declare function ScrollArea(props: ScrollAreaProps): JSX.Element;
8
+ export default ScrollArea;
@@ -0,0 +1,72 @@
1
+ import { type JSX } from "solid-js";
2
+ import { type ButtonVariant } from "../actions/Button";
3
+ import type { MaybeAccessor } from "../inputs/field-contract";
4
+ export type SettingsPageProps = {
5
+ title: JSX.Element;
6
+ subtitle?: JSX.Element;
7
+ icon?: string;
8
+ actions?: JSX.Element;
9
+ children: JSX.Element;
10
+ footer?: JSX.Element;
11
+ scrollPreserveKey?: string;
12
+ class?: string;
13
+ style?: JSX.CSSProperties | string;
14
+ };
15
+ export declare function SettingsPage(props: SettingsPageProps): JSX.Element;
16
+ export type SettingsSectionProps = {
17
+ title: JSX.Element;
18
+ subtitle?: JSX.Element;
19
+ icon?: string;
20
+ actions?: JSX.Element;
21
+ children: JSX.Element;
22
+ class?: string;
23
+ };
24
+ /**
25
+ * A full-page settings group. Dialogs keep using PanelDialog.Section; this
26
+ * component owns the quieter, observability-style paper used on admin pages.
27
+ */
28
+ export declare function SettingsSection(props: SettingsSectionProps): JSX.Element;
29
+ export type SettingsGroupProps = {
30
+ title: JSX.Element;
31
+ description?: JSX.Element;
32
+ children: JSX.Element;
33
+ class?: string;
34
+ };
35
+ export type SettingsGroupActionProps = {
36
+ children: JSX.Element;
37
+ };
38
+ type SettingsGroupComponent = ((props: SettingsGroupProps) => JSX.Element) & {
39
+ Action: (props: SettingsGroupActionProps) => JSX.Element;
40
+ };
41
+ export declare const SettingsGroup: SettingsGroupComponent;
42
+ export declare const sameSettingValue: (left: unknown, right: unknown) => boolean;
43
+ export declare const readSettingsError: (response: Response, fallback: string) => Promise<{
44
+ message: string;
45
+ fields: Record<string, string>;
46
+ }>;
47
+ export type SettingsFieldProps = {
48
+ label: string;
49
+ description: string;
50
+ error: MaybeAccessor<string | undefined>;
51
+ changed?: MaybeAccessor<boolean>;
52
+ children: JSX.Element | ((control: SettingsFieldControlProps) => JSX.Element);
53
+ class?: string;
54
+ };
55
+ export type SettingsFieldControlProps = {
56
+ describedBy: () => string;
57
+ };
58
+ export declare function SettingsField(props: SettingsFieldProps): JSX.Element;
59
+ export type SettingsSaveBarProps = {
60
+ changeCount: MaybeAccessor<number>;
61
+ loading: MaybeAccessor<boolean>;
62
+ saveDisabled?: MaybeAccessor<boolean>;
63
+ onDiscard: () => void;
64
+ onSave: () => void;
65
+ saveLabel?: string;
66
+ saveVariant?: ButtonVariant;
67
+ class?: string;
68
+ };
69
+ export declare function SettingsSaveBar(props: SettingsSaveBarProps): JSX.Element;
70
+ export type SettingsPanelFooterProps = SettingsSaveBarProps;
71
+ export declare function SettingsPanelFooter(props: SettingsPanelFooterProps): JSX.Element;
72
+ export {};
@@ -0,0 +1,41 @@
1
+ import { type JSX } from "solid-js";
2
+ export type SettingsCollectionProps = {
3
+ title: JSX.Element;
4
+ description?: JSX.Element;
5
+ empty?: JSX.Element;
6
+ children?: JSX.Element;
7
+ class?: string;
8
+ };
9
+ export type SettingsCollectionActionProps = {
10
+ children: JSX.Element;
11
+ };
12
+ export type SettingsCollectionItemProps = {
13
+ title: JSX.Element;
14
+ description?: JSX.Element;
15
+ icon?: JSX.Element;
16
+ children?: JSX.Element;
17
+ };
18
+ export type SettingsCollectionItemStatusProps = {
19
+ children: JSX.Element;
20
+ };
21
+ export type SettingsCollectionItemActionsProps = {
22
+ children: JSX.Element;
23
+ };
24
+ export type SettingsCollectionItemReorderProps = {
25
+ label: string;
26
+ index: number;
27
+ count: number;
28
+ disabled?: boolean;
29
+ onMove: (direction: -1 | 1) => void;
30
+ };
31
+ type SettingsCollectionItemComponent = ((props: SettingsCollectionItemProps) => JSX.Element) & {
32
+ Status: (props: SettingsCollectionItemStatusProps) => JSX.Element;
33
+ Actions: (props: SettingsCollectionItemActionsProps) => JSX.Element;
34
+ Reorder: (props: SettingsCollectionItemReorderProps) => JSX.Element;
35
+ };
36
+ type SettingsCollectionComponent = ((props: SettingsCollectionProps) => JSX.Element) & {
37
+ Action: (props: SettingsCollectionActionProps) => JSX.Element;
38
+ Item: SettingsCollectionItemComponent;
39
+ };
40
+ declare const SettingsCollection: SettingsCollectionComponent;
41
+ export default SettingsCollection;
@@ -0,0 +1,39 @@
1
+ import { type JSX } from "solid-js";
2
+ export type SettingsModalTabTone = "default" | "danger";
3
+ export type SettingsModalTabProps = {
4
+ id: string;
5
+ title: string;
6
+ description?: string;
7
+ icon?: string;
8
+ tone?: SettingsModalTabTone;
9
+ children: JSX.Element;
10
+ };
11
+ export type SettingsModalGroupProps = {
12
+ title: string;
13
+ children: JSX.Element;
14
+ };
15
+ export type SettingsModalFooterProps = {
16
+ children: JSX.Element;
17
+ };
18
+ export type SettingsModalProps = {
19
+ /** Accessible name for the settings surface. */
20
+ title: string;
21
+ /** @deprecated Retained for source compatibility; tab descriptions carry the visible context. */
22
+ subtitle?: string;
23
+ /** @deprecated Retained for source compatibility; tab icons identify the rail entries. */
24
+ icon?: string;
25
+ defaultTab?: string;
26
+ activeTab?: string;
27
+ onTabChange?: (id: string) => void;
28
+ onClose?: () => void;
29
+ closeLabel?: string;
30
+ class?: string;
31
+ children: JSX.Element;
32
+ };
33
+ type SettingsModalComponent = ((props: SettingsModalProps) => JSX.Element) & {
34
+ Tab: (props: SettingsModalTabProps) => JSX.Element;
35
+ Group: (props: SettingsModalGroupProps) => JSX.Element;
36
+ Footer: (props: SettingsModalFooterProps) => JSX.Element;
37
+ };
38
+ declare const SettingsModal: SettingsModalComponent;
39
+ export default SettingsModal;
@@ -0,0 +1,7 @@
1
+ import { type AppWorkspaceLayoutState } from "./app-workspace-state";
2
+ export type AppWorkspaceControllerOptions = {
3
+ root?: Document | HTMLElement;
4
+ readState?: () => AppWorkspaceLayoutState | null | undefined;
5
+ writeState?: (state: AppWorkspaceLayoutState) => void;
6
+ };
7
+ export declare const installAppWorkspaceController: (options?: AppWorkspaceControllerOptions) => (() => void);
@@ -0,0 +1,57 @@
1
+ export type AppWorkspaceLayoutState = {
2
+ version: 2;
3
+ sidebarWidth?: number;
4
+ sidebarCollapsed?: boolean;
5
+ paneWidths?: Record<string, number>;
6
+ detailWidths?: Record<string, number>;
7
+ drawerHeights?: Record<string, number>;
8
+ };
9
+ export declare const APP_WORKSPACE_SIDEBAR_DEFAULT = 208;
10
+ export declare const APP_WORKSPACE_SIDEBAR_COLLAPSED = 64;
11
+ export declare const APP_WORKSPACE_SIDEBAR_COLLAPSE_THRESHOLD = 128;
12
+ export declare const APP_WORKSPACE_SIDEBAR_MIN = 176;
13
+ export declare const APP_WORKSPACE_SIDEBAR_MAX = 360;
14
+ export declare const APP_WORKSPACE_DETAIL_DEFAULT = 384;
15
+ export declare const APP_WORKSPACE_DETAIL_MIN = 288;
16
+ export declare const APP_WORKSPACE_DETAIL_MAX = 640;
17
+ export declare const APP_WORKSPACE_DRAWER_DEFAULT = 240;
18
+ export declare const APP_WORKSPACE_DRAWER_MIN = 160;
19
+ export declare const APP_WORKSPACE_DRAWER_MAX = 560;
20
+ /** Space `appWorkspaceResizeLimits` always reserves for the main region. */
21
+ export declare const APP_WORKSPACE_MAIN_MIN = 320;
22
+ export declare const APP_WORKSPACE_MAIN_MIN_HEIGHT = 240;
23
+ export declare const APP_WORKSPACE_PANE_DEFAULT = 320;
24
+ export declare const APP_WORKSPACE_PANE_MIN = 240;
25
+ export declare const APP_WORKSPACE_PANE_MAX = 640;
26
+ export type AppWorkspaceResizeKind = "sidebar" | "pane" | "detail" | "drawer";
27
+ export declare const appWorkspaceResizeLimits: (options: {
28
+ kind: AppWorkspaceResizeKind;
29
+ workspaceSize: number;
30
+ reservedSize: number;
31
+ min?: number;
32
+ max?: number;
33
+ sidebarCollapsible?: boolean;
34
+ }) => {
35
+ min: number;
36
+ max: number;
37
+ };
38
+ /**
39
+ * Fits preferred auxiliary pane widths into a shared budget without giving
40
+ * DOM order priority. Minimums are reserved first; remaining space is shared
41
+ * in proportion to how much each pane still needs to reach its preference.
42
+ */
43
+ export declare const fitAppWorkspacePaneSizes: (panes: ReadonlyArray<{
44
+ desired: number;
45
+ min: number;
46
+ }>, availableSize: number) => number[];
47
+ export declare const shouldCollapseAppWorkspaceSidebar: (width: number, collapsible: boolean) => boolean;
48
+ export declare const resolveAppWorkspaceSidebarWidth: (width: number, maxWidth: number, collapsible: boolean) => {
49
+ width: number;
50
+ collapsed: boolean;
51
+ };
52
+ export declare const safeAppWorkspacePanelId: (panelId: string) => string;
53
+ export declare const appWorkspacePanelVariable: (kind: "pane" | "detail" | "drawer", panelId: string) => string;
54
+ export declare const normalizeAppWorkspaceLayoutState: (value: unknown) => AppWorkspaceLayoutState | null;
55
+ export declare const parseAppWorkspaceLayoutState: (value: string | null | undefined) => AppWorkspaceLayoutState | null;
56
+ export declare const serializeAppWorkspaceLayoutState: (state: AppWorkspaceLayoutState) => string;
57
+ export declare const appWorkspaceLayoutStyle: (state: AppWorkspaceLayoutState | null | undefined) => string | undefined;
@@ -0,0 +1,11 @@
1
+ export type FloatingWindowRect = {
2
+ x: number;
3
+ y: number;
4
+ width: number;
5
+ height: number;
6
+ };
7
+ export declare const FLOATING_WINDOW_VIEWPORT_GAP = 16;
8
+ export declare const fitFloatingWindowRect: (rect: FloatingWindowRect, minWidth: number, minHeight: number, viewport: {
9
+ width: number;
10
+ height: number;
11
+ }) => FloatingWindowRect;
@@ -0,0 +1,32 @@
1
+ export type { AppOverviewEmptyStateProps, AppOverviewPanelProps, AppOverviewProps, } from "./AppOverview";
2
+ export { default as AppOverview } from "./AppOverview";
3
+ export type { AppWorkspaceBottomDrawerHeight, AppWorkspaceBottomDrawerProps, AppWorkspaceContentProps, AppWorkspaceDetailProps, AppWorkspaceDetailWidth, AppWorkspaceMainPaneProps, AppWorkspaceMainProps, AppWorkspaceNavTreeItemProps, AppWorkspaceNavTreeProps, AppWorkspaceProps, AppWorkspaceSidebarAccessoryVisibility, AppWorkspaceSidebarBodyProps, AppWorkspaceSidebarIconActionProps, AppWorkspaceSidebarIconActionTone, AppWorkspaceSidebarIconGridProps, AppWorkspaceSidebarItemActionProps, AppWorkspaceSidebarItemActionsProps, AppWorkspaceSidebarItemIconProps, AppWorkspaceSidebarItemLabelProps, AppWorkspaceSidebarItemMetaProps, AppWorkspaceSidebarItemProps, AppWorkspaceSidebarItemTone, AppWorkspaceSidebarMobileItemsProps, AppWorkspaceSidebarMobileProps, AppWorkspaceSidebarMobileTriggerProps, AppWorkspaceSidebarProps, AppWorkspaceSidebarSectionProps, AppWorkspaceSidebarVisibility, } from "./AppWorkspace";
4
+ export { default as AppWorkspace } from "./AppWorkspace";
5
+ export type { AppWorkspaceControllerOptions } from "./app-workspace-controller";
6
+ export { installAppWorkspaceController } from "./app-workspace-controller";
7
+ export type { AppWorkspaceLayoutState, AppWorkspaceResizeKind, } from "./app-workspace-state";
8
+ export { APP_WORKSPACE_DETAIL_DEFAULT, APP_WORKSPACE_DETAIL_MAX, APP_WORKSPACE_DETAIL_MIN, APP_WORKSPACE_DRAWER_DEFAULT, APP_WORKSPACE_DRAWER_MAX, APP_WORKSPACE_DRAWER_MIN, APP_WORKSPACE_MAIN_MIN, APP_WORKSPACE_MAIN_MIN_HEIGHT, APP_WORKSPACE_PANE_DEFAULT, APP_WORKSPACE_PANE_MAX, APP_WORKSPACE_PANE_MIN, APP_WORKSPACE_SIDEBAR_COLLAPSE_THRESHOLD, APP_WORKSPACE_SIDEBAR_COLLAPSED, APP_WORKSPACE_SIDEBAR_DEFAULT, APP_WORKSPACE_SIDEBAR_MAX, APP_WORKSPACE_SIDEBAR_MIN, appWorkspaceLayoutStyle, appWorkspacePanelVariable, appWorkspaceResizeLimits, normalizeAppWorkspaceLayoutState, parseAppWorkspaceLayoutState, resolveAppWorkspaceSidebarWidth, safeAppWorkspacePanelId, serializeAppWorkspaceLayoutState, shouldCollapseAppWorkspaceSidebar, } from "./app-workspace-state";
9
+ export type { DataPanelProps } from "./DataPanel";
10
+ export { DataPanel } from "./DataPanel";
11
+ export type { DetailPanelActionButtonProps, DetailPanelActionLinkProps, DetailPanelActionProps, DetailPanelBodyProps, DetailPanelGroupProps, DetailPanelHeaderProps, DetailPanelProps, DetailPanelSectionProps, DetailPanelSummaryProps, DetailPanelTone, } from "./DetailPanel";
12
+ export { default as DetailPanel } from "./DetailPanel";
13
+ export type { DiscussionComposerProps, DiscussionItemProps, DiscussionListProps, DiscussionProps } from "./Discussion";
14
+ export { default as Discussion } from "./Discussion";
15
+ export type { FloatingWindowClose, FloatingWindowProps, OpenFloatingWindowOptions, } from "./FloatingWindow";
16
+ export { default as FloatingWindow, type FloatingWindowRect, fitFloatingWindowRect, openFloatingWindow, } from "./FloatingWindow";
17
+ export type { PanelDialogBodyProps, PanelDialogFooterProps, PanelDialogHeaderProps, PanelDialogProps, PanelDialogSectionProps, PanelDialogSurface, PanelDialogTabOption, PanelDialogTabsProps, } from "./PanelDialog";
18
+ export { confirmDiscardIfDirty, default as PanelDialog, panelDialogFixedOptions, panelDialogFixedPanelClass, panelDialogOptions, panelDialogPanelClass, panelDialogWideOptions, panelDialogWidePanelClass, panelDialogWorkspaceOptions, panelDialogWorkspacePanelClass, } from "./PanelDialog";
19
+ export type { PanelHeaderProps } from "./PanelHeader";
20
+ export { PanelHeader } from "./PanelHeader";
21
+ export type { PanesItem, PanesProps } from "./Panes";
22
+ export { default as Panes } from "./Panes";
23
+ export type { AddPanesItemOptions, PanesDirection, PanesGroup, PanesIntent, PanesLayout, PanesNode, PanesPath, PanesPathSegment, PanesSide, PanesSplit, } from "./panes-layout";
24
+ export { activatePanesItem, addPanesItem, applyPanesIntent, createPanesLayout, isPanesItemVisible, PANES_LAYOUT_VERSION, parsePanesLayout, reconcilePanesLayout, removePanesItem, resizePanesSplit, } from "./panes-layout";
25
+ export type { ScrollAreaProps } from "./ScrollArea";
26
+ export { default as ScrollArea } from "./ScrollArea";
27
+ export type { SettingsFieldControlProps, SettingsFieldProps, SettingsGroupActionProps, SettingsGroupProps, SettingsPageProps, SettingsPanelFooterProps, SettingsSaveBarProps, SettingsSectionProps, } from "./Settings";
28
+ export { readSettingsError, SettingsField, SettingsGroup, SettingsPage, SettingsPanelFooter, SettingsSaveBar, SettingsSection, sameSettingValue, } from "./Settings";
29
+ export type { SettingsCollectionActionProps, SettingsCollectionItemActionsProps, SettingsCollectionItemProps, SettingsCollectionItemReorderProps, SettingsCollectionItemStatusProps, SettingsCollectionProps, } from "./SettingsCollection";
30
+ export { default as SettingsCollection } from "./SettingsCollection";
31
+ export type { SettingsModalFooterProps, SettingsModalGroupProps, SettingsModalProps, SettingsModalTabProps, SettingsModalTabTone, } from "./SettingsModal";
32
+ export { default as SettingsModal } from "./SettingsModal";
@@ -0,0 +1,63 @@
1
+ export declare const PANES_LAYOUT_VERSION: 2;
2
+ export declare const PANES_MIN_RATIO = 0.08;
3
+ export declare const PANES_MAX_ID_LENGTH = 160;
4
+ export type PanesDirection = "horizontal" | "vertical";
5
+ export type PanesSide = "left" | "right" | "top" | "bottom";
6
+ export type PanesPathSegment = "first" | "second";
7
+ export type PanesPath = readonly PanesPathSegment[];
8
+ export type PanesGroup = {
9
+ type: "group";
10
+ items: string[];
11
+ active: string;
12
+ };
13
+ export type PanesSplit = {
14
+ type: "split";
15
+ direction: PanesDirection;
16
+ ratio: number;
17
+ first: PanesNode;
18
+ second: PanesNode;
19
+ };
20
+ export type PanesNode = PanesGroup | PanesSplit;
21
+ export type PanesLayout = {
22
+ version: typeof PANES_LAYOUT_VERSION;
23
+ root: PanesNode | null;
24
+ };
25
+ export type PanesIntent = {
26
+ type: "tab";
27
+ itemId: string;
28
+ targetItemId: string;
29
+ beforeItemId: string | null;
30
+ } | {
31
+ type: "split";
32
+ itemId: string;
33
+ targetItemId: string;
34
+ side: PanesSide;
35
+ };
36
+ export type PanesDropTarget = {
37
+ id: string;
38
+ kind: "tab" | "group" | "split";
39
+ targetItemId: string;
40
+ beforeItemId?: string | null;
41
+ side?: PanesSide;
42
+ intent: PanesIntent;
43
+ };
44
+ export type PanesDropTargetOptions = {
45
+ movable: boolean;
46
+ split: false | PanesDirection | "both";
47
+ };
48
+ export declare const parsePanesLayout: (value: unknown) => PanesLayout | null;
49
+ export declare const createPanesLayout: (itemIds: readonly string[]) => PanesLayout;
50
+ export declare const activatePanesItem: (layout: PanesLayout, itemId: string) => PanesLayout;
51
+ export declare const isPanesItemVisible: (layout: PanesLayout, itemId: string) => boolean;
52
+ export declare const removePanesItem: (layout: PanesLayout, itemId: string) => PanesLayout;
53
+ export type AddPanesItemOptions = {
54
+ itemId: string;
55
+ targetItemId: string | null;
56
+ beforeItemId?: string | null;
57
+ };
58
+ export declare const addPanesItem: (layout: PanesLayout, options: AddPanesItemOptions) => PanesLayout;
59
+ export declare const applyPanesIntent: (layout: PanesLayout, intent: PanesIntent) => PanesLayout;
60
+ export declare const reconcilePanesLayout: (layout: PanesLayout, desiredOpenItemIds: readonly string[]) => PanesLayout;
61
+ export declare const resizePanesSplit: (layout: PanesLayout, path: PanesPath, ratio: number) => PanesLayout;
62
+ export declare const samePanesIntent: (left: PanesIntent | null, right: PanesIntent | null) => boolean;
63
+ export declare const getPanesDropTargets: (layout: PanesLayout, itemId: string, options: PanesDropTargetOptions) => PanesDropTarget[];
@@ -0,0 +1,3 @@
1
+ export declare const isStableUiId: (value: unknown, maxLength?: number) => value is string;
2
+ export declare const assertStableUiId: (value: string, label: string, maxLength?: number) => string;
3
+ export declare const assertUniqueStableUiIds: (values: readonly string[], label: string, maxLength?: number) => void;
@@ -0,0 +1,4 @@
1
+ /** Semantic intent for user-facing feedback and actions. */
2
+ export type IntentTone = "neutral" | "info" | "success" | "warning" | "danger";
3
+ /** Deliberately small accent palette for data and identity presentation. */
4
+ export type AccentColor = "zinc" | "blue" | "emerald" | "amber" | "red";
@@ -0,0 +1,14 @@
1
+ import { type JSX } from "solid-js";
2
+ export type AvatarSize = "xs" | "sm" | "md" | "lg" | "xl";
3
+ export type AvatarProps = {
4
+ name: string;
5
+ src?: string | null;
6
+ icon?: string;
7
+ alt?: string;
8
+ fallback?: string;
9
+ size?: AvatarSize;
10
+ loading?: "eager" | "lazy";
11
+ class?: string;
12
+ style?: JSX.CSSProperties | string;
13
+ };
14
+ export declare function Avatar(props: AvatarProps): JSX.Element;