@youcan/celeste 0.6.32 → 0.6.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. package/dist/celeste.css +300 -234
  2. package/dist/cjs/chunks/index.js +95 -0
  3. package/dist/cjs/dropdown-menu-content.js +52 -2
  4. package/dist/cjs/dropdown-menu-item.js +13 -25
  5. package/dist/cjs/dropdown-menu-sub-content.js +49 -2
  6. package/dist/cjs/dropdown-menu-sub-trigger.js +43 -2
  7. package/dist/cjs/dropdown-menu-trigger.js +2 -2
  8. package/dist/cjs/dropdown.js +1 -2
  9. package/dist/cjs/index.js +15 -9
  10. package/dist/cjs/progress-bar.js +84 -0
  11. package/dist/cjs/progress-circle.js +92 -0
  12. package/dist/components/dropdown-menu/dropdown-menu-item.d.ts +1 -0
  13. package/dist/components/dropdown-menu/dropdown-menu-sub-trigger.d.ts +1 -0
  14. package/dist/components/index.d.ts +1 -0
  15. package/dist/components/progress/index.d.ts +4 -0
  16. package/dist/components/progress/progress-bar.d.ts +31 -0
  17. package/dist/components/progress/progress-circle.d.ts +27 -0
  18. package/dist/es/checkbox-label.js +1 -1
  19. package/dist/es/chunks/index.js +142 -47
  20. package/dist/es/chunks/index2.js +1 -1
  21. package/dist/es/combobox-group.js +1 -1
  22. package/dist/es/combobox-input.js +1 -1
  23. package/dist/es/combobox-item.js +1 -1
  24. package/dist/es/combobox-list.js +1 -1
  25. package/dist/es/combobox-root.js +1 -1
  26. package/dist/es/combobox-separator.js +1 -1
  27. package/dist/es/combobox-trigger.js +1 -1
  28. package/dist/es/command-group.js +1 -1
  29. package/dist/es/command-input.js +1 -1
  30. package/dist/es/command-item.js +1 -1
  31. package/dist/es/command-list.js +1 -1
  32. package/dist/es/command-root.js +1 -1
  33. package/dist/es/command-separator.js +1 -1
  34. package/dist/es/dropdown-menu-content.js +52 -2
  35. package/dist/es/dropdown-menu-group.js +1 -1
  36. package/dist/es/dropdown-menu-item.js +15 -27
  37. package/dist/es/dropdown-menu-label.js +1 -1
  38. package/dist/es/dropdown-menu-separator.js +1 -1
  39. package/dist/es/dropdown-menu-sub-content.js +49 -2
  40. package/dist/es/dropdown-menu-sub-trigger.js +43 -2
  41. package/dist/es/dropdown-menu-trigger.js +2 -2
  42. package/dist/es/dropdown.js +2 -3
  43. package/dist/es/index.js +48 -42
  44. package/dist/es/label.js +1 -1
  45. package/dist/es/progress-bar.js +85 -0
  46. package/dist/es/progress-circle.js +93 -0
  47. package/dist/es/scroll-bar.js +1 -1
  48. package/dist/es/segmented-control-item.js +1 -1
  49. package/dist/es/segmented-control.js +1 -1
  50. package/dist/es/select-content.js +1 -1
  51. package/dist/es/select-item.js +1 -1
  52. package/dist/es/select-trigger.js +1 -1
  53. package/dist/es/select-value.js +1 -1
  54. package/dist/es/tab-menu-content.js +1 -1
  55. package/dist/es/tab-menu-item.js +1 -1
  56. package/dist/es/tab-menu-list.js +1 -1
  57. package/dist/es/tab-menu.js +1 -1
  58. package/dist/es/tooltip.js +1 -1
  59. package/package.json +3 -3
  60. package/src/components/dropdown/dropdown.vue +0 -1
  61. package/src/components/dropdown-menu/dropdown-menu-content.vue +31 -21
  62. package/src/components/dropdown-menu/dropdown-menu-item.vue +8 -62
  63. package/src/components/dropdown-menu/dropdown-menu-sub-content.vue +32 -21
  64. package/src/components/dropdown-menu/dropdown-menu-sub-trigger.vue +30 -6
  65. package/src/components/dropdown-menu/dropdown-menu-trigger.vue +6 -20
  66. package/src/components/dropdown-menu/stories/dropdown-menu.stories.ts +150 -54
  67. package/src/components/index.ts +1 -0
  68. package/src/components/progress/index.ts +5 -0
  69. package/src/components/progress/progress-bar.vue +167 -0
  70. package/src/components/progress/progress-circle.vue +126 -0
  71. package/src/components/progress/stories/progress-bar.stories.ts +328 -0
  72. package/src/components/progress/stories/progress-circular.stories.ts +152 -0
  73. package/dist/cjs/chunks/dropdown-menu-content.vue_vue_type_style_index_0_lang.js +0 -51
  74. package/dist/cjs/chunks/dropdown-menu-sub-content.vue_vue_type_style_index_0_lang.js +0 -49
  75. package/dist/cjs/chunks/dropdown-menu-sub-trigger.vue_vue_type_style_index_0_lang.js +0 -32
  76. package/dist/es/chunks/dropdown-menu-content.vue_vue_type_style_index_0_lang.js +0 -52
  77. package/dist/es/chunks/dropdown-menu-sub-content.vue_vue_type_style_index_0_lang.js +0 -50
  78. package/dist/es/chunks/dropdown-menu-sub-trigger.vue_vue_type_style_index_0_lang.js +0 -33
