iryx-ui 0.23.0 → 0.24.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.
@@ -3,7 +3,7 @@
3
3
  * Consumed by the Vue plugin (global registration) and the Nuxt module
4
4
  * (auto-imports). Keep in sync with `src/components/index.ts`.
5
5
  */
6
- export declare const componentNames: readonly ["Accordion", "Alert", "App", "AppShell", "AspectRatio", "AuthProviders", "Avatar", "AvatarGroup", "Badge", "BarChart", "Banner", "Breadcrumb", "Button", "ButtonGroup", "Calendar", "Card", "Carousel", "ChartLegend", "Checkbox", "Code", "ColorPicker", "Combobox", "Collapsible", "CommandPalette", "Container", "ConfirmDialog", "ContextMenu", "DateField", "DatePicker", "DateRangePicker", "DescriptionList", "Dialog", "DonutChart", "Drawer", "DropdownMenu", "Editable", "EmptyState", "FileUpload", "Form", "FormField", "HoverCard", "Icon", "Input", "Kbd", "Label", "LineChart", "NavigationMenu", "NumberInput", "Menubar", "PageHeader", "Pagination", "PasswordInput", "PinInput", "Popover", "Progress", "RadioGroup", "Rating", "ScrollArea", "ScrollFade", "Select", "Separator", "Sidebar", "SignaturePad", "Skeleton", "Slider", "Sparkline", "Splitter", "Stat", "Stepper", "Switch", "Table", "Tabs", "TagsInput", "Textarea", "Toaster", "Toggle", "ToggleGroup", "TimeField", "Timeline", "Toolbar", "Tooltip", "Tree"];
6
+ export declare const componentNames: readonly ["Accordion", "Alert", "App", "AppShell", "AspectRatio", "AuthProviders", "Avatar", "AvatarGroup", "Badge", "BarChart", "Banner", "Breadcrumb", "Button", "ButtonGroup", "Calendar", "Card", "Carousel", "ChartLegend", "Checkbox", "Code", "ColorPicker", "Combobox", "Collapsible", "CommandPalette", "Container", "ConfirmDialog", "ConfirmPopover", "ContextMenu", "DateField", "DatePicker", "DateRangePicker", "DescriptionList", "Dialog", "DonutChart", "Drawer", "DropdownMenu", "Editable", "EmptyState", "FileUpload", "Form", "FormField", "HoverCard", "Icon", "Input", "Kbd", "Label", "LineChart", "NavigationMenu", "NumberInput", "Menubar", "PageHeader", "Pagination", "PasswordInput", "PinInput", "Popover", "Progress", "RadioGroup", "Rating", "ScrollArea", "ScrollFade", "Select", "Separator", "Sidebar", "SignaturePad", "Skeleton", "Slider", "Sparkline", "Splitter", "Stat", "Stepper", "Switch", "Table", "Tabs", "TagsInput", "Textarea", "Toaster", "Toggle", "ToggleGroup", "TimeField", "Timeline", "Toolbar", "Tooltip", "Tree"];
7
7
  export type ComponentName = (typeof componentNames)[number];
