@kerfjs/ui 4.4.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 (149) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +176 -0
  3. package/ai/skill.md +38 -0
  4. package/dist/app-tab.d.ts +18 -0
  5. package/dist/app-tab.js +3 -0
  6. package/dist/app-tab.js.map +1 -0
  7. package/dist/browser/app-tab.js +3 -0
  8. package/dist/browser/dialog-header.js +3 -0
  9. package/dist/browser/empty-state.js +4 -0
  10. package/dist/browser/loading-spinner.js +3 -0
  11. package/dist/browser/lucide-icon.js +3 -0
  12. package/dist/browser/menu-header.js +3 -0
  13. package/dist/browser/menu-item.js +3 -0
  14. package/dist/browser/page-header.js +3 -0
  15. package/dist/browser/resizable-region.js +3 -0
  16. package/dist/browser/segmented-control.js +3 -0
  17. package/dist/browser/select.js +4 -0
  18. package/dist/browser/state-banner.js +3 -0
  19. package/dist/browser/tab-bar.js +3 -0
  20. package/dist/browser/toolbar-control-group.js +3 -0
  21. package/dist/browser/toolbar-text.js +3 -0
  22. package/dist/browser/toolbar.js +3 -0
  23. package/dist/browser/value-table.js +3 -0
  24. package/dist/chunk-2PES33HS.js +13 -0
  25. package/dist/chunk-2PES33HS.js.map +1 -0
  26. package/dist/chunk-3O7ZEUW2.js +27 -0
  27. package/dist/chunk-3O7ZEUW2.js.map +1 -0
  28. package/dist/chunk-4HHCYSGT.js +79 -0
  29. package/dist/chunk-4HHCYSGT.js.map +1 -0
  30. package/dist/chunk-55DATV3A.js +10 -0
  31. package/dist/chunk-55DATV3A.js.map +1 -0
  32. package/dist/chunk-723YNJBH.js +17 -0
  33. package/dist/chunk-723YNJBH.js.map +1 -0
  34. package/dist/chunk-DAFFDO33.js +14 -0
  35. package/dist/chunk-DAFFDO33.js.map +1 -0
  36. package/dist/chunk-GY5WH7TO.js +10 -0
  37. package/dist/chunk-GY5WH7TO.js.map +1 -0
  38. package/dist/chunk-MBR3TYNL.js +14 -0
  39. package/dist/chunk-MBR3TYNL.js.map +1 -0
  40. package/dist/chunk-MFKMHK5W.js +10 -0
  41. package/dist/chunk-MFKMHK5W.js.map +1 -0
  42. package/dist/chunk-MQIZAD4A.js +227 -0
  43. package/dist/chunk-MQIZAD4A.js.map +1 -0
  44. package/dist/chunk-NHXX4JI5.js +28 -0
  45. package/dist/chunk-NHXX4JI5.js.map +1 -0
  46. package/dist/chunk-OPCJRCYO.js +19 -0
  47. package/dist/chunk-OPCJRCYO.js.map +1 -0
  48. package/dist/chunk-T5XNMVOI.js +24 -0
  49. package/dist/chunk-T5XNMVOI.js.map +1 -0
  50. package/dist/chunk-TRNBHPNW.js +54 -0
  51. package/dist/chunk-TRNBHPNW.js.map +1 -0
  52. package/dist/chunk-VHW5YNIB.js +17 -0
  53. package/dist/chunk-VHW5YNIB.js.map +1 -0
  54. package/dist/chunk-VKH2JLDZ.js +10 -0
  55. package/dist/chunk-VKH2JLDZ.js.map +1 -0
  56. package/dist/chunk-W2FK7ZNY.js +26 -0
  57. package/dist/chunk-W2FK7ZNY.js.map +1 -0
  58. package/dist/chunk-WVPYVDXY.js +15 -0
  59. package/dist/chunk-WVPYVDXY.js.map +1 -0
  60. package/dist/chunk-WY4CAEPG.js +14 -0
  61. package/dist/chunk-WY4CAEPG.js.map +1 -0
  62. package/dist/dialog-header.d.ts +14 -0
  63. package/dist/dialog-header.js +3 -0
  64. package/dist/dialog-header.js.map +1 -0
  65. package/dist/empty-state.d.ts +13 -0
  66. package/dist/empty-state.js +4 -0
  67. package/dist/empty-state.js.map +1 -0
  68. package/dist/index.d.ts +21 -0
  69. package/dist/index.js +21 -0
  70. package/dist/index.js.map +1 -0
  71. package/dist/loading-spinner.d.ts +10 -0
  72. package/dist/loading-spinner.js +3 -0
  73. package/dist/loading-spinner.js.map +1 -0
  74. package/dist/lucide-icon.d.ts +14 -0
  75. package/dist/lucide-icon.js +3 -0
  76. package/dist/lucide-icon.js.map +1 -0
  77. package/dist/menu-header.d.ts +15 -0
  78. package/dist/menu-header.js +3 -0
  79. package/dist/menu-header.js.map +1 -0
  80. package/dist/menu-item.d.ts +22 -0
  81. package/dist/menu-item.js +3 -0
  82. package/dist/menu-item.js.map +1 -0
  83. package/dist/page-header.d.ts +9 -0
  84. package/dist/page-header.js +3 -0
  85. package/dist/page-header.js.map +1 -0
  86. package/dist/resizable-region.d.ts +21 -0
  87. package/dist/resizable-region.js +3 -0
  88. package/dist/resizable-region.js.map +1 -0
  89. package/dist/segmented-control.d.ts +28 -0
  90. package/dist/segmented-control.js +3 -0
  91. package/dist/segmented-control.js.map +1 -0
  92. package/dist/select-register.d.ts +4 -0
  93. package/dist/select-register.js +10 -0
  94. package/dist/select-register.js.map +1 -0
  95. package/dist/select.d.ts +28 -0
  96. package/dist/select.js +4 -0
  97. package/dist/select.js.map +1 -0
  98. package/dist/state-banner.d.ts +15 -0
  99. package/dist/state-banner.js +3 -0
  100. package/dist/state-banner.js.map +1 -0
  101. package/dist/tab-bar.d.ts +14 -0
  102. package/dist/tab-bar.js +3 -0
  103. package/dist/tab-bar.js.map +1 -0
  104. package/dist/toolbar-control-group.d.ts +15 -0
  105. package/dist/toolbar-control-group.js +3 -0
  106. package/dist/toolbar-control-group.js.map +1 -0
  107. package/dist/toolbar-text.d.ts +11 -0
  108. package/dist/toolbar-text.js +3 -0
  109. package/dist/toolbar-text.js.map +1 -0
  110. package/dist/toolbar.d.ts +13 -0
  111. package/dist/toolbar.js +3 -0
  112. package/dist/toolbar.js.map +1 -0
  113. package/dist/value-table.d.ts +10 -0
  114. package/dist/value-table.js +3 -0
  115. package/dist/value-table.js.map +1 -0
  116. package/dist/wire-resizable-regions.d.ts +15 -0
  117. package/dist/wire-resizable-regions.js +4 -0
  118. package/dist/wire-resizable-regions.js.map +1 -0
  119. package/dist/wire-tab-bars.d.ts +17 -0
  120. package/dist/wire-tab-bars.js +3 -0
  121. package/dist/wire-tab-bars.js.map +1 -0
  122. package/docs/accessibility.md +56 -0
  123. package/docs/apple-hig.md +40 -0
  124. package/docs/component-contract.md +66 -0
  125. package/docs/design-philosophy.md +63 -0
  126. package/docs/ux-demo.md +18 -0
  127. package/docs/webawesome-theme.md +181 -0
  128. package/llms.txt +22 -0
  129. package/package.json +218 -0
  130. package/src/app-tab.css +20 -0
  131. package/src/dialog-header.css +9 -0
  132. package/src/empty-state.css +6 -0
  133. package/src/foundation.css +106 -0
  134. package/src/loading-spinner.css +4 -0
  135. package/src/lucide-icon.css +1 -0
  136. package/src/menu-header.css +13 -0
  137. package/src/menu-item.css +12 -0
  138. package/src/page-header.css +3 -0
  139. package/src/resizable-region.css +19 -0
  140. package/src/segmented-control.css +138 -0
  141. package/src/select.css +18 -0
  142. package/src/state-banner.css +31 -0
  143. package/src/styles.css +18 -0
  144. package/src/tab-bar.css +4 -0
  145. package/src/toolbar-control-group.css +25 -0
  146. package/src/toolbar-text.css +4 -0
  147. package/src/toolbar.css +9 -0
  148. package/src/value-table.css +5 -0
  149. package/src/webawesome.css +178 -0