@@ -1,4 +1,45 @@
1
- import { _ as _sfc_main } from "./chunks/dropdown-menu-sub-trigger.vue_vue_type_style_index_0_lang.js";
1
+ import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, createElementBlock, renderSlot, createCommentVNode, createElementVNode } from "vue";
2
+ import { useDelegatedProps } from "./use-delegated-props.js";
3
+ import { c as clsx } from "./chunks/clsx.js";
4
+ import { A as At, a7 as wh } from "./chunks/index.js";
5
+ import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
+ const _hoisted_1 = {
7
+ key: 0,
8
+ class: "celeste-dropdown-menu-sub-prefix"
9
+ };
10
+ const _hoisted_2 = { class: "celeste-dropdown-menu-sub-body" };
11
+ const _sfc_main = /* @__PURE__ */ defineComponent({
12
+ __name: "dropdown-menu-sub-trigger",
13
+ props: {
14
+ disabled: { type: Boolean },
15
+ textValue: {},
16
+ asChild: { type: Boolean },
17
+ as: {},
18
+ class: {}
19
+ },
20
+ setup(__props) {
21
+ const props = __props;
22
+ const delegatedProps = useDelegatedProps(props, "class");
23
+ const forwardedProps = At(delegatedProps);
24
+ return (_ctx, _cache) => {
25
+ return openBlock(), createBlock(unref(wh), mergeProps(unref(forwardedProps), {
26
+ class: unref(clsx)(props.class, "celeste-dropdown-menu-sub-trigger")
27
+ }), {
28
+ default: withCtx(() => [
29
+ _ctx.$slots.prefix ? (openBlock(), createElementBlock("div", _hoisted_1, [
30
+ renderSlot(_ctx.$slots, "prefix", {}, void 0, true)
31
+ ])) : createCommentVNode("", true),
32
+ createElementVNode("div", _hoisted_2, [
33
+ renderSlot(_ctx.$slots, "default", {}, void 0, true)
34
+ ]),
35
+ _cache[0] || (_cache[0] = createElementVNode("i", { class: "i-celeste-arrow-right-s-line" }, null, -1))
36
+ ]),
37
+ _: 3
38
+ }, 16, ["class"]);
39
+ };
40
+ }
41
+ });
42
+ const dropdownMenuSubTrigger = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-44257601"]]);
2
43
  export {
3
- _sfc_main as default
44
+ dropdownMenuSubTrigger as default
4
45
  };
@@ -12,7 +12,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
12
12
  const props = __props;
13
13
  const forwardedProps = At(props);
14
14
  return (_ctx, _cache) => {
15
- return openBlock(), createBlock(unref(rh), mergeProps({ class: "celeste-dropdown-menu-trigger" }, unref(forwardedProps)), {
15
+ return openBlock(), createBlock(unref(rh), mergeProps({ class: "celeste-dropdown-menu-trigger" }, unref(forwardedProps), { as: "div" }), {
16
16
  default: withCtx(() => [
17
17
  renderSlot(_ctx.$slots, "default", {}, void 0, true)
18
18
  ]),
@@ -21,7 +21,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
21
21
  };
22
22
  }
23
23
  });
24
- const dropdownMenuTrigger = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-d81106e4"]]);
24
+ const dropdownMenuTrigger = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-003a2030"]]);
25
25
  export {
26
26
  dropdownMenuTrigger as default
27
27
  };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent, mergeModels, useModel, ref, computed, watch, openBlock, createElementBlock, withKeys, createVNode, unref, withCtx, normalizeClass, createElementVNode, createCommentVNode, renderSlot, normalizeProps, guardReactiveProps, toDisplayString, createBlock, createSlots, Fragment, renderList } from "vue";
