@alpic-ai/ui 0.0.0-dev.g2df19cc → 0.0.0-dev.g2eefcc2

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 (113) hide show
  1. package/dist/components/accordion-card.d.mts +5 -6
  2. package/dist/components/accordion.d.mts +5 -6
  3. package/dist/components/alert.d.mts +9 -11
  4. package/dist/components/area-chart.d.mts +62 -0
  5. package/dist/components/area-chart.mjs +269 -0
  6. package/dist/components/attachment-tile.d.mts +1 -3
  7. package/dist/components/avatar.d.mts +8 -10
  8. package/dist/components/badge.d.mts +2 -4
  9. package/dist/components/bar-chart.d.mts +48 -0
  10. package/dist/components/bar-chart.mjs +256 -0
  11. package/dist/components/bar-list.d.mts +28 -0
  12. package/dist/components/bar-list.mjs +98 -0
  13. package/dist/components/breadcrumb.d.mts +10 -11
  14. package/dist/components/button.d.mts +6 -8
  15. package/dist/components/card.d.mts +9 -10
  16. package/dist/components/chart-card.d.mts +25 -0
  17. package/dist/components/chart-card.mjs +48 -0
  18. package/dist/components/chart-container.d.mts +20 -0
  19. package/dist/components/chart-container.mjs +37 -0
  20. package/dist/components/chart-legend.d.mts +16 -0
  21. package/dist/components/chart-legend.mjs +26 -0
  22. package/dist/components/chart-tooltip.d.mts +33 -0
  23. package/dist/components/chart-tooltip.mjs +52 -0
  24. package/dist/components/checkbox.d.mts +2 -3
  25. package/dist/components/collapsible.d.mts +4 -5
  26. package/dist/components/combobox.d.mts +12 -11
  27. package/dist/components/combobox.mjs +7 -4
  28. package/dist/components/command.d.mts +9 -10
  29. package/dist/components/copyable.d.mts +2 -3
  30. package/dist/components/description-list.d.mts +5 -6
  31. package/dist/components/dialog.d.mts +15 -17
  32. package/dist/components/donut-chart.d.mts +46 -0
  33. package/dist/components/donut-chart.mjs +185 -0
  34. package/dist/components/dropdown-menu.d.mts +18 -20
  35. package/dist/components/form.d.mts +38 -21
  36. package/dist/components/form.mjs +6 -6
  37. package/dist/components/github-button.d.mts +1 -2
  38. package/dist/components/heatmap-chart.d.mts +40 -0
  39. package/dist/components/heatmap-chart.mjs +198 -0
  40. package/dist/components/input-group.d.mts +5 -7
  41. package/dist/components/input.d.mts +4 -5
  42. package/dist/components/input.mjs +2 -2
  43. package/dist/components/label.d.mts +2 -3
  44. package/dist/components/line-chart.d.mts +55 -0
  45. package/dist/components/line-chart.mjs +211 -0
  46. package/dist/components/page-loader.d.mts +1 -3
  47. package/dist/components/pagination.d.mts +3 -4
  48. package/dist/components/popover.d.mts +5 -6
  49. package/dist/components/radio-group.d.mts +3 -4
  50. package/dist/components/scroll-area.d.mts +3 -4
  51. package/dist/components/select-trigger-variants.d.mts +1 -3
  52. package/dist/components/select.d.mts +9 -10
  53. package/dist/components/separator.d.mts +2 -3
  54. package/dist/components/sheet.d.mts +11 -12
  55. package/dist/components/shimmer-text.d.mts +2 -2
  56. package/dist/components/sidebar.d.mts +34 -36
  57. package/dist/components/sidebar.mjs +10 -10
  58. package/dist/components/skeleton.d.mts +2 -4
  59. package/dist/components/sonner.d.mts +5 -6
  60. package/dist/components/spinner.d.mts +3 -5
  61. package/dist/components/stat.d.mts +30 -0
  62. package/dist/components/stat.mjs +107 -0
  63. package/dist/components/status-dot.d.mts +2 -4
  64. package/dist/components/switch.d.mts +2 -3
  65. package/dist/components/table.d.mts +10 -11
  66. package/dist/components/tabs.d.mts +12 -14
  67. package/dist/components/tag.d.mts +3 -5
  68. package/dist/components/task-progress.d.mts +1 -3
  69. package/dist/components/textarea.d.mts +3 -4
  70. package/dist/components/textarea.mjs +2 -2
  71. package/dist/components/toggle-group.d.mts +4 -6
  72. package/dist/components/toggle-group.mjs +3 -3
  73. package/dist/components/tooltip-icon-button.d.mts +1 -2
  74. package/dist/components/tooltip.d.mts +5 -6
  75. package/dist/components/typography.d.mts +4 -5
  76. package/dist/components/wizard.d.mts +4 -23
  77. package/dist/components/wizard.mjs +1 -19
  78. package/dist/hooks/use-chart-theme.d.mts +18 -0
  79. package/dist/hooks/use-chart-theme.mjs +57 -0
  80. package/dist/hooks/use-mobile.mjs +3 -3
  81. package/dist/hooks/use-reduced-motion.d.mts +4 -0
  82. package/dist/hooks/use-reduced-motion.mjs +16 -0
  83. package/dist/lib/chart-palette.d.mts +4 -0
  84. package/dist/lib/chart-palette.mjs +95 -0
  85. package/dist/lib/chart.d.mts +14 -0
  86. package/dist/lib/chart.mjs +27 -0
  87. package/package.json +30 -29
  88. package/src/components/area-chart.tsx +339 -0
  89. package/src/components/bar-chart.tsx +309 -0
  90. package/src/components/bar-list.tsx +150 -0
  91. package/src/components/chart-card.tsx +63 -0
  92. package/src/components/chart-container.tsx +49 -0
  93. package/src/components/chart-legend.tsx +41 -0
  94. package/src/components/chart-tooltip.tsx +93 -0
  95. package/src/components/combobox.tsx +9 -2
  96. package/src/components/donut-chart.tsx +217 -0
  97. package/src/components/heatmap-chart.tsx +287 -0
  98. package/src/components/line-chart.tsx +264 -0
  99. package/src/components/stat.tsx +109 -0
  100. package/src/components/wizard.tsx +1 -35
  101. package/src/hooks/use-chart-theme.ts +75 -0
  102. package/src/hooks/use-reduced-motion.ts +17 -0
  103. package/src/lib/chart-palette.ts +110 -0
  104. package/src/lib/chart.ts +56 -0
  105. package/src/stories/area-chart.stories.tsx +198 -0
  106. package/src/stories/bar-chart.stories.tsx +167 -0
  107. package/src/stories/bar-list.stories.tsx +83 -0
  108. package/src/stories/donut-chart.stories.tsx +110 -0
  109. package/src/stories/heatmap-chart.stories.tsx +105 -0
  110. package/src/stories/line-chart.stories.tsx +144 -0
  111. package/src/stories/stat.stories.tsx +64 -0
  112. package/src/stories/wizard.stories.tsx +22 -4
  113. package/src/styles/tokens.css +63 -0
