@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,17 @@
1
+ import { type JSX } from "solid-js";
2
+ export type DescriptionListItem = {
3
+ term: JSX.Element;
4
+ description: JSX.Element;
5
+ action?: JSX.Element;
6
+ };
7
+ export type DescriptionListProps = {
8
+ items: readonly DescriptionListItem[];
9
+ columns?: 1 | 2 | 3;
10
+ layout?: "grid" | "rows";
11
+ size?: "sm" | "md";
12
+ actionVisibility?: "always" | "progressive";
13
+ class?: string;
14
+ };
15
+ /** Semantic key-value content with predictable responsive density. */
16
+ export declare function DescriptionList(props: DescriptionListProps): JSX.Element;
17
+ export default DescriptionList;
@@ -0,0 +1,11 @@
1
+ import type { JSX } from "solid-js";
2
+ export type LinkCardColor = "blue" | "emerald" | "violet" | "orange" | "red" | "amber" | "zinc" | "cyan" | "rose";
3
+ export type LinkCardProps = {
4
+ href: string;
5
+ title: string;
6
+ description: string;
7
+ icon: string;
8
+ color: LinkCardColor;
9
+ };
10
+ export declare function LinkCard(props: LinkCardProps): JSX.Element;
11
+ export default LinkCard;
@@ -0,0 +1,15 @@
1
+ import { type JSX } from "solid-js";
2
+ export type NotFoundStateAction = {
3
+ label: string;
4
+ href: string;
5
+ icon?: string;
6
+ };
7
+ export type NotFoundStateProps = {
8
+ code?: string;
9
+ title: string;
10
+ description?: string;
11
+ icon?: string;
12
+ action?: NotFoundStateAction;
13
+ };
14
+ export declare function NotFoundState(props: NotFoundStateProps): JSX.Element;
15
+ export default NotFoundState;
@@ -0,0 +1,39 @@
1
+ import { type JSX } from "solid-js";
2
+ import type { IntentTone } from "../semantics";
3
+ export type NoticeTone = Extract<IntentTone, "neutral" | "info" | "success" | "warning" | "danger">;
4
+ type NoticeCardContentProps = {
5
+ title: JSX.Element;
6
+ detail?: JSX.Element;
7
+ children?: JSX.Element;
8
+ } | {
9
+ title?: never;
10
+ detail?: never;
11
+ children: JSX.Element;
12
+ };
13
+ export type NoticeCardProps = Omit<JSX.HTMLAttributes<HTMLElement>, "children" | "class" | "title"> & NoticeCardContentProps & {
14
+ tone?: NoticeTone;
15
+ icon?: string | false;
16
+ class?: string;
17
+ bodyClass?: string;
18
+ };
19
+ export declare const NOTICE_CARD_CLASSES: {
20
+ readonly root: "k2b-notice-card";
21
+ readonly inner: "k2b-notice-card__inner";
22
+ readonly icon: "k2b-notice-card__icon";
23
+ readonly content: "k2b-notice-card__content";
24
+ readonly title: "k2b-notice-card__title";
25
+ readonly description: "k2b-notice-card__description";
26
+ readonly body: "k2b-notice-card__body";
27
+ };
28
+ export declare const NOTICE_CARD_ICONS: Readonly<Record<NoticeTone, string>>;
29
+ declare function NoticeCardComponent(props: NoticeCardProps): JSX.Element;
30
+ export type NoticeGridProps<T> = {
31
+ items: readonly T[];
32
+ children: (item: T) => JSX.Element;
33
+ class?: string;
34
+ };
35
+ declare function NoticeGrid<T>(props: NoticeGridProps<T>): JSX.Element;
36
+ export declare const NoticeCard: typeof NoticeCardComponent & {
37
+ Grid: typeof NoticeGrid;
38
+ };
39
+ export default NoticeCard;
@@ -0,0 +1,13 @@
1
+ import { type JSX } from "solid-js";
2
+ export type PaperTag = "div" | "section" | "article" | "a";
3
+ type PaperOwnProps<T extends PaperTag> = {
4
+ as?: T;
5
+ children?: JSX.Element;
6
+ class?: string;
7
+ elevated?: boolean;
8
+ interactive?: boolean;
9
+ tabIndex?: number;
10
+ };
11
+ export type PaperProps<T extends PaperTag = "div"> = PaperOwnProps<T> & Omit<JSX.IntrinsicElements[T], keyof PaperOwnProps<T>>;
12
+ export declare function Paper<T extends PaperTag = "div">(props: PaperProps<T>): JSX.Element;
13
+ export default Paper;
@@ -0,0 +1,17 @@
1
+ import { type JSX } from "solid-js";
2
+ export type PlaceholderAlign = "center" | "left";
3
+ export type PlaceholderSurface = "none" | "paper";
4
+ export type PlaceholderState = "empty" | "loading" | "error";
5
+ export type PlaceholderVariant = "compact" | "panel";
6
+ export type PlaceholderProps = {
7
+ title?: JSX.Element;
8
+ description?: JSX.Element;
9
+ icon?: string;
10
+ action?: JSX.Element;
11
+ align?: PlaceholderAlign;
12
+ surface?: PlaceholderSurface;
13
+ state?: PlaceholderState;
14
+ variant?: PlaceholderVariant;
15
+ class?: string;
16
+ };
17
+ export default function Placeholder(props: PlaceholderProps): JSX.Element;
@@ -0,0 +1,13 @@
1
+ import type { JSX } from "solid-js";
2
+ import type { IntentTone } from "../semantics";
3
+ export type ProgressBarTone = Extract<IntentTone, "info" | "success" | "danger">;
4
+ export type ProgressBarProps = {
5
+ value: number;
6
+ size?: "xs" | "sm" | "md";
7
+ tone?: ProgressBarTone;
8
+ showValue?: boolean;
9
+ label: string;
10
+ class?: string;
11
+ };
12
+ export declare function ProgressBar(props: ProgressBarProps): JSX.Element;
13
+ export default ProgressBar;
@@ -0,0 +1,22 @@
1
+ import { type JSX } from "solid-js";
2
+ import type { AccentColor } from "../semantics";
3
+ import { type StatGridSize } from "./StatGrid";
4
+ export type StatCellTone = AccentColor;
5
+ export type StatCellAccent = {
6
+ tone: StatCellTone;
7
+ icon: string;
8
+ text?: string;
9
+ };
10
+ export type StatCellProps = {
11
+ label: string;
12
+ value: string | number | JSX.Element;
13
+ sub?: string;
14
+ valueClass?: string;
15
+ accent?: StatCellAccent;
16
+ href?: string;
17
+ title?: string;
18
+ trend?: readonly number[];
19
+ size?: StatGridSize;
20
+ };
21
+ export declare function StatCell(props: StatCellProps): JSX.Element;
22
+ export default StatCell;
@@ -0,0 +1,21 @@
1
+ import { type JSX } from "solid-js";
2
+ export type StatGridSize = "md" | "sm";
3
+ export type StatGridSurface = "white" | "muted";
4
+ export type StatGridColumns = 1 | 2 | 3 | 4 | 5 | 6;
5
+ export type StatGridAction = {
6
+ label: string;
7
+ href: string;
8
+ };
9
+ export type StatGridProps = {
10
+ children: JSX.Element;
11
+ title?: string;
12
+ action?: StatGridAction;
13
+ columns?: StatGridColumns;
14
+ size?: StatGridSize;
15
+ surface?: StatGridSurface;
16
+ class?: string;
17
+ };
18
+ export declare const useStatGridSize: () => StatGridSize;
19
+ export declare const useStatGridSurface: () => StatGridSurface;
20
+ export declare function StatGrid(props: StatGridProps): JSX.Element;
21
+ export default StatGrid;
@@ -0,0 +1,12 @@
1
+ import { type JSX } from "solid-js";
2
+ export type StatusTone = "ok" | "warning" | "error" | "degraded" | "running" | "neutral";
3
+ export type StatusBadgeProps = {
4
+ tone: StatusTone;
5
+ label: JSX.Element;
6
+ icon?: string | null;
7
+ variant?: "chip" | "dot" | "text";
8
+ title?: string;
9
+ class?: string;
10
+ };
11
+ export declare function StatusBadge(props: StatusBadgeProps): JSX.Element;
12
+ export default StatusBadge;
@@ -0,0 +1,16 @@
1
+ import { type JSX } from "solid-js";
2
+ export type TagSize = "sm" | "md" | "lg";
3
+ export type TagProps = {
4
+ children: JSX.Element;
5
+ color?: string | null;
6
+ icon?: string;
7
+ size?: TagSize;
8
+ selected?: boolean;
9
+ onRemove?: () => void;
10
+ removeLabel?: string;
11
+ disabled?: boolean;
12
+ class?: string;
13
+ };
14
+ /** Compact label presentation with optional color, icon, and remove action. */
15
+ export declare function Tag(props: TagProps): JSX.Element;
16
+ export default Tag;
@@ -0,0 +1,24 @@
1
+ export type { AvatarProps, AvatarSize } from "./Avatar";
2
+ export { Avatar } from "./Avatar";
3
+ export type { DescriptionListItem, DescriptionListProps } from "./DescriptionList";
4
+ export { DescriptionList } from "./DescriptionList";
5
+ export type { LinkCardColor, LinkCardProps } from "./LinkCard";
6
+ export { LinkCard } from "./LinkCard";
7
+ export type { NotFoundStateAction, NotFoundStateProps } from "./NotFoundState";
8
+ export { NotFoundState } from "./NotFoundState";
9
+ export type { NoticeCardProps, NoticeGridProps, NoticeTone } from "./NoticeCard";
10
+ export { NOTICE_CARD_CLASSES, NOTICE_CARD_ICONS, NoticeCard } from "./NoticeCard";
11
+ export type { PaperProps, PaperTag } from "./Paper";
12
+ export { Paper } from "./Paper";
13
+ export type { PlaceholderAlign, PlaceholderProps, PlaceholderState, PlaceholderSurface, PlaceholderVariant, } from "./Placeholder";
14
+ export { default as Placeholder } from "./Placeholder";
15
+ export type { ProgressBarProps, ProgressBarTone } from "./ProgressBar";
16
+ export { ProgressBar } from "./ProgressBar";
17
+ export type { StatCellAccent, StatCellProps, StatCellTone } from "./StatCell";
18
+ export { StatCell } from "./StatCell";
19
+ export type { StatGridAction, StatGridColumns, StatGridProps, StatGridSize, StatGridSurface, } from "./StatGrid";
20
+ export { StatGrid } from "./StatGrid";
21
+ export type { StatusBadgeProps, StatusTone } from "./StatusBadge";
22
+ export { StatusBadge } from "./StatusBadge";
23
+ export type { TagProps, TagSize } from "./Tag";
24
+ export { Tag } from "./Tag";
@@ -0,0 +1,12 @@
1
+ import { type JSX } from "solid-js";
2
+ export type WidgetSize = "content" | "compact" | "standard";
3
+ export type WidgetProps = {
4
+ title: string;
5
+ icon?: string;
6
+ href?: string;
7
+ meta?: string;
8
+ size?: WidgetSize;
9
+ children: JSX.Element;
10
+ };
11
+ export declare function Widget(props: WidgetProps): JSX.Element;
12
+ export default Widget;
@@ -0,0 +1,11 @@
1
+ import { type JSX } from "solid-js";
2
+ import type { AccentColor } from "../semantics";
3
+ export type WidgetTone = AccentColor;
4
+ export type WidgetHeroProps = {
5
+ title: string;
6
+ subtitle?: string;
7
+ icon?: string;
8
+ tone?: WidgetTone;
9
+ };
10
+ export declare function WidgetHero(props: WidgetHeroProps): JSX.Element;
11
+ export default WidgetHero;
@@ -0,0 +1,17 @@
1
+ import { type JSX } from "solid-js";
2
+ import type { WidgetTone } from "./WidgetHero";
3
+ export type WidgetListItem = {
4
+ icon?: string;
5
+ iconTone?: WidgetTone;
6
+ label: string;
7
+ sub?: string;
8
+ meta?: string;
9
+ href?: string;
10
+ };
11
+ export type WidgetListProps = {
12
+ items: readonly WidgetListItem[];
13
+ emptyMessage?: string;
14
+ grow?: boolean;
15
+ };
16
+ export declare function WidgetList(props: WidgetListProps): JSX.Element;
17
+ export default WidgetList;
@@ -0,0 +1,14 @@
1
+ import { type JSX } from "solid-js";
2
+ import type { WidgetTone } from "./WidgetHero";
3
+ export type WidgetPill = {
4
+ label: string;
5
+ value: string | number;
6
+ tone?: WidgetTone;
7
+ href?: string;
8
+ };
9
+ export type WidgetPillsProps = {
10
+ pills: readonly WidgetPill[];
11
+ grow?: boolean;
12
+ };
13
+ export declare function WidgetPills(props: WidgetPillsProps): JSX.Element;
14
+ export default WidgetPills;
@@ -0,0 +1,17 @@
1
+ import { type JSX } from "solid-js";
2
+ import type { WidgetTone } from "./WidgetHero";
3
+ export type WidgetStatAccent = {
4
+ tone: WidgetTone;
5
+ icon: string;
6
+ text?: string;
7
+ };
8
+ export type WidgetStatProps = {
9
+ value: string | number;
10
+ label: string;
11
+ sub?: string;
12
+ valueClass?: string;
13
+ accent?: WidgetStatAccent;
14
+ grow?: boolean;
15
+ };
16
+ export declare function WidgetStat(props: WidgetStatProps): JSX.Element;
17
+ export default WidgetStat;
@@ -0,0 +1,12 @@
1
+ import { type JSX } from "solid-js";
2
+ import type { IntentTone } from "../semantics";
3
+ export type WidgetStatusTone = Extract<IntentTone, "info" | "success" | "warning" | "danger">;
4
+ export type WidgetStatusProps = {
5
+ tone: WidgetStatusTone;
6
+ title: string;
7
+ message?: string;
8
+ icon?: string;
9
+ grow?: boolean;
10
+ };
11
+ export declare function WidgetStatus(props: WidgetStatusProps): JSX.Element;
12
+ export default WidgetStatus;
@@ -0,0 +1,6 @@
1
+ export * from "./Widget";
2
+ export * from "./WidgetHero";
3
+ export * from "./WidgetList";
4
+ export * from "./WidgetPills";
5
+ export * from "./WidgetStat";
6
+ export * from "./WidgetStatus";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@k2b/ui",
3
- "version": "0.1.0-rc.0",
3
+ "version": "0.1.1",
4
4
  "description": "Production-ready components for SolidJS applications.",
5
5
  "repository": {
6
6
  "type": "git",