rei-kit 2.5.0 → 2.7.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.
- package/README.md +4 -4
- package/dist/components/AvatarStack.vue.d.ts +24 -0
- package/dist/components/BaseCalendar.vue.d.ts +45 -0
- package/dist/components/BaseChip.vue.d.ts +32 -0
- package/dist/components/BaseDatePicker.vue.d.ts +58 -0
- package/dist/components/BaseKbd.vue.d.ts +21 -0
- package/dist/components/BaseLink.vue.d.ts +33 -0
- package/dist/components/BaseRating.vue.d.ts +35 -0
- package/dist/components/BaseSeparator.vue.d.ts +20 -0
- package/dist/components/BaseSkeleton.vue.d.ts +25 -0
- package/dist/components/CopyButton.vue.d.ts +33 -0
- package/dist/components/FileDrop.vue.d.ts +45 -0
- package/dist/components/TagsInput.vue.d.ts +38 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +1243 -149
- package/dist/index.js.map +1 -1
- package/dist/styles.css +671 -0
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -4,8 +4,8 @@ import { _ as safeRedirect, a as useBoundValue, b as ensureSheetRoot, c as useTo
|
|
|
4
4
|
import { n as registerErrorMapper, r as toAppError, t as AppError } from "./app-error-DF9cijE0.js";
|
|
5
5
|
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-BOaGB7Aw.js";
|
|
6
6
|
import { n as BaseButton_default, t as SettingsRow_default } from "./SettingsRow-BXFn8tCk.js";
|
|
7
|
-
import { Fragment, Teleport, Transition, TransitionGroup, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, isRef, mergeModels, mergeProps, nextTick, normalizeClass, normalizeStyle, onBeforeUnmount, onErrorCaptured, onMounted, onScopeDispose, openBlock, readonly, ref, renderList, renderSlot, resolveDynamicComponent, toDisplayString, unref, useId, useModel, vModelRadio, vModelSelect, vModelText, vShow, watch, watchEffect, withCtx, withDirectives, withModifiers } from "vue";
|
|
8
|
-
import { ArrowDown, ArrowRight, ArrowUp, Check, CheckCircle2, ChevronDown, Info, Minus, Plus, TriangleAlert, X, XCircle } from "lucide-vue-next";
|
|
7
|
+
import { Fragment, Teleport, Transition, TransitionGroup, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, isRef, mergeModels, mergeProps, nextTick, normalizeClass, normalizeStyle, onBeforeUnmount, onErrorCaptured, onMounted, onScopeDispose, openBlock, readonly, ref, renderList, renderSlot, resolveDynamicComponent, toDisplayString, unref, useId, useModel, useTemplateRef, vModelRadio, vModelSelect, vModelText, vShow, watch, watchEffect, withCtx, withDirectives, withModifiers } from "vue";
|
|
8
|
+
import { ArrowDown, ArrowRight, ArrowUp, ArrowUpRight, CalendarDays, Check, CheckCircle2, ChevronDown, ChevronLeft, ChevronRight, Copy, Info, Minus, Paperclip, Plus, Star, TriangleAlert, Upload, X, XCircle } from "lucide-vue-next";
|
|
9
9
|
import { RouterLink } from "vue-router";
|
|
10
10
|
import { createI18n } from "vue-i18n";
|
|
11
11
|
//#region src/utils/day-label.ts
|
|
@@ -382,17 +382,17 @@ function useMediaQuery(query) {
|
|
|
382
382
|
}
|
|
383
383
|
//#endregion
|
|
384
384
|
//#region src/components/BaseAvatar.vue?vue&type=script&setup=true&lang.ts
|
|
385
|
-
var _hoisted_1$
|
|
385
|
+
var _hoisted_1$37 = [
|
|
386
386
|
"role",
|
|
387
387
|
"aria-label",
|
|
388
388
|
"aria-hidden"
|
|
389
389
|
];
|
|
390
|
-
var _hoisted_2$
|
|
391
|
-
var _hoisted_3$
|
|
390
|
+
var _hoisted_2$31 = ["src"];
|
|
391
|
+
var _hoisted_3$20 = {
|
|
392
392
|
key: 1,
|
|
393
393
|
class: "rk-avatar-initials"
|
|
394
394
|
};
|
|
395
|
-
var _hoisted_4$
|
|
395
|
+
var _hoisted_4$16 = {
|
|
396
396
|
key: 2,
|
|
397
397
|
viewBox: "0 0 20 20",
|
|
398
398
|
class: "rk-avatar-figure",
|
|
@@ -438,7 +438,7 @@ var BaseAvatar_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
438
438
|
alt: "",
|
|
439
439
|
class: "rk-avatar-img",
|
|
440
440
|
onError: _cache[0] || (_cache[0] = ($event) => broken.value = true)
|
|
441
|
-
}, null, 40, _hoisted_2$
|
|
441
|
+
}, null, 40, _hoisted_2$31)) : __props.fallback === "initials" && initials.value ? (openBlock(), createElementBlock("span", _hoisted_3$20, toDisplayString(initials.value), 1)) : (openBlock(), createElementBlock("svg", _hoisted_4$16, [..._cache[1] || (_cache[1] = [createElementVNode("circle", {
|
|
442
442
|
cx: "10",
|
|
443
443
|
cy: "6.75",
|
|
444
444
|
r: "3.25",
|
|
@@ -447,7 +447,7 @@ var BaseAvatar_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
447
447
|
d: "M3.75 17c0-3.05 2.8-5.25 6.25-5.25S16.25 13.95 16.25 17",
|
|
448
448
|
"stroke-width": "1.5",
|
|
449
449
|
"stroke-linecap": "round"
|
|
450
|
-
}, null, -1)])]))], 10, _hoisted_1$
|
|
450
|
+
}, null, -1)])]))], 10, _hoisted_1$37);
|
|
451
451
|
};
|
|
452
452
|
}
|
|
453
453
|
}), [["__scopeId", "data-v-47586bec"]]);
|
|
@@ -472,12 +472,12 @@ var BaseBadge_default = /* @__PURE__ */ defineComponent({
|
|
|
472
472
|
});
|
|
473
473
|
//#endregion
|
|
474
474
|
//#region src/components/BaseMenu.vue?vue&type=script&setup=true&lang.ts
|
|
475
|
-
var _hoisted_1$
|
|
475
|
+
var _hoisted_1$36 = [
|
|
476
476
|
"aria-label",
|
|
477
477
|
"aria-expanded",
|
|
478
478
|
"aria-controls"
|
|
479
479
|
];
|
|
480
|
-
var _hoisted_2$
|
|
480
|
+
var _hoisted_2$30 = ["id"];
|
|
481
481
|
//#endregion
|
|
482
482
|
//#region src/components/BaseMenu.vue
|
|
483
483
|
var BaseMenu_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
@@ -576,14 +576,14 @@ var BaseMenu_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PUR
|
|
|
576
576
|
"aria-haspopup": true,
|
|
577
577
|
"aria-controls": open.value ? unref(id) : void 0,
|
|
578
578
|
onClick: _cache[0] || (_cache[0] = ($event) => open.value = !open.value)
|
|
579
|
-
}, [renderSlot(_ctx.$slots, "trigger", { open: open.value }, void 0, true)], 8, _hoisted_1$
|
|
579
|
+
}, [renderSlot(_ctx.$slots, "trigger", { open: open.value }, void 0, true)], 8, _hoisted_1$36), open.value ? (openBlock(), createElementBlock("div", {
|
|
580
580
|
key: 0,
|
|
581
581
|
id: unref(id),
|
|
582
582
|
ref_key: "panel",
|
|
583
583
|
ref: panel,
|
|
584
584
|
class: normalizeClass(["rk-menu-panel surface-overlay", `is-${__props.align}`]),
|
|
585
585
|
role: "menu"
|
|
586
|
-
}, [renderSlot(_ctx.$slots, "default", {}, void 0, true)], 10, _hoisted_2$
|
|
586
|
+
}, [renderSlot(_ctx.$slots, "default", {}, void 0, true)], 10, _hoisted_2$30)) : createCommentVNode("", true)], 544);
|
|
587
587
|
};
|
|
588
588
|
}
|
|
589
589
|
}), [["__scopeId", "data-v-e57ec901"]]);
|
|
@@ -654,9 +654,9 @@ var BaseCard_default = /* @__PURE__ */ defineComponent({
|
|
|
654
654
|
});
|
|
655
655
|
//#endregion
|
|
656
656
|
//#region src/components/BaseCombobox.vue?vue&type=script&setup=true&lang.ts
|
|
657
|
-
var _hoisted_1$
|
|
658
|
-
var _hoisted_2$
|
|
659
|
-
var _hoisted_3$
|
|
657
|
+
var _hoisted_1$35 = ["for"];
|
|
658
|
+
var _hoisted_2$29 = { class: "rk-combo-field" };
|
|
659
|
+
var _hoisted_3$19 = [
|
|
660
660
|
"id",
|
|
661
661
|
"placeholder",
|
|
662
662
|
"disabled",
|
|
@@ -665,15 +665,15 @@ var _hoisted_3$15 = [
|
|
|
665
665
|
"aria-invalid",
|
|
666
666
|
"aria-describedby"
|
|
667
667
|
];
|
|
668
|
-
var _hoisted_4$
|
|
669
|
-
var _hoisted_5$
|
|
670
|
-
var _hoisted_6$
|
|
668
|
+
var _hoisted_4$15 = ["disabled"];
|
|
669
|
+
var _hoisted_5$9 = ["aria-label"];
|
|
670
|
+
var _hoisted_6$5 = [
|
|
671
671
|
"id",
|
|
672
672
|
"aria-selected",
|
|
673
673
|
"onPointerdown",
|
|
674
674
|
"onPointermove"
|
|
675
675
|
];
|
|
676
|
-
var _hoisted_7$
|
|
676
|
+
var _hoisted_7$4 = {
|
|
677
677
|
key: 0,
|
|
678
678
|
class: "rk-combo-empty"
|
|
679
679
|
};
|
|
@@ -793,8 +793,8 @@ var BaseCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
793
793
|
createElementVNode("label", {
|
|
794
794
|
for: unref(id),
|
|
795
795
|
class: "rk-combo-label"
|
|
796
|
-
}, toDisplayString(__props.label), 9, _hoisted_1$
|
|
797
|
-
createElementVNode("div", _hoisted_2$
|
|
796
|
+
}, toDisplayString(__props.label), 9, _hoisted_1$35),
|
|
797
|
+
createElementVNode("div", _hoisted_2$29, [withDirectives(createElementVNode("input", {
|
|
798
798
|
id: unref(id),
|
|
799
799
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => text.value = $event),
|
|
800
800
|
type: "text",
|
|
@@ -811,14 +811,14 @@ var BaseCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
811
811
|
"aria-describedby": describedBy.value,
|
|
812
812
|
onKeydown,
|
|
813
813
|
onFocus: _cache[1] || (_cache[1] = ($event) => open.value = true)
|
|
814
|
-
}, null, 40, _hoisted_3$
|
|
814
|
+
}, null, 40, _hoisted_3$19), [[vModelText, text.value]]), createElementVNode("button", {
|
|
815
815
|
type: "button",
|
|
816
816
|
class: "rk-combo-toggle",
|
|
817
817
|
tabindex: "-1",
|
|
818
818
|
"aria-hidden": "true",
|
|
819
819
|
disabled: __props.disabled,
|
|
820
820
|
onClick: _cache[2] || (_cache[2] = ($event) => open.value = !open.value)
|
|
821
|
-
}, " ▾ ", 8, _hoisted_4$
|
|
821
|
+
}, " ▾ ", 8, _hoisted_4$15)]),
|
|
822
822
|
withDirectives(createElementVNode("ul", {
|
|
823
823
|
id: listId,
|
|
824
824
|
ref_key: "list",
|
|
@@ -838,8 +838,8 @@ var BaseCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
838
838
|
"aria-selected": option.value === model.value,
|
|
839
839
|
onPointerdown: withModifiers(($event) => choose(option), ["prevent"]),
|
|
840
840
|
onPointermove: ($event) => highlighted.value = index
|
|
841
|
-
}, toDisplayString(option.label), 43, _hoisted_6$
|
|
842
|
-
}), 128)), matches.value.length === 0 ? (openBlock(), createElementBlock("li", _hoisted_7$
|
|
841
|
+
}, toDisplayString(option.label), 43, _hoisted_6$5);
|
|
842
|
+
}), 128)), matches.value.length === 0 ? (openBlock(), createElementBlock("li", _hoisted_7$4, toDisplayString(__props.emptyLabel), 1)) : createCommentVNode("", true)], 8, _hoisted_5$9), [[vShow, open.value]]),
|
|
843
843
|
__props.error ? (openBlock(), createElementBlock("p", {
|
|
844
844
|
key: 0,
|
|
845
845
|
id: errorId,
|
|
@@ -855,13 +855,13 @@ var BaseCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
855
855
|
}), [["__scopeId", "data-v-ce4c503f"]]);
|
|
856
856
|
//#endregion
|
|
857
857
|
//#region src/components/BaseRadioGroup.vue?vue&type=script&setup=true&lang.ts
|
|
858
|
-
var _hoisted_1$
|
|
859
|
-
var _hoisted_2$
|
|
858
|
+
var _hoisted_1$34 = ["aria-describedby"];
|
|
859
|
+
var _hoisted_2$28 = [
|
|
860
860
|
"name",
|
|
861
861
|
"value",
|
|
862
862
|
"disabled"
|
|
863
863
|
];
|
|
864
|
-
var _hoisted_3$
|
|
864
|
+
var _hoisted_3$18 = { class: "text-ink text-sm" };
|
|
865
865
|
//#endregion
|
|
866
866
|
//#region src/components/BaseRadioGroup.vue
|
|
867
867
|
var BaseRadioGroup_default = /* @__PURE__ */ defineComponent({
|
|
@@ -905,7 +905,7 @@ var BaseRadioGroup_default = /* @__PURE__ */ defineComponent({
|
|
|
905
905
|
value: option.value,
|
|
906
906
|
disabled: option.disabled,
|
|
907
907
|
class: "accent-primary focus-visible:outline-primary size-4 shrink-0 focus-visible:outline-2 focus-visible:outline-offset-2"
|
|
908
|
-
}, null, 8, _hoisted_2$
|
|
908
|
+
}, null, 8, _hoisted_2$28), [[vModelRadio, unref(model)]]), createElementVNode("span", _hoisted_3$18, toDisplayString(option.label), 1)], 2);
|
|
909
909
|
}), 128)),
|
|
910
910
|
__props.error ? (openBlock(), createElementBlock("p", {
|
|
911
911
|
key: 0,
|
|
@@ -916,24 +916,24 @@ var BaseRadioGroup_default = /* @__PURE__ */ defineComponent({
|
|
|
916
916
|
id: hintId,
|
|
917
917
|
class: "text-ink-soft text-xs"
|
|
918
918
|
}, toDisplayString(__props.hint), 1)) : createCommentVNode("", true)
|
|
919
|
-
], 8, _hoisted_1$
|
|
919
|
+
], 8, _hoisted_1$34);
|
|
920
920
|
};
|
|
921
921
|
}
|
|
922
922
|
});
|
|
923
923
|
//#endregion
|
|
924
924
|
//#region src/components/BaseSelect.vue?vue&type=script&setup=true&lang.ts
|
|
925
|
-
var _hoisted_1$
|
|
926
|
-
var _hoisted_2$
|
|
925
|
+
var _hoisted_1$33 = { class: "relative" };
|
|
926
|
+
var _hoisted_2$27 = [
|
|
927
927
|
"id",
|
|
928
928
|
"aria-invalid",
|
|
929
929
|
"aria-describedby"
|
|
930
930
|
];
|
|
931
|
-
var _hoisted_3$
|
|
931
|
+
var _hoisted_3$17 = {
|
|
932
932
|
key: 0,
|
|
933
933
|
value: void 0,
|
|
934
934
|
disabled: ""
|
|
935
935
|
};
|
|
936
|
-
var _hoisted_4$
|
|
936
|
+
var _hoisted_4$14 = ["value", "disabled"];
|
|
937
937
|
//#endregion
|
|
938
938
|
//#region src/components/BaseSelect.vue
|
|
939
939
|
var BaseSelect_default = /* @__PURE__ */ defineComponent({
|
|
@@ -969,7 +969,7 @@ var BaseSelect_default = /* @__PURE__ */ defineComponent({
|
|
|
969
969
|
"label-hidden": __props.labelHidden,
|
|
970
970
|
size: __props.size
|
|
971
971
|
}, {
|
|
972
|
-
default: withCtx(({ id, describedBy, invalid }) => [createElementVNode("div", _hoisted_1$
|
|
972
|
+
default: withCtx(({ id, describedBy, invalid }) => [createElementVNode("div", _hoisted_1$33, [withDirectives(createElementVNode("select", {
|
|
973
973
|
id,
|
|
974
974
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => model.value = $event),
|
|
975
975
|
"aria-invalid": invalid,
|
|
@@ -979,13 +979,13 @@ var BaseSelect_default = /* @__PURE__ */ defineComponent({
|
|
|
979
979
|
__props.variant === "unstyled" ? "" : SIZE_CLASS[__props.size],
|
|
980
980
|
__props.variant !== "unstyled" && invalid ? "border-negative" : ""
|
|
981
981
|
]])
|
|
982
|
-
}, [__props.placeholder ? (openBlock(), createElementBlock("option", _hoisted_3$
|
|
982
|
+
}, [__props.placeholder ? (openBlock(), createElementBlock("option", _hoisted_3$17, toDisplayString(__props.placeholder), 1)) : createCommentVNode("", true), (openBlock(true), createElementBlock(Fragment, null, renderList(__props.options, (option) => {
|
|
983
983
|
return openBlock(), createElementBlock("option", {
|
|
984
984
|
key: option.value,
|
|
985
985
|
value: option.value,
|
|
986
986
|
disabled: option.disabled
|
|
987
|
-
}, toDisplayString(option.label), 9, _hoisted_4$
|
|
988
|
-
}), 128))], 10, _hoisted_2$
|
|
987
|
+
}, toDisplayString(option.label), 9, _hoisted_4$14);
|
|
988
|
+
}), 128))], 10, _hoisted_2$27), [[vModelSelect, model.value]]), createVNode(unref(ChevronDown), {
|
|
989
989
|
class: "text-ink-soft pointer-events-none absolute top-1/2 right-3 size-4 -translate-y-1/2",
|
|
990
990
|
"aria-hidden": "true"
|
|
991
991
|
})])]),
|
|
@@ -1002,11 +1002,11 @@ var BaseSelect_default = /* @__PURE__ */ defineComponent({
|
|
|
1002
1002
|
});
|
|
1003
1003
|
//#endregion
|
|
1004
1004
|
//#region src/components/BaseSlider.vue?vue&type=script&setup=true&lang.ts
|
|
1005
|
-
var _hoisted_1$
|
|
1006
|
-
var _hoisted_2$
|
|
1007
|
-
var _hoisted_3$
|
|
1008
|
-
var _hoisted_4$
|
|
1009
|
-
var _hoisted_5$
|
|
1005
|
+
var _hoisted_1$32 = { class: "rk-slider" };
|
|
1006
|
+
var _hoisted_2$26 = { class: "rk-slider-head" };
|
|
1007
|
+
var _hoisted_3$16 = ["for"];
|
|
1008
|
+
var _hoisted_4$13 = ["for"];
|
|
1009
|
+
var _hoisted_5$8 = [
|
|
1010
1010
|
"id",
|
|
1011
1011
|
"min",
|
|
1012
1012
|
"max",
|
|
@@ -1050,15 +1050,15 @@ var BaseSlider_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1050
1050
|
return span <= 0 ? 0 : (model.value - __props.min) / span * 100;
|
|
1051
1051
|
});
|
|
1052
1052
|
return (_ctx, _cache) => {
|
|
1053
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
1054
|
-
createElementVNode("div", _hoisted_2$
|
|
1053
|
+
return openBlock(), createElementBlock("div", _hoisted_1$32, [
|
|
1054
|
+
createElementVNode("div", _hoisted_2$26, [createElementVNode("label", {
|
|
1055
1055
|
for: unref(id),
|
|
1056
1056
|
class: "rk-slider-label"
|
|
1057
|
-
}, toDisplayString(__props.label), 9, _hoisted_3$
|
|
1057
|
+
}, toDisplayString(__props.label), 9, _hoisted_3$16), __props.showValue ? (openBlock(), createElementBlock("output", {
|
|
1058
1058
|
key: 0,
|
|
1059
1059
|
for: unref(id),
|
|
1060
1060
|
class: "rk-slider-value"
|
|
1061
|
-
}, toDisplayString(text.value), 9, _hoisted_4$
|
|
1061
|
+
}, toDisplayString(text.value), 9, _hoisted_4$13)) : createCommentVNode("", true)]),
|
|
1062
1062
|
withDirectives(createElementVNode("input", {
|
|
1063
1063
|
id: unref(id),
|
|
1064
1064
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => model.value = $event),
|
|
@@ -1071,7 +1071,7 @@ var BaseSlider_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1071
1071
|
"aria-valuetext": text.value,
|
|
1072
1072
|
"aria-describedby": __props.hint ? hintId : void 0,
|
|
1073
1073
|
style: normalizeStyle({ "--rk-slider-filled": `${filled.value}%` })
|
|
1074
|
-
}, null, 12, _hoisted_5$
|
|
1074
|
+
}, null, 12, _hoisted_5$8), [[
|
|
1075
1075
|
vModelText,
|
|
1076
1076
|
model.value,
|
|
1077
1077
|
void 0,
|
|
@@ -1088,11 +1088,11 @@ var BaseSlider_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1088
1088
|
}), [["__scopeId", "data-v-7fa2769b"]]);
|
|
1089
1089
|
//#endregion
|
|
1090
1090
|
//#region src/components/BaseSpinner.vue?vue&type=script&setup=true&lang.ts
|
|
1091
|
-
var _hoisted_1$
|
|
1091
|
+
var _hoisted_1$31 = {
|
|
1092
1092
|
class: "rk-spin-wrap",
|
|
1093
1093
|
role: "status"
|
|
1094
1094
|
};
|
|
1095
|
-
var _hoisted_2$
|
|
1095
|
+
var _hoisted_2$25 = { class: "rk-spin-label" };
|
|
1096
1096
|
//#endregion
|
|
1097
1097
|
//#region src/components/BaseSpinner.vue
|
|
1098
1098
|
var BaseSpinner_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
@@ -1120,26 +1120,26 @@ var BaseSpinner_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__
|
|
|
1120
1120
|
lg: "2.5rem"
|
|
1121
1121
|
};
|
|
1122
1122
|
return (_ctx, _cache) => {
|
|
1123
|
-
return openBlock(), createElementBlock("span", _hoisted_1$
|
|
1123
|
+
return openBlock(), createElementBlock("span", _hoisted_1$31, [createElementVNode("span", {
|
|
1124
1124
|
class: "rk-spin",
|
|
1125
1125
|
style: normalizeStyle({
|
|
1126
1126
|
width: SIZES[__props.size],
|
|
1127
1127
|
height: SIZES[__props.size]
|
|
1128
1128
|
}),
|
|
1129
1129
|
"aria-hidden": "true"
|
|
1130
|
-
}, null, 4), createElementVNode("span", _hoisted_2$
|
|
1130
|
+
}, null, 4), createElementVNode("span", _hoisted_2$25, toDisplayString(__props.label), 1)]);
|
|
1131
1131
|
};
|
|
1132
1132
|
}
|
|
1133
1133
|
}), [["__scopeId", "data-v-842da62c"]]);
|
|
1134
1134
|
//#endregion
|
|
1135
1135
|
//#region src/components/BaseSwitch.vue?vue&type=script&setup=true&lang.ts
|
|
1136
|
-
var _hoisted_1$
|
|
1137
|
-
var _hoisted_2$
|
|
1136
|
+
var _hoisted_1$30 = { class: "flex items-center justify-between gap-4" };
|
|
1137
|
+
var _hoisted_2$24 = {
|
|
1138
1138
|
key: 0,
|
|
1139
1139
|
class: "min-w-0"
|
|
1140
1140
|
};
|
|
1141
|
-
var _hoisted_3$
|
|
1142
|
-
var _hoisted_4$
|
|
1141
|
+
var _hoisted_3$15 = ["id"];
|
|
1142
|
+
var _hoisted_4$12 = [
|
|
1143
1143
|
"aria-checked",
|
|
1144
1144
|
"aria-labelledby",
|
|
1145
1145
|
"aria-label",
|
|
@@ -1178,10 +1178,10 @@ var BaseSwitch_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1178
1178
|
if (!__props.disabled) model.value = !model.value;
|
|
1179
1179
|
}
|
|
1180
1180
|
return (_ctx, _cache) => {
|
|
1181
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
1181
|
+
return openBlock(), createElementBlock("div", _hoisted_1$30, [!__props.labelHidden ? (openBlock(), createElementBlock("span", _hoisted_2$24, [createElementVNode("span", {
|
|
1182
1182
|
id: unref(id),
|
|
1183
1183
|
class: "text-ink block text-sm"
|
|
1184
|
-
}, toDisplayString(__props.label), 9, _hoisted_3$
|
|
1184
|
+
}, toDisplayString(__props.label), 9, _hoisted_3$15), __props.hint ? (openBlock(), createElementBlock("span", {
|
|
1185
1185
|
key: 0,
|
|
1186
1186
|
id: hintId,
|
|
1187
1187
|
class: "text-ink-soft mt-0.5 block text-xs"
|
|
@@ -1198,17 +1198,17 @@ var BaseSwitch_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1198
1198
|
}, [..._cache[0] || (_cache[0] = [createElementVNode("span", {
|
|
1199
1199
|
class: "rk-switch-knob",
|
|
1200
1200
|
"aria-hidden": "true"
|
|
1201
|
-
}, null, -1)])], 10, _hoisted_4$
|
|
1201
|
+
}, null, -1)])], 10, _hoisted_4$12)]);
|
|
1202
1202
|
};
|
|
1203
1203
|
}
|
|
1204
1204
|
}), [["__scopeId", "data-v-3f4400a0"]]);
|
|
1205
1205
|
//#endregion
|
|
1206
1206
|
//#region src/components/BaseTable.vue?vue&type=script&setup=true&lang.ts
|
|
1207
|
-
var _hoisted_1$
|
|
1208
|
-
var _hoisted_2$
|
|
1209
|
-
var _hoisted_3$
|
|
1210
|
-
var _hoisted_4$
|
|
1211
|
-
var _hoisted_5$
|
|
1207
|
+
var _hoisted_1$29 = ["aria-label"];
|
|
1208
|
+
var _hoisted_2$23 = { class: "rk-table" };
|
|
1209
|
+
var _hoisted_3$14 = { key: 0 };
|
|
1210
|
+
var _hoisted_4$11 = { key: 1 };
|
|
1211
|
+
var _hoisted_5$7 = ["colspan"];
|
|
1212
1212
|
//#endregion
|
|
1213
1213
|
//#region src/components/BaseTable.vue
|
|
1214
1214
|
var BaseTable_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
@@ -1231,7 +1231,7 @@ var BaseTable_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
1231
1231
|
tabindex: "0",
|
|
1232
1232
|
role: "region",
|
|
1233
1233
|
"aria-label": __props.caption
|
|
1234
|
-
}, [createElementVNode("table", _hoisted_2$
|
|
1234
|
+
}, [createElementVNode("table", _hoisted_2$23, [
|
|
1235
1235
|
createElementVNode("caption", { class: normalizeClass(__props.captionHidden ? "rk-table-caption-hidden" : "rk-table-caption") }, toDisplayString(__props.caption), 3),
|
|
1236
1236
|
createElementVNode("thead", null, [createElementVNode("tr", null, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.columns, (column) => {
|
|
1237
1237
|
return openBlock(), createElementBlock("th", {
|
|
@@ -1240,7 +1240,7 @@ var BaseTable_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
1240
1240
|
class: normalizeClass([column.align === "end" && "is-end", column.nowrap && "is-nowrap"])
|
|
1241
1241
|
}, toDisplayString(column.label), 3);
|
|
1242
1242
|
}), 128))])]),
|
|
1243
|
-
__props.rows.length > 0 ? (openBlock(), createElementBlock("tbody", _hoisted_3$
|
|
1243
|
+
__props.rows.length > 0 ? (openBlock(), createElementBlock("tbody", _hoisted_3$14, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.rows, (row, index) => {
|
|
1244
1244
|
return openBlock(), createElementBlock("tr", { key: keyFor(row, index) }, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.columns, (column) => {
|
|
1245
1245
|
return openBlock(), createElementBlock("td", {
|
|
1246
1246
|
key: column.key,
|
|
@@ -1250,17 +1250,17 @@ var BaseTable_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
1250
1250
|
value: row[column.key]
|
|
1251
1251
|
}, () => [createTextVNode(toDisplayString(row[column.key]), 1)], true)], 2);
|
|
1252
1252
|
}), 128))]);
|
|
1253
|
-
}), 128))])) : (openBlock(), createElementBlock("tbody", _hoisted_4$
|
|
1253
|
+
}), 128))])) : (openBlock(), createElementBlock("tbody", _hoisted_4$11, [createElementVNode("tr", null, [createElementVNode("td", {
|
|
1254
1254
|
colspan: __props.columns.length,
|
|
1255
1255
|
class: "rk-table-empty"
|
|
1256
|
-
}, [renderSlot(_ctx.$slots, "empty", {}, void 0, true)], 8, _hoisted_5$
|
|
1257
|
-
])], 8, _hoisted_1$
|
|
1256
|
+
}, [renderSlot(_ctx.$slots, "empty", {}, void 0, true)], 8, _hoisted_5$7)])]))
|
|
1257
|
+
])], 8, _hoisted_1$29);
|
|
1258
1258
|
};
|
|
1259
1259
|
}
|
|
1260
1260
|
}), [["__scopeId", "data-v-89958b5a"]]);
|
|
1261
1261
|
//#endregion
|
|
1262
1262
|
//#region src/components/BaseTextarea.vue?vue&type=script&setup=true&lang.ts
|
|
1263
|
-
var _hoisted_1$
|
|
1263
|
+
var _hoisted_1$28 = [
|
|
1264
1264
|
"id",
|
|
1265
1265
|
"rows",
|
|
1266
1266
|
"aria-invalid",
|
|
@@ -1306,7 +1306,7 @@ var BaseTextarea_default = /* @__PURE__ */ defineComponent({
|
|
|
1306
1306
|
__props.variant === "unstyled" ? "" : "control text-ink rounded-card focus-visible:outline-primary resize-y px-3 py-2 leading-relaxed focus-visible:outline-2 focus-visible:outline-offset-1",
|
|
1307
1307
|
"text-base",
|
|
1308
1308
|
__props.variant !== "unstyled" && invalid ? "border-negative" : ""
|
|
1309
|
-
] }), null, 16, _hoisted_1$
|
|
1309
|
+
] }), null, 16, _hoisted_1$28), [[vModelText, unref(model)]])]),
|
|
1310
1310
|
_: 1
|
|
1311
1311
|
}, 8, [
|
|
1312
1312
|
"label",
|
|
@@ -1320,17 +1320,17 @@ var BaseTextarea_default = /* @__PURE__ */ defineComponent({
|
|
|
1320
1320
|
});
|
|
1321
1321
|
//#endregion
|
|
1322
1322
|
//#region src/components/EmptyState.vue?vue&type=script&setup=true&lang.ts
|
|
1323
|
-
var _hoisted_1$
|
|
1324
|
-
var _hoisted_2$
|
|
1323
|
+
var _hoisted_1$27 = { class: "flex flex-col items-center gap-3 px-6 py-10 text-center" };
|
|
1324
|
+
var _hoisted_2$22 = {
|
|
1325
1325
|
key: 0,
|
|
1326
1326
|
class: "bg-muted text-primary rounded-card flex size-12 items-center justify-center"
|
|
1327
1327
|
};
|
|
1328
|
-
var _hoisted_3$
|
|
1329
|
-
var _hoisted_4$
|
|
1328
|
+
var _hoisted_3$13 = { class: "text-ink text-base font-semibold" };
|
|
1329
|
+
var _hoisted_4$10 = {
|
|
1330
1330
|
key: 1,
|
|
1331
1331
|
class: "text-ink-soft max-w-[36ch] text-sm"
|
|
1332
1332
|
};
|
|
1333
|
-
var _hoisted_5$
|
|
1333
|
+
var _hoisted_5$6 = {
|
|
1334
1334
|
key: 2,
|
|
1335
1335
|
class: "mt-2 flex w-full flex-col gap-2"
|
|
1336
1336
|
};
|
|
@@ -1352,11 +1352,11 @@ var EmptyState_default = /* @__PURE__ */ defineComponent({
|
|
|
1352
1352
|
* goes — the button that creates the first one.
|
|
1353
1353
|
*/
|
|
1354
1354
|
return (_ctx, _cache) => {
|
|
1355
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
1356
|
-
_ctx.$slots.icon ? (openBlock(), createElementBlock("div", _hoisted_2$
|
|
1357
|
-
createElementVNode("h3", _hoisted_3$
|
|
1358
|
-
__props.description ? (openBlock(), createElementBlock("p", _hoisted_4$
|
|
1359
|
-
_ctx.$slots.action ? (openBlock(), createElementBlock("div", _hoisted_5$
|
|
1355
|
+
return openBlock(), createElementBlock("div", _hoisted_1$27, [
|
|
1356
|
+
_ctx.$slots.icon ? (openBlock(), createElementBlock("div", _hoisted_2$22, [renderSlot(_ctx.$slots, "icon")])) : createCommentVNode("", true),
|
|
1357
|
+
createElementVNode("h3", _hoisted_3$13, toDisplayString(__props.title), 1),
|
|
1358
|
+
__props.description ? (openBlock(), createElementBlock("p", _hoisted_4$10, toDisplayString(__props.description), 1)) : createCommentVNode("", true),
|
|
1359
|
+
_ctx.$slots.action ? (openBlock(), createElementBlock("div", _hoisted_5$6, [renderSlot(_ctx.$slots, "action")])) : createCommentVNode("", true)
|
|
1360
1360
|
]);
|
|
1361
1361
|
};
|
|
1362
1362
|
}
|
|
@@ -1423,11 +1423,11 @@ var PageContainer_default = /* @__PURE__ */ defineComponent({
|
|
|
1423
1423
|
});
|
|
1424
1424
|
//#endregion
|
|
1425
1425
|
//#region src/components/PageHeader.vue?vue&type=script&setup=true&lang.ts
|
|
1426
|
-
var _hoisted_1$
|
|
1427
|
-
var _hoisted_2$
|
|
1428
|
-
var _hoisted_3$
|
|
1429
|
-
var _hoisted_4$
|
|
1430
|
-
var _hoisted_5$
|
|
1426
|
+
var _hoisted_1$26 = { class: "grid h-12 shrink-0 grid-cols-[2.5rem_1fr_2.5rem] items-center" };
|
|
1427
|
+
var _hoisted_2$21 = { class: "justify-self-start" };
|
|
1428
|
+
var _hoisted_3$12 = { class: "text-ink flex min-w-0 justify-center text-base font-semibold tabular-nums" };
|
|
1429
|
+
var _hoisted_4$9 = { class: "truncate" };
|
|
1430
|
+
var _hoisted_5$5 = { class: "justify-self-end" };
|
|
1431
1431
|
//#endregion
|
|
1432
1432
|
//#region src/components/PageHeader.vue
|
|
1433
1433
|
var PageHeader_default = /* @__PURE__ */ defineComponent({
|
|
@@ -1444,17 +1444,17 @@ var PageHeader_default = /* @__PURE__ */ defineComponent({
|
|
|
1444
1444
|
* each other.
|
|
1445
1445
|
*/
|
|
1446
1446
|
return (_ctx, _cache) => {
|
|
1447
|
-
return openBlock(), createElementBlock("header", _hoisted_1$
|
|
1448
|
-
createElementVNode("div", _hoisted_2$
|
|
1449
|
-
createElementVNode("h1", _hoisted_3$
|
|
1450
|
-
createElementVNode("div", _hoisted_5$
|
|
1447
|
+
return openBlock(), createElementBlock("header", _hoisted_1$26, [
|
|
1448
|
+
createElementVNode("div", _hoisted_2$21, [renderSlot(_ctx.$slots, "left")]),
|
|
1449
|
+
createElementVNode("h1", _hoisted_3$12, [renderSlot(_ctx.$slots, "title", {}, () => [createElementVNode("span", _hoisted_4$9, toDisplayString(__props.title), 1)])]),
|
|
1450
|
+
createElementVNode("div", _hoisted_5$5, [renderSlot(_ctx.$slots, "right")])
|
|
1451
1451
|
]);
|
|
1452
1452
|
};
|
|
1453
1453
|
}
|
|
1454
1454
|
});
|
|
1455
1455
|
//#endregion
|
|
1456
1456
|
//#region src/components/ProgressBar.vue?vue&type=script&setup=true&lang.ts
|
|
1457
|
-
var _hoisted_1$
|
|
1457
|
+
var _hoisted_1$25 = ["aria-valuenow", "aria-label"];
|
|
1458
1458
|
//#endregion
|
|
1459
1459
|
//#region src/components/ProgressBar.vue
|
|
1460
1460
|
var ProgressBar_default = /* @__PURE__ */ defineComponent({
|
|
@@ -1486,43 +1486,43 @@ var ProgressBar_default = /* @__PURE__ */ defineComponent({
|
|
|
1486
1486
|
}, [createElementVNode("div", {
|
|
1487
1487
|
class: "bg-primary h-full rounded-full transition-[width] duration-700 ease-out",
|
|
1488
1488
|
style: normalizeStyle({ width: `${portion.value}%` })
|
|
1489
|
-
}, null, 4)], 10, _hoisted_1$
|
|
1489
|
+
}, null, 4)], 10, _hoisted_1$25);
|
|
1490
1490
|
};
|
|
1491
1491
|
}
|
|
1492
1492
|
});
|
|
1493
1493
|
//#endregion
|
|
1494
1494
|
//#region src/components/PriceCard.vue?vue&type=script&setup=true&lang.ts
|
|
1495
|
-
var _hoisted_1$
|
|
1495
|
+
var _hoisted_1$24 = {
|
|
1496
1496
|
key: 0,
|
|
1497
1497
|
class: "bg-primary rounded-cell text-on-primary absolute -top-3 left-7 px-3 py-1 text-[0.7rem] font-semibold"
|
|
1498
1498
|
};
|
|
1499
|
-
var _hoisted_2$
|
|
1500
|
-
var _hoisted_3$
|
|
1501
|
-
var _hoisted_4$
|
|
1499
|
+
var _hoisted_2$20 = { class: "flex items-start justify-between gap-4" };
|
|
1500
|
+
var _hoisted_3$11 = { class: "text-ink mt-5 text-lg font-semibold" };
|
|
1501
|
+
var _hoisted_4$8 = {
|
|
1502
1502
|
key: 1,
|
|
1503
1503
|
class: "text-ink-soft mt-1.5 text-sm leading-relaxed"
|
|
1504
1504
|
};
|
|
1505
|
-
var _hoisted_5$
|
|
1506
|
-
var _hoisted_6$
|
|
1507
|
-
var _hoisted_7$
|
|
1505
|
+
var _hoisted_5$4 = { class: "mt-6 flex items-baseline gap-1.5" };
|
|
1506
|
+
var _hoisted_6$4 = { class: "text-ink text-3xl font-semibold tracking-tight tabular-nums" };
|
|
1507
|
+
var _hoisted_7$3 = {
|
|
1508
1508
|
key: 0,
|
|
1509
1509
|
class: "text-ink-soft text-sm"
|
|
1510
1510
|
};
|
|
1511
|
-
var _hoisted_8 = {
|
|
1511
|
+
var _hoisted_8$2 = {
|
|
1512
1512
|
key: 2,
|
|
1513
1513
|
class: "text-ink-soft mt-1 text-xs"
|
|
1514
1514
|
};
|
|
1515
|
-
var _hoisted_9 = { class: "mt-7 flex-1 space-y-3" };
|
|
1516
|
-
var _hoisted_10 = {
|
|
1515
|
+
var _hoisted_9$2 = { class: "mt-7 flex-1 space-y-3" };
|
|
1516
|
+
var _hoisted_10$2 = {
|
|
1517
1517
|
key: 0,
|
|
1518
1518
|
class: "mt-[0.45rem] shrink-0"
|
|
1519
1519
|
};
|
|
1520
|
-
var _hoisted_11 = {
|
|
1520
|
+
var _hoisted_11$2 = {
|
|
1521
1521
|
key: 1,
|
|
1522
1522
|
class: "bg-primary/45 mt-[0.45rem] size-1.5 shrink-0 rounded-full",
|
|
1523
1523
|
"aria-hidden": "true"
|
|
1524
1524
|
};
|
|
1525
|
-
var _hoisted_12 = { class: "text-ink-soft leading-relaxed" };
|
|
1525
|
+
var _hoisted_12$1 = { class: "text-ink-soft leading-relaxed" };
|
|
1526
1526
|
var _hoisted_13 = {
|
|
1527
1527
|
key: 3,
|
|
1528
1528
|
class: "mt-8"
|
|
@@ -1567,23 +1567,23 @@ var PriceCard_default = /* @__PURE__ */ defineComponent({
|
|
|
1567
1567
|
const palette = computed(() => TONE[__props.tone]);
|
|
1568
1568
|
return (_ctx, _cache) => {
|
|
1569
1569
|
return openBlock(), createElementBlock("article", { class: normalizeClass(["surface rounded-card ease-standard relative flex h-full flex-col p-7 transition-[border-color,box-shadow,transform] duration-(--duration-slower) hover:[--surface-border-color:color-mix(in_oklab,var(--color-primary)_60%,transparent)] hover:[--surface-shadow:var(--shadow-raised)] sm:p-8", [palette.value.ring, __props.recommended ? "[--surface-shadow:var(--shadow-raised)]" : "hover:-translate-y-0.5"]]) }, [
|
|
1570
|
-
__props.badge && __props.recommended ? (openBlock(), createElementBlock("span", _hoisted_1$
|
|
1571
|
-
createElementVNode("div", _hoisted_2$
|
|
1570
|
+
__props.badge && __props.recommended ? (openBlock(), createElementBlock("span", _hoisted_1$24, toDisplayString(__props.badge), 1)) : createCommentVNode("", true),
|
|
1571
|
+
createElementVNode("div", _hoisted_2$20, [_ctx.$slots.icon ? (openBlock(), createElementBlock("span", {
|
|
1572
1572
|
key: 0,
|
|
1573
1573
|
class: normalizeClass(["rounded-card grid size-11 place-items-center text-xl", palette.value.icon])
|
|
1574
1574
|
}, [renderSlot(_ctx.$slots, "icon")], 2)) : createCommentVNode("", true), __props.chip ? (openBlock(), createElementBlock("span", {
|
|
1575
1575
|
key: 1,
|
|
1576
1576
|
class: normalizeClass(["rounded-cell ml-auto px-2.5 py-1 text-[0.7rem] font-medium", palette.value.soft])
|
|
1577
1577
|
}, toDisplayString(__props.chip), 3)) : createCommentVNode("", true)]),
|
|
1578
|
-
createElementVNode("h3", _hoisted_3$
|
|
1579
|
-
__props.lead ? (openBlock(), createElementBlock("p", _hoisted_4$
|
|
1580
|
-
createElementVNode("p", _hoisted_5$
|
|
1581
|
-
__props.note ? (openBlock(), createElementBlock("p", _hoisted_8, toDisplayString(__props.note), 1)) : createCommentVNode("", true),
|
|
1582
|
-
createElementVNode("ul", _hoisted_9, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.features, (feature) => {
|
|
1578
|
+
createElementVNode("h3", _hoisted_3$11, toDisplayString(__props.name), 1),
|
|
1579
|
+
__props.lead ? (openBlock(), createElementBlock("p", _hoisted_4$8, toDisplayString(__props.lead), 1)) : createCommentVNode("", true),
|
|
1580
|
+
createElementVNode("p", _hoisted_5$4, [createElementVNode("span", _hoisted_6$4, toDisplayString(__props.price), 1), __props.period ? (openBlock(), createElementBlock("span", _hoisted_7$3, toDisplayString(__props.period), 1)) : createCommentVNode("", true)]),
|
|
1581
|
+
__props.note ? (openBlock(), createElementBlock("p", _hoisted_8$2, toDisplayString(__props.note), 1)) : createCommentVNode("", true),
|
|
1582
|
+
createElementVNode("ul", _hoisted_9$2, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.features, (feature) => {
|
|
1583
1583
|
return openBlock(), createElementBlock("li", {
|
|
1584
1584
|
key: feature,
|
|
1585
1585
|
class: "flex gap-3 text-sm"
|
|
1586
|
-
}, [_ctx.$slots.bullet ? (openBlock(), createElementBlock("span", _hoisted_10, [renderSlot(_ctx.$slots, "bullet")])) : (openBlock(), createElementBlock("span", _hoisted_11)), createElementVNode("span", _hoisted_12, toDisplayString(feature), 1)]);
|
|
1586
|
+
}, [_ctx.$slots.bullet ? (openBlock(), createElementBlock("span", _hoisted_10$2, [renderSlot(_ctx.$slots, "bullet")])) : (openBlock(), createElementBlock("span", _hoisted_11$2)), createElementVNode("span", _hoisted_12$1, toDisplayString(feature), 1)]);
|
|
1587
1587
|
}), 128))]),
|
|
1588
1588
|
_ctx.$slots.action ? (openBlock(), createElementBlock("div", _hoisted_13, [renderSlot(_ctx.$slots, "action")])) : createCommentVNode("", true)
|
|
1589
1589
|
], 2);
|
|
@@ -1592,8 +1592,8 @@ var PriceCard_default = /* @__PURE__ */ defineComponent({
|
|
|
1592
1592
|
});
|
|
1593
1593
|
//#endregion
|
|
1594
1594
|
//#region src/components/ToneDot.vue?vue&type=script&setup=true&lang.ts
|
|
1595
|
-
var _hoisted_1$
|
|
1596
|
-
var _hoisted_2$
|
|
1595
|
+
var _hoisted_1$23 = { class: "inline-flex items-center gap-1.5" };
|
|
1596
|
+
var _hoisted_2$19 = {
|
|
1597
1597
|
key: 0,
|
|
1598
1598
|
class: "text-ink-soft text-xs font-medium"
|
|
1599
1599
|
};
|
|
@@ -1614,13 +1614,13 @@ var ToneDot_default = /* @__PURE__ */ defineComponent({
|
|
|
1614
1614
|
* priorities — without this component knowing about any of them.
|
|
1615
1615
|
*/
|
|
1616
1616
|
return (_ctx, _cache) => {
|
|
1617
|
-
return openBlock(), createElementBlock("span", _hoisted_1$
|
|
1617
|
+
return openBlock(), createElementBlock("span", _hoisted_1$23, [createElementVNode("span", { class: normalizeClass(["size-2 rounded-full", __props.fill]) }, null, 2), __props.label ? (openBlock(), createElementBlock("span", _hoisted_2$19, toDisplayString(__props.label), 1)) : createCommentVNode("", true)]);
|
|
1618
1618
|
};
|
|
1619
1619
|
}
|
|
1620
1620
|
});
|
|
1621
1621
|
//#endregion
|
|
1622
1622
|
//#region src/components/SectionHeading.vue?vue&type=script&setup=true&lang.ts
|
|
1623
|
-
var _hoisted_1$
|
|
1623
|
+
var _hoisted_1$22 = {
|
|
1624
1624
|
key: 0,
|
|
1625
1625
|
class: "text-ink-soft text-xs tabular-nums"
|
|
1626
1626
|
};
|
|
@@ -1638,15 +1638,15 @@ var SectionHeading_default = /* @__PURE__ */ defineComponent({
|
|
|
1638
1638
|
return openBlock(), createElementBlock("h2", { class: normalizeClass(["flex w-fit items-center gap-2 self-start rounded-full border px-3 py-1", __props.tone.card]) }, [
|
|
1639
1639
|
createVNode(ToneDot_default, { fill: __props.tone.fill }, null, 8, ["fill"]),
|
|
1640
1640
|
createElementVNode("span", { class: normalizeClass(["text-xs font-semibold tracking-wide uppercase", __props.tone.text]) }, toDisplayString(__props.label), 3),
|
|
1641
|
-
__props.count > 0 ? (openBlock(), createElementBlock("span", _hoisted_1$
|
|
1641
|
+
__props.count > 0 ? (openBlock(), createElementBlock("span", _hoisted_1$22, toDisplayString(__props.count), 1)) : createCommentVNode("", true)
|
|
1642
1642
|
], 2);
|
|
1643
1643
|
};
|
|
1644
1644
|
}
|
|
1645
1645
|
});
|
|
1646
1646
|
//#endregion
|
|
1647
1647
|
//#region src/components/SegmentedControl.vue?vue&type=script&setup=true&lang.ts
|
|
1648
|
-
var _hoisted_1$
|
|
1649
|
-
var _hoisted_2$
|
|
1648
|
+
var _hoisted_1$21 = { class: "bg-muted rounded-card flex w-full gap-1 p-1" };
|
|
1649
|
+
var _hoisted_2$18 = ["value", "name"];
|
|
1650
1650
|
//#endregion
|
|
1651
1651
|
//#region src/components/SegmentedControl.vue
|
|
1652
1652
|
var SegmentedControl_default = /* @__PURE__ */ defineComponent({
|
|
@@ -1660,7 +1660,7 @@ var SegmentedControl_default = /* @__PURE__ */ defineComponent({
|
|
|
1660
1660
|
const model = useModel(__props, "modelValue");
|
|
1661
1661
|
const name = useId();
|
|
1662
1662
|
return (_ctx, _cache) => {
|
|
1663
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
1663
|
+
return openBlock(), createElementBlock("div", _hoisted_1$21, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.options, (option) => {
|
|
1664
1664
|
return openBlock(), createElementBlock("label", {
|
|
1665
1665
|
key: String(option.value),
|
|
1666
1666
|
class: "flex-1 cursor-pointer"
|
|
@@ -1670,18 +1670,18 @@ var SegmentedControl_default = /* @__PURE__ */ defineComponent({
|
|
|
1670
1670
|
value: option.value,
|
|
1671
1671
|
name: unref(name),
|
|
1672
1672
|
class: "peer sr-only"
|
|
1673
|
-
}, null, 8, _hoisted_2$
|
|
1673
|
+
}, null, 8, _hoisted_2$18), [[vModelRadio, model.value]]), createElementVNode("span", { class: normalizeClass(["peer-focus-visible:outline-primary flex h-10 items-center justify-center rounded-xl px-2 text-sm font-medium transition-colors select-none peer-focus-visible:outline-2 peer-focus-visible:outline-offset-2", model.value === option.value ? "bg-surface text-ink shadow-(--shadow-control)" : "text-ink-soft"]) }, toDisplayString(option.label), 3)]);
|
|
1674
1674
|
}), 128))]);
|
|
1675
1675
|
};
|
|
1676
1676
|
}
|
|
1677
1677
|
});
|
|
1678
1678
|
//#endregion
|
|
1679
1679
|
//#region src/components/SkeletonList.vue?vue&type=script&setup=true&lang.ts
|
|
1680
|
-
var _hoisted_1$
|
|
1680
|
+
var _hoisted_1$20 = {
|
|
1681
1681
|
role: "status",
|
|
1682
1682
|
class: "flex flex-col gap-1"
|
|
1683
1683
|
};
|
|
1684
|
-
var _hoisted_2$
|
|
1684
|
+
var _hoisted_2$17 = { class: "sr-only" };
|
|
1685
1685
|
//#endregion
|
|
1686
1686
|
//#region src/components/SkeletonList.vue
|
|
1687
1687
|
var SkeletonList_default = /* @__PURE__ */ defineComponent({
|
|
@@ -1695,7 +1695,7 @@ var SkeletonList_default = /* @__PURE__ */ defineComponent({
|
|
|
1695
1695
|
/** A length starts with a digit, a dot, or opens a CSS function. */
|
|
1696
1696
|
const isLength = computed(() => /^(?:[.\d]|calc\(|var\(|clamp\(|min\(|max\()/.test(__props.rowHeight));
|
|
1697
1697
|
return (_ctx, _cache) => {
|
|
1698
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
1698
|
+
return openBlock(), createElementBlock("div", _hoisted_1$20, [createElementVNode("span", _hoisted_2$17, toDisplayString(__props.label), 1), (openBlock(true), createElementBlock(Fragment, null, renderList(__props.rows, (row) => {
|
|
1699
1699
|
return openBlock(), createElementBlock("div", {
|
|
1700
1700
|
key: row,
|
|
1701
1701
|
class: normalizeClass(["bg-muted rounded-card animate-pulse", isLength.value ? void 0 : __props.rowHeight]),
|
|
@@ -1708,10 +1708,10 @@ var SkeletonList_default = /* @__PURE__ */ defineComponent({
|
|
|
1708
1708
|
});
|
|
1709
1709
|
//#endregion
|
|
1710
1710
|
//#region src/components/StatCard.vue?vue&type=script&setup=true&lang.ts
|
|
1711
|
-
var _hoisted_1$
|
|
1712
|
-
var _hoisted_2$
|
|
1713
|
-
var _hoisted_3$
|
|
1714
|
-
var _hoisted_4$
|
|
1711
|
+
var _hoisted_1$19 = { class: "surface rounded-card flex flex-1 flex-col gap-0.5 p-3" };
|
|
1712
|
+
var _hoisted_2$16 = { class: "flex items-baseline gap-1" };
|
|
1713
|
+
var _hoisted_3$10 = { class: "text-ink text-xl font-semibold tabular-nums" };
|
|
1714
|
+
var _hoisted_4$7 = { class: "text-ink-soft text-xs" };
|
|
1715
1715
|
//#endregion
|
|
1716
1716
|
//#region src/components/StatCard.vue
|
|
1717
1717
|
var StatCard_default = /* @__PURE__ */ defineComponent({
|
|
@@ -1728,22 +1728,22 @@ var StatCard_default = /* @__PURE__ */ defineComponent({
|
|
|
1728
1728
|
flat: ArrowRight
|
|
1729
1729
|
};
|
|
1730
1730
|
return (_ctx, _cache) => {
|
|
1731
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
1731
|
+
return openBlock(), createElementBlock("div", _hoisted_1$19, [createElementVNode("div", _hoisted_2$16, [createElementVNode("span", _hoisted_3$10, toDisplayString(__props.value), 1), __props.trend ? (openBlock(), createBlock(resolveDynamicComponent(TREND_ICON[__props.trend]), {
|
|
1732
1732
|
key: 0,
|
|
1733
1733
|
class: "text-ink-soft size-3"
|
|
1734
|
-
})) : createCommentVNode("", true)]), createElementVNode("span", _hoisted_4$
|
|
1734
|
+
})) : createCommentVNode("", true)]), createElementVNode("span", _hoisted_4$7, toDisplayString(__props.label), 1)]);
|
|
1735
1735
|
};
|
|
1736
1736
|
}
|
|
1737
1737
|
});
|
|
1738
1738
|
//#endregion
|
|
1739
1739
|
//#region src/components/ToastHost.vue?vue&type=script&setup=true&lang.ts
|
|
1740
|
-
var _hoisted_1$
|
|
1740
|
+
var _hoisted_1$18 = [
|
|
1741
1741
|
"onMouseenter",
|
|
1742
1742
|
"onMouseleave",
|
|
1743
1743
|
"onFocusin",
|
|
1744
1744
|
"onFocusout"
|
|
1745
1745
|
];
|
|
1746
|
-
var _hoisted_2$
|
|
1746
|
+
var _hoisted_2$15 = { class: "flex-1 text-sm leading-snug" };
|
|
1747
1747
|
//#endregion
|
|
1748
1748
|
//#region src/components/ToastHost.vue
|
|
1749
1749
|
var ToastHost_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
@@ -1804,7 +1804,7 @@ var ToastHost_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
1804
1804
|
class: normalizeClass(["mt-0.5 size-5 shrink-0", TONE_CLASS[toast.tone]]),
|
|
1805
1805
|
"aria-hidden": "true"
|
|
1806
1806
|
}, null, 8, ["class"])),
|
|
1807
|
-
createElementVNode("p", _hoisted_2$
|
|
1807
|
+
createElementVNode("p", _hoisted_2$15, toDisplayString(toast.message), 1),
|
|
1808
1808
|
toast.action ? (openBlock(), createBlock(BaseButton_default, {
|
|
1809
1809
|
key: 0,
|
|
1810
1810
|
variant: "link",
|
|
@@ -1827,7 +1827,7 @@ var ToastHost_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
1827
1827
|
default: withCtx(() => [createVNode(unref(X), { class: "size-4" })]),
|
|
1828
1828
|
_: 1
|
|
1829
1829
|
}, 8, ["aria-label", "onClick"])
|
|
1830
|
-
], 40, _hoisted_1$
|
|
1830
|
+
], 40, _hoisted_1$18);
|
|
1831
1831
|
}), 128))]),
|
|
1832
1832
|
_: 1
|
|
1833
1833
|
})], 2)])) : createCommentVNode("", true);
|
|
@@ -1836,8 +1836,8 @@ var ToastHost_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
1836
1836
|
}), [["__scopeId", "data-v-737eb240"]]);
|
|
1837
1837
|
//#endregion
|
|
1838
1838
|
//#region src/components/LocaleLinks.vue?vue&type=script&setup=true&lang.ts
|
|
1839
|
-
var _hoisted_1$
|
|
1840
|
-
var _hoisted_2$
|
|
1839
|
+
var _hoisted_1$17 = ["aria-label"];
|
|
1840
|
+
var _hoisted_2$14 = [
|
|
1841
1841
|
"lang",
|
|
1842
1842
|
"aria-pressed",
|
|
1843
1843
|
"onClick"
|
|
@@ -1881,17 +1881,17 @@ var LocaleLinks_default = /* @__PURE__ */ defineComponent({
|
|
|
1881
1881
|
class: normalizeClass(["focus-ring rounded-full px-2.5 py-1.5 text-xs transition-colors", preference.value === locale ? "bg-muted text-ink font-semibold" : "text-ink-soft hover:text-ink"]),
|
|
1882
1882
|
"aria-pressed": preference.value === locale,
|
|
1883
1883
|
onClick: ($event) => preference.value = locale
|
|
1884
|
-
}, toDisplayString(__props.labels[locale]), 11, _hoisted_2$
|
|
1885
|
-
}), 128))], 8, _hoisted_1$
|
|
1884
|
+
}, toDisplayString(__props.labels[locale]), 11, _hoisted_2$14);
|
|
1885
|
+
}), 128))], 8, _hoisted_1$17);
|
|
1886
1886
|
};
|
|
1887
1887
|
}
|
|
1888
1888
|
});
|
|
1889
1889
|
//#endregion
|
|
1890
1890
|
//#region src/components/TabBar.vue?vue&type=script&setup=true&lang.ts
|
|
1891
|
-
var _hoisted_1$
|
|
1892
|
-
var _hoisted_2$
|
|
1893
|
-
var _hoisted_3$
|
|
1894
|
-
var _hoisted_4$
|
|
1891
|
+
var _hoisted_1$16 = { class: "tab-bar" };
|
|
1892
|
+
var _hoisted_2$13 = ["aria-label"];
|
|
1893
|
+
var _hoisted_3$9 = { class: "tab-icon-slot" };
|
|
1894
|
+
var _hoisted_4$6 = { class: "tab-label" };
|
|
1895
1895
|
//#endregion
|
|
1896
1896
|
//#region src/components/TabBar.vue
|
|
1897
1897
|
var TabBar_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
@@ -1903,7 +1903,7 @@ var TabBar_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
1903
1903
|
},
|
|
1904
1904
|
setup(__props) {
|
|
1905
1905
|
return (_ctx, _cache) => {
|
|
1906
|
-
return openBlock(), createElementBlock("header", _hoisted_1$
|
|
1906
|
+
return openBlock(), createElementBlock("header", _hoisted_1$16, [createElementVNode("nav", {
|
|
1907
1907
|
class: "tab-bar-inner",
|
|
1908
1908
|
"aria-label": __props.label || void 0
|
|
1909
1909
|
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.items, (item) => {
|
|
@@ -1914,20 +1914,967 @@ var TabBar_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
1914
1914
|
"aria-current": item.key === __props.active ? "page" : void 0,
|
|
1915
1915
|
onClick: _cache[0] || (_cache[0] = ($event) => unref(tapFeedback)())
|
|
1916
1916
|
}, {
|
|
1917
|
-
default: withCtx(() => [createElementVNode("span", _hoisted_3$
|
|
1917
|
+
default: withCtx(() => [createElementVNode("span", _hoisted_3$9, [(openBlock(), createBlock(resolveDynamicComponent(item.icon), { class: "tab-icon" }))]), createElementVNode("span", _hoisted_4$6, toDisplayString(item.label), 1)]),
|
|
1918
1918
|
_: 2
|
|
1919
1919
|
}, 1032, [
|
|
1920
1920
|
"to",
|
|
1921
1921
|
"class",
|
|
1922
1922
|
"aria-current"
|
|
1923
1923
|
]);
|
|
1924
|
-
}), 128))], 8, _hoisted_2$
|
|
1924
|
+
}), 128))], 8, _hoisted_2$13)]);
|
|
1925
1925
|
};
|
|
1926
1926
|
}
|
|
1927
1927
|
}), [["__scopeId", "data-v-a76891c4"]]);
|
|
1928
1928
|
//#endregion
|
|
1929
|
+
//#region src/components/AvatarStack.vue?vue&type=script&setup=true&lang.ts
|
|
1930
|
+
var _hoisted_1$15 = ["aria-label"];
|
|
1931
|
+
var _hoisted_2$12 = {
|
|
1932
|
+
key: 0,
|
|
1933
|
+
class: "rk-stack-item rk-stack-rest",
|
|
1934
|
+
"aria-hidden": "true"
|
|
1935
|
+
};
|
|
1936
|
+
//#endregion
|
|
1937
|
+
//#region src/components/AvatarStack.vue
|
|
1938
|
+
var AvatarStack_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
1939
|
+
__name: "AvatarStack",
|
|
1940
|
+
props: {
|
|
1941
|
+
people: {},
|
|
1942
|
+
label: {},
|
|
1943
|
+
max: { default: 4 },
|
|
1944
|
+
size: { default: "md" }
|
|
1945
|
+
},
|
|
1946
|
+
setup(__props) {
|
|
1947
|
+
const shown = computed(() => __props.people.slice(0, __props.max));
|
|
1948
|
+
const rest = computed(() => Math.max(0, __props.people.length - shown.value.length));
|
|
1949
|
+
return (_ctx, _cache) => {
|
|
1950
|
+
return openBlock(), createElementBlock("div", {
|
|
1951
|
+
class: normalizeClass(["rk-stack", `is-${__props.size}`]),
|
|
1952
|
+
role: "img",
|
|
1953
|
+
"aria-label": __props.label
|
|
1954
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(shown.value, (person) => {
|
|
1955
|
+
return openBlock(), createElementBlock("span", {
|
|
1956
|
+
key: person.name,
|
|
1957
|
+
class: "rk-stack-item",
|
|
1958
|
+
"aria-hidden": "true"
|
|
1959
|
+
}, [createVNode(BaseAvatar_default, {
|
|
1960
|
+
name: person.name,
|
|
1961
|
+
src: person.src,
|
|
1962
|
+
size: __props.size,
|
|
1963
|
+
fallback: "initials"
|
|
1964
|
+
}, null, 8, [
|
|
1965
|
+
"name",
|
|
1966
|
+
"src",
|
|
1967
|
+
"size"
|
|
1968
|
+
])]);
|
|
1969
|
+
}), 128)), rest.value ? (openBlock(), createElementBlock("span", _hoisted_2$12, "+" + toDisplayString(rest.value), 1)) : createCommentVNode("", true)], 10, _hoisted_1$15);
|
|
1970
|
+
};
|
|
1971
|
+
}
|
|
1972
|
+
}), [["__scopeId", "data-v-db629481"]]);
|
|
1973
|
+
//#endregion
|
|
1974
|
+
//#region src/components/BaseCalendar.vue?vue&type=script&setup=true&lang.ts
|
|
1975
|
+
var _hoisted_1$14 = { class: "rk-cal" };
|
|
1976
|
+
var _hoisted_2$11 = { class: "rk-cal-head" };
|
|
1977
|
+
var _hoisted_3$8 = ["aria-label"];
|
|
1978
|
+
var _hoisted_4$5 = ["aria-expanded"];
|
|
1979
|
+
var _hoisted_5$3 = ["aria-label"];
|
|
1980
|
+
var _hoisted_6$3 = {
|
|
1981
|
+
key: 0,
|
|
1982
|
+
class: "rk-cal-weekdays",
|
|
1983
|
+
"aria-hidden": "true"
|
|
1984
|
+
};
|
|
1985
|
+
var _hoisted_7$2 = ["aria-label"];
|
|
1986
|
+
var _hoisted_8$1 = [
|
|
1987
|
+
"tabindex",
|
|
1988
|
+
"disabled",
|
|
1989
|
+
"aria-label",
|
|
1990
|
+
"aria-selected",
|
|
1991
|
+
"aria-current",
|
|
1992
|
+
"onClick",
|
|
1993
|
+
"onPointerenter"
|
|
1994
|
+
];
|
|
1995
|
+
var _hoisted_9$1 = {
|
|
1996
|
+
key: 2,
|
|
1997
|
+
class: "rk-cal-blocks"
|
|
1998
|
+
};
|
|
1999
|
+
var _hoisted_10$1 = ["aria-label", "onClick"];
|
|
2000
|
+
var _hoisted_11$1 = {
|
|
2001
|
+
key: 3,
|
|
2002
|
+
class: "rk-cal-blocks"
|
|
2003
|
+
};
|
|
2004
|
+
var _hoisted_12 = ["onClick"];
|
|
2005
|
+
//#endregion
|
|
2006
|
+
//#region src/components/BaseCalendar.vue
|
|
2007
|
+
var BaseCalendar_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2008
|
+
__name: "BaseCalendar",
|
|
2009
|
+
props: /*@__PURE__*/ mergeModels({
|
|
2010
|
+
mode: { default: "single" },
|
|
2011
|
+
min: { default: () => void 0 },
|
|
2012
|
+
max: { default: () => void 0 },
|
|
2013
|
+
isDisabled: {
|
|
2014
|
+
type: Function,
|
|
2015
|
+
default: void 0
|
|
2016
|
+
},
|
|
2017
|
+
weekStartsOn: { default: 1 },
|
|
2018
|
+
previousLabel: {},
|
|
2019
|
+
nextLabel: {},
|
|
2020
|
+
today: { default: () => todayKey() }
|
|
2021
|
+
}, {
|
|
2022
|
+
"modelValue": {},
|
|
2023
|
+
"modelModifiers": {}
|
|
2024
|
+
}),
|
|
2025
|
+
emits: ["update:modelValue"],
|
|
2026
|
+
setup(__props) {
|
|
2027
|
+
const model = useModel(__props, "modelValue");
|
|
2028
|
+
const single = computed(() => __props.mode === "single" ? model.value : void 0);
|
|
2029
|
+
const range = computed(() => __props.mode === "range" ? model.value : void 0);
|
|
2030
|
+
const focused = ref(single.value ?? range.value?.start ?? __props.today);
|
|
2031
|
+
const view = ref("days");
|
|
2032
|
+
const grid = useTemplateRef("grid");
|
|
2033
|
+
/** Set while a range is half chosen, to paint what hovering would take. */
|
|
2034
|
+
const pendingStart = ref(null);
|
|
2035
|
+
const hovered = ref(null);
|
|
2036
|
+
const focusedDate = computed(() => fromDateKey(focused.value));
|
|
2037
|
+
const year = computed(() => focusedDate.value.getFullYear());
|
|
2038
|
+
const month = computed(() => focusedDate.value.getMonth());
|
|
2039
|
+
const monthTitle = computed(() => formatDate(focusedDate.value, {
|
|
2040
|
+
month: "long",
|
|
2041
|
+
year: "numeric"
|
|
2042
|
+
}));
|
|
2043
|
+
/** The weekday headings, in the app's locale, starting on the chosen day. */
|
|
2044
|
+
const weekdays = computed(() => {
|
|
2045
|
+
const sunday = new Date(2024, 0, 7);
|
|
2046
|
+
return Array.from({ length: 7 }, (_, i) => {
|
|
2047
|
+
const date = new Date(sunday);
|
|
2048
|
+
date.setDate(sunday.getDate() + (i + __props.weekStartsOn) % 7);
|
|
2049
|
+
return {
|
|
2050
|
+
short: formatDate(date, { weekday: "short" }),
|
|
2051
|
+
long: formatDate(date, { weekday: "long" })
|
|
2052
|
+
};
|
|
2053
|
+
});
|
|
2054
|
+
});
|
|
2055
|
+
/** Six weeks, always: a calendar that changes height as you page it jumps. */
|
|
2056
|
+
const weeks = computed(() => {
|
|
2057
|
+
const first = new Date(year.value, month.value, 1);
|
|
2058
|
+
const offset = (first.getDay() - __props.weekStartsOn + 7) % 7;
|
|
2059
|
+
let cursor = addDays(toDateKey(first), -offset);
|
|
2060
|
+
return Array.from({ length: 6 }, () => Array.from({ length: 7 }, () => {
|
|
2061
|
+
const key = cursor;
|
|
2062
|
+
cursor = addDays(cursor, 1);
|
|
2063
|
+
return key;
|
|
2064
|
+
}));
|
|
2065
|
+
});
|
|
2066
|
+
const months = computed(() => Array.from({ length: 12 }, (_, i) => ({
|
|
2067
|
+
index: i,
|
|
2068
|
+
label: formatDate(new Date(year.value, i, 1), { month: "short" }),
|
|
2069
|
+
long: formatDate(new Date(year.value, i, 1), { month: "long" })
|
|
2070
|
+
})));
|
|
2071
|
+
/** A block of twelve years, the one the focused year falls in. */
|
|
2072
|
+
const years = computed(() => {
|
|
2073
|
+
const start = Math.floor(year.value / 12) * 12;
|
|
2074
|
+
return Array.from({ length: 12 }, (_, i) => start + i);
|
|
2075
|
+
});
|
|
2076
|
+
const outside = (key) => fromDateKey(key).getMonth() !== month.value;
|
|
2077
|
+
function disabled(key) {
|
|
2078
|
+
if (__props.min !== void 0 && key < __props.min) return true;
|
|
2079
|
+
if (__props.max !== void 0 && key > __props.max) return true;
|
|
2080
|
+
return __props.isDisabled?.(key) ?? false;
|
|
2081
|
+
}
|
|
2082
|
+
const edges = computed(() => {
|
|
2083
|
+
if (__props.mode !== "range") return null;
|
|
2084
|
+
if (pendingStart.value) {
|
|
2085
|
+
const other = hovered.value ?? pendingStart.value;
|
|
2086
|
+
return pendingStart.value <= other ? {
|
|
2087
|
+
start: pendingStart.value,
|
|
2088
|
+
end: other
|
|
2089
|
+
} : {
|
|
2090
|
+
start: other,
|
|
2091
|
+
end: pendingStart.value
|
|
2092
|
+
};
|
|
2093
|
+
}
|
|
2094
|
+
return range.value ?? null;
|
|
2095
|
+
});
|
|
2096
|
+
function stateOf(key) {
|
|
2097
|
+
if (__props.mode === "single") return single.value === key ? "selected" : "";
|
|
2098
|
+
const span = edges.value;
|
|
2099
|
+
if (!span) return "";
|
|
2100
|
+
if (key === span.start || key === span.end) return "selected";
|
|
2101
|
+
return key > span.start && key < span.end ? "inside" : "";
|
|
2102
|
+
}
|
|
2103
|
+
function choose(key) {
|
|
2104
|
+
if (disabled(key)) return;
|
|
2105
|
+
focused.value = key;
|
|
2106
|
+
if (__props.mode === "single") {
|
|
2107
|
+
model.value = key;
|
|
2108
|
+
return;
|
|
2109
|
+
}
|
|
2110
|
+
if (!pendingStart.value) {
|
|
2111
|
+
pendingStart.value = key;
|
|
2112
|
+
return;
|
|
2113
|
+
}
|
|
2114
|
+
const start = pendingStart.value <= key ? pendingStart.value : key;
|
|
2115
|
+
const end = pendingStart.value <= key ? key : pendingStart.value;
|
|
2116
|
+
pendingStart.value = null;
|
|
2117
|
+
hovered.value = null;
|
|
2118
|
+
model.value = {
|
|
2119
|
+
start,
|
|
2120
|
+
end
|
|
2121
|
+
};
|
|
2122
|
+
}
|
|
2123
|
+
async function moveTo(key) {
|
|
2124
|
+
focused.value = key;
|
|
2125
|
+
await nextTick();
|
|
2126
|
+
grid.value?.querySelector("[tabindex=\"0\"]")?.focus();
|
|
2127
|
+
}
|
|
2128
|
+
function shiftMonths(count) {
|
|
2129
|
+
const date = new Date(year.value, month.value + count, 1);
|
|
2130
|
+
const last = new Date(date.getFullYear(), date.getMonth() + 1, 0).getDate();
|
|
2131
|
+
date.setDate(Math.min(focusedDate.value.getDate(), last));
|
|
2132
|
+
return toDateKey(date);
|
|
2133
|
+
}
|
|
2134
|
+
function onKeydown(event) {
|
|
2135
|
+
const next = {
|
|
2136
|
+
ArrowLeft: () => addDays(focused.value, -1),
|
|
2137
|
+
ArrowRight: () => addDays(focused.value, 1),
|
|
2138
|
+
ArrowUp: () => addDays(focused.value, -7),
|
|
2139
|
+
ArrowDown: () => addDays(focused.value, 7),
|
|
2140
|
+
Home: () => addDays(focused.value, -((fromDateKey(focused.value).getDay() - __props.weekStartsOn + 7) % 7)),
|
|
2141
|
+
End: () => addDays(focused.value, 6 - (fromDateKey(focused.value).getDay() - __props.weekStartsOn + 7) % 7),
|
|
2142
|
+
PageUp: () => shiftMonths(event.shiftKey ? -12 : -1),
|
|
2143
|
+
PageDown: () => shiftMonths(event.shiftKey ? 12 : 1)
|
|
2144
|
+
}[event.key];
|
|
2145
|
+
if (!next) return;
|
|
2146
|
+
event.preventDefault();
|
|
2147
|
+
moveTo(next());
|
|
2148
|
+
}
|
|
2149
|
+
/** The arrows move a month, a year, or twelve years — whatever is on screen. */
|
|
2150
|
+
function step(direction) {
|
|
2151
|
+
if (view.value === "days") return moveTo(shiftMonths(direction));
|
|
2152
|
+
const years = view.value === "months" ? 1 : 12;
|
|
2153
|
+
return moveTo(toDateKey(new Date(year.value + direction * years, month.value, 1)));
|
|
2154
|
+
}
|
|
2155
|
+
/** Down one view: years pick a year, months pick a month and land on days. */
|
|
2156
|
+
function chooseYear(value) {
|
|
2157
|
+
moveTo(toDateKey(new Date(value, month.value, 1)));
|
|
2158
|
+
view.value = "months";
|
|
2159
|
+
}
|
|
2160
|
+
function chooseMonth(index) {
|
|
2161
|
+
moveTo(toDateKey(new Date(year.value, index, 1)));
|
|
2162
|
+
view.value = "days";
|
|
2163
|
+
}
|
|
2164
|
+
function cycleView() {
|
|
2165
|
+
view.value = view.value === "days" ? "months" : view.value === "months" ? "years" : "days";
|
|
2166
|
+
}
|
|
2167
|
+
watch(() => [single.value, range.value?.start], ([day, start]) => {
|
|
2168
|
+
const next = day ?? start;
|
|
2169
|
+
if (next) focused.value = next;
|
|
2170
|
+
});
|
|
2171
|
+
return (_ctx, _cache) => {
|
|
2172
|
+
return openBlock(), createElementBlock("div", _hoisted_1$14, [
|
|
2173
|
+
createElementVNode("div", _hoisted_2$11, [
|
|
2174
|
+
createElementVNode("button", {
|
|
2175
|
+
type: "button",
|
|
2176
|
+
class: "rk-cal-arrow focus-ring",
|
|
2177
|
+
"aria-label": __props.previousLabel,
|
|
2178
|
+
onClick: _cache[0] || (_cache[0] = ($event) => step(-1))
|
|
2179
|
+
}, [createVNode(unref(ChevronLeft), {
|
|
2180
|
+
class: "size-4",
|
|
2181
|
+
"aria-hidden": "true"
|
|
2182
|
+
})], 8, _hoisted_3$8),
|
|
2183
|
+
createElementVNode("button", {
|
|
2184
|
+
type: "button",
|
|
2185
|
+
class: "rk-cal-title focus-ring",
|
|
2186
|
+
"aria-expanded": view.value !== "days",
|
|
2187
|
+
onClick: cycleView
|
|
2188
|
+
}, toDisplayString(view.value === "years" ? `${years.value[0]} – ${years.value[11]}` : monthTitle.value), 9, _hoisted_4$5),
|
|
2189
|
+
createElementVNode("button", {
|
|
2190
|
+
type: "button",
|
|
2191
|
+
class: "rk-cal-arrow focus-ring",
|
|
2192
|
+
"aria-label": __props.nextLabel,
|
|
2193
|
+
onClick: _cache[1] || (_cache[1] = ($event) => step(1))
|
|
2194
|
+
}, [createVNode(unref(ChevronRight), {
|
|
2195
|
+
class: "size-4",
|
|
2196
|
+
"aria-hidden": "true"
|
|
2197
|
+
})], 8, _hoisted_5$3)
|
|
2198
|
+
]),
|
|
2199
|
+
view.value === "days" ? (openBlock(), createElementBlock("div", _hoisted_6$3, [(openBlock(true), createElementBlock(Fragment, null, renderList(weekdays.value, (day) => {
|
|
2200
|
+
return openBlock(), createElementBlock("span", { key: day.long }, toDisplayString(day.short), 1);
|
|
2201
|
+
}), 128))])) : createCommentVNode("", true),
|
|
2202
|
+
view.value === "days" ? (openBlock(), createElementBlock("div", {
|
|
2203
|
+
key: 1,
|
|
2204
|
+
ref_key: "grid",
|
|
2205
|
+
ref: grid,
|
|
2206
|
+
class: "rk-cal-grid",
|
|
2207
|
+
role: "grid",
|
|
2208
|
+
"aria-label": monthTitle.value,
|
|
2209
|
+
onKeydown,
|
|
2210
|
+
onPointerleave: _cache[2] || (_cache[2] = ($event) => hovered.value = null)
|
|
2211
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(weeks.value, (week, index) => {
|
|
2212
|
+
return openBlock(), createElementBlock("div", {
|
|
2213
|
+
key: index,
|
|
2214
|
+
class: "rk-cal-week",
|
|
2215
|
+
role: "row"
|
|
2216
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(week, (key) => {
|
|
2217
|
+
return openBlock(), createElementBlock("div", {
|
|
2218
|
+
key,
|
|
2219
|
+
role: "gridcell",
|
|
2220
|
+
class: "rk-cal-cell"
|
|
2221
|
+
}, [createElementVNode("button", {
|
|
2222
|
+
type: "button",
|
|
2223
|
+
class: normalizeClass(["rk-cal-day", [stateOf(key) && `is-${stateOf(key)}`, { "is-outside": outside(key) }]]),
|
|
2224
|
+
tabindex: key === focused.value ? 0 : -1,
|
|
2225
|
+
disabled: disabled(key),
|
|
2226
|
+
"aria-label": unref(formatDate)(unref(fromDateKey)(key), { dateStyle: "full" }),
|
|
2227
|
+
"aria-selected": stateOf(key) === "selected",
|
|
2228
|
+
"aria-current": key === __props.today ? "date" : void 0,
|
|
2229
|
+
onClick: ($event) => choose(key),
|
|
2230
|
+
onPointerenter: ($event) => hovered.value = key
|
|
2231
|
+
}, toDisplayString(unref(fromDateKey)(key).getDate()), 43, _hoisted_8$1)]);
|
|
2232
|
+
}), 128))]);
|
|
2233
|
+
}), 128))], 40, _hoisted_7$2)) : view.value === "months" ? (openBlock(), createElementBlock("div", _hoisted_9$1, [(openBlock(true), createElementBlock(Fragment, null, renderList(months.value, (entry) => {
|
|
2234
|
+
return openBlock(), createElementBlock("button", {
|
|
2235
|
+
key: entry.index,
|
|
2236
|
+
type: "button",
|
|
2237
|
+
class: "rk-cal-block focus-ring",
|
|
2238
|
+
"aria-label": entry.long,
|
|
2239
|
+
onClick: ($event) => chooseMonth(entry.index)
|
|
2240
|
+
}, toDisplayString(entry.label), 9, _hoisted_10$1);
|
|
2241
|
+
}), 128))])) : (openBlock(), createElementBlock("div", _hoisted_11$1, [(openBlock(true), createElementBlock(Fragment, null, renderList(years.value, (value) => {
|
|
2242
|
+
return openBlock(), createElementBlock("button", {
|
|
2243
|
+
key: value,
|
|
2244
|
+
type: "button",
|
|
2245
|
+
class: "rk-cal-block focus-ring",
|
|
2246
|
+
onClick: ($event) => chooseYear(value)
|
|
2247
|
+
}, toDisplayString(value), 9, _hoisted_12);
|
|
2248
|
+
}), 128))]))
|
|
2249
|
+
]);
|
|
2250
|
+
};
|
|
2251
|
+
}
|
|
2252
|
+
}), [["__scopeId", "data-v-6d0b0811"]]);
|
|
2253
|
+
//#endregion
|
|
2254
|
+
//#region src/components/BaseChip.vue?vue&type=script&setup=true&lang.ts
|
|
2255
|
+
var _hoisted_1$13 = { class: "truncate" };
|
|
2256
|
+
var _hoisted_2$10 = ["aria-label", "disabled"];
|
|
2257
|
+
//#endregion
|
|
2258
|
+
//#region src/components/BaseChip.vue
|
|
2259
|
+
var BaseChip_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2260
|
+
__name: "BaseChip",
|
|
2261
|
+
props: {
|
|
2262
|
+
label: {},
|
|
2263
|
+
icon: { default: () => void 0 },
|
|
2264
|
+
tone: { default: "neutral" },
|
|
2265
|
+
removeLabel: { default: () => void 0 },
|
|
2266
|
+
selected: {
|
|
2267
|
+
type: Boolean,
|
|
2268
|
+
default: () => void 0
|
|
2269
|
+
},
|
|
2270
|
+
disabled: {
|
|
2271
|
+
type: Boolean,
|
|
2272
|
+
default: false
|
|
2273
|
+
}
|
|
2274
|
+
},
|
|
2275
|
+
emits: ["remove", "select"],
|
|
2276
|
+
setup(__props, { emit: __emit }) {
|
|
2277
|
+
const emit = __emit;
|
|
2278
|
+
return (_ctx, _cache) => {
|
|
2279
|
+
return openBlock(), createBlock(resolveDynamicComponent(__props.selected === void 0 ? "span" : "button"), {
|
|
2280
|
+
type: __props.selected === void 0 ? void 0 : "button",
|
|
2281
|
+
class: normalizeClass(["rk-chip", [`tone-${__props.tone}`, {
|
|
2282
|
+
"is-selected": __props.selected,
|
|
2283
|
+
"is-button": __props.selected !== void 0
|
|
2284
|
+
}]]),
|
|
2285
|
+
"aria-pressed": __props.selected,
|
|
2286
|
+
disabled: __props.selected === void 0 ? void 0 : __props.disabled,
|
|
2287
|
+
onClick: _cache[1] || (_cache[1] = ($event) => __props.selected === void 0 ? void 0 : emit("select"))
|
|
2288
|
+
}, {
|
|
2289
|
+
default: withCtx(() => [
|
|
2290
|
+
__props.icon ? (openBlock(), createBlock(resolveDynamicComponent(__props.icon), {
|
|
2291
|
+
key: 0,
|
|
2292
|
+
class: "size-3.5 shrink-0",
|
|
2293
|
+
"aria-hidden": "true"
|
|
2294
|
+
})) : createCommentVNode("", true),
|
|
2295
|
+
createElementVNode("span", _hoisted_1$13, toDisplayString(__props.label), 1),
|
|
2296
|
+
__props.removeLabel ? (openBlock(), createElementBlock("button", {
|
|
2297
|
+
key: 1,
|
|
2298
|
+
type: "button",
|
|
2299
|
+
class: "rk-chip-remove focus-ring",
|
|
2300
|
+
"aria-label": __props.removeLabel,
|
|
2301
|
+
disabled: __props.disabled,
|
|
2302
|
+
onClick: _cache[0] || (_cache[0] = withModifiers(($event) => emit("remove"), ["stop"]))
|
|
2303
|
+
}, [createVNode(unref(X), {
|
|
2304
|
+
class: "size-3",
|
|
2305
|
+
"aria-hidden": "true"
|
|
2306
|
+
})], 8, _hoisted_2$10)) : createCommentVNode("", true)
|
|
2307
|
+
]),
|
|
2308
|
+
_: 1
|
|
2309
|
+
}, 8, [
|
|
2310
|
+
"type",
|
|
2311
|
+
"class",
|
|
2312
|
+
"aria-pressed",
|
|
2313
|
+
"disabled"
|
|
2314
|
+
]);
|
|
2315
|
+
};
|
|
2316
|
+
}
|
|
2317
|
+
}), [["__scopeId", "data-v-e9026659"]]);
|
|
2318
|
+
//#endregion
|
|
2319
|
+
//#region src/components/BaseKbd.vue?vue&type=script&setup=true&lang.ts
|
|
2320
|
+
var _hoisted_1$12 = {
|
|
2321
|
+
key: 0,
|
|
2322
|
+
class: "rk-kbd-joiner",
|
|
2323
|
+
"aria-hidden": "true"
|
|
2324
|
+
};
|
|
2325
|
+
var _hoisted_2$9 = { class: "rk-kbd-key control" };
|
|
2326
|
+
//#endregion
|
|
2327
|
+
//#region src/components/BaseKbd.vue
|
|
2328
|
+
var BaseKbd_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2329
|
+
__name: "BaseKbd",
|
|
2330
|
+
props: {
|
|
2331
|
+
keys: {},
|
|
2332
|
+
joiner: { default: "" },
|
|
2333
|
+
size: { default: "md" }
|
|
2334
|
+
},
|
|
2335
|
+
setup(__props) {
|
|
2336
|
+
const list = computed(() => typeof __props.keys === "string" ? [__props.keys] : __props.keys);
|
|
2337
|
+
return (_ctx, _cache) => {
|
|
2338
|
+
return openBlock(), createElementBlock("span", { class: normalizeClass(["rk-kbd", `is-${__props.size}`]) }, [(openBlock(true), createElementBlock(Fragment, null, renderList(list.value, (key, index) => {
|
|
2339
|
+
return openBlock(), createElementBlock(Fragment, { key }, [index > 0 && __props.joiner ? (openBlock(), createElementBlock("span", _hoisted_1$12, toDisplayString(__props.joiner), 1)) : createCommentVNode("", true), createElementVNode("kbd", _hoisted_2$9, toDisplayString(key), 1)], 64);
|
|
2340
|
+
}), 128))], 2);
|
|
2341
|
+
};
|
|
2342
|
+
}
|
|
2343
|
+
}), [["__scopeId", "data-v-e4b97bbe"]]);
|
|
2344
|
+
//#endregion
|
|
2345
|
+
//#region src/components/BaseLink.vue
|
|
2346
|
+
var BaseLink_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2347
|
+
__name: "BaseLink",
|
|
2348
|
+
props: {
|
|
2349
|
+
to: { default: () => void 0 },
|
|
2350
|
+
href: { default: () => void 0 },
|
|
2351
|
+
external: {
|
|
2352
|
+
type: Boolean,
|
|
2353
|
+
default: () => void 0
|
|
2354
|
+
},
|
|
2355
|
+
tone: { default: "primary" },
|
|
2356
|
+
underline: { default: "hover" }
|
|
2357
|
+
},
|
|
2358
|
+
setup(__props) {
|
|
2359
|
+
const is = computed(() => __props.to !== void 0 ? RouterLink : "a");
|
|
2360
|
+
return (_ctx, _cache) => {
|
|
2361
|
+
return openBlock(), createBlock(resolveDynamicComponent(is.value), mergeProps({ class: ["rk-link focus-ring", [`tone-${__props.tone}`, `underline-${__props.underline}`]] }, __props.to !== void 0 ? { to: __props.to } : {
|
|
2362
|
+
href: __props.href,
|
|
2363
|
+
target: __props.external ? "_blank" : void 0,
|
|
2364
|
+
rel: __props.external ? "noopener noreferrer" : void 0
|
|
2365
|
+
}), {
|
|
2366
|
+
default: withCtx(() => [renderSlot(_ctx.$slots, "default", {}, void 0, true), __props.external ? (openBlock(), createBlock(unref(ArrowUpRight), {
|
|
2367
|
+
key: 0,
|
|
2368
|
+
class: "rk-link-mark",
|
|
2369
|
+
"aria-hidden": "true"
|
|
2370
|
+
})) : createCommentVNode("", true)]),
|
|
2371
|
+
_: 3
|
|
2372
|
+
}, 16, ["class"]);
|
|
2373
|
+
};
|
|
2374
|
+
}
|
|
2375
|
+
}), [["__scopeId", "data-v-88581007"]]);
|
|
2376
|
+
//#endregion
|
|
2377
|
+
//#region src/components/BaseRating.vue?vue&type=script&setup=true&lang.ts
|
|
2378
|
+
var _hoisted_1$11 = [
|
|
2379
|
+
"role",
|
|
2380
|
+
"aria-label",
|
|
2381
|
+
"tabindex",
|
|
2382
|
+
"aria-valuenow",
|
|
2383
|
+
"aria-valuemin",
|
|
2384
|
+
"aria-valuemax",
|
|
2385
|
+
"aria-valuetext"
|
|
2386
|
+
];
|
|
2387
|
+
//#endregion
|
|
2388
|
+
//#region src/components/BaseRating.vue
|
|
2389
|
+
var BaseRating_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2390
|
+
__name: "BaseRating",
|
|
2391
|
+
props: /*@__PURE__*/ mergeModels({
|
|
2392
|
+
max: { default: 5 },
|
|
2393
|
+
label: {},
|
|
2394
|
+
valueLabel: { type: Function },
|
|
2395
|
+
readonly: {
|
|
2396
|
+
type: Boolean,
|
|
2397
|
+
default: false
|
|
2398
|
+
},
|
|
2399
|
+
size: { default: "md" },
|
|
2400
|
+
allowClear: {
|
|
2401
|
+
type: Boolean,
|
|
2402
|
+
default: true
|
|
2403
|
+
}
|
|
2404
|
+
}, {
|
|
2405
|
+
"modelValue": { default: 0 },
|
|
2406
|
+
"modelModifiers": {}
|
|
2407
|
+
}),
|
|
2408
|
+
emits: ["update:modelValue"],
|
|
2409
|
+
setup(__props) {
|
|
2410
|
+
/** The score, with `v-model`. `0` is none given. */
|
|
2411
|
+
const model = useModel(__props, "modelValue");
|
|
2412
|
+
const hovered = ref(0);
|
|
2413
|
+
const shown = computed(() => hovered.value || model.value);
|
|
2414
|
+
const stars = computed(() => Array.from({ length: __props.max }, (_, i) => i + 1));
|
|
2415
|
+
function pick(value) {
|
|
2416
|
+
if (__props.readonly) return;
|
|
2417
|
+
model.value = __props.allowClear && model.value === value ? 0 : value;
|
|
2418
|
+
}
|
|
2419
|
+
function onKeydown(event) {
|
|
2420
|
+
const next = {
|
|
2421
|
+
ArrowRight: model.value + 1,
|
|
2422
|
+
ArrowUp: model.value + 1,
|
|
2423
|
+
ArrowLeft: model.value - 1,
|
|
2424
|
+
ArrowDown: model.value - 1,
|
|
2425
|
+
Home: 0,
|
|
2426
|
+
End: __props.max
|
|
2427
|
+
}[event.key];
|
|
2428
|
+
if (next === void 0) return;
|
|
2429
|
+
event.preventDefault();
|
|
2430
|
+
model.value = Math.min(__props.max, Math.max(0, next));
|
|
2431
|
+
}
|
|
2432
|
+
return (_ctx, _cache) => {
|
|
2433
|
+
return openBlock(), createElementBlock("div", {
|
|
2434
|
+
class: normalizeClass(["rk-rating", [`is-${__props.size}`, { "is-readonly": __props.readonly }]]),
|
|
2435
|
+
role: __props.readonly ? "img" : "slider",
|
|
2436
|
+
"aria-label": `${__props.label}: ${__props.valueLabel(model.value, __props.max)}`,
|
|
2437
|
+
tabindex: __props.readonly ? void 0 : 0,
|
|
2438
|
+
"aria-valuenow": __props.readonly ? void 0 : model.value,
|
|
2439
|
+
"aria-valuemin": __props.readonly ? void 0 : 0,
|
|
2440
|
+
"aria-valuemax": __props.readonly ? void 0 : __props.max,
|
|
2441
|
+
"aria-valuetext": __props.readonly ? void 0 : __props.valueLabel(model.value, __props.max),
|
|
2442
|
+
onKeydown: _cache[0] || (_cache[0] = ($event) => __props.readonly ? void 0 : onKeydown($event)),
|
|
2443
|
+
onPointerleave: _cache[1] || (_cache[1] = ($event) => hovered.value = 0)
|
|
2444
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(stars.value, (star) => {
|
|
2445
|
+
return openBlock(), createBlock(resolveDynamicComponent(__props.readonly ? "span" : "button"), {
|
|
2446
|
+
key: star,
|
|
2447
|
+
type: __props.readonly ? void 0 : "button",
|
|
2448
|
+
class: normalizeClass(["rk-rating-star", { "is-on": star <= shown.value }]),
|
|
2449
|
+
tabindex: __props.readonly ? void 0 : -1,
|
|
2450
|
+
"aria-hidden": true,
|
|
2451
|
+
onClick: ($event) => pick(star),
|
|
2452
|
+
onPointerenter: ($event) => __props.readonly ? void 0 : hovered.value = star
|
|
2453
|
+
}, {
|
|
2454
|
+
default: withCtx(() => [createVNode(unref(Star), { class: "rk-rating-icon" })]),
|
|
2455
|
+
_: 1
|
|
2456
|
+
}, 40, [
|
|
2457
|
+
"type",
|
|
2458
|
+
"class",
|
|
2459
|
+
"tabindex",
|
|
2460
|
+
"onClick",
|
|
2461
|
+
"onPointerenter"
|
|
2462
|
+
]);
|
|
2463
|
+
}), 128))], 42, _hoisted_1$11);
|
|
2464
|
+
};
|
|
2465
|
+
}
|
|
2466
|
+
}), [["__scopeId", "data-v-38007368"]]);
|
|
2467
|
+
//#endregion
|
|
2468
|
+
//#region src/components/BaseSeparator.vue?vue&type=script&setup=true&lang.ts
|
|
2469
|
+
var _hoisted_1$10 = { class: "rk-sep-label" };
|
|
2470
|
+
var _hoisted_2$8 = ["aria-orientation"];
|
|
2471
|
+
//#endregion
|
|
2472
|
+
//#region src/components/BaseSeparator.vue
|
|
2473
|
+
var BaseSeparator_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2474
|
+
__name: "BaseSeparator",
|
|
2475
|
+
props: {
|
|
2476
|
+
orientation: { default: "horizontal" },
|
|
2477
|
+
label: { default: "" },
|
|
2478
|
+
spacing: { default: "md" }
|
|
2479
|
+
},
|
|
2480
|
+
setup(__props) {
|
|
2481
|
+
/**
|
|
2482
|
+
* A line between things — with, when it helps, a word on it.
|
|
2483
|
+
*
|
|
2484
|
+
* `role="separator"` when it only divides, and nothing at all to assistive
|
|
2485
|
+
* tech when it carries a label, because then the text is the point and the
|
|
2486
|
+
* line is decoration around it.
|
|
2487
|
+
*
|
|
2488
|
+
* Vertical needs a height from its parent: inside a flex row, that is
|
|
2489
|
+
* `align-items: stretch`, which is the default.
|
|
2490
|
+
*/
|
|
2491
|
+
return (_ctx, _cache) => {
|
|
2492
|
+
return __props.label ? (openBlock(), createElementBlock("div", {
|
|
2493
|
+
key: 0,
|
|
2494
|
+
class: normalizeClass(["rk-sep-labelled", [`is-${__props.orientation}`, `space-${__props.spacing}`]]),
|
|
2495
|
+
"aria-hidden": "true"
|
|
2496
|
+
}, [
|
|
2497
|
+
_cache[0] || (_cache[0] = createElementVNode("span", { class: "rk-sep-line" }, null, -1)),
|
|
2498
|
+
createElementVNode("span", _hoisted_1$10, toDisplayString(__props.label), 1),
|
|
2499
|
+
_cache[1] || (_cache[1] = createElementVNode("span", { class: "rk-sep-line" }, null, -1))
|
|
2500
|
+
], 2)) : (openBlock(), createElementBlock("div", {
|
|
2501
|
+
key: 1,
|
|
2502
|
+
class: normalizeClass(["rk-sep", [`is-${__props.orientation}`, `space-${__props.spacing}`]]),
|
|
2503
|
+
role: "separator",
|
|
2504
|
+
"aria-orientation": __props.orientation
|
|
2505
|
+
}, null, 10, _hoisted_2$8));
|
|
2506
|
+
};
|
|
2507
|
+
}
|
|
2508
|
+
}), [["__scopeId", "data-v-9f8cc9aa"]]);
|
|
2509
|
+
//#endregion
|
|
2510
|
+
//#region src/components/BaseSkeleton.vue
|
|
2511
|
+
var BaseSkeleton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2512
|
+
__name: "BaseSkeleton",
|
|
2513
|
+
props: {
|
|
2514
|
+
width: { default: "100%" },
|
|
2515
|
+
height: { default: "1rem" },
|
|
2516
|
+
shape: { default: "block" }
|
|
2517
|
+
},
|
|
2518
|
+
setup(__props) {
|
|
2519
|
+
/**
|
|
2520
|
+
* One grey box standing in for content that has not arrived.
|
|
2521
|
+
*
|
|
2522
|
+
* `SkeletonList` is rows of these for a list; this is the primitive, for the
|
|
2523
|
+
* shapes a list does not cover — an avatar, a heading, a chart.
|
|
2524
|
+
*
|
|
2525
|
+
* A height is a CSS length, never a class: `h-4` inside a component the app
|
|
2526
|
+
* does not control would render at zero the day that utility is not in the
|
|
2527
|
+
* app's stylesheet, which is exactly how every skeleton in one app came out
|
|
2528
|
+
* invisible.
|
|
2529
|
+
*
|
|
2530
|
+
* It is hidden from assistive tech. The thing that is loading says so —
|
|
2531
|
+
* through `aria-busy`, or a status message — and a screen reader reading
|
|
2532
|
+
* "blank, blank, blank" helps nobody.
|
|
2533
|
+
*/
|
|
2534
|
+
return (_ctx, _cache) => {
|
|
2535
|
+
return openBlock(), createElementBlock("span", {
|
|
2536
|
+
class: normalizeClass(["rk-skeleton", `is-${__props.shape}`]),
|
|
2537
|
+
style: normalizeStyle({
|
|
2538
|
+
width: __props.shape === "circle" ? __props.height : __props.width,
|
|
2539
|
+
height: __props.height
|
|
2540
|
+
}),
|
|
2541
|
+
"aria-hidden": "true"
|
|
2542
|
+
}, null, 6);
|
|
2543
|
+
};
|
|
2544
|
+
}
|
|
2545
|
+
}), [["__scopeId", "data-v-37327de6"]]);
|
|
2546
|
+
//#endregion
|
|
2547
|
+
//#region src/components/CopyButton.vue?vue&type=script&setup=true&lang.ts
|
|
2548
|
+
var _hoisted_1$9 = ["aria-label"];
|
|
2549
|
+
var _hoisted_2$7 = { key: 2 };
|
|
2550
|
+
var _hoisted_3$7 = {
|
|
2551
|
+
class: "sr-only",
|
|
2552
|
+
role: "status",
|
|
2553
|
+
"aria-live": "polite"
|
|
2554
|
+
};
|
|
2555
|
+
//#endregion
|
|
2556
|
+
//#region src/components/CopyButton.vue
|
|
2557
|
+
var CopyButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2558
|
+
__name: "CopyButton",
|
|
2559
|
+
props: {
|
|
2560
|
+
text: {},
|
|
2561
|
+
copyLabel: {},
|
|
2562
|
+
copiedLabel: {},
|
|
2563
|
+
errorLabel: { default: () => void 0 },
|
|
2564
|
+
withText: {
|
|
2565
|
+
type: Boolean,
|
|
2566
|
+
default: false
|
|
2567
|
+
}
|
|
2568
|
+
},
|
|
2569
|
+
emits: ["copied", "failed"],
|
|
2570
|
+
setup(__props, { emit: __emit }) {
|
|
2571
|
+
const emit = __emit;
|
|
2572
|
+
const state = ref("idle");
|
|
2573
|
+
let timer = null;
|
|
2574
|
+
async function copy() {
|
|
2575
|
+
if (timer) clearTimeout(timer);
|
|
2576
|
+
try {
|
|
2577
|
+
await navigator.clipboard.writeText(__props.text);
|
|
2578
|
+
state.value = "copied";
|
|
2579
|
+
emit("copied");
|
|
2580
|
+
} catch {
|
|
2581
|
+
state.value = "failed";
|
|
2582
|
+
emit("failed");
|
|
2583
|
+
}
|
|
2584
|
+
timer = setTimeout(() => state.value = "idle", 2e3);
|
|
2585
|
+
}
|
|
2586
|
+
onBeforeUnmount(() => {
|
|
2587
|
+
if (timer) clearTimeout(timer);
|
|
2588
|
+
});
|
|
2589
|
+
return (_ctx, _cache) => {
|
|
2590
|
+
return openBlock(), createElementBlock("button", {
|
|
2591
|
+
type: "button",
|
|
2592
|
+
class: normalizeClass(["rk-copy control focus-ring", {
|
|
2593
|
+
"is-copied": state.value === "copied",
|
|
2594
|
+
"with-text": __props.withText
|
|
2595
|
+
}]),
|
|
2596
|
+
"aria-label": __props.withText ? void 0 : state.value === "copied" ? __props.copiedLabel : __props.copyLabel,
|
|
2597
|
+
onClick: copy
|
|
2598
|
+
}, [
|
|
2599
|
+
state.value === "copied" ? (openBlock(), createBlock(unref(Check), {
|
|
2600
|
+
key: 0,
|
|
2601
|
+
class: "size-4 shrink-0",
|
|
2602
|
+
"aria-hidden": "true"
|
|
2603
|
+
})) : (openBlock(), createBlock(unref(Copy), {
|
|
2604
|
+
key: 1,
|
|
2605
|
+
class: "size-4 shrink-0",
|
|
2606
|
+
"aria-hidden": "true"
|
|
2607
|
+
})),
|
|
2608
|
+
__props.withText ? (openBlock(), createElementBlock("span", _hoisted_2$7, toDisplayString(state.value === "copied" ? __props.copiedLabel : __props.copyLabel), 1)) : createCommentVNode("", true),
|
|
2609
|
+
createElementVNode("span", _hoisted_3$7, toDisplayString(state.value === "copied" ? __props.copiedLabel : state.value === "failed" ? __props.errorLabel ?? "" : ""), 1)
|
|
2610
|
+
], 10, _hoisted_1$9);
|
|
2611
|
+
};
|
|
2612
|
+
}
|
|
2613
|
+
}), [["__scopeId", "data-v-c481e140"]]);
|
|
2614
|
+
//#endregion
|
|
2615
|
+
//#region src/components/FileDrop.vue?vue&type=script&setup=true&lang.ts
|
|
2616
|
+
var _hoisted_1$8 = { class: "rk-drop" };
|
|
2617
|
+
var _hoisted_2$6 = ["for"];
|
|
2618
|
+
var _hoisted_3$6 = [
|
|
2619
|
+
"id",
|
|
2620
|
+
"accept",
|
|
2621
|
+
"multiple",
|
|
2622
|
+
"disabled"
|
|
2623
|
+
];
|
|
2624
|
+
var _hoisted_4$4 = { class: "rk-drop-label" };
|
|
2625
|
+
var _hoisted_5$2 = {
|
|
2626
|
+
key: 0,
|
|
2627
|
+
class: "rk-drop-hint"
|
|
2628
|
+
};
|
|
2629
|
+
var _hoisted_6$2 = { class: "rk-drop-browse" };
|
|
2630
|
+
var _hoisted_7$1 = {
|
|
2631
|
+
key: 0,
|
|
2632
|
+
class: "rk-drop-error",
|
|
2633
|
+
role: "alert"
|
|
2634
|
+
};
|
|
2635
|
+
var _hoisted_8 = {
|
|
2636
|
+
key: 1,
|
|
2637
|
+
class: "rk-drop-files"
|
|
2638
|
+
};
|
|
2639
|
+
var _hoisted_9 = { class: "truncate" };
|
|
2640
|
+
var _hoisted_10 = { class: "rk-drop-size" };
|
|
2641
|
+
var _hoisted_11 = [
|
|
2642
|
+
"aria-label",
|
|
2643
|
+
"disabled",
|
|
2644
|
+
"onClick"
|
|
2645
|
+
];
|
|
2646
|
+
//#endregion
|
|
2647
|
+
//#region src/components/FileDrop.vue
|
|
2648
|
+
var FileDrop_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2649
|
+
__name: "FileDrop",
|
|
2650
|
+
props: /*@__PURE__*/ mergeModels({
|
|
2651
|
+
label: {},
|
|
2652
|
+
hint: { default: "" },
|
|
2653
|
+
browseLabel: {},
|
|
2654
|
+
removeLabel: {},
|
|
2655
|
+
accept: { default: () => void 0 },
|
|
2656
|
+
multiple: {
|
|
2657
|
+
type: Boolean,
|
|
2658
|
+
default: false
|
|
2659
|
+
},
|
|
2660
|
+
maxSize: { default: () => void 0 },
|
|
2661
|
+
tooLargeLabel: { default: () => void 0 },
|
|
2662
|
+
disabled: {
|
|
2663
|
+
type: Boolean,
|
|
2664
|
+
default: false
|
|
2665
|
+
}
|
|
2666
|
+
}, {
|
|
2667
|
+
"modelValue": { default: () => [] },
|
|
2668
|
+
"modelModifiers": {}
|
|
2669
|
+
}),
|
|
2670
|
+
emits: /*@__PURE__*/ mergeModels(["rejected"], ["update:modelValue"]),
|
|
2671
|
+
setup(__props, { emit: __emit }) {
|
|
2672
|
+
const emit = __emit;
|
|
2673
|
+
/** The files held, with `v-model`. */
|
|
2674
|
+
const model = useModel(__props, "modelValue");
|
|
2675
|
+
const id = useId();
|
|
2676
|
+
const over = ref(false);
|
|
2677
|
+
const refused = ref(false);
|
|
2678
|
+
const tooBig = (file) => __props.maxSize !== void 0 && file.size > __props.maxSize;
|
|
2679
|
+
function take(list) {
|
|
2680
|
+
if (!list || __props.disabled) return;
|
|
2681
|
+
const incoming = Array.from(list);
|
|
2682
|
+
const rejected = incoming.filter(tooBig);
|
|
2683
|
+
const accepted = incoming.filter((file) => !tooBig(file));
|
|
2684
|
+
refused.value = rejected.length > 0;
|
|
2685
|
+
if (rejected.length) emit("rejected", rejected);
|
|
2686
|
+
model.value = __props.multiple ? [...model.value, ...accepted] : accepted.slice(0, 1);
|
|
2687
|
+
}
|
|
2688
|
+
function onDrop(event) {
|
|
2689
|
+
over.value = false;
|
|
2690
|
+
take(event.dataTransfer?.files ?? null);
|
|
2691
|
+
}
|
|
2692
|
+
function onInput(event) {
|
|
2693
|
+
const input = event.target;
|
|
2694
|
+
take(input.files);
|
|
2695
|
+
input.value = "";
|
|
2696
|
+
}
|
|
2697
|
+
function remove(index) {
|
|
2698
|
+
model.value = model.value.filter((_, at) => at !== index);
|
|
2699
|
+
}
|
|
2700
|
+
/** KB and MB by hand: `Intl` has no file sizes, and the unit is not a word. */
|
|
2701
|
+
const size = (bytes) => bytes >= 1048576 ? `${(bytes / 1048576).toFixed(1)} MB` : `${Math.max(1, Math.round(bytes / 1024))} KB`;
|
|
2702
|
+
const count = computed(() => model.value.length);
|
|
2703
|
+
return (_ctx, _cache) => {
|
|
2704
|
+
return openBlock(), createElementBlock("div", _hoisted_1$8, [
|
|
2705
|
+
createElementVNode("label", {
|
|
2706
|
+
class: normalizeClass(["rk-drop-box control", {
|
|
2707
|
+
"is-over": over.value,
|
|
2708
|
+
"is-disabled": __props.disabled
|
|
2709
|
+
}]),
|
|
2710
|
+
for: unref(id),
|
|
2711
|
+
onDragover: _cache[0] || (_cache[0] = withModifiers(($event) => over.value = !__props.disabled, ["prevent"])),
|
|
2712
|
+
onDragleave: _cache[1] || (_cache[1] = ($event) => over.value = false),
|
|
2713
|
+
onDrop: withModifiers(onDrop, ["prevent"])
|
|
2714
|
+
}, [
|
|
2715
|
+
createElementVNode("input", {
|
|
2716
|
+
id: unref(id),
|
|
2717
|
+
type: "file",
|
|
2718
|
+
class: "sr-only",
|
|
2719
|
+
accept: __props.accept,
|
|
2720
|
+
multiple: __props.multiple,
|
|
2721
|
+
disabled: __props.disabled,
|
|
2722
|
+
onChange: onInput
|
|
2723
|
+
}, null, 40, _hoisted_3$6),
|
|
2724
|
+
createVNode(unref(Upload), {
|
|
2725
|
+
class: "text-ink-soft size-6",
|
|
2726
|
+
"aria-hidden": "true"
|
|
2727
|
+
}),
|
|
2728
|
+
createElementVNode("span", _hoisted_4$4, toDisplayString(__props.label), 1),
|
|
2729
|
+
__props.hint ? (openBlock(), createElementBlock("span", _hoisted_5$2, toDisplayString(__props.hint), 1)) : createCommentVNode("", true),
|
|
2730
|
+
createElementVNode("span", _hoisted_6$2, toDisplayString(__props.browseLabel), 1)
|
|
2731
|
+
], 42, _hoisted_2$6),
|
|
2732
|
+
refused.value && __props.tooLargeLabel ? (openBlock(), createElementBlock("p", _hoisted_7$1, toDisplayString(__props.tooLargeLabel), 1)) : createCommentVNode("", true),
|
|
2733
|
+
count.value ? (openBlock(), createElementBlock("ul", _hoisted_8, [(openBlock(true), createElementBlock(Fragment, null, renderList(model.value, (file, index) => {
|
|
2734
|
+
return openBlock(), createElementBlock("li", {
|
|
2735
|
+
key: `${file.name}-${index}`,
|
|
2736
|
+
class: "rk-drop-file control"
|
|
2737
|
+
}, [
|
|
2738
|
+
createVNode(unref(Paperclip), {
|
|
2739
|
+
class: "text-ink-soft size-4 shrink-0",
|
|
2740
|
+
"aria-hidden": "true"
|
|
2741
|
+
}),
|
|
2742
|
+
createElementVNode("span", _hoisted_9, toDisplayString(file.name), 1),
|
|
2743
|
+
createElementVNode("span", _hoisted_10, toDisplayString(size(file.size)), 1),
|
|
2744
|
+
createElementVNode("button", {
|
|
2745
|
+
type: "button",
|
|
2746
|
+
class: "rk-drop-remove focus-ring",
|
|
2747
|
+
"aria-label": `${__props.removeLabel}: ${file.name}`,
|
|
2748
|
+
disabled: __props.disabled,
|
|
2749
|
+
onClick: ($event) => remove(index)
|
|
2750
|
+
}, [createVNode(unref(X), {
|
|
2751
|
+
class: "size-3.5",
|
|
2752
|
+
"aria-hidden": "true"
|
|
2753
|
+
})], 8, _hoisted_11)
|
|
2754
|
+
]);
|
|
2755
|
+
}), 128))])) : createCommentVNode("", true)
|
|
2756
|
+
]);
|
|
2757
|
+
};
|
|
2758
|
+
}
|
|
2759
|
+
}), [["__scopeId", "data-v-a42eab69"]]);
|
|
2760
|
+
//#endregion
|
|
2761
|
+
//#region src/components/TagsInput.vue?vue&type=script&setup=true&lang.ts
|
|
2762
|
+
var _hoisted_1$7 = [
|
|
2763
|
+
"id",
|
|
2764
|
+
"placeholder",
|
|
2765
|
+
"aria-describedby",
|
|
2766
|
+
"aria-invalid",
|
|
2767
|
+
"disabled"
|
|
2768
|
+
];
|
|
2769
|
+
//#endregion
|
|
2770
|
+
//#region src/components/TagsInput.vue
|
|
2771
|
+
var TagsInput_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
2772
|
+
__name: "TagsInput",
|
|
2773
|
+
props: /*@__PURE__*/ mergeModels({
|
|
2774
|
+
label: {},
|
|
2775
|
+
removeLabel: { type: Function },
|
|
2776
|
+
placeholder: { default: "" },
|
|
2777
|
+
hint: { default: "" },
|
|
2778
|
+
error: { default: "" },
|
|
2779
|
+
max: { default: () => void 0 },
|
|
2780
|
+
allowDuplicates: {
|
|
2781
|
+
type: Boolean,
|
|
2782
|
+
default: false
|
|
2783
|
+
},
|
|
2784
|
+
size: { default: "md" },
|
|
2785
|
+
labelHidden: {
|
|
2786
|
+
type: Boolean,
|
|
2787
|
+
default: false
|
|
2788
|
+
},
|
|
2789
|
+
disabled: {
|
|
2790
|
+
type: Boolean,
|
|
2791
|
+
default: false
|
|
2792
|
+
}
|
|
2793
|
+
}, {
|
|
2794
|
+
"modelValue": { default: () => [] },
|
|
2795
|
+
"modelModifiers": {}
|
|
2796
|
+
}),
|
|
2797
|
+
emits: ["update:modelValue"],
|
|
2798
|
+
setup(__props) {
|
|
2799
|
+
/** The tags, with `v-model`. */
|
|
2800
|
+
const model = useModel(__props, "modelValue");
|
|
2801
|
+
const draft = ref("");
|
|
2802
|
+
function add() {
|
|
2803
|
+
const value = draft.value.trim();
|
|
2804
|
+
draft.value = "";
|
|
2805
|
+
if (!value) return;
|
|
2806
|
+
if (__props.max !== void 0 && model.value.length >= __props.max) return;
|
|
2807
|
+
if (!__props.allowDuplicates && model.value.includes(value)) return;
|
|
2808
|
+
model.value = [...model.value, value];
|
|
2809
|
+
}
|
|
2810
|
+
function remove(index) {
|
|
2811
|
+
model.value = model.value.filter((_, at) => at !== index);
|
|
2812
|
+
}
|
|
2813
|
+
function onKeydown(event) {
|
|
2814
|
+
if (event.key === "Enter" || event.key === ",") {
|
|
2815
|
+
event.preventDefault();
|
|
2816
|
+
add();
|
|
2817
|
+
return;
|
|
2818
|
+
}
|
|
2819
|
+
if (event.key === "Backspace" && draft.value === "" && model.value.length) {
|
|
2820
|
+
event.preventDefault();
|
|
2821
|
+
remove(model.value.length - 1);
|
|
2822
|
+
}
|
|
2823
|
+
}
|
|
2824
|
+
return (_ctx, _cache) => {
|
|
2825
|
+
return openBlock(), createBlock(FormField_default, {
|
|
2826
|
+
label: __props.label,
|
|
2827
|
+
error: __props.error,
|
|
2828
|
+
hint: __props.hint,
|
|
2829
|
+
size: __props.size,
|
|
2830
|
+
"label-hidden": __props.labelHidden
|
|
2831
|
+
}, {
|
|
2832
|
+
default: withCtx(({ id, describedBy, invalid }) => [createElementVNode("div", {
|
|
2833
|
+
class: normalizeClass(["rk-tags control", {
|
|
2834
|
+
"is-invalid": invalid,
|
|
2835
|
+
"is-disabled": __props.disabled
|
|
2836
|
+
}]),
|
|
2837
|
+
onClick: _cache[1] || (_cache[1] = ($event) => !__props.disabled && _ctx.$el.querySelector("input")?.focus())
|
|
2838
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(model.value, (tag, index) => {
|
|
2839
|
+
return openBlock(), createBlock(BaseChip_default, {
|
|
2840
|
+
key: `${tag}-${index}`,
|
|
2841
|
+
label: tag,
|
|
2842
|
+
"remove-label": __props.removeLabel(tag),
|
|
2843
|
+
disabled: __props.disabled,
|
|
2844
|
+
onRemove: ($event) => remove(index)
|
|
2845
|
+
}, null, 8, [
|
|
2846
|
+
"label",
|
|
2847
|
+
"remove-label",
|
|
2848
|
+
"disabled",
|
|
2849
|
+
"onRemove"
|
|
2850
|
+
]);
|
|
2851
|
+
}), 128)), withDirectives(createElementVNode("input", {
|
|
2852
|
+
id,
|
|
2853
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => draft.value = $event),
|
|
2854
|
+
type: "text",
|
|
2855
|
+
class: "rk-tags-field",
|
|
2856
|
+
autocomplete: "off",
|
|
2857
|
+
placeholder: model.value.length ? "" : __props.placeholder,
|
|
2858
|
+
"aria-describedby": describedBy,
|
|
2859
|
+
"aria-invalid": invalid,
|
|
2860
|
+
disabled: __props.disabled || __props.max !== void 0 && model.value.length >= __props.max,
|
|
2861
|
+
onKeydown,
|
|
2862
|
+
onBlur: add
|
|
2863
|
+
}, null, 40, _hoisted_1$7), [[vModelText, draft.value]])], 2)]),
|
|
2864
|
+
_: 1
|
|
2865
|
+
}, 8, [
|
|
2866
|
+
"label",
|
|
2867
|
+
"error",
|
|
2868
|
+
"hint",
|
|
2869
|
+
"size",
|
|
2870
|
+
"label-hidden"
|
|
2871
|
+
]);
|
|
2872
|
+
};
|
|
2873
|
+
}
|
|
2874
|
+
}), [["__scopeId", "data-v-b372ae7b"]]);
|
|
2875
|
+
//#endregion
|
|
1929
2876
|
//#region src/components/BasePopover.vue?vue&type=script&setup=true&lang.ts
|
|
1930
|
-
var _hoisted_1$
|
|
2877
|
+
var _hoisted_1$6 = ["id", "aria-label"];
|
|
1931
2878
|
var FOCUSABLE = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"])";
|
|
1932
2879
|
//#endregion
|
|
1933
2880
|
//#region src/components/BasePopover.vue
|
|
@@ -2035,13 +2982,160 @@ var BasePopover_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__
|
|
|
2035
2982
|
role: "dialog",
|
|
2036
2983
|
"aria-label": __props.label,
|
|
2037
2984
|
tabindex: "-1"
|
|
2038
|
-
}, [renderSlot(_ctx.$slots, "default", { close }, void 0, true)], 14, _hoisted_1$
|
|
2985
|
+
}, [renderSlot(_ctx.$slots, "default", { close }, void 0, true)], 14, _hoisted_1$6)) : createCommentVNode("", true)]),
|
|
2039
2986
|
_: 3
|
|
2040
2987
|
})], 544);
|
|
2041
2988
|
};
|
|
2042
2989
|
}
|
|
2043
2990
|
}), [["__scopeId", "data-v-1e2d16d3"]]);
|
|
2044
2991
|
//#endregion
|
|
2992
|
+
//#region src/components/BaseDatePicker.vue?vue&type=script&setup=true&lang.ts
|
|
2993
|
+
var _hoisted_1$5 = [
|
|
2994
|
+
"id",
|
|
2995
|
+
"aria-describedby",
|
|
2996
|
+
"disabled"
|
|
2997
|
+
];
|
|
2998
|
+
var _hoisted_2$5 = { class: "truncate" };
|
|
2999
|
+
var _hoisted_3$5 = ["aria-label", "disabled"];
|
|
3000
|
+
var _hoisted_4$3 = { class: "rk-date-panel" };
|
|
3001
|
+
var _hoisted_5$1 = {
|
|
3002
|
+
key: 0,
|
|
3003
|
+
class: "rk-date-presets"
|
|
3004
|
+
};
|
|
3005
|
+
var _hoisted_6$1 = ["onClick"];
|
|
3006
|
+
//#endregion
|
|
3007
|
+
//#region src/components/BaseDatePicker.vue
|
|
3008
|
+
var BaseDatePicker_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
3009
|
+
__name: "BaseDatePicker",
|
|
3010
|
+
props: /*@__PURE__*/ mergeModels({
|
|
3011
|
+
label: {},
|
|
3012
|
+
mode: { default: "single" },
|
|
3013
|
+
placeholder: { default: "" },
|
|
3014
|
+
format: { default: () => ({ dateStyle: "medium" }) },
|
|
3015
|
+
presets: { default: () => void 0 },
|
|
3016
|
+
clearLabel: { default: () => void 0 },
|
|
3017
|
+
min: { default: () => void 0 },
|
|
3018
|
+
max: { default: () => void 0 },
|
|
3019
|
+
isDisabled: {
|
|
3020
|
+
type: Function,
|
|
3021
|
+
default: void 0
|
|
3022
|
+
},
|
|
3023
|
+
weekStartsOn: { default: 1 },
|
|
3024
|
+
previousLabel: {},
|
|
3025
|
+
nextLabel: {},
|
|
3026
|
+
today: { default: () => void 0 },
|
|
3027
|
+
error: { default: "" },
|
|
3028
|
+
hint: { default: "" },
|
|
3029
|
+
size: { default: "md" },
|
|
3030
|
+
labelHidden: {
|
|
3031
|
+
type: Boolean,
|
|
3032
|
+
default: false
|
|
3033
|
+
},
|
|
3034
|
+
disabled: {
|
|
3035
|
+
type: Boolean,
|
|
3036
|
+
default: false
|
|
3037
|
+
}
|
|
3038
|
+
}, {
|
|
3039
|
+
"modelValue": {},
|
|
3040
|
+
"modelModifiers": {}
|
|
3041
|
+
}),
|
|
3042
|
+
emits: ["update:modelValue"],
|
|
3043
|
+
setup(__props) {
|
|
3044
|
+
const model = useModel(__props, "modelValue");
|
|
3045
|
+
const open = ref(false);
|
|
3046
|
+
const shown = computed(() => {
|
|
3047
|
+
const value = model.value;
|
|
3048
|
+
if (value === void 0) return "";
|
|
3049
|
+
if (typeof value === "string") return formatDate(fromDateKey(value), __props.format);
|
|
3050
|
+
const start = formatDate(fromDateKey(value.start), __props.format);
|
|
3051
|
+
if (value.start === value.end) return start;
|
|
3052
|
+
return `${start} – ${formatDate(fromDateKey(value.end), __props.format)}`;
|
|
3053
|
+
});
|
|
3054
|
+
function onPicked(next) {
|
|
3055
|
+
model.value = next;
|
|
3056
|
+
if (__props.mode === "single" || next && typeof next === "object") open.value = false;
|
|
3057
|
+
}
|
|
3058
|
+
function applyPreset(preset) {
|
|
3059
|
+
model.value = preset.value();
|
|
3060
|
+
open.value = false;
|
|
3061
|
+
}
|
|
3062
|
+
function clear() {
|
|
3063
|
+
model.value = void 0;
|
|
3064
|
+
open.value = false;
|
|
3065
|
+
}
|
|
3066
|
+
return (_ctx, _cache) => {
|
|
3067
|
+
return openBlock(), createBlock(FormField_default, {
|
|
3068
|
+
label: __props.label,
|
|
3069
|
+
error: __props.error,
|
|
3070
|
+
hint: __props.hint,
|
|
3071
|
+
size: __props.size,
|
|
3072
|
+
"label-hidden": __props.labelHidden
|
|
3073
|
+
}, {
|
|
3074
|
+
default: withCtx(({ id, describedBy, invalid }) => [createVNode(BasePopover_default, {
|
|
3075
|
+
modelValue: open.value,
|
|
3076
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => open.value = $event),
|
|
3077
|
+
class: "rk-date",
|
|
3078
|
+
label: __props.label
|
|
3079
|
+
}, {
|
|
3080
|
+
trigger: withCtx(({ props }) => [createElementVNode("div", { class: normalizeClass(["rk-date-wrap control", { "is-invalid": invalid }]) }, [createElementVNode("button", mergeProps({
|
|
3081
|
+
id,
|
|
3082
|
+
type: "button",
|
|
3083
|
+
class: ["rk-date-field focus-ring", { "is-empty": !shown.value }],
|
|
3084
|
+
"aria-describedby": describedBy,
|
|
3085
|
+
disabled: __props.disabled
|
|
3086
|
+
}, props), [createVNode(unref(CalendarDays), {
|
|
3087
|
+
class: "size-4 shrink-0",
|
|
3088
|
+
"aria-hidden": "true"
|
|
3089
|
+
}), createElementVNode("span", _hoisted_2$5, toDisplayString(shown.value || __props.placeholder), 1)], 16, _hoisted_1$5), __props.clearLabel && shown.value ? (openBlock(), createElementBlock("button", {
|
|
3090
|
+
key: 0,
|
|
3091
|
+
type: "button",
|
|
3092
|
+
class: "rk-date-clear focus-ring",
|
|
3093
|
+
"aria-label": __props.clearLabel,
|
|
3094
|
+
disabled: __props.disabled,
|
|
3095
|
+
onClick: clear
|
|
3096
|
+
}, [createVNode(unref(X), {
|
|
3097
|
+
class: "size-3.5",
|
|
3098
|
+
"aria-hidden": "true"
|
|
3099
|
+
})], 8, _hoisted_3$5)) : createCommentVNode("", true)], 2)]),
|
|
3100
|
+
default: withCtx(() => [createElementVNode("div", _hoisted_4$3, [__props.presets?.length ? (openBlock(), createElementBlock("ul", _hoisted_5$1, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.presets, (preset) => {
|
|
3101
|
+
return openBlock(), createElementBlock("li", { key: preset.label }, [createElementVNode("button", {
|
|
3102
|
+
type: "button",
|
|
3103
|
+
class: "rk-date-preset focus-ring",
|
|
3104
|
+
onClick: ($event) => applyPreset(preset)
|
|
3105
|
+
}, toDisplayString(preset.label), 9, _hoisted_6$1)]);
|
|
3106
|
+
}), 128))])) : createCommentVNode("", true), createVNode(BaseCalendar_default, mergeProps({
|
|
3107
|
+
"model-value": model.value,
|
|
3108
|
+
mode: __props.mode,
|
|
3109
|
+
min: __props.min,
|
|
3110
|
+
max: __props.max,
|
|
3111
|
+
"is-disabled": __props.isDisabled,
|
|
3112
|
+
"week-starts-on": __props.weekStartsOn,
|
|
3113
|
+
"previous-label": __props.previousLabel,
|
|
3114
|
+
"next-label": __props.nextLabel
|
|
3115
|
+
}, __props.today ? { today: __props.today } : {}, { "onUpdate:modelValue": onPicked }), null, 16, [
|
|
3116
|
+
"model-value",
|
|
3117
|
+
"mode",
|
|
3118
|
+
"min",
|
|
3119
|
+
"max",
|
|
3120
|
+
"is-disabled",
|
|
3121
|
+
"week-starts-on",
|
|
3122
|
+
"previous-label",
|
|
3123
|
+
"next-label"
|
|
3124
|
+
])])]),
|
|
3125
|
+
_: 2
|
|
3126
|
+
}, 1032, ["modelValue", "label"])]),
|
|
3127
|
+
_: 1
|
|
3128
|
+
}, 8, [
|
|
3129
|
+
"label",
|
|
3130
|
+
"error",
|
|
3131
|
+
"hint",
|
|
3132
|
+
"size",
|
|
3133
|
+
"label-hidden"
|
|
3134
|
+
]);
|
|
3135
|
+
};
|
|
3136
|
+
}
|
|
3137
|
+
}), [["__scopeId", "data-v-154e27fb"]]);
|
|
3138
|
+
//#endregion
|
|
2045
3139
|
//#region src/components/ToggleGroup.vue?vue&type=script&setup=true&lang.ts
|
|
2046
3140
|
var _hoisted_1$4 = ["aria-label"];
|
|
2047
3141
|
var _hoisted_2$4 = [
|
|
@@ -2737,8 +3831,8 @@ function createI18nRuntime(options) {
|
|
|
2737
3831
|
*
|
|
2738
3832
|
* The fallback keeps `vitest` and `vite dev` honest, where no define runs.
|
|
2739
3833
|
*/
|
|
2740
|
-
var VERSION = "2.
|
|
3834
|
+
var VERSION = "2.7.0";
|
|
2741
3835
|
//#endregion
|
|
2742
|
-
export { AppError, BaseAlert_default as BaseAlert, BaseAvatar_default as BaseAvatar, BaseBadge_default as BaseBadge, BaseButton_default as BaseButton, BaseCard_default as BaseCard, BaseCheckbox_default as BaseCheckbox, BaseCombobox_default as BaseCombobox, BaseInput_default as BaseInput, BaseMenu_default as BaseMenu, BasePopover_default as BasePopover, BaseRadioGroup_default as BaseRadioGroup, BaseSelect_default as BaseSelect, BaseSheet_default as BaseSheet, BaseSlider_default as BaseSlider, BaseSpinner_default as BaseSpinner, BaseStepper_default as BaseStepper, BaseSwitch_default as BaseSwitch, BaseTable_default as BaseTable, BaseTextarea_default as BaseTextarea, CircularProgress_default as CircularProgress, EmptyState_default as EmptyState, ErrorBoundary_default as ErrorBoundary, FormField_default as FormField, GoogleButton_default as GoogleButton, LocaleLinks_default as LocaleLinks, MATERIALS, NumberInput_default as NumberInput, PALETTES, PageContainer_default as PageContainer, PageHeader_default as PageHeader, PinInput_default as PinInput, PriceCard_default as PriceCard, ProgressBar_default as ProgressBar, SHEET_ROOT_ID, SectionHeading_default as SectionHeading, SegmentedControl_default as SegmentedControl, SettingsGroup_default as SettingsGroup, SettingsRow_default as SettingsRow, SkeletonList_default as SkeletonList, StatCard_default as StatCard, TabBar_default as TabBar, ToastHost_default as ToastHost, ToggleGroup_default as ToggleGroup, ToneDot_default as ToneDot, VERSION, addDays, applyMaterial, applyPalette, applyTheme, createI18nRuntime, downloadJson, eachDayOfYear, ensureSheetRoot, formatDate, formatNumber, fromDateKey, isApplePortable, isInstalled, isMaterial, isPaletteName, isThemePreference, lastNDays, leadingBlanks, needsIosInstall, readStoredTheme, registerErrorMapper, relativeDayLabel, safeRedirect, setFormatLocale, setMaterialStorageKey, setPaletteStorageKey, setThemeStorageKey, startOfWeek, tapFeedback, toAppError, toDateKey, toRedirectPath, todayKey, useDebouncedCallback, useDragScroll, useMaterial, useMediaQuery, useOnline, usePalette, useTheme, useToast, useToday, useVisualViewport };
|
|
3836
|
+
export { AppError, AvatarStack_default as AvatarStack, BaseAlert_default as BaseAlert, BaseAvatar_default as BaseAvatar, BaseBadge_default as BaseBadge, BaseButton_default as BaseButton, BaseCalendar_default as BaseCalendar, BaseCard_default as BaseCard, BaseCheckbox_default as BaseCheckbox, BaseChip_default as BaseChip, BaseCombobox_default as BaseCombobox, BaseDatePicker_default as BaseDatePicker, BaseInput_default as BaseInput, BaseKbd_default as BaseKbd, BaseLink_default as BaseLink, BaseMenu_default as BaseMenu, BasePopover_default as BasePopover, BaseRadioGroup_default as BaseRadioGroup, BaseRating_default as BaseRating, BaseSelect_default as BaseSelect, BaseSeparator_default as BaseSeparator, BaseSheet_default as BaseSheet, BaseSkeleton_default as BaseSkeleton, BaseSlider_default as BaseSlider, BaseSpinner_default as BaseSpinner, BaseStepper_default as BaseStepper, BaseSwitch_default as BaseSwitch, BaseTable_default as BaseTable, BaseTextarea_default as BaseTextarea, CircularProgress_default as CircularProgress, CopyButton_default as CopyButton, EmptyState_default as EmptyState, ErrorBoundary_default as ErrorBoundary, FileDrop_default as FileDrop, FormField_default as FormField, GoogleButton_default as GoogleButton, LocaleLinks_default as LocaleLinks, MATERIALS, NumberInput_default as NumberInput, PALETTES, PageContainer_default as PageContainer, PageHeader_default as PageHeader, PinInput_default as PinInput, PriceCard_default as PriceCard, ProgressBar_default as ProgressBar, SHEET_ROOT_ID, SectionHeading_default as SectionHeading, SegmentedControl_default as SegmentedControl, SettingsGroup_default as SettingsGroup, SettingsRow_default as SettingsRow, SkeletonList_default as SkeletonList, StatCard_default as StatCard, TabBar_default as TabBar, TagsInput_default as TagsInput, ToastHost_default as ToastHost, ToggleGroup_default as ToggleGroup, ToneDot_default as ToneDot, VERSION, addDays, applyMaterial, applyPalette, applyTheme, createI18nRuntime, downloadJson, eachDayOfYear, ensureSheetRoot, formatDate, formatNumber, fromDateKey, isApplePortable, isInstalled, isMaterial, isPaletteName, isThemePreference, lastNDays, leadingBlanks, needsIosInstall, readStoredTheme, registerErrorMapper, relativeDayLabel, safeRedirect, setFormatLocale, setMaterialStorageKey, setPaletteStorageKey, setThemeStorageKey, startOfWeek, tapFeedback, toAppError, toDateKey, toRedirectPath, todayKey, useDebouncedCallback, useDragScroll, useMaterial, useMediaQuery, useOnline, usePalette, useTheme, useToast, useToday, useVisualViewport };
|
|
2743
3837
|
|
|
2744
3838
|
//# sourceMappingURL=index.js.map
|