@@ -1,6 +1,5 @@
1
1
  import * as AccordionPrimitive from "@radix-ui/react-accordion";
2
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
- import * as React from "react";
2
+ import * as React$1 from "react";
4
3
 
5
4
  //#region src/components/accordion-card.d.ts
6
5
  declare function AccordionCard({
@@ -16,17 +15,17 @@ declare function AccordionCard({
16
15
  open?: boolean;
17
16
  onOpenChange?: (nextOpen: boolean) => void;
18
17
  disabled?: boolean;
19
- } & Omit<React.ComponentProps<typeof AccordionPrimitive.Root>, "type" | "collapsible" | "defaultValue" | "value" | "onValueChange" | "disabled">): _$react_jsx_runtime0.JSX.Element;
18
+ } & Omit<React$1.ComponentProps<typeof AccordionPrimitive.Root>, "type" | "collapsible" | "defaultValue" | "value" | "onValueChange" | "disabled">): React$1.JSX.Element;
20
19
  declare function AccordionCardHeader({
21
20
  className,
22
21
  children,
23
22
  ...props
24
- }: React.ComponentProps<typeof AccordionPrimitive.Trigger>): _$react_jsx_runtime0.JSX.Element;
23
+ }: React$1.ComponentProps<typeof AccordionPrimitive.Trigger>): React$1.JSX.Element;
25
24
  declare function AccordionCardTitle({
26
25
  className,
27
26
  children,
28
27
  ...props
29
- }: React.HTMLAttributes<HTMLHeadingElement>): _$react_jsx_runtime0.JSX.Element;
28
+ }: React$1.HTMLAttributes<HTMLHeadingElement>): React$1.JSX.Element;
30
29
  /**
31
30
  * `className` is forwarded to the inner padding wrapper, not the Radix Content root.
32
31
  * The root always applies overflow-hidden and the accordion animations.
@@ -36,6 +35,6 @@ declare function AccordionCardContent({
36
35
  className,
37
36
  children,
38
37
  ...props
39
- }: React.ComponentProps<typeof AccordionPrimitive.Content>): _$react_jsx_runtime0.JSX.Element;
38
+ }: React$1.ComponentProps<typeof AccordionPrimitive.Content>): React$1.JSX.Element;
40
39
  //#endregion
41
40
  export { AccordionCard, AccordionCardContent, AccordionCardHeader, AccordionCardTitle };
@@ -1,20 +1,19 @@
1
1
  import * as AccordionPrimitive from "@radix-ui/react-accordion";
2
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
- import * as React from "react";
2
+ import * as React$1 from "react";
4
3
 
5
4
  //#region src/components/accordion.d.ts
6
5
  declare function Accordion({
7
6
  ...props
8
- }: React.ComponentProps<typeof AccordionPrimitive.Root>): _$react_jsx_runtime0.JSX.Element;
7
+ }: React$1.ComponentProps<typeof AccordionPrimitive.Root>): React$1.JSX.Element;
9
8
  declare function AccordionItem({
10
9
  className,
11
10
  ...props
12
- }: React.ComponentProps<typeof AccordionPrimitive.Item>): _$react_jsx_runtime0.JSX.Element;
11
+ }: React$1.ComponentProps<typeof AccordionPrimitive.Item>): React$1.JSX.Element;
13
12
  declare function AccordionTrigger({
14
13
  className,
15
14
  children,
16
15
  ...props
17
- }: React.ComponentProps<typeof AccordionPrimitive.Trigger>): _$react_jsx_runtime0.JSX.Element;
16
+ }: React$1.ComponentProps<typeof AccordionPrimitive.Trigger>): React$1.JSX.Element;
18
17
  /**
19
18
  * `className` is forwarded to the inner padding wrapper, not the Radix Content root.
20
19
  * The root always applies overflow-hidden and the accordion animations.
@@ -24,6 +23,6 @@ declare function AccordionContent({
24
23
  className,
25
24
  children,
26
25
  ...props
27
- }: React.ComponentProps<typeof AccordionPrimitive.Content>): _$react_jsx_runtime0.JSX.Element;
26
+ }: React$1.ComponentProps<typeof AccordionPrimitive.Content>): React$1.JSX.Element;
28
27
  //#endregion
29
28
  export { Accordion, AccordionContent, AccordionItem, AccordionTrigger };
@@ -1,40 +1,38 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import { VariantProps } from "class-variance-authority";
3
- import * as React from "react";
4
- import * as _$class_variance_authority_types0 from "class-variance-authority/types";
2
+ import * as React$1 from "react";
5
3
 
6
4
  //#region src/components/alert.d.ts
7
5
  declare const alertVariants: (props?: ({
8
6
  variant?: "default" | "destructive" | "warning" | "success" | null | undefined;
9
- } & _$class_variance_authority_types0.ClassProp) | undefined) => string;
10
- interface AlertProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof alertVariants> {}
7
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
8
+ interface AlertProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof alertVariants> {}
11
9
  declare function Alert({
12
10
  className,
13
11
  variant,
14
12
  ...props
15
- }: AlertProps): _$react_jsx_runtime0.JSX.Element;
13
+ }: AlertProps): React$1.JSX.Element;
16
14
  declare function AlertTitle({
17
15
  className,
18
16
  ...props
19
- }: React.HTMLAttributes<HTMLParagraphElement>): _$react_jsx_runtime0.JSX.Element;
17
+ }: React$1.HTMLAttributes<HTMLParagraphElement>): React$1.JSX.Element;
20
18
  declare function AlertDescription({
21
19
  className,
22
20
  ...props
23
- }: React.HTMLAttributes<HTMLDivElement>): _$react_jsx_runtime0.JSX.Element;
21
+ }: React$1.HTMLAttributes<HTMLDivElement>): React$1.JSX.Element;
24
22
  interface ConvenienceAlertProps {
25
23
  title?: string;
26
- description?: React.ReactNode;
24
+ description?: React$1.ReactNode;
27
25
  className?: string;
28
26
  }
29
27
  declare function ErrorAlert({
30
28
  title,
31
29
  description,
32
30
  className
33
- }: ConvenienceAlertProps): _$react_jsx_runtime0.JSX.Element;
31
+ }: ConvenienceAlertProps): React$1.JSX.Element;
34
32
  declare function WarningAlert({
35
33
  title,
36
34
  description,
37
35
  className
38
- }: ConvenienceAlertProps): _$react_jsx_runtime0.JSX.Element;
36
+ }: ConvenienceAlertProps): React$1.JSX.Element;
39
37
  //#endregion
40
38
  export { Alert, AlertDescription, AlertTitle, ErrorAlert, WarningAlert };
@@ -0,0 +1,62 @@
1
+ import { ChartSeries } from "../lib/chart.mjs";
2
+ import { ChartPaletteName } from "../lib/chart-palette.mjs";
3
+ import * as React$1 from "react";
4
+
5
+ //#region src/components/area-chart.d.ts
6
+ declare const CURVE_TYPE: {
7
+ readonly monotone: "monotone";
8
+ readonly linear: "linear";
9
+ readonly step: "stepAfter";
10
+ };
11
+ interface ChartMarker {
12
+ x: string | number;
13
+ y: number;
14
+ label?: string;
15
+ color?: string;
16
+ }
17
+ interface AreaChartProps {
18
+ data: ReadonlyArray<Record<string, string | number | null | undefined>>;
19
+ index: string;
20
+ series: ChartSeries[];
21
+ variant?: "stacked" | "grouped" | "expand";
22
+ curve?: keyof typeof CURVE_TYPE;
23
+ legend?: boolean;
24
+ valueFlags?: boolean;
25
+ height?: number;
26
+ yAxisWidth?: number;
27
+ palette?: ChartPaletteName;
28
+ referenceLine?: {
29
+ y: number;
30
+ label?: string;
31
+ band?: boolean;
32
+ };
33
+ markers?: ChartMarker[];
34
+ lastValueLabel?: boolean;
35
+ texture?: boolean;
36
+ loading?: boolean;
37
+ valueFormatter?: (value: number) => string;
38
+ labelFormatter?: (label: string | number) => string;
39
+ className?: string;
40
+ }
41
+ declare function AreaChart({
42
+ data,
43
+ index,
44
+ series,
45
+ variant,
46
+ curve,
47
+ legend,
48
+ valueFlags,
49
+ height,
50
+ yAxisWidth,
51
+ palette,
52
+ referenceLine,
53
+ markers,
54
+ lastValueLabel,
55
+ texture,
56
+ loading,
57
+ valueFormatter,
58
+ labelFormatter,
59
+ className
60
+ }: AreaChartProps): React$1.JSX.Element;
61
+ //#endregion
62
+ export { AreaChart, AreaChartProps, ChartMarker };
@@ -0,0 +1,269 @@
1
+ "use client";
2
+ import { cn } from "../lib/cn.mjs";
3
+ import { useReducedMotion } from "../hooks/use-reduced-motion.mjs";
4
+ import { orderByLuminance, resolveSeries } from "../lib/chart.mjs";
5
+ import { useChartContext } from "./chart-container.mjs";
6
+ import { ChartLegend } from "./chart-legend.mjs";
7
+ import { ChartTooltipContent } from "./chart-tooltip.mjs";
8
+ import { jsx, jsxs } from "react/jsx-runtime";
9
+ import * as React$1 from "react";
10
+ import { Area, AreaChart as AreaChart$1, CartesianGrid, LabelList, ReferenceArea, ReferenceDot, ReferenceLine, ResponsiveContainer, Tooltip, XAxis, YAxis } from "recharts";
11
+ //#region src/components/area-chart.tsx
12
+ const CURVE_TYPE = {
13
+ monotone: "monotone",
14
+ linear: "linear",
15
+ step: "stepAfter"
16
+ };
17
+ function AreaChart({ data, index, series, variant = "stacked", curve = "monotone", legend = false, valueFlags = false, height = 200, yAxisWidth = 48, palette, referenceLine, markers, lastValueLabel = false, texture = false, loading = false, valueFormatter = (value) => value.toLocaleString("en-US"), labelFormatter, className }) {
18
+ const { palette: paletteColors, theme } = useChartContext(palette);
19
+ const reactId = React$1.useId().replace(/:/g, "");
20
+ const animated = !useReducedMotion();
21
+ const resolved = resolveSeries(series, paletteColors, theme);
22
+ const stacked = variant === "stacked" || variant === "expand";
23
+ const rendered = stacked ? orderByLuminance(resolved) : resolved;
24
+ const filled = !(variant === "grouped" && rendered.length > 1);
25
+ const lead = resolved[0];
26
+ const withTotal = stacked && rendered.length > 1;
27
+ const numericMax = React$1.useMemo(() => {
28
+ let max = 0;
29
+ for (const row of data) {
30
+ let rowTotal = 0;
31
+ for (const entry of series) {
32
+ const value = Number(row[entry.key]);
33
+ if (Number.isFinite(value)) {
34
+ rowTotal += value;
35
+ if (!stacked && value > max) max = value;
36
+ }
37
+ }
38
+ if (stacked && rowTotal > max) max = rowTotal;
39
+ }
40
+ return max;
41
+ }, [
42
+ data,
43
+ series,
44
+ stacked
45
+ ]);
46
+ const curveType = CURVE_TYPE[curve];
47
+ const margin = {
48
+ top: markers?.length ? 18 : 8,
49
+ right: lastValueLabel ? 56 : 8,
50
+ bottom: 2,
51
+ left: 0
52
+ };
53
+ const axis = {
54
+ stroke: theme.border,
55
+ tick: {
56
+ fill: theme.axisForeground,
57
+ fontSize: 10,
58
+ fontFamily: theme.fontMono
59
+ },
60
+ tickLine: false,
61
+ axisLine: {
62
+ stroke: theme.border,
63
+ strokeOpacity: .6
64
+ }
65
+ };
66
+ const legendItems = resolved.map((entry) => ({
67
+ name: entry.name,
68
+ color: entry.color,
69
+ dashed: entry.dashed
70
+ }));
71
+ const activeDotFor = (entry) => valueFlags ? (dotProps) => {
72
+ if (dotProps.cx == null || dotProps.cy == null) return /* @__PURE__ */ jsx("g", {});
73
+ return /* @__PURE__ */ jsxs("g", { children: [/* @__PURE__ */ jsx("circle", {
74
+ cx: dotProps.cx,
75
+ cy: dotProps.cy,
76
+ r: 3.5,
77
+ fill: entry.color,
78
+ stroke: theme.card,
79
+ strokeWidth: 2
80
+ }), /* @__PURE__ */ jsx("text", {
81
+ x: dotProps.cx,
82
+ y: dotProps.cy - 8,
83
+ textAnchor: "middle",
84
+ fill: entry.color,
85
+ fontFamily: theme.fontMono,
86
+ fontSize: 10,
87
+ style: { fontVariantNumeric: "tabular-nums" },
88
+ children: valueFormatter(Number(dotProps.value ?? 0))
89
+ })] });
90
+ } : {
91
+ r: 3.5,
92
+ fill: entry.color,
93
+ stroke: theme.card,
94
+ strokeWidth: 2
95
+ };
96
+ const fillFor = (entry, slot) => {
97
+ if (!filled) return "none";
98
+ if (texture && lead && entry.key === lead.key) return `url(#hatch-${reactId})`;
99
+ return `url(#area-${reactId}-${slot})`;
100
+ };
101
+ const renderLastLabel = (color) => (props) => {
102
+ if (props.index !== data.length - 1 || props.x == null || props.y == null) return null;
103
+ return /* @__PURE__ */ jsx("text", {
104
+ x: Number(props.x) + 6,
105
+ y: Number(props.y),
106
+ dy: 3,
107
+ fill: color,
108
+ fontFamily: theme.fontMono,
109
+ fontSize: 10,
110
+ textAnchor: "start",
111
+ style: { fontVariantNumeric: "tabular-nums" },
112
+ children: valueFormatter(Number(props.value ?? 0))
113
+ });
114
+ };
115
+ const isEmpty = data.length === 0 || rendered.length === 0;
116
+ return /* @__PURE__ */ jsxs("div", {
117
+ "data-slot": "area-chart",
118
+ className: cn("flex w-full flex-col gap-3", className),
119
+ children: [/* @__PURE__ */ jsx("div", {
120
+ className: "w-full",
121
+ style: { height },
122
+ children: loading ? /* @__PURE__ */ jsxs("div", {
123
+ className: "flex h-full items-center justify-center gap-2.5 font-mono text-quaternary-foreground text-text-xs",
124
+ children: [/* @__PURE__ */ jsx("span", { className: "size-4 animate-spin rounded-full border-2 border-border border-t-foreground" }), "loading…"]
125
+ }) : isEmpty ? /* @__PURE__ */ jsx("div", {
126
+ className: "flex h-full items-center justify-center rounded-lg border border-border border-dashed font-mono text-quaternary-foreground text-text-xs",
127
+ children: "no data in range"
128
+ }) : /* @__PURE__ */ jsx(ResponsiveContainer, {
129
+ width: "100%",
130
+ height: "100%",
131
+ children: /* @__PURE__ */ jsxs(AreaChart$1, {
132
+ data,
133
+ stackOffset: variant === "expand" ? "expand" : "none",
134
+ margin,
135
+ children: [
136
+ /* @__PURE__ */ jsxs("defs", { children: [filled && rendered.map((entry, slot) => /* @__PURE__ */ jsxs("linearGradient", {
137
+ id: `area-${reactId}-${slot}`,
138
+ x1: "0",
139
+ y1: "0",
140
+ x2: "0",
141
+ y2: "1",
142
+ children: [/* @__PURE__ */ jsx("stop", {
143
+ offset: "0%",
144
+ stopColor: entry.color,
145
+ stopOpacity: stacked ? .78 : .5
146
+ }), /* @__PURE__ */ jsx("stop", {
147
+ offset: "100%",
148
+ stopColor: entry.color,
149
+ stopOpacity: stacked ? .32 : .04
150
+ })]
151
+ }, entry.key)), texture && filled && lead && /* @__PURE__ */ jsxs("pattern", {
152
+ id: `hatch-${reactId}`,
153
+ patternUnits: "userSpaceOnUse",
154
+ width: 6,
155
+ height: 6,
156
+ patternTransform: "rotate(45)",
157
+ children: [/* @__PURE__ */ jsx("rect", {
158
+ width: 6,
159
+ height: 6,
160
+ fill: lead.color,
161
+ fillOpacity: .18
162
+ }), /* @__PURE__ */ jsx("line", {
163
+ x1: 0,
164
+ y1: 0,
165
+ x2: 0,
166
+ y2: 6,
167
+ stroke: lead.color,
168
+ strokeWidth: 1.2,
169
+ strokeOpacity: .6
170
+ })]
171
+ })] }),
172
+ /* @__PURE__ */ jsx(CartesianGrid, {
173
+ vertical: false,
174
+ stroke: theme.grid,
175
+ strokeDasharray: "2 4"
176
+ }),
177
+ /* @__PURE__ */ jsx(XAxis, {
178
+ dataKey: index,
179
+ ...axis,
180
+ interval: "preserveStartEnd",
181
+ minTickGap: 44
182
+ }),
183
+ /* @__PURE__ */ jsx(YAxis, {
184
+ ...axis,
185
+ width: yAxisWidth,
186
+ tickFormatter: (value) => variant === "expand" ? `${Math.round(value * 100)}%` : valueFormatter(value)
187
+ }),
188
+ /* @__PURE__ */ jsx(Tooltip, {
189
+ offset: 12,
190
+ allowEscapeViewBox: {
191
+ x: false,
192
+ y: false
193
+ },
194
+ cursor: {
195
+ stroke: theme.axisForeground,
196
+ strokeWidth: 1,
197
+ strokeDasharray: "3 3"
198
+ },
199
+ content: /* @__PURE__ */ jsx(ChartTooltipContent, {
200
+ valueFormatter,
201
+ labelFormatter,
202
+ showTotal: withTotal
203
+ })
204
+ }),
205
+ referenceLine?.band && /* @__PURE__ */ jsx(ReferenceArea, {
206
+ y1: referenceLine.y,
207
+ y2: numericMax,
208
+ fill: theme.warning,
209
+ fillOpacity: .06,
210
+ ifOverflow: "extendDomain"
211
+ }),
212
+ referenceLine && /* @__PURE__ */ jsx(ReferenceLine, {
213
+ y: referenceLine.y,
214
+ stroke: theme.warning,
215
+ strokeDasharray: "4 4",
216
+ strokeOpacity: .6,
217
+ label: referenceLine.label ? {
218
+ value: referenceLine.label,
219
+ fill: theme.warning,
220
+ fontSize: 9,
221
+ fontFamily: theme.fontMono,
222
+ position: "insideBottomRight"
223
+ } : void 0
224
+ }),
225
+ rendered.map((entry, slot) => /* @__PURE__ */ jsx(Area, {
226
+ type: curveType,
227
+ dataKey: entry.key,
228
+ name: entry.name,
229
+ stackId: stacked ? "stack" : void 0,
230
+ stroke: entry.color,
231
+ strokeWidth: entry.dashed ? 2 : 1.6,
232
+ strokeDasharray: entry.dashed ? "5 3" : void 0,
233
+ fill: fillFor(entry, slot),
234
+ dot: false,
235
+ activeDot: activeDotFor(entry),
236
+ isAnimationActive: animated,
237
+ animationDuration: 650,
238
+ animationEasing: "ease-out",
239
+ children: lastValueLabel && /* @__PURE__ */ jsx(LabelList, {
240
+ dataKey: entry.key,
241
+ content: renderLastLabel(entry.color)
242
+ })
243
+ }, entry.key)),
244
+ markers?.map((marker) => /* @__PURE__ */ jsx(ReferenceDot, {
245
+ x: marker.x,
246
+ y: marker.y,
247
+ r: 3.5,
248
+ fill: marker.color ?? theme.foreground,
249
+ stroke: theme.card,
250
+ strokeWidth: 2,
251
+ label: marker.label ? {
252
+ value: marker.label,
253
+ fill: marker.color ?? theme.foreground,
254
+ fontSize: 9,
255
+ fontFamily: theme.fontMono,
256
+ position: "top"
257
+ } : void 0
258
+ }, `${marker.x}-${marker.y}`))
259
+ ]
260
+ })
261
+ })
262
+ }), legend && !isEmpty && /* @__PURE__ */ jsx(ChartLegend, {
263
+ items: legendItems,
264
+ style: { paddingLeft: yAxisWidth }
265
+ })]
266
+ });
267
+ }
268
+ //#endregion
269
+ export { AreaChart };
@@ -1,5 +1,3 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
-
3
1
  //#region src/components/attachment-tile.d.ts