2
2
  import { c as clsx } from "./chunks/clsx.js";
3
- import { a1 as Hv, j as jv, a3 as Uv, $ as Xv, a0 as Jv, a2 as tm, Z as Zv, T as qv, X as Qv } from "./chunks/index.js";
3
+ import { U as Hv, j as jv, $ as Uv, X as Xv, T as Jv, _ as tm, Z as Zv, L as qv, R as Qv } from "./chunks/index.js";
4
4
  import Badge from "./badge.js";
5
5
  import TextInput from "./text-input.js";
6
6
  import DropdownItem from "./dropdown-item.js";
@@ -191,7 +191,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
191
191
  }),
192
192
  !_ctx.disabled ? (openBlock(), createBlock(unref(Xv), {
193
193
  key: 0,
194
- "force-mount": "",
195
194
  dismissable: "",
196
195
  "avoid-collisions": true,
197
196
  class: normalizeClass(["celeste-dropdown-content", unref(clsx)(
@@ -286,7 +285,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
286
285
  };
287
286
  }
288
287
  });
289
- const dropdown = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-8ef0e6e7"]]);
288
+ const dropdown = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-13b7b76a"]]);
290
289
  export {
291
290
  dropdown as default
292
291
  };
package/dist/es/index.js CHANGED
@@ -22,45 +22,47 @@ import { _ as _sfc_main$2 } from "./chunks/content-divider.vue_vue_type_style_in
22
22
  import contextMenuItem from "./context-menu-item.js";
23
23
  import DropdownItem from "./dropdown-item.js";
24
24
  import dropdown from "./dropdown.js";
25
- import { _ as _sfc_main$3 } from "./chunks/dropdown-menu-content.vue_vue_type_style_index_0_lang.js";
25
+ import dropdownMenuContent from "./dropdown-menu-content.js";
26
26
  import dropdownMenuGroup from "./dropdown-menu-group.js";
27
27
  import dropdownMenuItem from "./dropdown-menu-item.js";
28
28
  import dropdownMenuLabel from "./dropdown-menu-label.js";
29
29
  import dropdownMenuSeparator from "./dropdown-menu-separator.js";
30
- import { _ as _sfc_main$5 } from "./chunks/dropdown-menu-sub-content.vue_vue_type_style_index_0_lang.js";
31
- import { _ as _sfc_main$6 } from "./chunks/dropdown-menu-sub-trigger.vue_vue_type_style_index_0_lang.js";
32
- import { _ as _sfc_main$4 } from "./chunks/dropdown-menu-sub.js";
30
+ import dropdownMenuSubContent from "./dropdown-menu-sub-content.js";
31
+ import dropdownMenuSubTrigger from "./dropdown-menu-sub-trigger.js";
32
+ import { _ as _sfc_main$3 } from "./chunks/dropdown-menu-sub.js";
33
33
  import dropdownMenuTrigger from "./dropdown-menu-trigger.js";
34
34
  import dropdownMenu from "./dropdown-menu.js";
35
35
  import hintText from "./hint-text.js";
36
36
  import Label from "./label.js";
37
37
  import modalBody from "./modal-body.js";
38
- import { _ as _sfc_main$8 } from "./chunks/modal-close.js";
38
+ import { _ as _sfc_main$5 } from "./chunks/modal-close.js";
39
39
  import modalContent from "./modal-content.js";
40
40
  import modalFooter from "./modal-footer.js";
41
41
  import modalHeader from "./modal-header.js";
42
- import { _ as _sfc_main$9 } from "./chunks/modal-trigger.js";
43
- import { _ as _sfc_main$7 } from "./chunks/modal.js";
42
+ import { _ as _sfc_main$6 } from "./chunks/modal-trigger.js";
43
+ import { _ as _sfc_main$4 } from "./chunks/modal.js";
44
44
  import PopoverContent from "./popover-content.js";
45
45
  import PopoverTrigger from "./popover-trigger.js";
46
- import { _ as _sfc_main$a } from "./chunks/popover.js";
46
+ import { _ as _sfc_main$7 } from "./chunks/popover.js";
47
+ import progressBar from "./progress-bar.js";
48
+ import progressCircle from "./progress-circle.js";
47
49
  import richEditor from "./rich-editor.js";
48
- import { _ as _sfc_main$b } from "./chunks/scroll-area.js";
50
+ import { _ as _sfc_main$8 } from "./chunks/scroll-area.js";
49
51
  import segmentedControlItem from "./segmented-control-item.js";
50
52
  import segmentedControl from "./segmented-control.js";
51
53
  import SelectContent from "./select-content.js";
52
- import { _ as _sfc_main$d } from "./chunks/select-group.js";
54
+ import { _ as _sfc_main$a } from "./chunks/select-group.js";
53
55
  import SelectIcon from "./select-icon.js";
54
56
  import SelectItem from "./select-item.js";
55
57
  import selectLabel from "./select-label.js";
56
58
  import selectSeparator from "./select-separator.js";
57
59
  import SelectTrigger from "./select-trigger.js";
58
60
  import SelectValue from "./select-value.js";
59
- import { _ as _sfc_main$c } from "./chunks/select.js";
60
- import { _ as _sfc_main$e } from "./chunks/slider.vue_vue_type_style_index_0_lang.js";
61
+ import { _ as _sfc_main$9 } from "./chunks/select.js";
62
+ import { _ as _sfc_main$b } from "./chunks/slider.vue_vue_type_style_index_0_lang.js";
61
63
  import SonnerAlert from "./sonner-alert.js";
62
- import { _ as _sfc_main$f, t as toast$1 } from "./chunks/sonner.js";
63
- import { _ as _sfc_main$g } from "./chunks/switch.vue_vue_type_style_index_0_lang.js";
64
+ import { _ as _sfc_main$c, t as toast$1 } from "./chunks/sonner.js";
65
+ import { _ as _sfc_main$d } from "./chunks/switch.vue_vue_type_style_index_0_lang.js";
64
66
  import tabMenuContent from "./tab-menu-content.js";
65
67
  import tabMenuItem from "./tab-menu-item.js";
66
68
  import tabMenuList from "./tab-menu-list.js";
@@ -96,48 +98,50 @@ const components = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePr
96
98
  Dropdown: dropdown,
97
99
  DropdownItem,
98
100
  DropdownMenu: dropdownMenu,
99
- DropdownMenuContent: _sfc_main$3,
101
+ DropdownMenuContent: dropdownMenuContent,
100
102
  DropdownMenuGroup: dropdownMenuGroup,
101
103
  DropdownMenuItem: dropdownMenuItem,
102
104
  DropdownMenuLabel: dropdownMenuLabel,
103
105
  DropdownMenuSeparator: dropdownMenuSeparator,
104
- DropdownMenuSub: _sfc_main$4,
105
- DropdownMenuSubContent: _sfc_main$5,
106
- DropdownMenuSubTrigger: _sfc_main$6,
106
+ DropdownMenuSub: _sfc_main$3,
107
+ DropdownMenuSubContent: dropdownMenuSubContent,
108
+ DropdownMenuSubTrigger: dropdownMenuSubTrigger,
107
109
  DropdownMenuTrigger: dropdownMenuTrigger,
108
110
  FancyButton: fancyButton,
109
111
  HintText: hintText,
110
112
  Label,
111
113
  LinkButton,
112
- Modal: _sfc_main$7,
114
+ Modal: _sfc_main$4,
113
115
  ModalBody: modalBody,
114
- ModalClose: _sfc_main$8,
116
+ ModalClose: _sfc_main$5,
115
117
  ModalContent: modalContent,
116
118
  ModalFooter: modalFooter,
117
119
  ModalHeader: modalHeader,
118
- ModalTrigger: _sfc_main$9,
119
- Popover: _sfc_main$a,
120
+ ModalTrigger: _sfc_main$6,
121
+ Popover: _sfc_main$7,
120
122
  PopoverContent,
121
123
  PopoverTrigger,
124
+ ProgressBar: progressBar,
125
+ ProgressCircle: progressCircle,
122
126
  RichEditor: richEditor,
123
- ScrollArea: _sfc_main$b,
127
+ ScrollArea: _sfc_main$8,
124
128
  SegmentedControl: segmentedControl,
125
129
  SegmentedControlItem: segmentedControlItem,
126
- Select: _sfc_main$c,
130
+ Select: _sfc_main$9,
127
131
  SelectContent,
128
- SelectGroup: _sfc_main$d,
132
+ SelectGroup: _sfc_main$a,
129
133
  SelectIcon,
130
134
  SelectItem,
131
135
  SelectLabel: selectLabel,
132
136
  SelectSeparator: selectSeparator,
133
137
  SelectTrigger,
134
138
  SelectValue,
135
- Slider: _sfc_main$e,
139
+ Slider: _sfc_main$b,
136
140
  SocialButton: socialButton,
137
- Sonner: _sfc_main$f,
141
+ Sonner: _sfc_main$c,
138
142
  SonnerAlert,
139
143
  StatusBadge: statusBadge,
140
- Switch: _sfc_main$g,
144
+ Switch: _sfc_main$d,
141
145
  TabMenu: tabMenu,
142
146
  TabMenuContent: tabMenuContent,
143
147
  TabMenuItem: tabMenuItem,
@@ -229,49 +233,51 @@ export {
229
233
  dropdown as Dropdown,
230
234
  DropdownItem,
231
235
  dropdownMenu as DropdownMenu,
232
- _sfc_main$3 as DropdownMenuContent,
236
+ dropdownMenuContent as DropdownMenuContent,
233
237
  dropdownMenuGroup as DropdownMenuGroup,
234
238
  dropdownMenuItem as DropdownMenuItem,
235
239
  dropdownMenuLabel as DropdownMenuLabel,
236
240
  dropdownMenuSeparator as DropdownMenuSeparator,
237
- _sfc_main$4 as DropdownMenuSub,
238
- _sfc_main$5 as DropdownMenuSubContent,
239
- _sfc_main$6 as DropdownMenuSubTrigger,
241
+ _sfc_main$3 as DropdownMenuSub,
242
+ dropdownMenuSubContent as DropdownMenuSubContent,
243
+ dropdownMenuSubTrigger as DropdownMenuSubTrigger,
240
244
  dropdownMenuTrigger as DropdownMenuTrigger,
241
245
  fancyButton as FancyButton,
242
246
  HEX_VALIDATION_PATTERN,
243
247
  hintText as HintText,
244
248
  Label,
245
249
  LinkButton,
246
- _sfc_main$7 as Modal,
250
+ _sfc_main$4 as Modal,
247
251
  modalBody as ModalBody,
248
- _sfc_main$8 as ModalClose,
252
+ _sfc_main$5 as ModalClose,
249
253
  modalContent as ModalContent,
250
254
  modalFooter as ModalFooter,
251
255
  modalHeader as ModalHeader,
252
- _sfc_main$9 as ModalTrigger,
253
- _sfc_main$a as Popover,
256
+ _sfc_main$6 as ModalTrigger,
257
+ _sfc_main$7 as Popover,
254
258
  PopoverContent,
255
259
  PopoverTrigger,
260
+ progressBar as ProgressBar,
261
+ progressCircle as ProgressCircle,
256
262
  richEditor as RichEditor,
257
- _sfc_main$b as ScrollArea,
263
+ _sfc_main$8 as ScrollArea,
258
264
  segmentedControl as SegmentedControl,
259
265
  segmentedControlItem as SegmentedControlItem,
260
- _sfc_main$c as Select,
266
+ _sfc_main$9 as Select,
261
267
  SelectContent,
262
- _sfc_main$d as SelectGroup,
268
+ _sfc_main$a as SelectGroup,
263
269
  SelectIcon,
264
270
  SelectItem,
265
271
  selectLabel as SelectLabel,
266
272
  selectSeparator as SelectSeparator,
267
273
  SelectTrigger,
268
274
  SelectValue,
269
- _sfc_main$e as Slider,
275
+ _sfc_main$b as Slider,
270
276
  socialButton as SocialButton,
271
- _sfc_main$f as Sonner,
277
+ _sfc_main$c as Sonner,
272
278
  SonnerAlert,
273
279
  statusBadge as StatusBadge,
274
- _sfc_main$g as Switch,
280
+ _sfc_main$d as Switch,
275
281
  tabMenu as TabMenu,
276
282
  tabMenuContent as TabMenuContent,
277
283
  tabMenuItem as TabMenuItem,
package/dist/es/label.js CHANGED
@@ -2,7 +2,7 @@ import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, re
2
2
  import Tooltip from "./tooltip.js";
3
3
  import { useDelegatedProps } from "./use-delegated-props.js";
4
4
  import { c as clsx } from "./chunks/clsx.js";
5
- import { S as Oh } from "./chunks/index.js";
5
+ import { J as Oh } from "./chunks/index.js";
6
6
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
7
7
  const _hoisted_1 = {
8
8
  key: 0,
@@ -0,0 +1,85 @@
1
+ import { defineComponent, useCssVars, computed, openBlock, createElementBlock, toDisplayString, createCommentVNode, createElementVNode, renderSlot, createTextVNode, createVNode, unref, mergeProps, withCtx } from "vue";
2
+ import { useDelegatedProps } from "./use-delegated-props.js";
3
+ import { c as clsx } from "./chunks/clsx.js";
4
+ import { ak as By, al as Iy } from "./chunks/index.js";
5
+ import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
+ const _hoisted_1 = ["data-layout"];
7
+ const _hoisted_2 = {
8
+ key: 0,
9
+ class: "celeste-progress-bar-label"
10
+ };
11
+ const _hoisted_3 = {
12
+ key: 0,
13
+ class: "celeste-progress-bar-label-title"
14
+ };
15
+ const _hoisted_4 = { class: "celeste-progress-bar-label" };
16
+ const _hoisted_5 = {
17
+ key: 1,
18
+ class: "celeste-progress-bar-description"
19
+ };
20
+ const _sfc_main = /* @__PURE__ */ defineComponent({
21
+ __name: "progress-bar",
22
+ props: {
23
+ modelValue: { default: 0 },
24
+ max: { default: 100 },
25
+ getValueLabel: {},
26
+ asChild: { type: Boolean },
27
+ as: {},
28
+ class: {},
29
+ color: { default: "primary" },
30
+ title: {},
31
+ layout: { default: "bare" }
32
+ },
33
+ setup(__props) {
34
+ useCssVars((_ctx) => ({
35
+ "6ba22aeb": progressIndicator.value
36
+ }));
37
+ const props = __props;
38
+ const delegatedProps = useDelegatedProps(props, "class");
39
+ const progress = computed(() => {
40
+ if (props.max === 0)
41
+ return 0;
42
+ const value = Math.min(Math.max(props.modelValue ?? 0, 0), props.max);
43
+ return Math.round(value / props.max * 100);
44
+ });
45
+ const progressIndicator = computed(() => {
46
+ return 100 - (props.modelValue ?? 0) / props.max * 100;
47
+ });
48
+ return (_ctx, _cache) => {
49
+ return openBlock(), createElementBlock("div", {
50
+ class: "celeste-progress-bar-wrapper",
51
+ "data-layout": _ctx.layout
52
+ }, [
53
+ _ctx.layout !== "bare" ? (openBlock(), createElementBlock("div", _hoisted_2, [
54
+ props.title && _ctx.layout !== "inline" ? (openBlock(), createElementBlock("span", _hoisted_3, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
55
+ createElementVNode("span", _hoisted_4, [
56
+ renderSlot(_ctx.$slots, "label", {}, () => [
57
+ createTextVNode(toDisplayString(progress.value) + "% ", 1)
58
+ ], true)
59
+ ])
60
+ ])) : createCommentVNode("", true),
61
+ createVNode(unref(By), mergeProps(unref(delegatedProps), {
62
+ class: unref(clsx)(
63
+ "celeste-progress-bar",
64
+ props.class
65
+ )
66
+ }), {
67
+ default: withCtx(() => [
68
+ createVNode(unref(Iy), {
69
+ class: "celeste-progress-bar-indicator",
70
+ "data-color": _ctx.color
71
+ }, null, 8, ["data-color"])
72
+ ]),
73
+ _: 1
74
+ }, 16, ["class"]),
75
+ _ctx.$slots.description && _ctx.layout === "default" ? (openBlock(), createElementBlock("div", _hoisted_5, [
76
+ renderSlot(_ctx.$slots, "description", {}, void 0, true)
77
+ ])) : createCommentVNode("", true)
78
+ ], 8, _hoisted_1);
79
+ };
80
+ }
81
+ });
82
+ const progressBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-850aadb2"]]);
83
+ export {
84
+ progressBar as default
85
+ };
@@ -0,0 +1,93 @@
1
+ import { defineComponent, useCssVars, computed, openBlock, createBlock, unref, mergeProps, withCtx, createVNode, createElementBlock, createElementVNode, renderSlot, createTextVNode, toDisplayString, createCommentVNode } from "vue";
2
+ import { useDelegatedProps } from "./use-delegated-props.js";
3
+ import { c as clsx } from "./chunks/clsx.js";
4
+ import { ak as By, al as Iy } from "./chunks/index.js";
5
+ import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
+ const _hoisted_1 = ["width", "height"];
7
+ const _hoisted_2 = ["cx", "cy", "r"];
8
+ const _hoisted_3 = ["cx", "cy", "r", "stroke-dasharray", "stroke-dashoffset"];
9
+ const _hoisted_4 = {
10
+ key: 0,
11
+ class: "celeste-progress-circle-label"
12
+ };
13
+ const STROKE_WIDTH = 6.4;
14
+ const _sfc_main = /* @__PURE__ */ defineComponent({
15
+ __name: "progress-circle",
16
+ props: {
17
+ modelValue: { default: 0 },
18
+ max: { default: 100 },
19
+ getValueLabel: {},
20
+ asChild: { type: Boolean },
21
+ as: {},
22
+ class: {},
23
+ size: { default: 80 }
24
+ },
25
+ setup(__props) {
26
+ useCssVars((_ctx) => ({
27
+ "433ff7ca": circleSize.value
28
+ }));
29
+ const props = __props;
30
+ const delegatedProps = useDelegatedProps(props, "class");
31
+ const radius = computed(() => (props.size - STROKE_WIDTH) / 2);
32
+ const circumference = computed(() => 2 * Math.PI * radius.value);
33
+ const progress = computed(() => {
34
+ if (props.max === 0)
35
+ return 0;
36
+ const value = Math.min(Math.max(props.modelValue ?? 0, 0), props.max);
37
+ return Math.round(value / props.max * 100);
38
+ });
39
+ const offset = computed(() => {
40
+ return circumference.value * (1 - progress.value / 100);
41
+ });
42
+ const circleSize = computed(() => `${props.size}px`);
43
+ return (_ctx, _cache) => {
44
+ return openBlock(), createBlock(unref(By), mergeProps(unref(delegatedProps), {
45
+ value: props.modelValue,
46
+ class: unref(clsx)("celeste-progress-circle", props.class),
47
+ as: "div"
48
+ }), {
49
+ default: withCtx(() => [
50
+ createVNode(unref(Iy), { "as-child": "" }, {
51
+ default: withCtx(() => [
52
+ (openBlock(), createElementBlock("svg", {
53
+ class: "celeste-progress-circle-svg",
54
+ width: props.size,
55
+ height: props.size
56
+ }, [
57
+ createElementVNode("circle", {
58
+ class: "celeste-progress-circle-track",
59
+ cx: props.size / 2,
60
+ cy: props.size / 2,
61
+ r: radius.value,
62
+ "stroke-width": STROKE_WIDTH,
63
+ fill: "transparent"
64
+ }, null, 8, _hoisted_2),
65
+ createElementVNode("circle", {
66
+ class: "celeste-progress-circle-indicator",
67
+ cx: props.size / 2,
68
+ cy: props.size / 2,
69
+ r: radius.value,
70
+ "stroke-width": STROKE_WIDTH,
71
+ fill: "transparent",
72
+ "stroke-dasharray": circumference.value,
73
+ "stroke-dashoffset": offset.value
74
+ }, null, 8, _hoisted_3)
75
+ ], 8, _hoisted_1))
76
+ ]),
77
+ _: 1
78
+ }),
79
+ props.size !== 48 ? (openBlock(), createElementBlock("div", _hoisted_4, [
80
+ renderSlot(_ctx.$slots, "default", {}, () => [
81
+ createTextVNode(toDisplayString(progress.value) + "% ", 1)
82
+ ], true)
83
+ ])) : createCommentVNode("", true)
84
+ ]),
85
+ _: 3
86
+ }, 16, ["value", "class"]);
87
+ };
88
+ }
89
+ });
90
+ const progressCircle = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-f8ba36bb"]]);
91
+ export {
92
+ progressCircle as default
93
+ };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, withCtx, createVNode } from "vue";
2
2
  import { c as clsx } from "./chunks/clsx.js";
3
- import { R as My, V as Vy } from "./chunks/index.js";
3
+ import { M as My, V as Vy } from "./chunks/index.js";
4
4
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
5
5
  const _sfc_main = /* @__PURE__ */ defineComponent({
6
6
  __name: "scroll-bar",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { P as sv } from "./chunks/index.js";
4
+ import { I as sv } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "segmented-control-item",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { x as xe, M as lv } from "./chunks/index.js";
4
+ import { x as xe, H as lv } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "segmented-control",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, withCtx, createVNode, mergeProps, renderSlot } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { x as xe, ak as zy, al as Ky, am as Xy } from "./chunks/index.js";
4
+ import { x as xe, am as zy, an as Ky, ao as Xy } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "select-content",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, createVNode, renderSlot, createElementVNode } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { an as jy, ao as Yy, ap as Uy } from "./chunks/index.js";
4
+ import { ap as jy, aq as Yy, ar as Uy } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "select-item",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot, createVNode, createElementVNode } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { aq as Ly, ar as eg } from "./chunks/index.js";
4
+ import { as as Ly, at as eg } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "select-trigger",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { as as Qy } from "./chunks/index.js";
4
+ import { au as Qy } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "select-value",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { L as bg } from "./chunks/index.js";
4
+ import { E as bg } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "tab-menu-content",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot, createElementBlock, createCommentVNode } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { A as At, J as Cg } from "./chunks/index.js";
4
+ import { A as At, D as Cg } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _hoisted_1 = {
7
7
  key: 0,
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot } from "vue";
2
2
  import { useDelegatedProps } from "./use-delegated-props.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { I as gg } from "./chunks/index.js";
4
+ import { C as gg } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "tab-menu-list",
@@ -1,5 +1,5 @@
1
1
  import { defineComponent, openBlock, createBlock, unref, mergeProps, withCtx, renderSlot } from "vue";
2
- import { x as xe, H as yg } from "./chunks/index.js";
2
+ import { x as xe, B as yg } from "./chunks/index.js";
3
3
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
4
4
  const _sfc_main = /* @__PURE__ */ defineComponent({
5
5
  __name: "tab-menu",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, ref, openBlock, createBlock, unref, withCtx, createVNode, mergeProps, renderSlot, createElementBlock, normalizeClass, createCommentVNode, createElementVNode, toDisplayString } from "vue";
2
2
  import CompactButton from "./compact-button.js";
3
3
  import { c as clsx } from "./chunks/clsx.js";
4
- import { x as xe, at as Lg, au as zg, av as Kg, aw as jg, ax as Hg, ay as Wg } from "./chunks/index.js";
4
+ import { x as xe, av as Lg, aw as zg, ax as Kg, ay as jg, az as Hg, aA as Wg } from "./chunks/index.js";
5
5
  import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
6
6
  const _hoisted_1 = { class: "celeste-tooltip-content-box" };
7
7
  const _hoisted_2 = {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@youcan/celeste",
3
3
  "type": "module",
4
- "version": "0.6.32",
4
+ "version": "0.6.34",
5
5
  "author": "YouCan <tech@youcan.shop>",
6
6
  "keywords": [
7
7
  "youcan",
@@ -43,8 +43,8 @@
43
43
  "radix-vue": "^1.9.12",
44
44
  "tinycolor2": "^1.6.0",
45
45
  "vue-sonner": "^2.0.2",
46
- "@youcan/celeste-icons": "0.6.32",
47
- "@youcan/celeste-tokens": "0.6.32"
46
+ "@youcan/celeste-icons": "0.6.34",
47
+ "@youcan/celeste-tokens": "0.6.34"
48
48
  },
49
49
  "devDependencies": {
50
50
  "@chromatic-com/storybook": "^4.0.0",
@@ -211,7 +211,6 @@ export interface SelectedType {
211
211
 
212
212
  <ComboboxContent
213
213
  v-if="!disabled"
214
- force-mount
215
214
  dismissable
216
215
  :avoid-collisions="true"
217
216
  class="celeste-dropdown-content"