@cck-ui/core 0.14.0 → 0.15.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/cjs/components/empty-state/empty-state.cjs +10 -2
- package/cjs/components/empty-state/empty-state.cjs.map +1 -1
- package/cjs/components/empty-state/empty-state.module.cjs.map +1 -1
- package/cjs/components/semi-circle-progress/index.cjs +14 -0
- package/cjs/components/semi-circle-progress/index.cjs.map +1 -0
- package/cjs/components/semi-circle-progress/semi-circle-progress.cjs +530 -0
- package/cjs/components/semi-circle-progress/semi-circle-progress.cjs.map +1 -0
- package/cjs/components/semi-circle-progress/semi-circle-progress.module.cjs +12 -0
- package/cjs/components/semi-circle-progress/semi-circle-progress.module.cjs.map +1 -0
- package/cjs/components/semi-circle-progress/semi-circle-progress.utils.cjs +26 -0
- package/cjs/components/semi-circle-progress/semi-circle-progress.utils.cjs.map +1 -0
- package/cjs/index.cjs +20 -17
- package/cjs/index.cjs.map +1 -1
- package/esm/components/empty-state/empty-state.mjs +10 -2
- package/esm/components/empty-state/empty-state.mjs.map +1 -1
- package/esm/components/empty-state/empty-state.module.mjs.map +1 -1
- package/esm/components/semi-circle-progress/index.mjs +11 -0
- package/esm/components/semi-circle-progress/index.mjs.map +1 -0
- package/esm/components/semi-circle-progress/semi-circle-progress.mjs +530 -0
- package/esm/components/semi-circle-progress/semi-circle-progress.mjs.map +1 -0
- package/esm/components/semi-circle-progress/semi-circle-progress.module.mjs +12 -0
- package/esm/components/semi-circle-progress/semi-circle-progress.module.mjs.map +1 -0
- package/esm/components/semi-circle-progress/semi-circle-progress.utils.mjs +26 -0
- package/esm/components/semi-circle-progress/semi-circle-progress.utils.mjs.map +1 -0
- package/esm/index.mjs +3 -1
- package/esm/index.mjs.map +1 -1
- package/lib/components/empty-state/empty-state.types.d.ts +4 -0
- package/lib/components/index.d.ts +1 -0
- package/lib/components/semi-circle-progress/index.d.ts +6 -0
- package/lib/components/semi-circle-progress/semi-circle-progress.types.d.ts +57 -0
- package/lib/components/semi-circle-progress/semi-circle-progress.utils.d.ts +7 -0
- package/package.json +1 -1
- package/styles/empty-state.css +1 -1
- package/styles/empty-state.layer.css +1 -1
- package/styles/semi-circle-progress.css +58 -0
- package/styles/semi-circle-progress.layer.css +59 -0
- package/styles.css +60 -1
- package/styles.layer.css +60 -1
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
const require_rem = require("../../core/utils/units-converters/rem.cjs");
|
|
3
|
+
const require_get_theme_color = require("../../core/config-provider/color-functions/get-theme-color/get-theme-color.cjs");
|
|
4
|
+
const require_create_vars_resolver = require("../../core/styles-api/create-vars-resolver/create-vars-resolver.cjs");
|
|
5
|
+
//#region packages/@cck-ui/core/src/components/semi-circle-progress/semi-circle-progress.utils.ts
|
|
6
|
+
function getRotation({ orientation, fillDirection }) {
|
|
7
|
+
if (orientation === "down") {
|
|
8
|
+
if (fillDirection === "right-to-left") return "rotate(180deg) rotateY(180deg)";
|
|
9
|
+
return "rotate(180deg)";
|
|
10
|
+
}
|
|
11
|
+
if (fillDirection === "left-to-right") return "rotateY(180deg)";
|
|
12
|
+
}
|
|
13
|
+
const varsResolver = require_create_vars_resolver.createVarsResolver((theme, { filledSegmentColor, emptySegmentColor, orientation, fillDirection, transitionDuration, thickness }) => ({ root: {
|
|
14
|
+
"--scp-empty-segment-color": emptySegmentColor ? require_get_theme_color.getThemeColor(emptySegmentColor, theme) : void 0,
|
|
15
|
+
"--scp-filled-segment-color": filledSegmentColor ? require_get_theme_color.getThemeColor(filledSegmentColor, theme) : void 0,
|
|
16
|
+
"--scp-rotation": getRotation({
|
|
17
|
+
orientation,
|
|
18
|
+
fillDirection
|
|
19
|
+
}),
|
|
20
|
+
"--scp-thickness": require_rem.rem(thickness),
|
|
21
|
+
"--scp-transition-duration": transitionDuration ? `${transitionDuration}ms` : void 0
|
|
22
|
+
} }));
|
|
23
|
+
//#endregion
|
|
24
|
+
exports.varsResolver = varsResolver;
|
|
25
|
+
|
|
26
|
+
//# sourceMappingURL=semi-circle-progress.utils.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"semi-circle-progress.utils.cjs","names":["createVarsResolver","getThemeColor","rem"],"sources":["../../../src/components/semi-circle-progress/semi-circle-progress.utils.ts"],"sourcesContent":["import { createVarsResolver, getThemeColor, rem } from '../../core'\nimport { SemiCircleProgressFactory, SemiCircleProgressProps } from './semi-circle-progress.types'\n\nfunction getRotation({\n orientation,\n fillDirection,\n}: Pick<SemiCircleProgressProps, 'orientation' | 'fillDirection'>) {\n if (orientation === 'down') {\n if (fillDirection === 'right-to-left') {\n return 'rotate(180deg) rotateY(180deg)'\n }\n return 'rotate(180deg)'\n }\n if (fillDirection === 'left-to-right') {\n return 'rotateY(180deg)'\n }\n\n return undefined\n}\n\nexport const varsResolver = createVarsResolver<SemiCircleProgressFactory>(\n (\n theme,\n {\n filledSegmentColor,\n emptySegmentColor,\n orientation,\n fillDirection,\n transitionDuration,\n thickness,\n }\n ) => ({\n root: {\n '--scp-empty-segment-color': emptySegmentColor\n ? getThemeColor(emptySegmentColor, theme)\n : undefined,\n '--scp-filled-segment-color': filledSegmentColor\n ? getThemeColor(filledSegmentColor, theme)\n : undefined,\n '--scp-rotation': getRotation({ orientation, fillDirection }),\n '--scp-thickness': rem(thickness),\n '--scp-transition-duration': transitionDuration ? `${transitionDuration}ms` : undefined,\n },\n })\n)\n"],"mappings":";;;;;AAGA,SAAS,YAAY,EACnB,aACA,iBACiE;CACjE,IAAI,gBAAgB,QAAQ;EAC1B,IAAI,kBAAkB,iBACpB,OAAO;EAET,OAAO;CACT;CACA,IAAI,kBAAkB,iBACpB,OAAO;AAIX;AAEA,MAAa,eAAeA,6BAAAA,oBAExB,OACA,EACE,oBACA,mBACA,aACA,eACA,oBACA,iBAEE,EACJ,MAAM;CACJ,6BAA6B,oBACzBC,wBAAAA,cAAc,mBAAmB,KAAK,IACtC,KAAA;CACJ,8BAA8B,qBAC1BA,wBAAAA,cAAc,oBAAoB,KAAK,IACvC,KAAA;CACJ,kBAAkB,YAAY;EAAE;EAAa;CAAc,CAAC;CAC5D,mBAAmBC,YAAAA,IAAI,SAAS;CAChC,6BAA6B,qBAAqB,GAAG,mBAAmB,MAAM,KAAA;AAChF,EACF,EACF"}
|
package/cjs/index.cjs
CHANGED
|
@@ -69,11 +69,12 @@ const require_index$12 = require("./components/empty-state/index.cjs");
|
|
|
69
69
|
const require_index$13 = require("./components/flex/index.cjs");
|
|
70
70
|
const require_index$14 = require("./components/grid/index.cjs");
|
|
71
71
|
const require_index$15 = require("./components/group/index.cjs");
|
|
72
|
-
const require_index$16 = require("./components/
|
|
73
|
-
const require_index$17 = require("./components/
|
|
74
|
-
const require_index$18 = require("./components/
|
|
75
|
-
const require_index$19 = require("./components/
|
|
76
|
-
const require_index$20 = require("./components/
|
|
72
|
+
const require_index$16 = require("./components/semi-circle-progress/index.cjs");
|
|
73
|
+
const require_index$17 = require("./components/simple-grid/index.cjs");
|
|
74
|
+
const require_index$18 = require("./components/space/index.cjs");
|
|
75
|
+
const require_index$19 = require("./components/splitter/index.cjs");
|
|
76
|
+
const require_index$20 = require("./components/stack/index.cjs");
|
|
77
|
+
const require_index$21 = require("./components/text/index.cjs");
|
|
77
78
|
let _vue_shared = require("@vue/shared");
|
|
78
79
|
//#region packages/@cck-ui/core/src/index.ts
|
|
79
80
|
const INSTALLED_KEY = Symbol("INSTALLED_KEY");
|
|
@@ -98,12 +99,13 @@ const components = [
|
|
|
98
99
|
require_index$14.CGrid,
|
|
99
100
|
require_index$15.CGroup,
|
|
100
101
|
require_index$7.CLoader,
|
|
101
|
-
require_index$16.
|
|
102
|
-
require_index$17.
|
|
103
|
-
require_index$18.
|
|
104
|
-
require_index$
|
|
105
|
-
require_index$19.
|
|
106
|
-
require_index$20.
|
|
102
|
+
require_index$16.CSemiCircleProgress,
|
|
103
|
+
require_index$17.CSimpleGrid,
|
|
104
|
+
require_index$18.CSpace,
|
|
105
|
+
require_index$19.CSplitter,
|
|
106
|
+
require_index$19.CSplitterPane,
|
|
107
|
+
require_index$20.CStack,
|
|
108
|
+
require_index$21.CText,
|
|
107
109
|
require_index$8.CTransition,
|
|
108
110
|
require_index$3.UnstyledButton
|
|
109
111
|
];
|
|
@@ -137,12 +139,13 @@ exports.CGrid = require_index$14.CGrid;
|
|
|
137
139
|
exports.CGroup = require_index$15.CGroup;
|
|
138
140
|
exports.CLoader = require_index$7.CLoader;
|
|
139
141
|
exports.CONFIG_KEY = require_config_provider_types.CONFIG_KEY;
|
|
140
|
-
exports.
|
|
141
|
-
exports.
|
|
142
|
-
exports.
|
|
143
|
-
exports.
|
|
144
|
-
exports.
|
|
145
|
-
exports.
|
|
142
|
+
exports.CSemiCircleProgress = require_index$16.CSemiCircleProgress;
|
|
143
|
+
exports.CSimpleGrid = require_index$17.CSimpleGrid;
|
|
144
|
+
exports.CSpace = require_index$18.CSpace;
|
|
145
|
+
exports.CSplitter = require_index$19.CSplitter;
|
|
146
|
+
exports.CSplitterPane = require_index$19.CSplitterPane;
|
|
147
|
+
exports.CStack = require_index$20.CStack;
|
|
148
|
+
exports.CText = require_index$21.CText;
|
|
146
149
|
exports.CTransition = require_index$8.CTransition;
|
|
147
150
|
exports.CckConfigProvider = require_index$1.CckConfigProvider;
|
|
148
151
|
exports.CckUI = CckUI;
|
package/cjs/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","names":["CckConfigProvider","CBox","CAlert","CAspectRatio","CButton","CButtonGroup","CButtonGroupSection","CCenter","CCloseButton","CCol","CContainer","CEmptyState","CEmptyStateActions","CEmptyStateDescription","CEmptyStateIndicator","CEmptyStateTitle","CFlex","CGrid","CGroup","CLoader","CSimpleGrid","CSpace","CSplitter","CSplitterPane","CStack","CText","CTransition","UnstyledButton"],"sources":["../src/index.ts"],"sourcesContent":["import type { App, Plugin } from 'vue'\nimport {\n CAlert,\n CAspectRatio,\n CButton,\n CButtonGroup,\n CButtonGroupSection,\n CCenter,\n CCloseButton,\n CCol,\n CContainer,\n CEmptyState,\n CEmptyStateActions,\n CEmptyStateDescription,\n CEmptyStateIndicator,\n CEmptyStateTitle,\n CFlex,\n CGrid,\n CGroup,\n CLoader,\n CSimpleGrid,\n CSpace,\n CSplitter,\n CSplitterPane,\n CStack,\n CText,\n CTransition,\n UnstyledButton,\n} from './components'\nimport { CckConfigProvider, CBox } from './core'\n\nconst INSTALLED_KEY = Symbol('INSTALLED_KEY')\n\nconst components = [\n CckConfigProvider,\n CBox,\n CAlert,\n CAspectRatio,\n CButton,\n CButtonGroup,\n CButtonGroupSection,\n CCenter,\n CCloseButton,\n CCol,\n CContainer,\n CEmptyState,\n CEmptyStateActions,\n CEmptyStateDescription,\n CEmptyStateIndicator,\n CEmptyStateTitle,\n CFlex,\n CGrid,\n CGroup,\n CLoader,\n CSimpleGrid,\n CSpace,\n CSplitter,\n CSplitterPane,\n CStack,\n CText,\n CTransition,\n UnstyledButton,\n]\n\nconst CckUI: Plugin = {\n install(app: App) {\n if ((app as any)[INSTALLED_KEY]) {\n return\n }\n ;(app as any)[INSTALLED_KEY] = true\n components.forEach((c) => {\n if (c.name) {\n app.component(c.name, c)\n }\n })\n },\n}\n\nexport default CckUI\nexport { CckUI }\n\nexport * from './components'\nexport * from './core'\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.cjs","names":["CckConfigProvider","CBox","CAlert","CAspectRatio","CButton","CButtonGroup","CButtonGroupSection","CCenter","CCloseButton","CCol","CContainer","CEmptyState","CEmptyStateActions","CEmptyStateDescription","CEmptyStateIndicator","CEmptyStateTitle","CFlex","CGrid","CGroup","CLoader","CSemiCircleProgress","CSimpleGrid","CSpace","CSplitter","CSplitterPane","CStack","CText","CTransition","UnstyledButton"],"sources":["../src/index.ts"],"sourcesContent":["import type { App, Plugin } from 'vue'\nimport {\n CAlert,\n CAspectRatio,\n CButton,\n CButtonGroup,\n CButtonGroupSection,\n CCenter,\n CCloseButton,\n CCol,\n CContainer,\n CEmptyState,\n CEmptyStateActions,\n CEmptyStateDescription,\n CEmptyStateIndicator,\n CEmptyStateTitle,\n CFlex,\n CGrid,\n CGroup,\n CLoader,\n CSemiCircleProgress,\n CSimpleGrid,\n CSpace,\n CSplitter,\n CSplitterPane,\n CStack,\n CText,\n CTransition,\n UnstyledButton,\n} from './components'\nimport { CckConfigProvider, CBox } from './core'\n\nconst INSTALLED_KEY = Symbol('INSTALLED_KEY')\n\nconst components = [\n CckConfigProvider,\n CBox,\n CAlert,\n CAspectRatio,\n CButton,\n CButtonGroup,\n CButtonGroupSection,\n CCenter,\n CCloseButton,\n CCol,\n CContainer,\n CEmptyState,\n CEmptyStateActions,\n CEmptyStateDescription,\n CEmptyStateIndicator,\n CEmptyStateTitle,\n CFlex,\n CGrid,\n CGroup,\n CLoader,\n CSemiCircleProgress,\n CSimpleGrid,\n CSpace,\n CSplitter,\n CSplitterPane,\n CStack,\n CText,\n CTransition,\n UnstyledButton,\n]\n\nconst CckUI: Plugin = {\n install(app: App) {\n if ((app as any)[INSTALLED_KEY]) {\n return\n }\n ;(app as any)[INSTALLED_KEY] = true\n components.forEach((c) => {\n if (c.name) {\n app.component(c.name, c)\n }\n })\n },\n}\n\nexport default CckUI\nexport { CckUI }\n\nexport * from './components'\nexport * from './core'\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgCA,MAAM,gBAAgB,OAAO,eAAe;AAE5C,MAAM,aAAa;CACjBA,gBAAAA;CACAC,gBAAAA;CACAC,gBAAAA;CACAC,gBAAAA;CACAC,gBAAAA;CACAC,gBAAAA;CACAC,gBAAAA;CACAC,iBAAAA;CACAC,gBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,gBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,iBAAAA;CACAC,gBAAAA;CACAC,gBAAAA;AACF;AAEA,MAAM,QAAgB,EACpB,QAAQ,KAAU;CAChB,IAAK,IAAY,gBACf;CAED,IAAa,iBAAiB;CAC/B,WAAW,SAAS,MAAM;EACxB,IAAI,EAAE,MACJ,IAAI,UAAU,EAAE,MAAM,CAAC;CAE3B,CAAC;AACH,EACF"}
|
|
@@ -32,6 +32,10 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
32
32
|
type: null,
|
|
33
33
|
required: false
|
|
34
34
|
},
|
|
35
|
+
order: {
|
|
36
|
+
type: Number,
|
|
37
|
+
required: false
|
|
38
|
+
},
|
|
35
39
|
withIndicatorBackground: {
|
|
36
40
|
type: Boolean,
|
|
37
41
|
required: false
|
|
@@ -346,6 +350,7 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
346
350
|
"align",
|
|
347
351
|
"variant",
|
|
348
352
|
"color",
|
|
353
|
+
"order",
|
|
349
354
|
"withIndicatorBackground",
|
|
350
355
|
"mod",
|
|
351
356
|
"attributes"
|
|
@@ -427,10 +432,13 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
427
432
|
_: 3
|
|
428
433
|
})) : createCommentVNode("v-if", true), $setup.hasBodyContent ? (openBlock(), createBlock($setup["CBox"], normalizeProps(mergeProps({ key: 1 }, $setup.bodyAttrs)), {
|
|
429
434
|
default: withCtx(() => [
|
|
430
|
-
_ctx.$slots.title ? (openBlock(), createBlock($setup["EmptyStateTitle"], {
|
|
435
|
+
_ctx.$slots.title ? (openBlock(), createBlock($setup["EmptyStateTitle"], {
|
|
436
|
+
key: 0,
|
|
437
|
+
order: $setup.props.order
|
|
438
|
+
}, {
|
|
431
439
|
default: withCtx(() => [renderSlot(_ctx.$slots, "title")]),
|
|
432
440
|
_: 3
|
|
433
|
-
})) : createCommentVNode("v-if", true),
|
|
441
|
+
}, 8, ["order"])) : createCommentVNode("v-if", true),
|
|
434
442
|
_ctx.$slots.description ? (openBlock(), createBlock($setup["EmptyStateDescription"], { key: 1 }, {
|
|
435
443
|
default: withCtx(() => [renderSlot(_ctx.$slots, "description")]),
|
|
436
444
|
_: 3
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"empty-state.mjs","names":[],"sources":["../../../src/components/empty-state/empty-state.vue"],"sourcesContent":["<template>\n <c-box ref=\"_root\" v-bind=\"mergedRootAttrs\" :variant=\"props.variant\">\n <empty-state-indicator v-if=\"$slots.icon\">\n <slot name=\"icon\" />\n </empty-state-indicator>\n <c-box v-if=\"hasBodyContent\" v-bind=\"bodyAttrs\">\n <empty-state-title v-if=\"$slots.title\">\n <slot name=\"title\" />\n </empty-state-title>\n <empty-state-description v-if=\"$slots.description\">\n <slot name=\"description\" />\n </empty-state-description>\n <slot />\n <empty-state-actions v-if=\"$slots.actions\">\n <slot name=\"actions\" />\n </empty-state-actions>\n </c-box>\n </c-box>\n</template>\n\n<script setup lang=\"ts\">\nimport { computed, ref, useAttrs, useSlots } from 'vue'\nimport { CBox, useComponentProps, useStyles } from '../../core'\nimport { EmptyStateFactory, EmptyStateProps } from './empty-state.types'\nimport classes from './empty-state.module.css'\nimport { varsResolver } from './empty-state.utils'\nimport { provideEmptyStateContext } from './empty-state.context'\nimport EmptyStateActions from './empty-state-actions/empty-state-actions.vue'\nimport EmptyStateDescription from './empty-state-description/empty-state-description.vue'\nimport EmptyStateIndicator from './empty-state-indicator/empty-state-indicator.vue'\nimport EmptyStateTitle from './empty-state-title/empty-state-title.vue'\n\ndefineOptions({\n name: 'CEmptyState',\n})\n\ndefineSlots<{\n actions: any\n default: any\n description: any\n icon: any\n title: any\n}>()\n\nconst _root = ref<InstanceType<typeof CBox> | null>(null)\n\nconst attrs = useAttrs()\nconst slots = useSlots()\n\nconst rawProps = defineProps<EmptyStateProps>()\n\nconst defaultProps = {\n size: 'md',\n align: 'center',\n} satisfies Partial<EmptyStateProps>\n\nconst props = useComponentProps({\n component: 'CEmptyState',\n defaultProps,\n props: rawProps,\n})\n\nconst knownProps = [\n 'classNames',\n 'className',\n 'style',\n 'styles',\n 'unstyled',\n 'vars',\n 'align',\n 'variant',\n 'color',\n 'withIndicatorBackground',\n 'mod',\n 'attributes',\n]\n\nconst modList = computed(() => [\n {\n align: props.value.align,\n },\n])\n\nconst getStyles = useStyles<EmptyStateFactory>({\n name: 'EmptyState',\n classes,\n props: { ...props.value, ...attrs } as EmptyStateProps,\n className: props.value.className,\n style: props.value.style,\n classNames: props.value.classNames,\n styles: props.value.styles,\n unstyled: props.value.unstyled,\n attributes: props.value.attributes,\n vars: props.value.vars,\n varsResolver,\n})\n\nconst withIndicatorBackground = computed(\n () => props.value.withIndicatorBackground || !!props.value.variant\n)\n\nprovideEmptyStateContext({\n getStyles,\n withIndicatorBackground,\n})\n\nconst hasBodyContent = computed(() => {\n return !!(slots.actions || slots.default || slots.description || slots.title)\n})\n\nconst rootAttrs = computed(() => getStyles('root', { variant: props.value.variant }))\nconst bodyAttrs = computed(() => getStyles('body'))\n\nconst mergedRootAttrs = computed(() => {\n const others: Record<string, any> = {}\n const propsValue = props.value\n for (const key in propsValue) {\n if (!knownProps.includes(key)) {\n others[key] = propsValue[key as keyof typeof propsValue]\n }\n }\n const userMod = props.value.mod\n const mergedMod = [\n ...(Array.isArray(userMod) ? userMod : [userMod].filter(Boolean)),\n ...(modList.value || []),\n ]\n return { ...others, mod: mergedMod, ...rootAttrs.value }\n})\n\ndefineExpose({\n root: computed(() => _root.value?.root ?? null),\n})\n</script>\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"empty-state.mjs","names":[],"sources":["../../../src/components/empty-state/empty-state.vue"],"sourcesContent":["<template>\n <c-box ref=\"_root\" v-bind=\"mergedRootAttrs\" :variant=\"props.variant\">\n <empty-state-indicator v-if=\"$slots.icon\">\n <slot name=\"icon\" />\n </empty-state-indicator>\n <c-box v-if=\"hasBodyContent\" v-bind=\"bodyAttrs\">\n <empty-state-title v-if=\"$slots.title\" :order=\"props.order\">\n <slot name=\"title\" />\n </empty-state-title>\n <empty-state-description v-if=\"$slots.description\">\n <slot name=\"description\" />\n </empty-state-description>\n <slot />\n <empty-state-actions v-if=\"$slots.actions\">\n <slot name=\"actions\" />\n </empty-state-actions>\n </c-box>\n </c-box>\n</template>\n\n<script setup lang=\"ts\">\nimport { computed, ref, useAttrs, useSlots } from 'vue'\nimport { CBox, useComponentProps, useStyles } from '../../core'\nimport { EmptyStateFactory, EmptyStateProps } from './empty-state.types'\nimport classes from './empty-state.module.css'\nimport { varsResolver } from './empty-state.utils'\nimport { provideEmptyStateContext } from './empty-state.context'\nimport EmptyStateActions from './empty-state-actions/empty-state-actions.vue'\nimport EmptyStateDescription from './empty-state-description/empty-state-description.vue'\nimport EmptyStateIndicator from './empty-state-indicator/empty-state-indicator.vue'\nimport EmptyStateTitle from './empty-state-title/empty-state-title.vue'\n\ndefineOptions({\n name: 'CEmptyState',\n})\n\ndefineSlots<{\n actions: any\n default: any\n description: any\n icon: any\n title: any\n}>()\n\nconst _root = ref<InstanceType<typeof CBox> | null>(null)\n\nconst attrs = useAttrs()\nconst slots = useSlots()\n\nconst rawProps = defineProps<EmptyStateProps>()\n\nconst defaultProps = {\n size: 'md',\n align: 'center',\n} satisfies Partial<EmptyStateProps>\n\nconst props = useComponentProps({\n component: 'CEmptyState',\n defaultProps,\n props: rawProps,\n})\n\nconst knownProps = [\n 'classNames',\n 'className',\n 'style',\n 'styles',\n 'unstyled',\n 'vars',\n 'align',\n 'variant',\n 'color',\n 'order',\n 'withIndicatorBackground',\n 'mod',\n 'attributes',\n]\n\nconst modList = computed(() => [\n {\n align: props.value.align,\n },\n])\n\nconst getStyles = useStyles<EmptyStateFactory>({\n name: 'EmptyState',\n classes,\n props: { ...props.value, ...attrs } as EmptyStateProps,\n className: props.value.className,\n style: props.value.style,\n classNames: props.value.classNames,\n styles: props.value.styles,\n unstyled: props.value.unstyled,\n attributes: props.value.attributes,\n vars: props.value.vars,\n varsResolver,\n})\n\nconst withIndicatorBackground = computed(\n () => props.value.withIndicatorBackground || !!props.value.variant\n)\n\nprovideEmptyStateContext({\n getStyles,\n withIndicatorBackground,\n})\n\nconst hasBodyContent = computed(() => {\n return !!(slots.actions || slots.default || slots.description || slots.title)\n})\n\nconst rootAttrs = computed(() => getStyles('root', { variant: props.value.variant }))\nconst bodyAttrs = computed(() => getStyles('body'))\n\nconst mergedRootAttrs = computed(() => {\n const others: Record<string, any> = {}\n const propsValue = props.value\n for (const key in propsValue) {\n if (!knownProps.includes(key)) {\n others[key] = propsValue[key as keyof typeof propsValue]\n }\n }\n const userMod = props.value.mod\n const mergedMod = [\n ...(Array.isArray(userMod) ? userMod : [userMod].filter(Boolean)),\n ...(modList.value || []),\n ]\n return { ...others, mod: mergedMod, ...rootAttrs.value }\n})\n\ndefineExpose({\n root: computed(() => _root.value?.root ?? null),\n})\n</script>\n"],"mappings":"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"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"empty-state.module.mjs","names":[],"sources":["../../../src/components/empty-state/empty-state.module.css"],"sourcesContent":[".root {\n --empty-state-indicator-size-xs: 32px;\n --empty-state-indicator-size-sm: 40px;\n --empty-state-indicator-size-md: 48px;\n --empty-state-indicator-size-lg: 60px;\n --empty-state-indicator-size-xl: 72px;\n\n --empty-state-gap-xs: 6px;\n --empty-state-gap-sm: 8px;\n --empty-state-gap-md: 10px;\n --empty-state-gap-lg: 12px;\n --empty-state-gap-xl: 16px;\n\n --empty-state-title-fz-xs: var(--c-font-size-sm);\n --empty-state-title-fz-sm: var(--c-font-size-md);\n --empty-state-title-fz-md: var(--c-font-size-lg);\n --empty-state-title-fz-lg: var(--c-font-size-xl);\n --empty-state-title-fz-xl: calc(var(--c-font-size-xl) * 1.2);\n\n --empty-state-description-fz-xs: var(--c-font-size-xs);\n --empty-state-description-fz-sm: var(--c-font-size-sm);\n --empty-state-description-fz-md: var(--c-font-size-sm);\n --empty-state-description-fz-lg: var(--c-font-size-md);\n --empty-state-description-fz-xl: var(--c-font-size-lg);\n\n display: flex;\n gap: var(--empty-state-gap, var(--empty-state-gap-md));\n\n &[data-align='center'] {\n flex-direction: column;\n align-items: center;\n }\n\n &[data-align='left'] {\n flex-direction: row;\n align-items: flex-start;\n }\n\n &[data-align='right'] {\n flex-direction: row-reverse;\n align-items: flex-start;\n }\n}\n\n.body {\n display: flex;\n flex-direction: column;\n gap: var(--empty-state-gap, var(--empty-state-gap-md));\n min-width: 0;\n\n [data-align='center'] > & {\n align-items: center;\n text-align: center;\n }\n\n [data-align='left'] > & {\n align-items: flex-start;\n text-align: left;\n }\n\n [data-align='right'] > & {\n align-items: flex-end;\n text-align: right;\n }\n}\n\n.indicator {\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n color: var(--
|
|
1
|
+
{"version":3,"file":"empty-state.module.mjs","names":[],"sources":["../../../src/components/empty-state/empty-state.module.css"],"sourcesContent":[".root {\n --empty-state-indicator-size-xs: 32px;\n --empty-state-indicator-size-sm: 40px;\n --empty-state-indicator-size-md: 48px;\n --empty-state-indicator-size-lg: 60px;\n --empty-state-indicator-size-xl: 72px;\n\n --empty-state-gap-xs: 6px;\n --empty-state-gap-sm: 8px;\n --empty-state-gap-md: 10px;\n --empty-state-gap-lg: 12px;\n --empty-state-gap-xl: 16px;\n\n --empty-state-title-fz-xs: var(--c-font-size-sm);\n --empty-state-title-fz-sm: var(--c-font-size-md);\n --empty-state-title-fz-md: var(--c-font-size-lg);\n --empty-state-title-fz-lg: var(--c-font-size-xl);\n --empty-state-title-fz-xl: calc(var(--c-font-size-xl) * 1.2);\n\n --empty-state-description-fz-xs: var(--c-font-size-xs);\n --empty-state-description-fz-sm: var(--c-font-size-sm);\n --empty-state-description-fz-md: var(--c-font-size-sm);\n --empty-state-description-fz-lg: var(--c-font-size-md);\n --empty-state-description-fz-xl: var(--c-font-size-lg);\n\n display: flex;\n gap: var(--empty-state-gap, var(--empty-state-gap-md));\n\n &[data-align='center'] {\n flex-direction: column;\n align-items: center;\n }\n\n &[data-align='left'] {\n flex-direction: row;\n align-items: flex-start;\n }\n\n &[data-align='right'] {\n flex-direction: row-reverse;\n align-items: flex-start;\n }\n}\n\n.body {\n display: flex;\n flex-direction: column;\n gap: var(--empty-state-gap, var(--empty-state-gap-md));\n min-width: 0;\n\n [data-align='center'] > & {\n align-items: center;\n text-align: center;\n }\n\n [data-align='left'] > & {\n align-items: flex-start;\n text-align: left;\n }\n\n [data-align='right'] > & {\n align-items: flex-end;\n text-align: right;\n }\n}\n\n.indicator {\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n color: var(--empty-state-indicator-color, var(--c-color-dimmed));\n font-size: var(--empty-state-indicator-size, var(--empty-state-indicator-size-md));\n line-height: 1;\n\n & > svg {\n width: 1em;\n height: 1em;\n }\n\n &[data-with-background] {\n @mixin light {\n --empty-state-indicator-default-bg: var(--c-color-gray-1);\n }\n\n @mixin dark {\n --empty-state-indicator-default-bg: var(--c-color-dark-6);\n }\n\n width: 2em;\n height: 2em;\n border-radius: 1000px;\n background-color: var(--empty-state-indicator-bg, var(--empty-state-indicator-default-bg));\n }\n}\n\n.title {\n font-size: var(--empty-state-title-fz, var(--empty-state-title-fz-md));\n font-weight: 600;\n line-height: 1.3;\n color: var(--c-color-bright);\n margin: 0;\n text-wrap: balance;\n}\n\n.description {\n font-size: var(--empty-state-description-fz, var(--empty-state-description-fz-md));\n line-height: 1.55;\n color: var(--c-color-dimmed);\n margin: 0;\n max-width: 32rem;\n text-wrap: pretty;\n}\n\n.actions {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n gap: var(--c-spacing-sm);\n}\n"],"mappings":";;AAAA,IAAA,6BAAe;CAAC,QAAO;CAAa,QAAO;CAAa,aAAY;CAAY,SAAQ;CAAa,eAAc;CAAa,WAAU;AAAY"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { withInstall } from "../../core/utils/vue/install.mjs";
|
|
3
|
+
import { withClasses, withExtend, withPropsFactory, withVarsResolver } from "../../core/utils/vue/statics.mjs";
|
|
4
|
+
import semi_circle_progress_module_default from "./semi-circle-progress.module.mjs";
|
|
5
|
+
import { varsResolver } from "./semi-circle-progress.utils.mjs";
|
|
6
|
+
import semi_circle_progress_default from "./semi-circle-progress.mjs";
|
|
7
|
+
const CSemiCircleProgress = withInstall(withPropsFactory(withExtend(withVarsResolver(withClasses(semi_circle_progress_default, semi_circle_progress_module_default), varsResolver))));
|
|
8
|
+
//#endregion
|
|
9
|
+
export { CSemiCircleProgress, CSemiCircleProgress as default };
|
|
10
|
+
|
|
11
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","names":["SemiCircleProgress","classes"],"sources":["../../../src/components/semi-circle-progress/index.ts"],"sourcesContent":["import SemiCircleProgress from './semi-circle-progress.vue'\nimport classes from './semi-circle-progress.module.css'\nimport { varsResolver } from './semi-circle-progress.utils'\nimport {\n SFCWithInstallAndClasses,\n withClasses,\n withExtend,\n withInstall,\n withPropsFactory,\n withVarsResolver,\n} from '../../core'\n\nconst SemiCircleProgressWithStatic = withPropsFactory(\n withExtend(withVarsResolver(withClasses(SemiCircleProgress, classes), varsResolver))\n)\n\nexport const CSemiCircleProgress: SFCWithInstallAndClasses<\n typeof SemiCircleProgress,\n typeof classes\n> = withInstall(SemiCircleProgressWithStatic)\n\nexport default CSemiCircleProgress\n\nexport * from './semi-circle-progress.types'\n"],"mappings":";;;;;;AAgBA,MAAa,sBAGT,YAPiC,iBACnC,WAAW,iBAAiB,YAAYA,8BAAoBC,mCAAO,GAAG,YAAY,CAAC,CAMrE,CAA4B"}
|