4
2
  interface AttachmentTileProps {
5
3
  /** Source URL for the attachment thumbnail */
@@ -21,6 +19,6 @@ declare function AttachmentTile({
21
19
  onRemove,
22
20
  onClick,
23
21
  className
24
- }: AttachmentTileProps): _$react_jsx_runtime0.JSX.Element;
22
+ }: AttachmentTileProps): import("react").JSX.Element;
25
23
  //#endregion
26
24
  export { AttachmentTile, type AttachmentTileProps };
@@ -1,16 +1,14 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import { VariantProps } from "class-variance-authority";
3
- import * as React from "react";
2
+ import * as React$1 from "react";
4
3
  import * as AvatarPrimitive from "@radix-ui/react-avatar";
5
- import * as _$class_variance_authority_types0 from "class-variance-authority/types";
6
4
 
7
5
  //#region src/components/avatar.d.ts
8
6
  declare const avatarVariants: (props?: ({
9
7
  size?: "xs" | "sm" | "md" | "lg" | "xl" | null | undefined;
10
- } & _$class_variance_authority_types0.ClassProp) | undefined) => string;
8
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
11
9
  type AvatarSize = NonNullable<VariantProps<typeof avatarVariants>["size"]>;
12
10
  type AvatarStatus = "online";
13
- interface AvatarProps extends React.ComponentProps<typeof AvatarPrimitive.Root>, VariantProps<typeof avatarVariants> {
11
+ interface AvatarProps extends React$1.ComponentProps<typeof AvatarPrimitive.Root>, VariantProps<typeof avatarVariants> {
14
12
  status?: AvatarStatus;
15
13
  }
16
14
  declare function Avatar({
@@ -19,16 +17,16 @@ declare function Avatar({
19
17
  className,
20
18
  children,
21
19
  ...props
22
- }: AvatarProps): _$react_jsx_runtime0.JSX.Element;
20
+ }: AvatarProps): React$1.JSX.Element;
23
21
  declare function AvatarImage({
24
22
  className,
25
23
  ...props
26
- }: React.ComponentProps<typeof AvatarPrimitive.Image>): _$react_jsx_runtime0.JSX.Element;
24
+ }: React$1.ComponentProps<typeof AvatarPrimitive.Image>): React$1.JSX.Element;
27
25
  declare function AvatarFallback({
28
26
  className,
29
27
  ...props
30
- }: React.ComponentProps<typeof AvatarPrimitive.Fallback>): _$react_jsx_runtime0.JSX.Element;
31
- interface AvatarLabelGroupProps extends React.ComponentProps<"div"> {
28
+ }: React$1.ComponentProps<typeof AvatarPrimitive.Fallback>): React$1.JSX.Element;
29
+ interface AvatarLabelGroupProps extends React$1.ComponentProps<"div"> {
32
30
  size?: "sm" | "md";
33
31
  src?: string;
34
32
  alt?: string;
@@ -47,6 +45,6 @@ declare function AvatarLabelGroup({
47
45
  status,
48
46
  className,
49
47
  ...props
50
- }: AvatarLabelGroupProps): _$react_jsx_runtime0.JSX.Element;
48
+ }: AvatarLabelGroupProps): React$1.JSX.Element;
51
49
  //#endregion