@@ -0,0 +1,13 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface EmptyStateProps {
4
+ title: string;
5
+ detail?: string;
6
+ icon?: SafeHtml;
7
+ action?: SafeHtml;
8
+ busy?: boolean;
9
+ className?: string;
10
+ }
11
+ declare function EmptyState({ title, detail, icon, action, busy, className }: EmptyStateProps): SafeHtml;
12
+
13
+ export { EmptyState, type EmptyStateProps };
@@ -0,0 +1,4 @@
1
+ export { EmptyState } from './chunk-WVPYVDXY.js';
2
+
3
+
4
+ //# sourceMappingURL=empty-state.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"empty-state.js"}
@@ -0,0 +1,21 @@
1
+ export { AppTab, AppTabProps } from './app-tab.js';
2
+ export { DialogHeader, DialogHeaderProps } from './dialog-header.js';
3
+ export { EmptyState, EmptyStateProps } from './empty-state.js';
4
+ export { LoadingSpinner, LoadingSpinnerProps } from './loading-spinner.js';
5
+ export { LucideIcon, LucideIconProps, LucideNode } from './lucide-icon.js';
6
+ export { MenuHeader, MenuHeaderProps } from './menu-header.js';
7
+ export { MenuItem, MenuItemProps } from './menu-item.js';
8
+ export { PageHeader, PageHeaderProps } from './page-header.js';
9
+ export { ResizableRegion, ResizableRegionAxis, ResizableRegionEdge, ResizableRegionProps, clampRegionSize, resizeRegionFromPointer } from './resizable-region.js';
10
+ export { SegmentedControl, SegmentedControlAppearance, SegmentedControlChoice, SegmentedControlLayout, SegmentedControlProps, SegmentedControlShape, SegmentedControlSize } from './segmented-control.js';
11
+ export { Select, SelectChoice, SelectProps } from './select.js';
12
+ export { StateBanner, StateBannerProps, StateBannerTone } from './state-banner.js';
13
+ export { TabBar, TabBarProps } from './tab-bar.js';
14
+ export { Toolbar, ToolbarProps } from './toolbar.js';
15
+ export { ToolbarControlGroup, ToolbarControlGroupProps } from './toolbar-control-group.js';
16
+ export { ToolbarText, ToolbarTextProps, ToolbarTextSize } from './toolbar-text.js';
17
+ export { ValueTable, ValueTableProps } from './value-table.js';
18
+ export { ResizeCommit, WireResizableRegionsOptions, wireResizableRegions } from './wire-resizable-regions.js';
19
+ export { TabDropPosition, TabReorder, TabReorderSource, WireTabBarsOptions, reorderTabs, wireTabBars } from './wire-tab-bars.js';
20
+ import 'kerfjs';
21
+ import 'lucide';
package/dist/index.js ADDED
@@ -0,0 +1,21 @@
1
+ export { ToolbarText } from './chunk-GY5WH7TO.js';
2
+ export { Toolbar } from './chunk-DAFFDO33.js';
3
+ export { ValueTable } from './chunk-VKH2JLDZ.js';
4
+ export { wireResizableRegions } from './chunk-4HHCYSGT.js';
5
+ export { reorderTabs, wireTabBars } from './chunk-MQIZAD4A.js';
6
+ export { PageHeader } from './chunk-2PES33HS.js';
7
+ export { ResizableRegion, clampRegionSize, resizeRegionFromPointer } from './chunk-3O7ZEUW2.js';
8
+ export { SegmentedControl } from './chunk-TRNBHPNW.js';
9
+ export { Select } from './chunk-NHXX4JI5.js';
10
+ export { StateBanner } from './chunk-VHW5YNIB.js';
11
+ export { TabBar } from './chunk-MBR3TYNL.js';
12
+ export { ToolbarControlGroup } from './chunk-MFKMHK5W.js';
13
+ export { AppTab } from './chunk-T5XNMVOI.js';
14
+ export { DialogHeader } from './chunk-723YNJBH.js';
15
+ export { EmptyState } from './chunk-WVPYVDXY.js';
16
+ export { LoadingSpinner } from './chunk-55DATV3A.js';
17
+ export { LucideIcon } from './chunk-W2FK7ZNY.js';
18
+ export { MenuHeader } from './chunk-OPCJRCYO.js';
19
+ export { MenuItem } from './chunk-WY4CAEPG.js';
20
+
21
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"index.js"}
@@ -0,0 +1,10 @@
1
+ import * as kerfjs from 'kerfjs';
2
+
3
+ interface LoadingSpinnerProps {
4
+ className?: string;
5
+ label?: string;
6
+ }
7
+ /** Stable viewBox-centered progress ring based on svg-spinners' MIT-licensed 180-ring. */
8
+ declare function LoadingSpinner({ className, label }: LoadingSpinnerProps): kerfjs.SafeHtml;
9
+
10
+ export { LoadingSpinner, type LoadingSpinnerProps };
@@ -0,0 +1,3 @@
1
+ export { LoadingSpinner } from './chunk-55DATV3A.js';
2
+
3
+ //# sourceMappingURL=loading-spinner.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"loading-spinner.js"}
@@ -0,0 +1,14 @@
1
+ import * as kerfjs from 'kerfjs';
2
+ import { IconNode } from 'lucide';
3
+
4
+ type LucideNode = IconNode;
5
+ interface LucideIconProps {
6
+ icon: LucideNode;
7
+ name: string;
8
+ className?: string;
9
+ label?: string;
10
+ }
11
+ /** Render a Lucide-compatible icon node without copying icon SVG strings. */
12
+ declare function LucideIcon({ icon, name, className, label }: LucideIconProps): kerfjs.SafeHtml;
13
+
14
+ export { LucideIcon, type LucideIconProps, type LucideNode };
@@ -0,0 +1,3 @@
1
+ export { LucideIcon } from './chunk-W2FK7ZNY.js';
2
+
3
+ //# sourceMappingURL=lucide-icon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"lucide-icon.js"}
@@ -0,0 +1,15 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface MenuHeaderProps {
4
+ label: string;
5
+ action?: string;
6
+ actionLabel?: string;
7
+ actionIcon?: SafeHtml;
8
+ actionDisabled?: boolean;
9
+ disabledReason?: string;
10
+ expanded?: boolean;
11
+ toggle?: boolean;
12
+ }
13
+ declare function MenuHeader({ label, action, actionLabel, actionIcon, actionDisabled, disabledReason, expanded, toggle }: MenuHeaderProps): SafeHtml;
14
+
15
+ export { MenuHeader, type MenuHeaderProps };
@@ -0,0 +1,3 @@
1
+ export { MenuHeader } from './chunk-OPCJRCYO.js';
2
+
3
+ //# sourceMappingURL=menu-header.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"menu-header.js"}
@@ -0,0 +1,22 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface MenuItemProps {
4
+ label: string | SafeHtml;
5
+ icon?: SafeHtml;
6
+ trailing?: SafeHtml;
7
+ selected?: boolean;
8
+ action: string;
9
+ itemId?: string;
10
+ className?: string;
11
+ style?: string;
12
+ pressed?: boolean;
13
+ accessibleLabel?: string;
14
+ title?: string;
15
+ multiline?: boolean;
16
+ state?: string;
17
+ disabled?: boolean;
18
+ tabIndex?: number;
19
+ }
20
+ declare function MenuItem({ label, icon, trailing, selected, action, itemId, className, style, pressed, accessibleLabel, title, multiline, state, disabled, tabIndex }: MenuItemProps): SafeHtml;
21
+
22
+ export { MenuItem, type MenuItemProps };
@@ -0,0 +1,3 @@
1
+ export { MenuItem } from './chunk-WY4CAEPG.js';
2
+
3
+ //# sourceMappingURL=menu-item.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"menu-item.js"}
@@ -0,0 +1,9 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface PageHeaderProps {
4
+ title: string | SafeHtml;
5
+ action?: SafeHtml;
6
+ }
7
+ declare function PageHeader({ title, action }: PageHeaderProps): SafeHtml;
8
+
9
+ export { PageHeader, type PageHeaderProps };
@@ -0,0 +1,3 @@
1
+ export { PageHeader } from './chunk-2PES33HS.js';
2
+
3
+ //# sourceMappingURL=page-header.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"page-header.js"}
@@ -0,0 +1,21 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ type ResizableRegionAxis = 'horizontal' | 'vertical';
4
+ type ResizableRegionEdge = 'start' | 'end';
5
+ interface ResizableRegionProps {
6
+ id: string;
7
+ label: string;
8
+ size: number;
9
+ min: number;
10
+ max: number;
11
+ axis?: ResizableRegionAxis;
12
+ edge?: ResizableRegionEdge;
13
+ collapsed?: boolean;
14
+ transitioning?: boolean;
15
+ children: SafeHtml | SafeHtml[];
16
+ }
17
+ declare const clampRegionSize: (size: number, min: number, max: number) => number;
18
+ declare const resizeRegionFromPointer: (startSize: number, delta: number, edge: ResizableRegionEdge) => number;
19
+ declare function ResizableRegion({ id, label, size, min, max, axis, edge, collapsed, transitioning, children }: ResizableRegionProps): SafeHtml;
20
+
21
+ export { ResizableRegion, type ResizableRegionAxis, type ResizableRegionEdge, type ResizableRegionProps, clampRegionSize, resizeRegionFromPointer };
@@ -0,0 +1,3 @@
1
+ export { ResizableRegion, clampRegionSize, resizeRegionFromPointer } from './chunk-3O7ZEUW2.js';
2
+
3
+ //# sourceMappingURL=resizable-region.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"resizable-region.js"}
@@ -0,0 +1,28 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ type SegmentedControlAppearance = 'filled' | 'outlined' | 'toolbar';
4
+ type SegmentedControlShape = 'rounded' | 'pill';
5
+ type SegmentedControlSize = 'small' | 'default';
6
+ type SegmentedControlLayout = 'content' | 'equal';
7
+ interface SegmentedControlChoice {
8
+ value: string;
9
+ label: string;
10
+ content?: SafeHtml;
11
+ title?: string;
12
+ disabled?: boolean;
13
+ }
14
+ interface SegmentedControlProps {
15
+ id: string;
16
+ label: string;
17
+ value: string;
18
+ choices: readonly SegmentedControlChoice[];
19
+ action?: string;
20
+ appearance?: SegmentedControlAppearance;
21
+ shape?: SegmentedControlShape;
22
+ size?: SegmentedControlSize;
23
+ layout?: SegmentedControlLayout;
24
+ className?: string;
25
+ }
26
+ declare function SegmentedControl({ id, label, value, choices, action, appearance, shape, size, layout, className, }: SegmentedControlProps): SafeHtml;
27
+
28
+ export { SegmentedControl, type SegmentedControlAppearance, type SegmentedControlChoice, type SegmentedControlLayout, type SegmentedControlProps, type SegmentedControlShape, type SegmentedControlSize };
@@ -0,0 +1,3 @@
1
+ export { SegmentedControl } from './chunk-TRNBHPNW.js';
2
+
3
+ //# sourceMappingURL=segmented-control.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"segmented-control.js"}
@@ -0,0 +1,4 @@
1
+ /** Marker export for tests and tooling; importing this module performs registration. */
2
+ declare const selectElementsRegistered = true;
3
+
4
+ export { selectElementsRegistered };
@@ -0,0 +1,10 @@
1
+ import '@awesome.me/webawesome/dist/components/divider/divider.js';
2
+ import '@awesome.me/webawesome/dist/components/option/option.js';
3
+ import '@awesome.me/webawesome/dist/components/select/select.js';
4
+
5
+ // src/select-register.ts
6
+ var selectElementsRegistered = true;
7
+
8
+ export { selectElementsRegistered };
9
+
10
+ //# sourceMappingURL=select-register.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/select-register.ts"],"names":[],"mappings":";;;;;AAKO,IAAM,wBAAA,GAA2B","file":"select-register.js","sourcesContent":["import '@awesome.me/webawesome/dist/components/divider/divider.js';\nimport '@awesome.me/webawesome/dist/components/option/option.js';\nimport '@awesome.me/webawesome/dist/components/select/select.js';\n\n/** Marker export for tests and tooling; importing this module performs registration. */\nexport const selectElementsRegistered = true;\n"]}
@@ -0,0 +1,28 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+ import { LucideNode } from './lucide-icon.js';
3
+ import 'lucide';
4
+
5
+ interface SelectChoice<Value extends string = string> {
6
+ value: Value;
7
+ label: string;
8
+ icon?: LucideNode;
9
+ iconName?: string;
10
+ color?: string;
11
+ group?: string;
12
+ separatorBefore?: boolean;
13
+ }
14
+ interface SelectProps<Value extends string = string> {
15
+ name: string;
16
+ value: Value;
17
+ label?: string;
18
+ ariaLabel?: string;
19
+ choices: readonly SelectChoice<Value>[];
20
+ className?: string;
21
+ placeholder?: string;
22
+ disabled?: boolean;
23
+ fitMenu?: boolean;
24
+ renderSelected?: (choice: SelectChoice<Value>) => SafeHtml;
25
+ }
26
+ declare function Select<Value extends string>({ name, value, label, ariaLabel, choices, className, placeholder, disabled, fitMenu, renderSelected }: SelectProps<Value>): SafeHtml;
27
+
28
+ export { Select, type SelectChoice, type SelectProps };
package/dist/select.js ADDED
@@ -0,0 +1,4 @@
1
+ export { Select } from './chunk-NHXX4JI5.js';
2
+
3
+
4
+ //# sourceMappingURL=select.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"select.js"}
@@ -0,0 +1,15 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ type StateBannerTone = 'neutral' | 'info' | 'success' | 'warning' | 'danger';
4
+ interface StateBannerProps {
5
+ title: string;
6
+ detail?: string;
7
+ icon?: SafeHtml;
8
+ action?: SafeHtml;
9
+ tone?: StateBannerTone;
10
+ urgency?: 'status' | 'alert';
11
+ className?: string;
12
+ }
13
+ declare function StateBanner({ title, detail, icon, action, tone, urgency, className }: StateBannerProps): SafeHtml;
14
+
15
+ export { StateBanner, type StateBannerProps, type StateBannerTone };
@@ -0,0 +1,3 @@
1
+ export { StateBanner } from './chunk-VHW5YNIB.js';
2
+
3
+ //# sourceMappingURL=state-banner.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"state-banner.js"}
@@ -0,0 +1,14 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface TabBarProps {
4
+ id: string;
5
+ label: string;
6
+ children: SafeHtml | readonly SafeHtml[];
7
+ leading?: SafeHtml;
8
+ trailing?: SafeHtml;
9
+ className?: string;
10
+ }
11
+ /** Render a controlled tab strip. The application owns selection, order, and persistence. */
12
+ declare function TabBar({ id, label, children, leading, trailing, className }: TabBarProps): SafeHtml;
13
+
14
+ export { TabBar, type TabBarProps };
@@ -0,0 +1,3 @@
1
+ export { TabBar } from './chunk-MBR3TYNL.js';
2
+
3
+ //# sourceMappingURL=tab-bar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"tab-bar.js"}
@@ -0,0 +1,15 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface ToolbarControlGroupProps {
4
+ children: SafeHtml | SafeHtml[];
5
+ label?: string;
6
+ className?: string;
7
+ expanded?: boolean;
8
+ single?: boolean;
9
+ appearance?: 'contained' | 'borderless';
10
+ tone?: 'default' | 'dark';
11
+ buttonAppearance?: 'plain' | 'push';
12
+ }
13
+ declare function ToolbarControlGroup({ children, label, className, expanded, single, appearance, tone, buttonAppearance }: ToolbarControlGroupProps): SafeHtml;
14
+
15
+ export { ToolbarControlGroup, type ToolbarControlGroupProps };
@@ -0,0 +1,3 @@
1
+ export { ToolbarControlGroup } from './chunk-MFKMHK5W.js';
2
+
3
+ //# sourceMappingURL=toolbar-control-group.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"toolbar-control-group.js"}
@@ -0,0 +1,11 @@
1
+ import * as kerfjs from 'kerfjs';
2
+
3
+ type ToolbarTextSize = 'large' | 'default' | 'small';
4
+ interface ToolbarTextProps {
5
+ text: string;
6
+ size?: ToolbarTextSize;
7
+ className?: string;
8
+ }
9
+ declare function ToolbarText({ text, size, className }: ToolbarTextProps): kerfjs.SafeHtml;
10
+
11
+ export { ToolbarText, type ToolbarTextProps, type ToolbarTextSize };
@@ -0,0 +1,3 @@
1
+ export { ToolbarText } from './chunk-GY5WH7TO.js';
2
+
3
+ //# sourceMappingURL=toolbar-text.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"toolbar-text.js"}
@@ -0,0 +1,13 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface ToolbarProps {
4
+ leading?: SafeHtml;
5
+ center?: SafeHtml;
6
+ trailing?: SafeHtml;
7
+ label?: string;
8
+ divider?: boolean;
9
+ className?: string;
10
+ }
11
+ declare function Toolbar({ leading, center, trailing, label, divider, className }: ToolbarProps): SafeHtml;
12
+
13
+ export { Toolbar, type ToolbarProps };
@@ -0,0 +1,3 @@
1
+ export { Toolbar } from './chunk-DAFFDO33.js';
2
+
3
+ //# sourceMappingURL=toolbar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"toolbar.js"}
@@ -0,0 +1,10 @@
1
+ import { SafeHtml } from 'kerfjs';
2
+
3
+ interface ValueTableProps {
4
+ label: string;
5
+ className?: string;
6
+ children: SafeHtml | SafeHtml[];
7
+ }
8
+ declare function ValueTable({ label, className, children }: ValueTableProps): SafeHtml;
9
+
10
+ export { ValueTable, type ValueTableProps };
@@ -0,0 +1,3 @@
1
+ export { ValueTable } from './chunk-VKH2JLDZ.js';
2
+
3
+ //# sourceMappingURL=value-table.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"value-table.js"}
@@ -0,0 +1,15 @@
1
+ interface ResizeCommit {
2
+ id: string;
3
+ size: number;
4
+ source: 'keyboard' | 'pointer';
5
+ }
6
+ interface WireResizableRegionsOptions {
7
+ step?: number;
8
+ largeStep?: number;
9
+ onPreview?: (change: ResizeCommit) => void;
10
+ onCommit: (change: ResizeCommit) => void;
11
+ }
12
+ /** Wire pointer and separator-keyboard behavior for every ResizableRegion below root. */
13
+ declare function wireResizableRegions(root: HTMLElement, { step, largeStep, onPreview, onCommit }: WireResizableRegionsOptions): () => void;
14
+
15
+ export { type ResizeCommit, type WireResizableRegionsOptions, wireResizableRegions };
@@ -0,0 +1,4 @@
1
+ export { wireResizableRegions } from './chunk-4HHCYSGT.js';
2
+
3
+
4
+ //# sourceMappingURL=wire-resizable-regions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"wire-resizable-regions.js"}
@@ -0,0 +1,17 @@
1
+ type TabReorderSource = 'pointer' | 'keyboard';
2
+ type TabDropPosition = 'before' | 'after';
3
+ interface TabReorder {
4
+ barId: string;
5
+ sourceId: string;
6
+ targetId: string;
7
+ position: TabDropPosition;
8
+ source: TabReorderSource;
9
+ }
10
+ interface WireTabBarsOptions {
11
+ onReorder: (change: TabReorder) => void;
12
+ }
13
+ declare function reorderTabs<T>(items: readonly T[], getId: (item: T) => string, sourceId: string, targetId: string, position: TabDropPosition): T[];
14
+ /** Wire reordering and keyboard navigation while leaving controlled state in the application. */
15
+ declare function wireTabBars(root: HTMLElement | Document, { onReorder }: WireTabBarsOptions): () => void;
16
+
17
+ export { type TabDropPosition, type TabReorder, type TabReorderSource, type WireTabBarsOptions, reorderTabs, wireTabBars };
@@ -0,0 +1,3 @@
1
+ export { reorderTabs, wireTabBars } from './chunk-MQIZAD4A.js';
2
+
3
+ //# sourceMappingURL=wire-tab-bars.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"wire-tab-bars.js"}
@@ -0,0 +1,56 @@
1
+ # Accessibility and keyboard contracts
2
+
3
+ These are normative contracts for package components and consuming applications.
4
+
5
+ ## Shared rules
6
+
7
+ - All controls have accessible names and visible `:focus-visible` treatment.
8
+ - Decorative `LucideIcon` output is `aria-hidden`; pass `label` only when the SVG itself conveys meaning.
9
+ - `MenuItem` uses native button Enter/Space behavior. `selected` maps to `aria-current="page"`; `pressed` maps to `aria-pressed`. It deliberately does not emit `role="menuitem"` in isolation—a true ARIA menu must own arrow, Home/End, Escape, and focus behavior as one widget.
10
+ - `LoadingSpinner` is either labeled (`role="img"`) or hidden. Its rotation stops for reduced motion.
11
+ - `StateBanner` defaults to polite `role="status"`; use `urgency="alert"` only for an attention-requiring failure.
12
+ - `EmptyState` reports busy state through `aria-busy` and never relies on an illustration as its label.
13
+ - `Select` follows the Web Awesome host's standard `input`/`change` events. Application tests verify the live `value`, focus, and events—not attributes alone.
14
+
15
+ ## ResizableRegion
16
+
17
+ The handle exposes separator role, orientation, name, minimum, maximum, and current values. `wireResizableRegions()` adds:
18
+
19
+ - the axis arrow keys in 16 px steps by default;
20
+ - Shift+Arrow in 64 px steps;
21
+ - Home and End for minimum and maximum;
22
+ - primary-pointer drag with clamping;
23
+ - preview callbacks while dragging and one commit callback on release.
24
+
25
+ The application owns persistence and collapsed/expanded policy. Keep the last expanded size outside the component and restore it when reopening.
26
+
27
+ ## Tabs
28
+
29
+ `AppTab` renders one controlled tab. `TabBar` supplies the containing tab list,
30
+ fixed leading/trailing regions, and a horizontally scrollable strip.
31
+ `wireTabBars()` adds Left/Right wrapping, Home/End, Delete/Backspace close
32
+ activation, same-bar pointer reordering, `Alt+Shift+ArrowLeft/ArrowRight`
33
+ reordering, focus restoration, scroll-into-view, and pointer-proximity
34
+ autoscroll at either horizontal edge. Edge autoscroll is direct manipulation,
35
+ stops on drop/drag end/disposal, and does not change keyboard behavior. It
36
+ returns a disposer.
37
+
38
+ The application owns the ordered tab array, selection, panels, close policy,
39
+ routing, and persistence. On `onReorder`, synchronously render the reported
40
+ order so the helper can restore focus to the moved tab. Pair tabs with
41
+ `tabpanel` elements and keep exactly one selected tab at `tabindex="0"`.
42
+
43
+ ## SegmentedControl
44
+
45
+ `SegmentedControl` labels its native-button group and projects the controlled
46
+ selection through both `aria-pressed` and `data-selected`. Every enabled choice
47
+ stays in sequential Tab order, matching Hot Sheet 2's compact view and inspector
48
+ controls; Enter and Space use native button activation. The application handles
49
+ the supplied `data-action`, reads `data-segment-value`, updates `value`, and
50
+ re-renders. Keep labels unique and meaningful even when `content` shows only an
51
+ icon. Use tabs—not a segmented control—when choices switch page regions that
52
+ need `tab`/`tabpanel` semantics.
53
+
54
+ ## Verification matrix
55
+
56
+ For each changed component, inspect default, hover, focus, disabled, selected/pressed, busy/error, long-content, wide, narrow, light, dark, increased-contrast, reduced-motion, keyboard-only, and 200%-zoom states where applicable. DOM order must match reading and focus order, with no clipping or unreachable action.
@@ -0,0 +1,40 @@
1
+ # Translating Apple HIG principles to Kerf UI
2
+
3
+ Native Apple applications should use native platform controls and follow the Human Interface Guidelines directly. `@kerfjs/ui` is a web package: it translates the HIG's interaction, hierarchy, writing, accessibility, and feedback principles into semantic HTML and CSS. It does not imitate macOS chrome or materials.
4
+
5
+ ## Foundations
6
+
7
+ - Accessibility is behavior: every workflow is keyboard-operable; focus is visible; DOM and reading order agree; controls have accessible names; decorative icons are hidden.
8
+ - Use adaptive semantic colors. Every custom role needs usable light, dark, and increased-contrast behavior. Never rely on color alone.
9
+ - Use the system UI font stack and allow browser zoom through 200%. Avoid thin weights and hard minimums that clip enlarged text.
10
+ - Group with space and alignment before adding borders. Keep essential content in the leading reading path and secondary detail in progressive disclosure.
11
+ - Use one icon family and one metaphor per action. Directional icons may mirror in RTL; checkmarks, logos, and real-world objects do not.
12
+ - Motion is brief, causal, and optional. Honor reduced-motion and reduced-transparency preferences; repeating indicators stop moving under reduced motion.
13
+ - Writing is concise, specific, and action-led. Labels describe the result, not implementation details.
14
+
15
+ ## Interaction
16
+
17
+ - Prefer native buttons, links, headings, lists, and form controls so browser keyboard behavior comes for free.
18
+ - Use 28 px targets by preference, 20 px as the absolute package floor, and 44 px where the layout allows.
19
+ - Do not move focus after background updates. After a destructive foreground action, move it predictably to the nearest logical survivor.
20
+ - Distinguish selection, focus, pressed, disabled, pending, success, and failure in both semantics and presentation.
21
+ - Use `role="status"` for passive updates. Reserve `role="alert"` for failures requiring attention.
22
+ - Do not timer-dismiss essential feedback. A transient notice that disappears must not be the only record of an important outcome.
23
+ - Place controls near the content they affect. Avoid modal presentation when an inline or popover interaction preserves context safely.
24
+ - Use segmented controls for a small set of mutually exclusive modes. Keep every choice named and keyboard reachable, make the selected mode visible without relying on color alone, and choose rounded or pill geometry to fit the surrounding toolbar or content surface.
25
+
26
+ ## Layout and appearance
27
+
28
+ - Browser surfaces are HIG-shaped, not HIG-skinned: no fake traffic lights, title bars, SF Symbols, or CSS imitation of Liquid Glass.
29
+ - Logical CSS properties support language direction. Truncation and wrapping decisions are explicit; identifiers retain useful leading and trailing context.
30
+ - At constrained widths, remove or move secondary information before shrinking controls or text below usable sizes.
31
+ - Test light, dark, increased contrast, reduced motion, keyboard-only use, 200% zoom, and narrow/wide layouts.
32
+
33
+ ## AI experiences
34
+
35
+ - Identify AI-generated or AI-modified content when that fact affects trust or review.
36
+ - State meaningful uncertainty and consequences in plain language.
37
+ - Keep people in control with reviewable changes and adjacent Edit, Undo, Retry, Reject, or Report actions.
38
+ - Do not use anthropomorphic animation or decoration to imply confidence, agency, or authorship.
39
+
40
+ These rules are a portable implementation guide, not a replacement for current Apple documentation when building a native client.