8
8
  /**
9
9
  * Names of every block exported from `iryx-ui/marketing`.
@@ -1,5 +1,5 @@
1
1
  //#region src/component-names.ts
2
- var e = /* @__PURE__ */ "Accordion.Alert.App.AppShell.AspectRatio.AuthProviders.Avatar.AvatarGroup.Badge.BarChart.Banner.Breadcrumb.Button.ButtonGroup.Calendar.Card.Carousel.ChartLegend.Checkbox.Code.ColorPicker.Combobox.Collapsible.CommandPalette.Container.ConfirmDialog.ContextMenu.DateField.DatePicker.DateRangePicker.DescriptionList.Dialog.DonutChart.Drawer.DropdownMenu.Editable.EmptyState.FileUpload.Form.FormField.HoverCard.Icon.Input.Kbd.Label.LineChart.NavigationMenu.NumberInput.Menubar.PageHeader.Pagination.PasswordInput.PinInput.Popover.Progress.RadioGroup.Rating.ScrollArea.ScrollFade.Select.Separator.Sidebar.SignaturePad.Skeleton.Slider.Sparkline.Splitter.Stat.Stepper.Switch.Table.Tabs.TagsInput.Textarea.Toaster.Toggle.ToggleGroup.TimeField.Timeline.Toolbar.Tooltip.Tree".split("."), t = [
2
+ var e = /* @__PURE__ */ "Accordion.Alert.App.AppShell.AspectRatio.AuthProviders.Avatar.AvatarGroup.Badge.BarChart.Banner.Breadcrumb.Button.ButtonGroup.Calendar.Card.Carousel.ChartLegend.Checkbox.Code.ColorPicker.Combobox.Collapsible.CommandPalette.Container.ConfirmDialog.ConfirmPopover.ContextMenu.DateField.DatePicker.DateRangePicker.DescriptionList.Dialog.DonutChart.Drawer.DropdownMenu.Editable.EmptyState.FileUpload.Form.FormField.HoverCard.Icon.Input.Kbd.Label.LineChart.NavigationMenu.NumberInput.Menubar.PageHeader.Pagination.PasswordInput.PinInput.Popover.Progress.RadioGroup.Rating.ScrollArea.ScrollFade.Select.Separator.Sidebar.SignaturePad.Skeleton.Slider.Sparkline.Splitter.Stat.Stepper.Switch.Table.Tabs.TagsInput.Textarea.Toaster.Toggle.ToggleGroup.TimeField.Timeline.Toolbar.Tooltip.Tree".split("."), t = [
3
3
  "BrowserFrame",
4
4
  "FeatureCard",
5
5
  "Hero",
@@ -0,0 +1,5 @@
1
+ import e from "./ConfirmPopover.vue_vue_type_script_setup_true_lang.js";
2
+ //#region src/components/ConfirmPopover.vue
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };
@@ -0,0 +1,63 @@
1
+ import type { ClassValue } from '../class-value';
2
+ export interface ConfirmPopoverProps {
3
+ /** The question. */
4
+ title?: string;
5
+ /** Secondary detail under the question. */
6
+ description?: string;
7
+ confirmLabel?: string;
8
+ cancelLabel?: string;
9
+ /** Style the confirming button as destructive. */
10
+ danger?: boolean;
11
+ side?: 'top' | 'right' | 'bottom' | 'left';
12
+ align?: 'start' | 'center' | 'end';
13
+ sideOffset?: number;
14
+ /** Render the little pointer against the trigger. */
15
+ arrow?: boolean;
16
+ /** Skip built-in classes; you take over styling entirely. */
17
+ unstyled?: boolean;
18
+ class?: ClassValue;
19
+ /** Override classes per element, e.g. `{ confirm: 'w-full' }`. */
20
+ ui?: {
21
+ content?: string;
22
+ title?: string;
23
+ description?: string;
24
+ actions?: string;
25
+ cancel?: string;
26
+ confirm?: string;
27
+ };
28
+ }
29
+ type __VLS_Props = ConfirmPopoverProps;
30
+ type __VLS_ModelProps = {
31
+ 'open'?: boolean | undefined;
32
+ };
33
+ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
34
+ declare var __VLS_9: {}, __VLS_11: {};
35
+ type __VLS_Slots = {} & {
36
+ trigger?: (props: typeof __VLS_9) => any;
37
+ } & {
38
+ description?: (props: typeof __VLS_11) => any;
39
+ };
40
+ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
41
+ "update:open": (value: boolean | undefined) => any;
42
+ cancel: () => any;
43
+ confirm: () => any;
44
+ }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
45
+ "onUpdate:open"?: ((value: boolean | undefined) => any) | undefined;
46
+ onCancel?: (() => any) | undefined;
47
+ onConfirm?: (() => any) | undefined;
48
+ }>, {
49
+ unstyled: boolean;
50
+ side: "top" | "right" | "bottom" | "left";
51
+ sideOffset: number;
52
+ confirmLabel: string;
53
+ cancelLabel: string;
54
+ arrow: boolean;
55
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
56
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
57
+ declare const _default: typeof __VLS_export;
58
+ export default _default;
59
+ type __VLS_WithSlots<T, S> = T & {
60
+ new (): {
61
+ $slots: S;
62
+ };
63
+ };
@@ -0,0 +1,102 @@
1
+ import { useIryxUiConfig as e } from "../config.js";
2
+ import t from "./Button.js";
3
+ import { confirmPopoverTheme as n } from "../theme/confirm-popover.js";
4
+ import r from "./Popover.js";
5
+ import { computed as i, createBlock as a, createCommentVNode as o, createElementBlock as s, createElementVNode as c, createTextVNode as l, createVNode as u, defineComponent as d, mergeModels as f, normalizeClass as p, openBlock as m, renderSlot as h, toDisplayString as g, useModel as _, withCtx as v } from "vue";
6
+ //#region src/components/ConfirmPopover.vue?vue&type=script&setup=true&lang.ts
7
+ var y = /*@__PURE__*/ d({
8
+ __name: "ConfirmPopover",
9
+ props: /*@__PURE__*/ f({
10
+ title: {},
11
+ description: {},
12
+ confirmLabel: { default: "Confirm" },
13
+ cancelLabel: { default: "Cancel" },
14
+ danger: { type: Boolean },
15
+ side: { default: "bottom" },
16
+ align: {},
17
+ sideOffset: { default: 6 },
18
+ arrow: {
19
+ type: Boolean,
20
+ default: !0
21
+ },
22
+ unstyled: {
23
+ type: Boolean,
24
+ default: void 0
25
+ },
26
+ class: { type: [
27
+ String,
28
+ Boolean,
29
+ null,
30
+ Array
31
+ ] },
32
+ ui: {}
33
+ }, {
34
+ open: {
35
+ type: Boolean,
36
+ default: void 0
37
+ },
38
+ openModifiers: {}
39
+ }),
40
+ emits: /*@__PURE__*/ f(["confirm", "cancel"], ["update:open"]),
41
+ setup(d, { emit: f }) {
42
+ let y = d, b = f, x = _(d, "open");
43
+ function S() {
44
+ b("confirm"), x.value = !1;
45
+ }
46
+ function C() {
47
+ b("cancel"), x.value = !1;
48
+ }
49
+ let w = e(), T = i(() => y.unstyled ?? w.unstyled), E = i(() => n()), D = i(() => T.value ? y.ui?.description : E.value.description({ class: y.ui?.description })), O = i(() => T.value ? y.ui?.actions : E.value.actions({ class: y.ui?.actions }));
50
+ return (e, n) => (m(), a(r, {
51
+ open: x.value,
52
+ "onUpdate:open": n[0] ||= (e) => x.value = e,
53
+ side: y.side,
54
+ align: y.align,
55
+ "side-offset": y.sideOffset,
56
+ arrow: y.arrow,
57
+ padding: "sm",
58
+ width: "sm",
59
+ title: y.title,
60
+ unstyled: y.unstyled,
61
+ class: p(y.class),
62
+ ui: {
63
+ content: y.ui?.content,
64
+ title: y.ui?.title
65
+ }
66
+ }, {
67
+ trigger: v(() => [h(e.$slots, "trigger")]),
68
+ default: v(() => [y.description || e.$slots.description ? (m(), s("p", {
69
+ key: 0,
70
+ class: p(D.value)
71
+ }, [h(e.$slots, "description", {}, () => [l(g(y.description), 1)])], 2)) : o("", !0), c("div", { class: p(O.value) }, [u(t, {
72
+ size: "sm",
73
+ variant: "outline",
74
+ class: p(y.ui?.cancel),
75
+ onClick: C
76
+ }, {
77
+ default: v(() => [l(g(y.cancelLabel), 1)]),
78
+ _: 1
79
+ }, 8, ["class"]), u(t, {
80
+ size: "sm",
81
+ class: p([y.danger && "bg-danger bg-none text-danger-foreground hover:brightness-110", y.ui?.confirm]),
82
+ onClick: S
83
+ }, {
84
+ default: v(() => [l(g(y.confirmLabel), 1)]),
85
+ _: 1
86
+ }, 8, ["class"])], 2)]),
87
+ _: 3
88
+ }, 8, [
89
+ "open",
90
+ "side",
91
+ "align",
92
+ "side-offset",
93
+ "arrow",
94
+ "title",
95
+ "unstyled",
96
+ "class",
97
+ "ui"
98
+ ]));
99
+ }
100
+ });
101
+ //#endregion
102
+ export { y as default };
@@ -19,8 +19,12 @@ export interface LineChartProps {
19
19
  /**
20
20
  * `area` adds a wash beneath the line. Ignored for multiple series, where
21
21
  * overlapping washes muddy into a colour that belongs to neither.
22
+ *
23
+ * `stacked` is the multi-series answer to that: each series sits on top of
24
+ * the one before it, so the bands abut instead of overlapping and the top
25
+ * edge reads as the total. It falls back to `area` for a single series.
22
26
  */
23
- variant?: 'line' | 'area';
27
+ variant?: 'line' | 'area' | 'stacked';
24
28
  /**
25
29
  * How much to curve the line, from `0` (straight segments between
26
30
  * readings) to `1` (fully rounded). Straight by default: a curve claims the
@@ -66,7 +70,7 @@ export interface LineChartProps {
66
70
  /** Skip built-in classes; you take over styling entirely. */
67
71
  unstyled?: boolean;
68
72
  class?: ClassValue;
69
- ui?: Partial<Record<'root' | 'svg' | 'grid' | 'tick' | 'category' | 'line' | 'area' | 'crosshair' | 'marker' | 'markerRing' | 'tooltip' | 'tooltipLabel' | 'tooltipValue' | 'table', string>>;
73
+ ui?: Partial<Record<'root' | 'svg' | 'grid' | 'tick' | 'category' | 'line' | 'area' | 'band' | 'crosshair' | 'marker' | 'markerRing' | 'tooltip' | 'tooltipLabel' | 'tooltipValue' | 'table', string>>;
70
74
  }
71
75
  declare var __VLS_6: {
72
76
  orientation: import("..").ChartOrientation;
@@ -105,7 +109,7 @@ type __VLS_Slots = {} & {
105
109
  overlay?: (props: typeof __VLS_8) => any;
106
110
  };
107
111
  declare const __VLS_base: import("vue").DefineComponent<LineChartProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<LineChartProps> & Readonly<{}>, {
108
- variant: "line" | "area";
112
+ variant: "line" | "area" | "stacked";
109
113
  unstyled: boolean;
110
114
  data: readonly LineChartDatum[];
111
115
  legend: boolean;
@@ -4,34 +4,34 @@ import { cartesianLayout as n, clampTooltip as r, seriesColor as i, slotOf as a,
4
4
  import { useChartAnimation as s, useChartReveal as c } from "../composables/chart-reveal.js";
5
5
  import l from "./ChartLegend.js";
6
6
  import { lineChartTheme as u } from "../theme/line-chart.js";
7
- import { Fragment as d, computed as f, createBlock as ee, createCommentVNode as p, createElementBlock as m, createElementVNode as h, defineComponent as g, guardReactiveProps as _, normalizeClass as v, normalizeProps as y, normalizeStyle as b, openBlock as x, ref as S, renderList as C, renderSlot as w, toDisplayString as T, unref as E, useId as D } from "vue";
7
+ import { Fragment as d, computed as f, createBlock as ee, createCommentVNode as p, createElementBlock as m, createElementVNode as h, defineComponent as g, guardReactiveProps as _, normalizeClass as v, normalizeProps as y, normalizeStyle as b, openBlock as x, ref as S, renderList as C, renderSlot as w, toDisplayString as T, unref as E, useId as te } from "vue";
8
8
  //#region src/components/LineChart.vue?vue&type=script&setup=true&lang.ts
9
- var te = ["role", "aria-label"], ne = [
9
+ var ne = ["role", "aria-label"], re = [
10
10
  "width",
11
11
  "height",
12
12
  "viewBox"
13
- ], O = [
13
+ ], ie = [
14
14
  "x1",
15
15
  "y1",
16
16
  "x2",
17
17
  "y2"
18
- ], re = ["x", "y"], ie = { key: 1 }, ae = [
18
+ ], ae = ["x", "y"], oe = [
19
19
  "x",
20
20
  "y",
21
21
  "width",
22
22
  "height"
23
- ], oe = [
23
+ ], se = [
24
24
  "x1",
25
25
  "y1",
26
26
  "x2",
27
27
  "y2"
28
- ], se = ["clip-path"], ce = ["d", "fill"], le = ["d"], ue = ["cx", "cy"], de = ["cx", "cy"], fe = ["x", "y"], pe = [
28
+ ], ce = ["clip-path"], le = ["d", "fill"], ue = ["d"], de = ["d"], fe = ["cx", "cy"], pe = ["cx", "cy"], me = ["x", "y"], he = [
29
29
  "x",
30
30
  "y",
31
31
  "width",
32
32
  "height",
33
33
  "onPointerenter"
34
- ], me = { scope: "row" }, k = /*@__PURE__*/ g({
34
+ ], ge = { scope: "row" }, D = /*@__PURE__*/ g({
35
35
  __name: "LineChart",
36
36
  props: {
37
37
  data: { default: () => [] },
@@ -76,52 +76,68 @@ var te = ["role", "aria-label"], ne = [
76
76
  ui: {}
77
77
  },
78
78
  setup(g) {
79
- let k = g, he = e(), A = f(() => k.unstyled ?? he.unstyled), j = S(), { width: M } = t(j), ge = f(() => new Intl.NumberFormat(k.locale, k.format));
80
- function N(e) {
81
- return ge.value.format(e);
79
+ let D = g, _e = e(), O = f(() => D.unstyled ?? _e.unstyled), k = S(), { width: A } = t(k), ve = f(() => new Intl.NumberFormat(D.locale, D.format));
80
+ function j(e) {
81
+ return ve.value.format(e);
82
82
  }
83
- let P = f(() => {
84
- let e = k.series?.length ? [...k.series] : [{ key: "value" }];
83
+ let M = f(() => {
84
+ let e = D.series?.length ? [...D.series] : [{ key: "value" }];
85
85
  return o(e.length), e;
86
- }), F = f(() => P.value.length > 1), _e = f(() => F.value || k.legend && P.value[0].name != null);
87
- function I(e, t) {
86
+ }), N = f(() => M.value.length > 1), ye = f(() => N.value || D.legend && M.value[0].name != null);
87
+ function P(e, t) {
88
88
  let n = e[t];
89
89
  return typeof n == "number" && Number.isFinite(n) ? n : null;
90
90
  }
91
- let L = f(() => n({
92
- values: k.data.flatMap((e) => P.value.map((t) => I(e, t.key))),
93
- categories: k.data.length,
94
- longestLabel: Math.max(...k.data.map((e) => e.label.length), 1),
95
- width: M.value,
96
- height: k.height,
97
- tickCount: k.ticks,
98
- showAxis: k.axis,
99
- formatTick: N,
100
- includeZero: k.zero
91
+ let F = f(() => D.variant === "stacked" && N.value), I = f(() => D.data.map((e) => M.value.reduce((t, n) => {
92
+ let r = t[t.length - 1] ?? 0;
93
+ return t.push(r + (P(e, n.key) ?? 0)), t;
94
+ }, []))), L = f(() => n({
95
+ values: F.value ? I.value.map((e) => e[e.length - 1]) : D.data.flatMap((e) => M.value.map((t) => P(e, t.key))),
96
+ categories: D.data.length,
97
+ longestLabel: Math.max(...D.data.map((e) => e.label.length), 1),
98
+ width: A.value,
99
+ height: D.height,
100
+ tickCount: D.ticks,
101
+ showAxis: D.axis,
102
+ formatTick: j,
103
+ includeZero: D.zero || F.value
101
104
  }));
102
105
  function R(e) {
103
106
  return Math.round(e * 100) / 100;
104
107
  }
105
- let z = f(() => M.value ? P.value.map((e, t) => {
108
+ let z = f(() => A.value ? M.value.map((e, t) => {
106
109
  let n = [], r = [];
107
- return k.data.forEach((t, i) => {
108
- let a = I(t, e.key);
109
- if (a == null) {
110
+ return D.data.forEach((i, a) => {
111
+ let o = F.value ? I.value[a][t] : P(i, e.key);
112
+ if (o == null) {
110
113
  r.length && n.push(r), r = [];
111
114
  return;
112
115
  }
113
116
  r.push({
114
- x: R(L.value.pointAt(i)),
115
- y: R(L.value.y(a)),
116
- index: i
117
+ x: R(L.value.pointAt(a)),
118
+ y: R(L.value.y(o)),
119
+ index: a
117
120
  });
118
121
  }), r.length && n.push(r), {
119
122
  runs: n,
120
123
  color: i(a(e, t)),
121
124
  seriesIndex: t
122
125
  };
123
- }) : []), B = f(() => k.variant === "area" && !F.value && z.value.length > 0), V = f(() => {
124
- let e = k.data?.length ?? 0;
126
+ }) : []), B = f(() => (D.variant === "area" || D.variant === "stacked") && !N.value && z.value.length > 0), be = f(() => !F.value || !A.value ? [] : M.value.map((e, t) => ({
127
+ top: D.data.map((e, n) => ({
128
+ x: R(L.value.pointAt(n)),
129
+ y: R(L.value.y(I.value[n][t])),
130
+ index: n
131
+ })),
132
+ base: D.data.map((e, n) => ({
133
+ x: R(L.value.pointAt(n)),
134
+ y: R(L.value.y(t === 0 ? 0 : I.value[n][t - 1])),
135
+ index: n
136
+ })),
137
+ color: i(a(e, t)),
138
+ seriesIndex: t
139
+ }))), V = f(() => {
140
+ let e = D.data?.length ?? 0;
125
141
  return {
126
142
  first: e ? R(L.value.pointAt(0)) : 0,
127
143
  last: e ? R(L.value.pointAt(e - 1)) : 0,
@@ -130,11 +146,11 @@ var te = ["role", "aria-label"], ne = [
130
146
  };
131
147
  });
132
148
  function H(e) {
133
- return k.flush && e.x === V.value.last ? `L${V.value.right} ${e.y}` : "";
149
+ return D.flush && e.x === V.value.last ? `L${V.value.right} ${e.y}` : "";
134
150
  }
135
- let U = f(() => Math.min(Math.max(k.tension, 0), 1) / 6);
151
+ let U = f(() => Math.min(Math.max(D.tension, 0), 1) / 6);
136
152
  function W(e) {
137
- let t = e[0], n = e[e.length - 1], r = k.flush && t.x === V.value.first ? `M${V.value.left} ${t.y} L${t.x} ${t.y}` : `M${t.x} ${t.y}`;
153
+ let t = e[0], n = e[e.length - 1], r = D.flush && t.x === V.value.first ? `M${V.value.left} ${t.y} L${t.x} ${t.y}` : `M${t.x} ${t.y}`;
138
154
  if (U.value === 0 || e.length < 2) return [
139
155
  r,
140
156
  ...e.slice(1).map((e) => `L${e.x} ${e.y}`),
@@ -150,11 +166,14 @@ var te = ["role", "aria-label"], ne = [
150
166
  H(n)
151
167
  ].filter(Boolean).join(" ");
152
168
  }
153
- function ve(e) {
154
- let t = L.value.plot.top + L.value.plot.height, n = e[0], r = e[e.length - 1], i = k.flush && n.x === V.value.first ? V.value.left : n.x, a = k.flush && r.x === V.value.last ? V.value.right : r.x;
169
+ function xe(e) {
170
+ let t = L.value.plot.top + L.value.plot.height, n = e[0], r = e[e.length - 1], i = D.flush && n.x === V.value.first ? V.value.left : n.x, a = D.flush && r.x === V.value.last ? V.value.right : r.x;
155
171
  return `${W(e)} L${a} ${t} L${i} ${t} Z`;
156
172
  }
157
- let G = `iryx-area-${D()}`, K = `iryx-plot-clip-${D()}`, q = S(), J = f(() => q.value == null ? [] : z.value.flatMap((e) => {
173
+ function Se(e, t) {
174
+ return `${W(e)} ${W([...t].reverse()).replace("M", "L")} Z`;
175
+ }
176
+ let G = `iryx-area-${te()}`, K = `iryx-plot-clip-${te()}`, q = S(), J = f(() => q.value == null ? [] : z.value.flatMap((e) => {
158
177
  for (let t of e.runs) {
159
178
  let n = t.find((e) => e.index === q.value);
160
179
  if (n) return [{
@@ -165,69 +184,70 @@ var te = ["role", "aria-label"], ne = [
165
184
  return [];
166
185
  })), Y = f(() => q.value == null ? void 0 : R(L.value.pointAt(q.value))), X = f(() => {
167
186
  if (q.value == null) return;
168
- let e = k.data[q.value];
187
+ let e = D.data[q.value];
169
188
  if (!e) return;
170
- let t = P.value.map((t, n) => ({
189
+ let t = M.value.map((t, n) => ({
171
190
  name: t.name ?? t.key,
172
191
  color: i(a(t, n)),
173
- value: I(e, t.key)
192
+ value: P(e, t.key)
174
193
  })).filter((e) => e.value != null).map((e) => ({
175
194
  ...e,
176
- value: N(e.value)
195
+ value: j(e.value)
177
196
  }));
178
197
  if (!t.length) return;
179
- let n = F.value ? Math.max(e.label.length, ...t.map((e) => e.name.length + e.value.length + 3)) : e.label.length + t[0].value.length + 2;
198
+ let n = N.value ? Math.max(e.label.length, ...t.map((e) => e.name.length + e.value.length + 3)) : e.label.length + t[0].value.length + 2;
180
199
  return {
181
200
  label: e.label,
182
201
  rows: t,
183
- multi: F.value,
184
- x: r(L.value.pointAt(q.value), "x".repeat(n), M.value),
202
+ multi: N.value,
203
+ x: r(L.value.pointAt(q.value), "x".repeat(n), A.value),
185
204
  y: Math.min(...J.value.map((e) => e.y), L.value.plot.top + L.value.plot.height)
186
205
  };
187
- }), Z = s(f(() => k.animate)), { revealed: ye } = c(f(() => !!(M.value && z.value.length)), Z), be = f(() => ({
188
- transform: `scaleX(${+!!ye.value})`,
206
+ }), Z = s(f(() => D.animate)), { revealed: Ce } = c(f(() => !!(A.value && z.value.length)), Z), we = f(() => ({
207
+ transform: `scaleX(${+!!Ce.value})`,
189
208
  transformOrigin: `${L.value.plot.left}px 0px`,
190
209
  transition: `transform ${Z.value.duration}ms ${Z.value.css}`
191
210
  })), Q = f(() => u());
192
211
  function $(e, t) {
193
- let n = k.ui?.[e];
194
- return A.value ? [n, t] : Q.value[e]({ class: [n, t] });
212
+ let n = D.ui?.[e];
213
+ return O.value ? [n, t] : Q.value[e]({ class: [n, t] });
195
214
  }
196
215
  return (e, t) => (x(), m("div", {
197
216
  ref_key: "root",
198
- ref: j,
199
- role: k.label ? "figure" : void 0,
200
- "aria-label": k.label,
201
- class: v($("root", k.class))
217
+ ref: k,
218
+ role: D.label ? "figure" : void 0,
219
+ "aria-label": D.label,
220
+ class: v($("root", D.class))
202
221
  }, [
203
- _e.value ? (x(), ee(l, {
222
+ ye.value ? (x(), ee(l, {
204
223
  key: 0,
205
- series: P.value,
206
- unstyled: k.unstyled
224
+ series: M.value,
225
+ unstyled: D.unstyled
207
226
  }, null, 8, ["series", "unstyled"])) : p("", !0),
208
- h("div", { class: v(A.value ? void 0 : Q.value.plot()) }, [(x(), m("svg", {
209
- width: E(M),
210
- height: k.height,
211
- viewBox: `0 0 ${E(M)} ${k.height}`,
227
+ h("div", { class: v(O.value ? void 0 : Q.value.plot()) }, [(x(), m("svg", {
228
+ width: E(A),
229
+ height: D.height,
230
+ viewBox: `0 0 ${E(A)} ${D.height}`,
212
231
  "aria-hidden": "true",
213
232
  class: v($("svg"))
214
233
  }, [
215
- k.axis ? (x(!0), m(d, { key: 0 }, C(L.value.ticks, (e) => (x(), m("g", { key: `tick-${e}` }, [h("line", {
234
+ D.axis ? (x(!0), m(d, { key: 0 }, C(L.value.ticks, (e) => (x(), m("g", { key: `tick-${e}` }, [h("line", {
216
235
  x1: L.value.plot.left,
217
236
  y1: L.value.y(e),
218
237
  x2: L.value.plot.left + L.value.plot.width,
219
238
  y2: L.value.y(e),
220
239
  "stroke-width": "1",
221
240
  class: v($("grid"))
222
- }, null, 10, O), h("text", {
241
+ }, null, 10, ie), h("text", {
223
242
  x: L.value.plot.left - E(8),
224
243
  y: L.value.y(e),
225
244
  "text-anchor": "end",
226
245
  "dominant-baseline": "middle",
227
246
  class: v($("tick"))
228
- }, T(N(e)), 11, re)]))), 128)) : p("", !0),
247
+ }, T(j(e)), 11, ae)]))), 128)) : p("", !0),
229
248
  w(e.$slots, "underlay", y(_(L.value))),
230
- B.value ? (x(), m("defs", ie, [h("linearGradient", {
249
+ h("defs", null, [B.value ? (x(), m("linearGradient", {
250
+ key: 0,
231
251
  id: G,
232
252
  x1: "0",
233
253
  y1: "0",
@@ -241,65 +261,74 @@ var te = ["role", "aria-label"], ne = [
241
261
  offset: "100%",
242
262
  "stop-color": "currentColor",
243
263
  "stop-opacity": "0"
244
- }, null, -1)]]), h("clipPath", { id: K }, [h("rect", {
264
+ }, null, -1)]])) : p("", !0), h("clipPath", { id: K }, [h("rect", {
245
265
  x: L.value.plot.left,
246
266
  y: L.value.plot.top,
247
267
  width: L.value.plot.width,
248
268
  height: L.value.plot.height,
249
- style: b(be.value)
250
- }, null, 12, ae)])])) : p("", !0),
269
+ style: b(we.value)
270
+ }, null, 12, oe)])]),
251
271
  Y.value == null ? p("", !0) : (x(), m("line", {
252
- key: 2,
272
+ key: 1,
253
273
  x1: Y.value,
254
274
  y1: L.value.plot.top,
255
275
  x2: Y.value,
256
276
  y2: L.value.plot.top + L.value.plot.height,
257
277
  "stroke-width": "1",
258
278
  class: v($("crosshair"))
259
- }, null, 10, oe)),
260
- h("g", { "clip-path": `url(#${K})` }, [(x(!0), m(d, null, C(B.value ? z.value[0].runs : [], (e, t) => (x(), m("path", {
261
- key: `area-${t}`,
262
- d: ve(e),
263
- fill: `url(#${G})`,
264
- style: b({ color: z.value[0].color }),
265
- class: v($("area"))
266
- }, null, 14, ce))), 128)), (x(!0), m(d, null, C(z.value, (e) => (x(), m(d, { key: `series-${e.seriesIndex}` }, [(x(!0), m(d, null, C(e.runs, (t, n) => (x(), m("path", {
267
- key: `line-${e.seriesIndex}-${n}`,
268
- d: W(t),
269
- style: b({ stroke: e.color }),
270
- class: v($("line"))
271
- }, null, 14, le))), 128))], 64))), 128))], 8, se),
279
+ }, null, 10, se)),
280
+ h("g", { "clip-path": `url(#${K})` }, [
281
+ (x(!0), m(d, null, C(B.value ? z.value[0].runs : [], (e, t) => (x(), m("path", {
282
+ key: `area-${t}`,
283
+ d: xe(e),
284
+ fill: `url(#${G})`,
285
+ style: b({ color: z.value[0].color }),
286
+ class: v($("area"))
287
+ }, null, 14, le))), 128)),
288
+ (x(!0), m(d, null, C(be.value, (e) => (x(), m("path", {
289
+ key: `band-${e.seriesIndex}`,
290
+ d: Se(e.top, e.base),
291
+ style: b({ fill: e.color }),
292
+ class: v($("band"))
293
+ }, null, 14, ue))), 128)),
294
+ (x(!0), m(d, null, C(z.value, (e) => (x(), m(d, { key: `series-${e.seriesIndex}` }, [(x(!0), m(d, null, C(e.runs, (t, n) => (x(), m("path", {
295
+ key: `line-${e.seriesIndex}-${n}`,
296
+ d: W(t),
297
+ style: b({ stroke: e.color }),
298
+ class: v($("line"))
299
+ }, null, 14, de))), 128))], 64))), 128))
300
+ ], 8, ce),
272
301
  (x(!0), m(d, null, C(J.value, (e, t) => (x(), m(d, { key: `marker-${t}` }, [h("circle", {
273
302
  cx: e.x,
274
303
  cy: e.y,
275
304
  r: "6",
276
305
  class: v($("markerRing"))
277
- }, null, 10, ue), h("circle", {
306
+ }, null, 10, fe), h("circle", {
278
307
  cx: e.x,
279
308
  cy: e.y,
280
309
  r: "4",
281
310
  style: b({ fill: e.color }),
282
311
  class: v($("marker"))
283
- }, null, 14, de)], 64))), 128)),
284
- (x(!0), m(d, null, C(k.data, (e, t) => (x(), m(d, { key: `label-${e.label}-${t}` }, [t % L.value.labelStep === 0 ? (x(), m("text", {
312
+ }, null, 14, pe)], 64))), 128)),
313
+ (x(!0), m(d, null, C(D.data, (e, t) => (x(), m(d, { key: `label-${e.label}-${t}` }, [t % L.value.labelStep === 0 ? (x(), m("text", {
285
314
  key: 0,
286
315
  x: L.value.pointAt(t),
287
316
  y: L.value.plot.top + L.value.plot.height + 14,
288
317
  "text-anchor": "middle",
289
318
  class: v($("category"))
290
- }, T(e.label), 11, fe)) : p("", !0)], 64))), 128)),
319
+ }, T(e.label), 11, me)) : p("", !0)], 64))), 128)),
291
320
  w(e.$slots, "overlay", y(_(L.value))),
292
- (x(!0), m(d, null, C(k.data, (e, n) => (x(), m("rect", {
321
+ (x(!0), m(d, null, C(D.data, (e, n) => (x(), m("rect", {
293
322
  key: `hit-${e.label}-${n}`,
294
323
  x: L.value.plot.left + L.value.bandWidth * n,
295
324
  y: L.value.plot.top,
296
325
  width: L.value.bandWidth,
297
326
  height: L.value.plot.height,
298
- class: v(A.value ? void 0 : Q.value.hit()),
327
+ class: v(O.value ? void 0 : Q.value.hit()),
299
328
  onPointerenter: (e) => q.value = n,
300
329
  onPointerleave: t[0] ||= (e) => q.value = void 0
301
- }, null, 42, pe))), 128))
302
- ], 10, ne)), X.value ? (x(), m("div", {
330
+ }, null, 42, he))), 128))
331
+ ], 10, re)), X.value ? (x(), m("div", {
303
332
  key: 0,
304
333
  class: v($("tooltip", X.value.multi ? "flex-col items-start gap-1" : void 0)),
305
334
  style: b({
@@ -322,15 +351,15 @@ var te = ["role", "aria-label"], ne = [
322
351
  class: v($("tooltipValue"))
323
352
  }, T(X.value.rows[0].value), 3))], 6)) : p("", !0)], 2),
324
353
  h("div", { class: v($("table")) }, [h("table", null, [
325
- h("caption", null, T(k.label), 1),
326
- h("thead", null, [h("tr", null, [t[2] ||= h("th", { scope: "col" }, " Category ", -1), (x(!0), m(d, null, C(P.value, (e) => (x(), m("th", {
354
+ h("caption", null, T(D.label), 1),
355
+ h("thead", null, [h("tr", null, [t[2] ||= h("th", { scope: "col" }, " Category ", -1), (x(!0), m(d, null, C(M.value, (e) => (x(), m("th", {
327
356
  key: e.key,
328
357
  scope: "col"
329
358
  }, T(e.name ?? "Value"), 1))), 128))])]),
330
- h("tbody", null, [(x(!0), m(d, null, C(k.data, (e, t) => (x(), m("tr", { key: `row-${e.label}-${t}` }, [h("th", me, T(e.label), 1), (x(!0), m(d, null, C(P.value, (t) => (x(), m("td", { key: t.key }, T(I(e, t.key) == null ? "—" : N(I(e, t.key))), 1))), 128))]))), 128))])
359
+ h("tbody", null, [(x(!0), m(d, null, C(D.data, (e, t) => (x(), m("tr", { key: `row-${e.label}-${t}` }, [h("th", ge, T(e.label), 1), (x(!0), m(d, null, C(M.value, (t) => (x(), m("td", { key: t.key }, T(P(e, t.key) == null ? "—" : j(P(e, t.key))), 1))), 128))]))), 128))])
331
360
  ])], 2)
332
- ], 10, te));
361
+ ], 10, ne));
333
362
  }
334
363
  });
335
364
  //#endregion
336
- export { k as default };
365
+ export { D as default };
@@ -23,6 +23,7 @@ export { default as ColorPicker } from './ColorPicker.vue';
23
23
  export { default as Combobox } from './Combobox.vue';
24
24
  export { default as CommandPalette } from './CommandPalette.vue';
25
25
  export { default as ConfirmDialog } from './ConfirmDialog.vue';
26
+ export { default as ConfirmPopover } from './ConfirmPopover.vue';
26
27
  export { default as Container } from './Container.vue';
27
28
  export { default as ContextMenu } from './ContextMenu.vue';
28
29
  export { default as DateField } from './DateField.vue';