@machinemetrics/mm-react-components 1.5.0-0 → 1.5.0

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 (219) hide show
  1. package/CHANGELOG.md +40 -31
  2. package/README.md +0 -27
  3. package/agent-docs/agent-documentation-reference.md +13 -106
  4. package/agent-docs/ai-agent-guide.md +13 -15
  5. package/agent-docs/ai-agent-init-guide.md +1 -1
  6. package/agent-docs/chakra-migration-readme.md +7 -6
  7. package/agent-docs/chakra-migration-troubleshooting.md +8 -8
  8. package/agent-docs/component-mapping-reference.md +46 -12
  9. package/agent-docs/{cursor-skill-mm-carbide.md → cursor-skill-components.md} +18 -14
  10. package/agent-docs/lovable.md +0 -1
  11. package/dist/README.md +0 -27
  12. package/dist/components/ui/accordion.d.ts +2 -9
  13. package/dist/components/ui/accordion.d.ts.map +1 -1
  14. package/dist/components/ui/alert-dialog.d.ts +2 -11
  15. package/dist/components/ui/alert-dialog.d.ts.map +1 -1
  16. package/dist/components/ui/alert.d.ts +3 -4
  17. package/dist/components/ui/alert.d.ts.map +1 -1
  18. package/dist/components/ui/avatar.d.ts +1 -5
  19. package/dist/components/ui/avatar.d.ts.map +1 -1
  20. package/dist/components/ui/breadcrumb.d.ts +1 -9
  21. package/dist/components/ui/breadcrumb.d.ts.map +1 -1
  22. package/dist/components/ui/button.d.ts +1 -7
  23. package/dist/components/ui/button.d.ts.map +1 -1
  24. package/dist/components/ui/card.d.ts +3 -25
  25. package/dist/components/ui/card.d.ts.map +1 -1
  26. package/dist/components/ui/collapsible.d.ts +1 -22
  27. package/dist/components/ui/collapsible.d.ts.map +1 -1
  28. package/dist/components/ui/command.d.ts +0 -3
  29. package/dist/components/ui/command.d.ts.map +1 -1
  30. package/dist/components/ui/data-table/pagination.d.ts.map +1 -1
  31. package/dist/components/ui/data-table/toolbar/DataTableToolbar.d.ts.map +1 -1
  32. package/dist/components/ui/data-table/toolbar/filters/FilterMenu.d.ts.map +1 -1
  33. package/dist/components/ui/data-table/toolbar/filters/index.d.ts +0 -2
  34. package/dist/components/ui/data-table/toolbar/filters/index.d.ts.map +1 -1
  35. package/dist/components/ui/date-picker.d.ts +1 -8
  36. package/dist/components/ui/date-picker.d.ts.map +1 -1
  37. package/dist/components/ui/date-range-picker.d.ts +8 -2
  38. package/dist/components/ui/date-range-picker.d.ts.map +1 -1
  39. package/dist/components/ui/dialog.d.ts +2 -12
  40. package/dist/components/ui/dialog.d.ts.map +1 -1
  41. package/dist/components/ui/drawer.d.ts +2 -16
  42. package/dist/components/ui/drawer.d.ts.map +1 -1
  43. package/dist/components/ui/form.d.ts +1 -19
  44. package/dist/components/ui/form.d.ts.map +1 -1
  45. package/dist/components/ui/pagination.d.ts +0 -21
  46. package/dist/components/ui/pagination.d.ts.map +1 -1
  47. package/dist/components/ui/popover.d.ts +2 -11
  48. package/dist/components/ui/popover.d.ts.map +1 -1
  49. package/dist/components/ui/select.d.ts +2 -10
  50. package/dist/components/ui/select.d.ts.map +1 -1
  51. package/dist/components/ui/sheet-banner.d.ts +1 -1
  52. package/dist/components/ui/sheet-banner.d.ts.map +1 -1
  53. package/dist/components/ui/sonner.d.ts +1 -4
  54. package/dist/components/ui/sonner.d.ts.map +1 -1
  55. package/dist/components/ui/table.d.ts +2 -8
  56. package/dist/components/ui/table.d.ts.map +1 -1
  57. package/dist/components/ui/tabs.d.ts +26 -5
  58. package/dist/components/ui/tabs.d.ts.map +1 -1
  59. package/dist/components/ui/toggle-group.d.ts +0 -6
  60. package/dist/components/ui/toggle-group.d.ts.map +1 -1
  61. package/dist/components/ui/tooltip.d.ts +1 -6
  62. package/dist/components/ui/tooltip.d.ts.map +1 -1
  63. package/dist/cursor-skill/components/SKILL.md +231 -0
  64. package/dist/cursor-skill/components/component-structure.md +33 -0
  65. package/dist/cursor-skill/components/reference.md +39 -0
  66. package/dist/cursor-skill/{mm-carbide → components}/widget-rules.md +16 -50
  67. package/dist/docs/GETTING_STARTED.md +0 -26
  68. package/dist/index.d.ts +3 -20
  69. package/dist/index.d.ts.map +1 -1
  70. package/dist/lib/mm-react-components.css +1 -1
  71. package/dist/mm-react-components.es.js +816 -971
  72. package/dist/mm-react-components.es.js.map +1 -1
  73. package/dist/mm-react-components.umd.js +1 -1
  74. package/dist/mm-react-components.umd.js.map +1 -1
  75. package/dist/preview/AccordionPreview.d.ts.map +1 -1
  76. package/dist/preview/BreadcrumbPreview.d.ts.map +1 -1
  77. package/dist/preview/ButtonPreview.d.ts.map +1 -1
  78. package/dist/preview/CardPreview.d.ts.map +1 -1
  79. package/dist/preview/CollapsiblePreview.d.ts.map +1 -1
  80. package/dist/preview/DataTableLimitationsPreview.d.ts.map +1 -1
  81. package/dist/preview/DateRangePickerPreview.d.ts.map +1 -1
  82. package/dist/preview/SearchInputPreview.d.ts +2 -0
  83. package/dist/preview/SearchInputPreview.d.ts.map +1 -0
  84. package/dist/preview/SheetBannerPreview.d.ts.map +1 -1
  85. package/dist/preview/SimplePaginationPreview.d.ts +2 -0
  86. package/dist/preview/SimplePaginationPreview.d.ts.map +1 -0
  87. package/dist/preview/SpinnerCarbidePreview.d.ts +2 -0
  88. package/dist/preview/SpinnerCarbidePreview.d.ts.map +1 -0
  89. package/dist/scripts/init.cjs +3 -3
  90. package/dist/scripts/install-skill.cjs +425 -47
  91. package/dist/themes/carbide.css +21 -234
  92. package/package.json +6 -5
  93. package/agent-docs/tickets-pattern.md +0 -78
  94. package/dist/components/ui/data-table/toolbar/filters/FilterControl.d.ts +0 -14
  95. package/dist/components/ui/data-table/toolbar/filters/FilterControl.d.ts.map +0 -1
  96. package/dist/components/ui/data-table/toolbar/filters/InlineFilterMenu.d.ts +0 -13
  97. package/dist/components/ui/data-table/toolbar/filters/InlineFilterMenu.d.ts.map +0 -1
  98. package/dist/components/ui/date-range-picker/get-range-calendar-selected.d.ts +0 -8
  99. package/dist/components/ui/date-range-picker/get-range-calendar-selected.d.ts.map +0 -1
  100. package/dist/components/ui/date-range-picker/hooks/use-date-range-picker-state.d.ts +0 -38
  101. package/dist/components/ui/date-range-picker/hooks/use-date-range-picker-state.d.ts.map +0 -1
  102. package/dist/components/ui/date-range-picker/index.d.ts +0 -9
  103. package/dist/components/ui/date-range-picker/index.d.ts.map +0 -1
  104. package/dist/components/ui/date-range-picker/parts/company-day-settings-row.d.ts +0 -7
  105. package/dist/components/ui/date-range-picker/parts/company-day-settings-row.d.ts.map +0 -1
  106. package/dist/components/ui/date-range-picker/parts/custom-hours-selects.d.ts +0 -8
  107. package/dist/components/ui/date-range-picker/parts/custom-hours-selects.d.ts.map +0 -1
  108. package/dist/components/ui/date-range-picker/parts/date-range-picker-cancel-apply-buttons.d.ts +0 -10
  109. package/dist/components/ui/date-range-picker/parts/date-range-picker-cancel-apply-buttons.d.ts.map +0 -1
  110. package/dist/components/ui/date-range-picker/parts/date-range-picker-clear-button.d.ts +0 -5
  111. package/dist/components/ui/date-range-picker/parts/date-range-picker-clear-button.d.ts.map +0 -1
  112. package/dist/components/ui/date-range-picker/parts/date-range-picker-trigger.d.ts +0 -24
  113. package/dist/components/ui/date-range-picker/parts/date-range-picker-trigger.d.ts.map +0 -1
  114. package/dist/components/ui/date-range-picker/parts/dual-month-range-calendars.d.ts +0 -15
  115. package/dist/components/ui/date-range-picker/parts/dual-month-range-calendars.d.ts.map +0 -1
  116. package/dist/components/ui/date-range-picker/parts/full-variant-header.d.ts +0 -2
  117. package/dist/components/ui/date-range-picker/parts/full-variant-header.d.ts.map +0 -1
  118. package/dist/components/ui/date-range-picker/parts/preset-sidebar.d.ts +0 -9
  119. package/dist/components/ui/date-range-picker/parts/preset-sidebar.d.ts.map +0 -1
  120. package/dist/components/ui/date-range-picker/parts/range-calendar.d.ts +0 -16
  121. package/dist/components/ui/date-range-picker/parts/range-calendar.d.ts.map +0 -1
  122. package/dist/components/ui/date-range-picker/presets.d.ts +0 -34
  123. package/dist/components/ui/date-range-picker/presets.d.ts.map +0 -1
  124. package/dist/components/ui/date-range-picker/types.d.ts +0 -29
  125. package/dist/components/ui/date-range-picker/types.d.ts.map +0 -1
  126. package/dist/components/ui/date-range-picker/utils.d.ts +0 -24
  127. package/dist/components/ui/date-range-picker/utils.d.ts.map +0 -1
  128. package/dist/components/ui/date-range-picker/variants/full.d.ts +0 -11
  129. package/dist/components/ui/date-range-picker/variants/full.d.ts.map +0 -1
  130. package/dist/components/ui/date-range-picker/variants/simple.d.ts +0 -9
  131. package/dist/components/ui/date-range-picker/variants/simple.d.ts.map +0 -1
  132. package/dist/components/ui/kanban/KanbanBoard.d.ts +0 -8
  133. package/dist/components/ui/kanban/KanbanBoard.d.ts.map +0 -1
  134. package/dist/components/ui/kanban/KanbanCard.d.ts +0 -8
  135. package/dist/components/ui/kanban/KanbanCard.d.ts.map +0 -1
  136. package/dist/components/ui/kanban/KanbanCardOverlay.d.ts +0 -8
  137. package/dist/components/ui/kanban/KanbanCardOverlay.d.ts.map +0 -1
  138. package/dist/components/ui/kanban/KanbanColumn.d.ts +0 -8
  139. package/dist/components/ui/kanban/KanbanColumn.d.ts.map +0 -1
  140. package/dist/components/ui/kanban/KanbanContext.d.ts +0 -28
  141. package/dist/components/ui/kanban/KanbanContext.d.ts.map +0 -1
  142. package/dist/components/ui/kanban/dragEndUtils.d.ts +0 -26
  143. package/dist/components/ui/kanban/dragEndUtils.d.ts.map +0 -1
  144. package/dist/components/ui/kanban/index.d.ts +0 -9
  145. package/dist/components/ui/kanban/index.d.ts.map +0 -1
  146. package/dist/components/ui/kanban/types.d.ts +0 -58
  147. package/dist/components/ui/kanban/types.d.ts.map +0 -1
  148. package/dist/components/ui/status/index.d.ts +0 -7
  149. package/dist/components/ui/status/index.d.ts.map +0 -1
  150. package/dist/components/ui/status/status-badge.d.ts +0 -17
  151. package/dist/components/ui/status/status-badge.d.ts.map +0 -1
  152. package/dist/components/ui/status/status-intent.d.ts +0 -21
  153. package/dist/components/ui/status/status-intent.d.ts.map +0 -1
  154. package/dist/components/ui/status/status-progress.d.ts +0 -20
  155. package/dist/components/ui/status/status-progress.d.ts.map +0 -1
  156. package/dist/components/ui/tabs/index.d.ts +0 -6
  157. package/dist/components/ui/tabs/index.d.ts.map +0 -1
  158. package/dist/components/ui/tabs/scroll-tabs-row.d.ts +0 -6
  159. package/dist/components/ui/tabs/scroll-tabs-row.d.ts.map +0 -1
  160. package/dist/components/ui/tabs/tabs-constants.d.ts +0 -11
  161. package/dist/components/ui/tabs/tabs-constants.d.ts.map +0 -1
  162. package/dist/components/ui/tabs/tabs-content.d.ts +0 -5
  163. package/dist/components/ui/tabs/tabs-content.d.ts.map +0 -1
  164. package/dist/components/ui/tabs/tabs-context.d.ts +0 -9
  165. package/dist/components/ui/tabs/tabs-context.d.ts.map +0 -1
  166. package/dist/components/ui/tabs/tabs-list-underline.d.ts +0 -7
  167. package/dist/components/ui/tabs/tabs-list-underline.d.ts.map +0 -1
  168. package/dist/components/ui/tabs/tabs-list.d.ts +0 -8
  169. package/dist/components/ui/tabs/tabs-list.d.ts.map +0 -1
  170. package/dist/components/ui/tabs/tabs-trigger.d.ts +0 -7
  171. package/dist/components/ui/tabs/tabs-trigger.d.ts.map +0 -1
  172. package/dist/components/ui/tabs/tabs-variants.d.ts +0 -7
  173. package/dist/components/ui/tabs/tabs-variants.d.ts.map +0 -1
  174. package/dist/components/ui/tabs/tabs.d.ts +0 -15
  175. package/dist/components/ui/tabs/tabs.d.ts.map +0 -1
  176. package/dist/components/ui/tabs/use-tabs-underline-scroll.d.ts +0 -15
  177. package/dist/components/ui/tabs/use-tabs-underline-scroll.d.ts.map +0 -1
  178. package/dist/components/ui/tickets/TicketActivitySection.d.ts +0 -20
  179. package/dist/components/ui/tickets/TicketActivitySection.d.ts.map +0 -1
  180. package/dist/components/ui/tickets/TicketDates.d.ts +0 -20
  181. package/dist/components/ui/tickets/TicketDates.d.ts.map +0 -1
  182. package/dist/components/ui/tickets/TicketDetailLayout.d.ts +0 -32
  183. package/dist/components/ui/tickets/TicketDetailLayout.d.ts.map +0 -1
  184. package/dist/components/ui/tickets/TicketDetails.d.ts +0 -34
  185. package/dist/components/ui/tickets/TicketDetails.d.ts.map +0 -1
  186. package/dist/components/ui/tickets/TicketDetailsSidebar.d.ts +0 -21
  187. package/dist/components/ui/tickets/TicketDetailsSidebar.d.ts.map +0 -1
  188. package/dist/components/ui/tickets/TicketFieldControl.d.ts +0 -32
  189. package/dist/components/ui/tickets/TicketFieldControl.d.ts.map +0 -1
  190. package/dist/components/ui/tickets/TicketForm.d.ts +0 -22
  191. package/dist/components/ui/tickets/TicketForm.d.ts.map +0 -1
  192. package/dist/components/ui/tickets/TicketLabels.d.ts +0 -57
  193. package/dist/components/ui/tickets/TicketLabels.d.ts.map +0 -1
  194. package/dist/components/ui/tickets/TicketTypes.d.ts +0 -67
  195. package/dist/components/ui/tickets/TicketTypes.d.ts.map +0 -1
  196. package/dist/components/ui/tickets/TicketUserSelect.d.ts +0 -17
  197. package/dist/components/ui/tickets/TicketUserSelect.d.ts.map +0 -1
  198. package/dist/components/ui/tickets/UserDisplay.d.ts +0 -21
  199. package/dist/components/ui/tickets/UserDisplay.d.ts.map +0 -1
  200. package/dist/components/ui/tickets/UserFieldValue.d.ts +0 -24
  201. package/dist/components/ui/tickets/UserFieldValue.d.ts.map +0 -1
  202. package/dist/components/ui/tickets/index.d.ts +0 -12
  203. package/dist/components/ui/tickets/index.d.ts.map +0 -1
  204. package/dist/cursor-skill/mm-carbide/SKILL.md +0 -84
  205. package/dist/cursor-skill/mm-carbide/reference.md +0 -71
  206. package/dist/lib/normalize-host-color-mode.d.ts +0 -6
  207. package/dist/lib/normalize-host-color-mode.d.ts.map +0 -1
  208. package/dist/lib/theme-root.d.ts +0 -18
  209. package/dist/lib/theme-root.d.ts.map +0 -1
  210. package/dist/lib/use-host-theme.d.ts +0 -15
  211. package/dist/lib/use-host-theme.d.ts.map +0 -1
  212. package/dist/lib/with-display-name.d.ts +0 -2
  213. package/dist/lib/with-display-name.d.ts.map +0 -1
  214. package/dist/preview/KanbanPreview.d.ts +0 -2
  215. package/dist/preview/KanbanPreview.d.ts.map +0 -1
  216. package/dist/preview/StatusPreview.d.ts +0 -2
  217. package/dist/preview/StatusPreview.d.ts.map +0 -1
  218. package/dist/preview/TicketsPreview.d.ts +0 -2
  219. package/dist/preview/TicketsPreview.d.ts.map +0 -1