52
50
  export { Avatar, AvatarFallback, AvatarImage, AvatarLabelGroup, type AvatarSize, type AvatarStatus };
@@ -1,12 +1,10 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import { VariantProps } from "class-variance-authority";
3
- import * as _$class_variance_authority_types0 from "class-variance-authority/types";
4
2
 
5
3
  //#region src/components/badge.d.ts
6
4
  declare const badgeVariants: (props?: ({
7
5
  variant?: "warning" | "success" | "secondary" | "primary" | "error" | null | undefined;
8
6
  size?: "sm" | "md" | null | undefined;
9
- } & _$class_variance_authority_types0.ClassProp) | undefined) => string;
7
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
10
8
  interface BadgeProps extends React.ComponentProps<"span">, VariantProps<typeof badgeVariants> {}
11
9
  declare function Badge({
12
10
  className,
@@ -14,7 +12,7 @@ declare function Badge({
14
12
  size,
15
13
  children,
16
14
  ...props
17
- }: BadgeProps): _$react_jsx_runtime0.JSX.Element;
15
+ }: BadgeProps): import("react").JSX.Element;
18
16
  type BadgeVariant = NonNullable<VariantProps<typeof badgeVariants>["variant"]>;
19
17
  //#endregion
20
18
  export { Badge, type BadgeVariant, badgeVariants };