@@ -1,71 +0,0 @@
1
- # mm-carbide reference
2
-
3
- ## Styling and conventions
4
-
5
- - **Authoritative tokens:** **`@machinemetrics/mm-react-components/themes/carbide`** (`carbide.css`) — search for `--` variables and `.carbide` rules. **`agent-docs/style-color-reference.md`** is an overview only. Precompiled `/styles` is scoped to this library’s build; use **`var(--token)`** from `carbide.css` when needed.
6
- - **Colors and tokens:** Use only CSS variables / semantic tokens (e.g. `bg-background`, `text-foreground`, `text-muted-foreground`, `border-border`, `bg-primary`, `text-destructive`). Never use raw Tailwind color classes like `bg-blue-600` or `text-gray-500`. For palette stops, use arbitrary values: `bg-[var(--grey-500)]`, etc.
7
- - **Variants and sizes:** Use component props: `variant="default"|"destructive"|"outline"|"secondary"|"ghost"|"link"`, `size="sm"|"md"|"lg"|"icon"` where supported (Button and similar). **Badge** also supports semantic status variants: `neutral`, `info`, `success`, `critical`, `warning`, `attention`, `production`, `setup`, `custom` — see **agent-documentation-reference.md** (_Badge variants_).
8
- - **Layout:** In apps with Tailwind, use `flex`, `grid`, and `gap-*` for spacing; avoid ad-hoc margins between siblings. For **copy-paste examples** that must run with **only** `/styles` + `.carbide`, avoid utility `className` on snippet nodes; use component props (`Card variant="sectioned"`, `tone="muted"`, `Accordion variant="inset"`, `CollapsibleContent spacing="comfortable"`, etc.) or `style` with `var(--…)`.
9
- - **Converting to Carbide:** Remove existing inline styles and component CSS; map to library components and use variants/tokens. See SKILL.md section “Converting to Carbide.”
10
- - **Setup:** Import library styles (e.g. `import '@machinemetrics/mm-react-components/styles'`) and wrap the app (or Carbide root) in `<div className="carbide">` so the theme and fonts apply.
11
-
12
- ## Component discovery
13
-
14
- **When the package is installed in this project:** Check **agent-docs** at `node_modules/@machinemetrics/mm-react-components/agent-docs/`; use **agent-documentation-reference.md** as the index for existing components and patterns.
15
-
16
- **When the package is not installed in this workspace:** agent-docs is not present. Use this reference and [widget-rules.md](widget-rules.md); recommend installing the package in the project (`mm-init` or `npm install @machinemetrics/mm-react-components`) for the full doc set.
17
-
18
- ## Key exports (from @machinemetrics/mm-react-components)
19
-
20
- Import from the package main entry (see `src/index.ts` in the repo for the full list).
21
-
22
- **Layout and structure**: PageHeader, ResizablePanelGroup (ResizablePanel, ResizableHandle), Sidebar (SidebarProvider, SidebarInset, SidebarMenu, SidebarMenuButton, SidebarTrigger, etc.), Card (CardHeader, CardTitle, CardDescription, CardContent, CardFooter, CardAction; `variant="sectioned"`, section `tone="muted"`), **ScrollArea** (ScrollBar), Tabs (TabsList, TabsTrigger, TabsContent), Breadcrumb, Field (FieldLabel, FieldDescription, FieldError, FieldGroup, etc.), Item (ItemMedia, ItemContent, ItemActions, etc.).
23
-
24
- **Overlays and dialogs**: Dialog (DialogTrigger, DialogContent, DialogHeader, DialogFooter, etc.), Sheet, Drawer, AlertDialog, Popover, Tooltip (TooltipTrigger, TooltipContent, TooltipProvider), DropdownMenu, HoverCard, ContextMenu.
25
-
26
- **Forms**: Form, FormField, FormItem, FormLabel, FormControl, FormDescription, FormMessage; Input, SearchInput, Textarea, Label, Checkbox, Switch, RadioGroup/RadioGroupItem, Select, Slider, NativeSelect, Combobox, InputOTP, InputGroup, DatePicker, DateRangePicker, Calendar.
27
-
28
- **Data display**: DataTable, DataTablePagination, ResponsiveTable, DataTableToolbar, createColumnDescriptor, createTextColumn, createNumericColumn, createBadgeColumn, createDateColumn, etc.; Table (TableHeader, TableBody, TableRow, TableCell, etc.); ChartContainer, ChartTooltip, ChartLegend, ChartStyle; Progress, Skeleton, Badge, Avatar, HeroMetricCard.
29
-
30
- **Feedback and actions**: Button, buttonVariants, ButtonGroup; Toaster, toast; Alert, AlertTitle, AlertDescription; Spinner, SpinnerCarbide; Pagination, SimplePagination; Empty (EmptyHeader, EmptyTitle, EmptyDescription, etc.).
31
-
32
- **Other**: Accordion (`variant="default"|"inset"`), Collapsible (`CollapsibleContent` `spacing`), Separator, Dropzone, Carousel, Command, CodePreview, Kbd, cn (utility). Theme: activateCarbideTheme, toggleCarbideTheme, isCarbideThemeActive, etc.
33
-
34
- ## Panel-like UI (don’t use Card for every section)
35
-
36
- | Need | Use |
37
- |------|-----|
38
- | Split workspace, dashboard, IDE-like layout | **ResizablePanelGroup** (drag-to-resize; stack vertically on mobile) |
39
- | Navigation panel (app nav, links, sidebar) | **Sidebar** (collapsible to icons) |
40
- | Temporary/slide-out panel (settings, details, filters) | **Sheet** (slides from any side) |
41
- | Discrete content block (summary, metric, form section) | **Card** |
42
-
43
- Use Card only for content blocks. For full app layout: Sidebar + ResizablePanelGroup (or main content area); Sheet for overlay panels.
44
-
45
- ## Scrolling: Card vs ScrollArea
46
-
47
- There is no "Panel" component. For panel-like or card-like regions where content may be longer than the visible area, use **ScrollArea** for the scrollable region. **Card** is structure only (border, sections) and does not scroll.
48
-
49
- - **ScrollArea only scrolls when it has a constrained height.** Without a height (or max-height) on the ScrollArea root, the container grows with content and no scrollbar appears. Always set an explicit height: e.g. `className="h-[300px]"` or `max-h-[50vh]`.
50
- - In a **flex column** (e.g. Card with `flex flex-col max-h-[80vh]`), use `ScrollArea className="flex-1 min-h-0"`. The `min-h-0` is required so the flex item can shrink below its content size; without it, ScrollArea won’t scroll.
51
- - Put long content inside ScrollArea; use Card for the outer container and ScrollArea inside CardContent (or as the body) when the body should scroll.
52
-
53
- **If ScrollArea doesn’t scroll:** Ensure the ScrollArea element has a bounded height (fixed height, max-height, or `flex-1 min-h-0` inside a constrained flex container). Never use ScrollArea without one of these.
54
-
55
- ## Patterns
56
-
57
- - **DateRangePicker**: For **date ranges** (filters, reports). State: `value` / `onValueChange` with tuple `[string \| null, string \| null]` (**`yyyy-MM-dd`**). **`variant="full"`** = presets sidebar + dual-month calendar + company/custom hours. Customize presets with **`presetIds`** (use **`PRESET_IDS`** constants) and **`presetLabels`**. Programmatic matching: **`resolvePresets`**, **`findMatchingPreset`**, **`DATE_RANGE_PRESETS`**. Single date → **`DatePicker`**; bare calendar → **`Calendar`**. Full details: `agent-docs/agent-documentation-reference.md` (DateRangePicker section) and `src/components/ui/date-range-picker/README.md`.
58
- - **PageHeader**: Use for page titles with optional actions, tabs, and breadcrumbs (ActionConfig, TabConfig, MenuItemConfig).
59
- - **DataTable**: Use createColumnDescriptor / createTextColumn / createNumericColumn / createBadgeColumn / createDateColumn and column registry; use useDataTableState, DataTableToolbar, DataTablePagination.
60
- - **Form**: Use Form + FormField with react-hook-form; FormItem, FormLabel, FormControl, FormDescription, FormMessage.
61
- - **Charts**: Use ChartContainer, ChartTooltip, ChartLegend, ChartStyle with recharts; see chart component for config.
62
-
63
- ## Widget rules summary
64
-
65
- - **When to use**: Charts/graphs for trends, comparisons, distributions (with insight annotations). Icons/indicators for status, categories, severity. Metrics/numbers for single KPIs with context (vs target, trend). Text only for labels, brief context, annotations.
66
- - **Insight-driven**: Add comparisons (vs average, vs goal), highlight what matters (color, sizing), show direction/trend (arrows, sparklines), explain significance.
67
- - **Avoid**: Text-only widgets, generic charts without context, equal visual weight for all data, missing comparison or context.
68
- - **Chart limits**: Max 4 lines per line chart, max 4 bars per cluster, max 5 sectors in pie; use small multiples or focus charts if more needed.
69
- - **Accessibility**: WCAG contrast (4.5:1 text, 3:1 graphics); never rely on color alone—use patterns, shapes, or labels; direct labels on data when possible.
70
-
71
- For full widget and visualization rules, see [widget-rules.md](widget-rules.md).
@@ -1,6 +0,0 @@
1
- /**
2
- * Maps host-reported color mode to next-themes names. Unknown values default to light.
3
- * @internal Used by useHostTheme; not part of the public package API.
4
- */
5
- export declare function normalizeHostColorMode(colorMode: string | undefined): 'dark' | 'light';
6
- //# sourceMappingURL=normalize-host-color-mode.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"normalize-host-color-mode.d.ts","sourceRoot":"","sources":["../../src/lib/normalize-host-color-mode.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,sBAAsB,CACpC,SAAS,EAAE,MAAM,GAAG,SAAS,GAC5B,MAAM,GAAG,OAAO,CAMlB"}
@@ -1,18 +0,0 @@
1
- import { type ThemeProviderProps } from 'next-themes';
2
- export type ThemeRootProps = ThemeProviderProps;
3
- /**
4
- * Wrap your app tree once (inside `#root`, not on `<html>`). Applies Carbide-friendly
5
- * defaults: class on `document.documentElement`, light default, no system theme, no
6
- * localStorage (host-driven apps). Pass standard `ThemeProvider` props to override.
7
- *
8
- * @example
9
- * ```tsx
10
- * import { ThemeRoot } from '@machinemetrics/mm-react-components';
11
- *
12
- * <ThemeRoot>
13
- * <App />
14
- * </ThemeRoot>
15
- * ```
16
- */
17
- export declare function ThemeRoot({ children, ...rest }: Readonly<ThemeRootProps>): import("react/jsx-runtime").JSX.Element;
18
- //# sourceMappingURL=theme-root.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"theme-root.d.ts","sourceRoot":"","sources":["../../src/lib/theme-root.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAErE,MAAM,MAAM,cAAc,GAAG,kBAAkB,CAAC;AAEhD;;;;;;;;;;;;;GAaG;AACH,wBAAgB,SAAS,CAAC,EAAE,QAAQ,EAAE,GAAG,IAAI,EAAE,EAAE,QAAQ,CAAC,cAAc,CAAC,2CAcxE"}
@@ -1,15 +0,0 @@
1
- /**
2
- * Syncs light/dark on `document.documentElement` with a host-provided value (e.g.
3
- * `useMMAppParams().colorMode`). Call once near the top of your root `App` inside
4
- * {@link ThemeRoot}. Trims and lowercases host values; unknown values become light.
5
- *
6
- * @example
7
- * ```tsx
8
- * import { useHostTheme } from '@machinemetrics/mm-react-components';
9
- * import { useMMAppParams } from '@machinemetrics/mm-react-tools';
10
- *
11
- * useHostTheme(useMMAppParams().colorMode);
12
- * ```
13
- */
14
- export declare function useHostTheme(colorMode: string | undefined): void;
15
- //# sourceMappingURL=use-host-theme.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-host-theme.d.ts","sourceRoot":"","sources":["../../src/lib/use-host-theme.ts"],"names":[],"mappings":"AAKA;;;;;;;;;;;;GAYG;AACH,wBAAgB,YAAY,CAAC,SAAS,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,CAsBhE"}
@@ -1,2 +0,0 @@
1
- export declare function withDisplayName<T>(component: T, name: string): T;
2
- //# sourceMappingURL=with-display-name.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"with-display-name.d.ts","sourceRoot":"","sources":["../../src/lib/with-display-name.ts"],"names":[],"mappings":"AAAA,wBAAgB,eAAe,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,GAAG,CAAC,CAWhE"}
@@ -1,2 +0,0 @@
1
- export default function KanbanPreview(): import("react/jsx-runtime").JSX.Element;
2
- //# sourceMappingURL=KanbanPreview.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"KanbanPreview.d.ts","sourceRoot":"","sources":["../../src/preview/KanbanPreview.tsx"],"names":[],"mappings":"AAuEA,MAAM,CAAC,OAAO,UAAU,aAAa,4CAsDpC"}
@@ -1,2 +0,0 @@
1
- export default function StatusPreview(): import("react/jsx-runtime").JSX.Element;
2
- //# sourceMappingURL=StatusPreview.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"StatusPreview.d.ts","sourceRoot":"","sources":["../../src/preview/StatusPreview.tsx"],"names":[],"mappings":"AAeA,MAAM,CAAC,OAAO,UAAU,aAAa,4CA+DpC"}
@@ -1,2 +0,0 @@
1
- export default function TicketsPreview(): import("react/jsx-runtime").JSX.Element;
2
- //# sourceMappingURL=TicketsPreview.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TicketsPreview.d.ts","sourceRoot":"","sources":["../../src/preview/TicketsPreview.tsx"],"names":[],"mappings":"AAmSA,MAAM,CAAC,OAAO,UAAU,cAAc,4CAmErC"}