@@ -0,0 +1,48 @@
1
+ import { ChartSeries } from "../lib/chart.mjs";
2
+ import { ChartPaletteName } from "../lib/chart-palette.mjs";
3
+ import { ChartMarker } from "./area-chart.mjs";
4
+ import * as React$1 from "react";
5
+
6
+ //#region src/components/bar-chart.d.ts
7
+ interface BarChartProps {
8
+ data: ReadonlyArray<Record<string, string | number | null | undefined>>;
9
+ index: string;
10
+ series: ChartSeries[];
11
+ variant?: "stacked" | "grouped" | "expand";
12
+ legend?: boolean;
13
+ valueLabels?: boolean;
14
+ height?: number;
15
+ yAxisWidth?: number;
16
+ palette?: ChartPaletteName;
17
+ referenceLine?: {
18
+ y: number;
19
+ label?: string;
20
+ band?: boolean;
21
+ };
22
+ markers?: ChartMarker[];
23
+ texture?: boolean;
24
+ loading?: boolean;
25
+ valueFormatter?: (value: number) => string;
26
+ labelFormatter?: (label: string | number) => string;
27
+ className?: string;
28
+ }
29
+ declare function BarChart({
30
+ data,
31
+ index,
32
+ series,
33
+ variant,
34
+ legend,
35
+ valueLabels,
36
+ height,
37
+ yAxisWidth,
38
+ palette,
39
+ referenceLine,
40
+ markers,
41
+ texture,
42
+ loading,
43
+ valueFormatter,
44
+ labelFormatter,
45
+ className
46
+ }: BarChartProps): React$1.JSX.Element;
47
+ //#endregion
48
+ export { BarChart, BarChartProps };