hzzt-plus 1.0.1 → 1.0.3
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/attributes.json +1 -0
- package/dist/index.full.js +3204 -304
- package/dist/index.full.min.js +16 -16
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +18 -18
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +3199 -306
- package/dist/locale/en.js +1 -1
- package/dist/locale/en.min.js +1 -1
- package/dist/locale/en.min.mjs +1 -1
- package/dist/locale/en.mjs +1 -1
- package/dist/locale/zh-cn.js +1 -1
- package/dist/locale/zh-cn.min.js +1 -1
- package/dist/locale/zh-cn.min.mjs +1 -1
- package/dist/locale/zh-cn.mjs +1 -1
- package/es/component.mjs +5 -1
- package/es/component.mjs.map +1 -1
- package/es/components/collapse/index.mjs +2 -2
- package/es/components/collapse/src/collapse.mjs +67 -0
- package/es/components/collapse/src/collapse.mjs.map +1 -1
- package/es/components/collapse/src/collapse2.mjs +0 -67
- package/es/components/collapse/src/collapse2.mjs.map +1 -1
- package/es/components/dropdown/index.d.ts +5 -5
- package/es/components/dropdown/src/index.mjs +3 -2
- package/es/components/dropdown/src/index.mjs.map +1 -1
- package/es/components/dropdown/src/index.vue.d.ts +6 -5
- package/es/components/index.d.ts +2 -0
- package/es/components/index.mjs +4 -0
- package/es/components/index.mjs.map +1 -1
- package/es/components/input-range/index.d.ts +5 -0
- package/es/components/input-range/index.mjs +9 -0
- package/es/components/input-range/index.mjs.map +1 -0
- package/es/components/input-range/src/input-range.d.ts +24 -0
- package/es/components/input-range/src/input-range.mjs +31 -0
- package/es/components/input-range/src/input-range.mjs.map +1 -0
- package/es/components/input-range/src/input-range.vue.d.ts +86 -0
- package/es/components/input-range/src/input-range2.mjs +81 -0
- package/es/components/input-range/src/input-range2.mjs.map +1 -0
- package/es/components/input-range/style/css.d.ts +2 -0
- package/es/components/input-range/style/css.mjs +3 -0
- package/es/components/input-range/style/css.mjs.map +1 -0
- package/es/components/input-range/style/index.d.ts +2 -0
- package/es/components/input-range/style/index.mjs +3 -0
- package/es/components/input-range/style/index.mjs.map +1 -0
- package/es/components/page-size/index.d.ts +1 -1
- package/es/components/page-size/src/index.mjs.map +1 -1
- package/es/components/page-size/src/index.vue.d.ts +1 -1
- package/es/components/scan/src/scan2.mjs.map +1 -1
- package/es/components/select-input/index.d.ts +10 -10
- package/es/components/select-input/src/select-input.d.ts +3 -3
- package/es/components/select-input/src/select-input.mjs.map +1 -1
- package/es/components/select-input/src/select-input.vue.d.ts +10 -10
- package/es/components/select-textarea/index.d.ts +5 -0
- package/es/components/select-textarea/index.mjs +9 -0
- package/es/components/select-textarea/index.mjs.map +1 -0
- package/es/components/select-textarea/src/select-textarea.d.ts +26 -0
- package/es/components/select-textarea/src/select-textarea.mjs +36 -0
- package/es/components/select-textarea/src/select-textarea.mjs.map +1 -0
- package/es/components/select-textarea/src/select-textarea.vue.d.ts +13075 -0
- package/es/components/select-textarea/src/select-textarea2.mjs +105 -0
- package/es/components/select-textarea/src/select-textarea2.mjs.map +1 -0
- package/es/components/select-textarea/style/css.d.ts +2 -0
- package/es/components/select-textarea/style/css.mjs +3 -0
- package/es/components/select-textarea/style/css.mjs.map +1 -0
- package/es/components/select-textarea/style/index.d.ts +2 -0
- package/es/components/select-textarea/style/index.mjs +3 -0
- package/es/components/select-textarea/style/index.mjs.map +1 -0
- package/es/components/title/src/title2.mjs +1 -2
- package/es/components/title/src/title2.mjs.map +1 -1
- package/es/hooks/index.d.ts +1 -0
- package/es/hooks/index.mjs +1 -0
- package/es/hooks/index.mjs.map +1 -1
- package/es/hooks/use-cursor/index.d.ts +1 -0
- package/es/hooks/use-cursor/index.mjs +14 -0
- package/es/hooks/use-cursor/index.mjs.map +1 -0
- package/es/index.mjs +5 -0
- package/es/index.mjs.map +1 -1
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/global.d.ts +2 -0
- package/lib/component.js +5 -1
- package/lib/component.js.map +1 -1
- package/lib/components/collapse/index.js +2 -2
- package/lib/components/collapse/src/collapse.js +70 -0
- package/lib/components/collapse/src/collapse.js.map +1 -1
- package/lib/components/collapse/src/collapse2.js +0 -70
- package/lib/components/collapse/src/collapse2.js.map +1 -1
- package/lib/components/dropdown/index.d.ts +5 -5
- package/lib/components/dropdown/src/index.js +3 -2
- package/lib/components/dropdown/src/index.js.map +1 -1
- package/lib/components/dropdown/src/index.vue.d.ts +6 -5
- package/lib/components/index.d.ts +2 -0
- package/lib/components/index.js +10 -0
- package/lib/components/index.js.map +1 -1
- package/lib/components/input-range/index.d.ts +5 -0
- package/lib/components/input-range/index.js +16 -0
- package/lib/components/input-range/index.js.map +1 -0
- package/lib/components/input-range/src/input-range.d.ts +24 -0
- package/lib/components/input-range/src/input-range.js +36 -0
- package/lib/components/input-range/src/input-range.js.map +1 -0
- package/lib/components/input-range/src/input-range.vue.d.ts +86 -0
- package/lib/components/input-range/src/input-range2.js +85 -0
- package/lib/components/input-range/src/input-range2.js.map +1 -0
- package/lib/components/input-range/style/css.d.ts +2 -0
- package/lib/components/input-range/style/css.js +6 -0
- package/lib/components/input-range/style/css.js.map +1 -0
- package/lib/components/input-range/style/index.d.ts +2 -0
- package/lib/components/input-range/style/index.js +6 -0
- package/lib/components/input-range/style/index.js.map +1 -0
- package/lib/components/page-size/index.d.ts +1 -1
- package/lib/components/page-size/src/index.js.map +1 -1
- package/lib/components/page-size/src/index.vue.d.ts +1 -1
- package/lib/components/scan/src/scan2.js.map +1 -1
- package/lib/components/select-input/index.d.ts +10 -10
- package/lib/components/select-input/src/select-input.d.ts +3 -3
- package/lib/components/select-input/src/select-input.js.map +1 -1
- package/lib/components/select-input/src/select-input.vue.d.ts +10 -10
- package/lib/components/select-textarea/index.d.ts +5 -0
- package/lib/components/select-textarea/index.js +16 -0
- package/lib/components/select-textarea/index.js.map +1 -0
- package/lib/components/select-textarea/src/select-textarea.d.ts +26 -0
- package/lib/components/select-textarea/src/select-textarea.js +41 -0
- package/lib/components/select-textarea/src/select-textarea.js.map +1 -0
- package/lib/components/select-textarea/src/select-textarea.vue.d.ts +13075 -0
- package/lib/components/select-textarea/src/select-textarea2.js +109 -0
- package/lib/components/select-textarea/src/select-textarea2.js.map +1 -0
- package/lib/components/select-textarea/style/css.d.ts +2 -0
- package/lib/components/select-textarea/style/css.js +6 -0
- package/lib/components/select-textarea/style/css.js.map +1 -0
- package/lib/components/select-textarea/style/index.d.ts +2 -0
- package/lib/components/select-textarea/style/index.js +6 -0
- package/lib/components/select-textarea/style/index.js.map +1 -0
- package/lib/components/title/src/title2.js +1 -2
- package/lib/components/title/src/title2.js.map +1 -1
- package/lib/hooks/index.d.ts +1 -0
- package/lib/hooks/index.js +2 -0
- package/lib/hooks/index.js.map +1 -1
- package/lib/hooks/use-cursor/index.d.ts +1 -0
- package/lib/hooks/use-cursor/index.js +18 -0
- package/lib/hooks/use-cursor/index.js.map +1 -0
- package/lib/index.js +40 -28
- package/lib/index.js.map +1 -1
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/package.json +1 -1
- package/tags.json +1 -0
- package/theme/hzzt-input-range.css +0 -0
- package/theme/hzzt-select-textarea.css +0 -0
- package/theme/src/index.scss +2 -0
- package/theme/src/input-range.scss +0 -0
- package/theme/src/select-textarea.scss +0 -0
- package/web-types.json +1 -0
package/dist/locale/en.js
CHANGED
package/dist/locale/en.min.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/*! Hzzt Plus
|
|
1
|
+
/*! Hzzt Plus v1.0.2 */(function(e,r){typeof exports=="object"&&typeof module!="undefined"?module.exports=r():typeof define=="function"&&define.amd?define(r):(e=typeof globalThis!="undefined"?globalThis:e||self,e.HzztPlusLocaleEn=r())})(this,function(){"use strict";var e={name:"en",hzzt:{collapse:{expand:"expand",retract:"retract"},pagination:{total:"",strip:""},pageSize:{total:"Total ",strip:"",page:"page",d:"",per_page:"per page"},quarterpicker:{prevYear:"Previous Year",nextYear:"Next Year",year:"",firstQuarter:"First quarter",secondQuarter:"Second quarter",thirdQuarter:"Third quarter",fourthQuarter:"Fourth quarter"}}};return e});
|
|
2
2
|
//# sourceMappingURL=en.min.js.map
|
package/dist/locale/en.min.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/*! Hzzt Plus
|
|
1
|
+
/*! Hzzt Plus v1.0.2 */var r={name:"en",hzzt:{collapse:{expand:"expand",retract:"retract"},pagination:{total:"",strip:""},pageSize:{total:"Total ",strip:"",page:"page",d:"",per_page:"per page"},quarterpicker:{prevYear:"Previous Year",nextYear:"Next Year",year:"",firstQuarter:"First quarter",secondQuarter:"Second quarter",thirdQuarter:"Third quarter",fourthQuarter:"Fourth quarter"}}};export{r as default};
|
|
2
2
|
//# sourceMappingURL=en.min.mjs.map
|
package/dist/locale/en.mjs
CHANGED
package/dist/locale/zh-cn.js
CHANGED
package/dist/locale/zh-cn.min.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/*! Hzzt Plus
|
|
1
|
+
/*! Hzzt Plus v1.0.2 */(function(u,e){typeof exports=="object"&&typeof module!="undefined"?module.exports=e():typeof define=="function"&&define.amd?define(e):(u=typeof globalThis!="undefined"?globalThis:u||self,u.HzztPlusLocaleZhCn=e())})(this,function(){"use strict";var u={name:"zh-cn",hzzt:{collapse:{expand:"\u5C55\u5F00",retract:"\u6536\u8D77"},pagination:{total:"\u5171",strip:"\u6761"},pageSize:{total:"\u5171",strip:"\u6761",d:"\u7B2C",page:"\u9875",per_page:"\u6BCF\u9875"},quarterpicker:{prevYear:"\u524D\u4E00\u5E74",nextYear:"\u540E\u4E00\u5E74",year:"\u5E74",firstQuarter:"\u7B2C\u4E00\u5B63\u5EA6",secondQuarter:"\u7B2C\u4E8C\u5B63\u5EA6",thirdQuarter:"\u7B2C\u4E09\u5B63\u5EA6",fourthQuarter:"\u7B2C\u56DB\u5B63\u5EA6"}}};return u});
|
|
2
2
|
//# sourceMappingURL=zh-cn.min.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/*! Hzzt Plus
|
|
1
|
+
/*! Hzzt Plus v1.0.2 */var u={name:"zh-cn",hzzt:{collapse:{expand:"\u5C55\u5F00",retract:"\u6536\u8D77"},pagination:{total:"\u5171",strip:"\u6761"},pageSize:{total:"\u5171",strip:"\u6761",d:"\u7B2C",page:"\u9875",per_page:"\u6BCF\u9875"},quarterpicker:{prevYear:"\u524D\u4E00\u5E74",nextYear:"\u540E\u4E00\u5E74",year:"\u5E74",firstQuarter:"\u7B2C\u4E00\u5B63\u5EA6",secondQuarter:"\u7B2C\u4E8C\u5B63\u5EA6",thirdQuarter:"\u7B2C\u4E09\u5B63\u5EA6",fourthQuarter:"\u7B2C\u56DB\u5B63\u5EA6"}}};export{u as default};
|
|
2
2
|
//# sourceMappingURL=zh-cn.min.mjs.map
|
package/dist/locale/zh-cn.mjs
CHANGED
package/es/component.mjs
CHANGED
|
@@ -12,6 +12,8 @@ import { HzztCheckButton } from './components/check-button/index.mjs';
|
|
|
12
12
|
import { HzztQuarterPicker } from './components/quarter-picker/index.mjs';
|
|
13
13
|
import { HzztScan } from './components/scan/index.mjs';
|
|
14
14
|
import { HzztSelectInput } from './components/select-input/index.mjs';
|
|
15
|
+
import { HzztSelectTextarea } from './components/select-textarea/index.mjs';
|
|
16
|
+
import { HzztInputRange } from './components/input-range/index.mjs';
|
|
15
17
|
|
|
16
18
|
var Components = [
|
|
17
19
|
HzztConfigProvider,
|
|
@@ -27,7 +29,9 @@ var Components = [
|
|
|
27
29
|
HzztCheckButton,
|
|
28
30
|
HzztQuarterPicker,
|
|
29
31
|
HzztScan,
|
|
30
|
-
HzztSelectInput
|
|
32
|
+
HzztSelectInput,
|
|
33
|
+
HzztSelectTextarea,
|
|
34
|
+
HzztInputRange
|
|
31
35
|
];
|
|
32
36
|
|
|
33
37
|
export { Components as default };
|
package/es/component.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.mjs","sources":["../../../packages/hzzt-plus/component.ts"],"sourcesContent":["import { HzztTitle } from '@hzzt-plus/components/title'\nimport { HzztDropdown } from '@hzzt-plus/components/dropdown'\nimport { HzztCollapse } from '@hzzt-plus/components/collapse'\nimport { HzztConfigProvider } from '@hzzt-plus/components/config-provider'\nimport { HzztTab } from '@hzzt-plus/components/tab'\nimport { HzztIcon } from '@hzzt-plus/components/icon'\nimport { HzztPagination } from '@hzzt-plus/components/pagination'\nimport { HzztTooltip } from '@hzzt-plus/components/tooltip'\nimport { HzztPageSize } from '@hzzt-plus/components/page-size'\nimport { HzztConfirmPassword } from '@hzzt-plus/components/confirm-password'\nimport { HzztCheckButton } from '@hzzt-plus/components/check-button'\nimport { HzztQuarterPicker } from '@hzzt-plus/components/quarter-picker'\nimport { HzztScan } from '@hzzt-plus/components/scan'\nimport { HzztSelectInput } from '@hzzt-plus/components/select-input'\n\nimport type { Plugin } from 'vue'\n\nexport default [\n HzztConfigProvider,\n HzztTitle,\n HzztDropdown,\n HzztCollapse,\n HzztTab,\n HzztIcon,\n HzztPagination,\n HzztTooltip,\n HzztPageSize,\n HzztConfirmPassword,\n HzztCheckButton,\n HzztQuarterPicker,\n HzztScan,\n HzztSelectInput,\n] as Plugin[]\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"component.mjs","sources":["../../../packages/hzzt-plus/component.ts"],"sourcesContent":["import { HzztTitle } from '@hzzt-plus/components/title'\nimport { HzztDropdown } from '@hzzt-plus/components/dropdown'\nimport { HzztCollapse } from '@hzzt-plus/components/collapse'\nimport { HzztConfigProvider } from '@hzzt-plus/components/config-provider'\nimport { HzztTab } from '@hzzt-plus/components/tab'\nimport { HzztIcon } from '@hzzt-plus/components/icon'\nimport { HzztPagination } from '@hzzt-plus/components/pagination'\nimport { HzztTooltip } from '@hzzt-plus/components/tooltip'\nimport { HzztPageSize } from '@hzzt-plus/components/page-size'\nimport { HzztConfirmPassword } from '@hzzt-plus/components/confirm-password'\nimport { HzztCheckButton } from '@hzzt-plus/components/check-button'\nimport { HzztQuarterPicker } from '@hzzt-plus/components/quarter-picker'\nimport { HzztScan } from '@hzzt-plus/components/scan'\nimport { HzztSelectInput } from '@hzzt-plus/components/select-input'\nimport { HzztSelectTextarea } from '@hzzt-plus/components/select-textarea'\nimport { HzztInputRange } from '@hzzt-plus/components/input-range'\n\nimport type { Plugin } from 'vue'\n\nexport default [\n HzztConfigProvider,\n HzztTitle,\n HzztDropdown,\n HzztCollapse,\n HzztTab,\n HzztIcon,\n HzztPagination,\n HzztTooltip,\n HzztPageSize,\n HzztConfirmPassword,\n HzztCheckButton,\n HzztQuarterPicker,\n HzztScan,\n HzztSelectInput,\n HzztSelectTextarea,\n HzztInputRange,\n] as Plugin[]\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAgBA,iBAAe;AACf,EAAE,kBAAkB;AACpB,EAAE,SAAS;AACX,EAAE,YAAY;AACd,EAAE,YAAY;AACd,EAAE,OAAO;AACT,EAAE,QAAQ;AACV,EAAE,cAAc;AAChB,EAAE,WAAW;AACb,EAAE,YAAY;AACd,EAAE,mBAAmB;AACrB,EAAE,eAAe;AACjB,EAAE,iBAAiB;AACnB,EAAE,QAAQ;AACV,EAAE,eAAe;AACjB,EAAE,kBAAkB;AACpB,EAAE,cAAc;AAChB,CAAC;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import '../../utils/index.mjs';
|
|
2
|
-
import Collapse from './src/
|
|
3
|
-
import './src/
|
|
2
|
+
import Collapse from './src/collapse.mjs';
|
|
3
|
+
import './src/collapse2.mjs';
|
|
4
4
|
import { withInstall } from '../../utils/vue/install.mjs';
|
|
5
5
|
|
|
6
6
|
const HzztCollapse = withInstall(Collapse);
|
|
@@ -1,2 +1,69 @@
|
|
|
1
|
+
import { createElementVNode, defineComponent, ref, watch, openBlock, createElementBlock, toDisplayString, unref, createCommentVNode, renderSlot } from 'vue';
|
|
2
|
+
import '../../../hooks/index.mjs';
|
|
3
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
4
|
+
import { useLocale } from '../../../hooks/use-locale/index.mjs';
|
|
1
5
|
|
|
6
|
+
const _hoisted_1 = { class: "hzzt-collapse" };
|
|
7
|
+
const _hoisted_2 = { class: "flex align-items-center" };
|
|
8
|
+
const _hoisted_3 = { class: "hzzt-collapse-title-wrapper" };
|
|
9
|
+
const _hoisted_4 = /* @__PURE__ */ createElementVNode("div", { class: "hzzt-collapse-title-block" }, null, -1);
|
|
10
|
+
const _hoisted_5 = { class: "hzzt-collapse-title" };
|
|
11
|
+
const _hoisted_6 = /* @__PURE__ */ createElementVNode("div", { class: "hzzt-collapse-line" }, null, -1);
|
|
12
|
+
const _hoisted_7 = {
|
|
13
|
+
key: 0,
|
|
14
|
+
class: "hzzt-collapse-text"
|
|
15
|
+
};
|
|
16
|
+
const __default__ = defineComponent({
|
|
17
|
+
name: "HzztCollapse"
|
|
18
|
+
});
|
|
19
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
20
|
+
...__default__,
|
|
21
|
+
props: {
|
|
22
|
+
defaultActive: {
|
|
23
|
+
type: Boolean,
|
|
24
|
+
default: false
|
|
25
|
+
},
|
|
26
|
+
title: {
|
|
27
|
+
type: String,
|
|
28
|
+
default: ""
|
|
29
|
+
},
|
|
30
|
+
expand: {
|
|
31
|
+
type: Boolean,
|
|
32
|
+
default: true
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
setup(__props) {
|
|
36
|
+
const props = __props;
|
|
37
|
+
const { t } = useLocale();
|
|
38
|
+
const active = ref(props.defaultActive);
|
|
39
|
+
watch(() => props.defaultActive, (val) => {
|
|
40
|
+
active.value = val;
|
|
41
|
+
});
|
|
42
|
+
function toggle() {
|
|
43
|
+
active.value = !active.value;
|
|
44
|
+
}
|
|
45
|
+
return (_ctx, _cache) => {
|
|
46
|
+
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
47
|
+
createElementVNode("div", {
|
|
48
|
+
class: "hzzt-collapse-header",
|
|
49
|
+
onClick: toggle
|
|
50
|
+
}, [
|
|
51
|
+
createElementVNode("div", _hoisted_2, [
|
|
52
|
+
createElementVNode("div", _hoisted_3, [
|
|
53
|
+
_hoisted_4,
|
|
54
|
+
createElementVNode("div", _hoisted_5, toDisplayString(__props.title), 1)
|
|
55
|
+
]),
|
|
56
|
+
_hoisted_6
|
|
57
|
+
]),
|
|
58
|
+
__props.expand ? (openBlock(), createElementBlock("span", _hoisted_7, toDisplayString(active.value ? unref(t)("hzzt.collapse.retract") : unref(t)("hzzt.collapse.expand")), 1)) : createCommentVNode("v-if", true)
|
|
59
|
+
]),
|
|
60
|
+
renderSlot(_ctx.$slots, "active", { active: active.value }),
|
|
61
|
+
renderSlot(_ctx.$slots, "default")
|
|
62
|
+
]);
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "collapse.vue"]]);
|
|
67
|
+
|
|
68
|
+
export { Collapse as default };
|
|
2
69
|
//# sourceMappingURL=collapse.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collapse.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"collapse.mjs","sources":["../../../../../../packages/components/collapse/src/collapse.vue"],"sourcesContent":["<template>\n <div class=\"hzzt-collapse\">\n <div class=\"hzzt-collapse-header\" @click=\"toggle\">\n <div class=\"flex align-items-center\">\n <div class=\"hzzt-collapse-title-wrapper\">\n <div class=\"hzzt-collapse-title-block\" />\n <div class=\"hzzt-collapse-title\">{{ title }}</div>\n </div>\n <div class=\"hzzt-collapse-line\" />\n </div>\n <span v-if=\"expand\" class=\"hzzt-collapse-text\">{{\n active ? t('hzzt.collapse.retract') : t('hzzt.collapse.expand')\n }}</span>\n </div>\n <slot name=\"active\" :active=\"active\" />\n <slot />\n </div>\n</template>\n\n<script setup lang=\"ts\">\nimport { ref, watch } from 'vue'\nimport { useLocale } from '@hzzt-plus/hooks'\n\ndefineOptions({\n name: 'HzztCollapse',\n})\nconst { t } = useLocale()\nconst props = defineProps({\n defaultActive: {\n type: Boolean,\n default: false,\n },\n title: {\n type: String,\n default: '',\n },\n expand: {\n type: Boolean,\n default: true,\n },\n})\n\nconst active = ref(props.defaultActive)\n\nwatch(\n () => props.defaultActive,\n (val: boolean) => {\n active.value = val\n }\n)\n\nfunction toggle() {\n active.value = !active.value\n}\n</script>\n"],"names":["_createElementVNode","_toDisplayString","_openBlock","_createElementBlock","_unref","_createCommentVNode"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAoBA,KAAA;AACA,IAAA,KAAS,EAAiB;;;AAEZ,KACN;AACR,IAAA,MAAA,EAAA;;;;;;;;;;;;;;;;;;;AACA,UAAM,OAAI,EAAc,MAAA;AAgBxB,SAAM,EAAA;AAEN,UAAAA,kBAAA,CAAA,KAAA,EAAA,UAAA,EAAA;AAAA,YACQA,kBAAM,CAAA,KAAA,EAAA,UAAA,EAAA;AAAA,cACM,UAAA;AAChB,cAAAA,kBAAe,CAAA,KAAA,EAAA,UAAA,EAAAC,eAAA,CAAA,OAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA;AAAA,aACjB,CAAA;AAAA,YACF,UAAA;AAEA,WAAA,CAAA;AACE,UAAO,OAAA,CAAA,MAAgB,IAAAC,SAAA,EAAA,EAAAC,kBAAA,CAAA,MAAA,EAAA,UAAA,EAAAF,eAAA,CAAA,MAAA,CAAA,KAAA,GAAAG,KAAA,CAAA,CAAA,CAAA,CAAA,uBAAA,CAAA,GAAAA,KAAA,CAAA,CAAA,CAAA,CAAA,sBAAA,CAAA,CAAA,EAAA,CAAA,CAAA,IAAAC,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA;AAAA,SACzB,CAAA;;;;;;;;;;;"}
|
|
@@ -1,69 +1,2 @@
|
|
|
1
|
-
import { createElementVNode, defineComponent, ref, watch, openBlock, createElementBlock, toDisplayString, unref, createCommentVNode, renderSlot } from 'vue';
|
|
2
|
-
import '../../../hooks/index.mjs';
|
|
3
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
4
|
-
import { useLocale } from '../../../hooks/use-locale/index.mjs';
|
|
5
1
|
|
|
6
|
-
const _hoisted_1 = { class: "hzzt-collapse" };
|
|
7
|
-
const _hoisted_2 = { class: "flex align-items-center" };
|
|
8
|
-
const _hoisted_3 = { class: "hzzt-collapse-title-wrapper" };
|
|
9
|
-
const _hoisted_4 = /* @__PURE__ */ createElementVNode("div", { class: "hzzt-collapse-title-block" }, null, -1);
|
|
10
|
-
const _hoisted_5 = { class: "hzzt-collapse-title" };
|
|
11
|
-
const _hoisted_6 = /* @__PURE__ */ createElementVNode("div", { class: "hzzt-collapse-line" }, null, -1);
|
|
12
|
-
const _hoisted_7 = {
|
|
13
|
-
key: 0,
|
|
14
|
-
class: "hzzt-collapse-text"
|
|
15
|
-
};
|
|
16
|
-
const __default__ = defineComponent({
|
|
17
|
-
name: "HzztCollapse"
|
|
18
|
-
});
|
|
19
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
20
|
-
...__default__,
|
|
21
|
-
props: {
|
|
22
|
-
defaultActive: {
|
|
23
|
-
type: Boolean,
|
|
24
|
-
default: false
|
|
25
|
-
},
|
|
26
|
-
title: {
|
|
27
|
-
type: String,
|
|
28
|
-
default: ""
|
|
29
|
-
},
|
|
30
|
-
expand: {
|
|
31
|
-
type: Boolean,
|
|
32
|
-
default: true
|
|
33
|
-
}
|
|
34
|
-
},
|
|
35
|
-
setup(__props) {
|
|
36
|
-
const props = __props;
|
|
37
|
-
const { t } = useLocale();
|
|
38
|
-
const active = ref(props.defaultActive);
|
|
39
|
-
watch(() => props.defaultActive, (val) => {
|
|
40
|
-
active.value = val;
|
|
41
|
-
});
|
|
42
|
-
function toggle() {
|
|
43
|
-
active.value = !active.value;
|
|
44
|
-
}
|
|
45
|
-
return (_ctx, _cache) => {
|
|
46
|
-
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
47
|
-
createElementVNode("div", {
|
|
48
|
-
class: "hzzt-collapse-header",
|
|
49
|
-
onClick: toggle
|
|
50
|
-
}, [
|
|
51
|
-
createElementVNode("div", _hoisted_2, [
|
|
52
|
-
createElementVNode("div", _hoisted_3, [
|
|
53
|
-
_hoisted_4,
|
|
54
|
-
createElementVNode("div", _hoisted_5, toDisplayString(__props.title), 1)
|
|
55
|
-
]),
|
|
56
|
-
_hoisted_6
|
|
57
|
-
]),
|
|
58
|
-
__props.expand ? (openBlock(), createElementBlock("span", _hoisted_7, toDisplayString(active.value ? unref(t)("hzzt.collapse.retract") : unref(t)("hzzt.collapse.expand")), 1)) : createCommentVNode("v-if", true)
|
|
59
|
-
]),
|
|
60
|
-
renderSlot(_ctx.$slots, "active", { active: active.value }),
|
|
61
|
-
renderSlot(_ctx.$slots, "default")
|
|
62
|
-
]);
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
|
-
var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "collapse.vue"]]);
|
|
67
|
-
|
|
68
|
-
export { Collapse as default };
|
|
69
2
|
//# sourceMappingURL=collapse2.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collapse2.mjs","sources":[
|
|
1
|
+
{"version":3,"file":"collapse2.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const HzztDropdown: import("hzzt-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
2
2
|
options: {
|
|
3
|
-
type:
|
|
3
|
+
type: import("vue").PropType<import("..").OptionType[]>;
|
|
4
4
|
default: () => never[];
|
|
5
5
|
};
|
|
6
6
|
label: StringConstructor;
|
|
@@ -28,7 +28,7 @@ export declare const HzztDropdown: import("hzzt-plus/es/utils").SFCWithInstall<i
|
|
|
28
28
|
}, {
|
|
29
29
|
dProps: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
30
30
|
options: {
|
|
31
|
-
type:
|
|
31
|
+
type: import("vue").PropType<import("..").OptionType[]>;
|
|
32
32
|
default: () => never[];
|
|
33
33
|
};
|
|
34
34
|
label: StringConstructor;
|
|
@@ -60,12 +60,12 @@ export declare const HzztDropdown: import("hzzt-plus/es/utils").SFCWithInstall<i
|
|
|
60
60
|
toggle: import("vue").Ref<boolean>;
|
|
61
61
|
dropToggle: () => void;
|
|
62
62
|
close: () => void;
|
|
63
|
-
selectValue: (val:
|
|
63
|
+
selectValue: (val: string[]) => void;
|
|
64
64
|
vClickOutside: import("vue").ObjectDirective<any, any>;
|
|
65
65
|
isEmpty: (val: unknown) => boolean;
|
|
66
66
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "change"[], "change", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
67
67
|
options: {
|
|
68
|
-
type:
|
|
68
|
+
type: import("vue").PropType<import("..").OptionType[]>;
|
|
69
69
|
default: () => never[];
|
|
70
70
|
};
|
|
71
71
|
label: StringConstructor;
|
|
@@ -94,7 +94,7 @@ export declare const HzztDropdown: import("hzzt-plus/es/utils").SFCWithInstall<i
|
|
|
94
94
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
95
95
|
}, {
|
|
96
96
|
props: Record<string, any>;
|
|
97
|
-
options:
|
|
97
|
+
options: import("..").OptionType[];
|
|
98
98
|
defaultValue: unknown[];
|
|
99
99
|
position: string;
|
|
100
100
|
returnType: string;
|
|
@@ -2,6 +2,7 @@ import { createElementVNode, defineComponent, ref, withDirectives, openBlock, cr
|
|
|
2
2
|
import { ClickOutside } from 'element-plus';
|
|
3
3
|
import '../../../utils/index.mjs';
|
|
4
4
|
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
5
|
+
import { definePropType } from '../../../utils/vue/props/runtime.mjs';
|
|
5
6
|
import { isEmpty } from '../../../utils/types.mjs';
|
|
6
7
|
|
|
7
8
|
const _hoisted_1 = ["onClick"];
|
|
@@ -18,7 +19,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
18
19
|
...__default__,
|
|
19
20
|
props: {
|
|
20
21
|
options: {
|
|
21
|
-
type: Array,
|
|
22
|
+
type: definePropType(Array),
|
|
22
23
|
default: () => []
|
|
23
24
|
},
|
|
24
25
|
label: String,
|
|
@@ -59,7 +60,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
59
60
|
emits("change", val);
|
|
60
61
|
}
|
|
61
62
|
if (dProps.returnType === "String") {
|
|
62
|
-
emits("change", val.
|
|
63
|
+
emits("change", val[val.length - 1]);
|
|
63
64
|
}
|
|
64
65
|
}
|
|
65
66
|
return (_ctx, _cache) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/components/dropdown/src/index.vue"],"sourcesContent":["<template>\n <ul v-click-outside=\"close\" class=\"hzzt-dropdown\" @click.stop=\"dropToggle\">\n <li :class=\"{ 'hzzt-dropdown-li': true, 'hzzt-dropdown-li-show': toggle }\">\n <span class=\"hzzt-dropdown-name\">{{ label }}</span>\n <span class=\"caret\" />\n <ul class=\"hzzt-dropdown-menu\">\n <template v-for=\"(option, index) in options\">\n <li\n v-if=\"isEmpty(option[props.children])\"\n :key=\"index\"\n :class=\"{\n 'hzzt-dropdown-menu-item': true,\n selected: defaultValue.includes(option[props.value]),\n }\"\n >\n <a\n class=\"hzzt-dropdown-menu-item-label\"\n @click=\"selectValue([option[props.value]])\"\n
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/components/dropdown/src/index.vue"],"sourcesContent":["<template>\n <ul v-click-outside=\"close\" class=\"hzzt-dropdown\" @click.stop=\"dropToggle\">\n <li :class=\"{ 'hzzt-dropdown-li': true, 'hzzt-dropdown-li-show': toggle }\">\n <span class=\"hzzt-dropdown-name\">{{ label }}</span>\n <span class=\"caret\" />\n <ul class=\"hzzt-dropdown-menu\">\n <template v-for=\"(option, index) in options\">\n <li\n v-if=\"isEmpty(option[props.children])\"\n :key=\"index\"\n :class=\"{\n 'hzzt-dropdown-menu-item': true,\n selected: defaultValue.includes(option[props.value]),\n }\"\n >\n <a\n class=\"hzzt-dropdown-menu-item-label\"\n @click=\"selectValue([option[props.value]])\"\n >{{ option[props.label] }}</a\n >\n </li>\n <li\n v-else\n :key=\"index + 'submenu'\"\n class=\"hzzt-dropdown-menu-item hzzt-dropdown-submenu\"\n >\n <a class=\"submenu\">{{ option[props.label] }}</a>\n <ul :class=\"['pull-' + position]\" class=\"hzzt-dropdown-menu\">\n <li\n v-for=\"(child, cIndex) in option.children\"\n :key=\"cIndex\"\n :class=\"{\n 'hzzt-dropdown-menu-item': true,\n selected: defaultValue.includes(child[props.value]),\n }\"\n >\n <a\n class=\"hzzt-dropdown-menu-item-label\"\n @click=\"\n selectValue([option[props.value], child[props.value]])\n \"\n >{{ child[props.label] }}</a\n >\n </li>\n </ul>\n </li>\n <li v-if=\"option.divider\" :key=\"index + 'divider'\" class=\"divider\" />\n </template>\n </ul>\n </li>\n </ul>\n</template>\n\n<script setup lang=\"ts\">\n import {ref} from 'vue'\n import {ClickOutside as vClickOutside} from 'element-plus'\n import {definePropType, isEmpty} from '@hzzt-plus/utils'\n import {OptionType} from \"@hzzt-plus/components\";\n\n const dProps = defineProps({\n options: {\n type: definePropType<OptionType[]>(Array),\n default: () => [],\n },\n label: String,\n value: String,\n defaultValue: {\n type: Array,\n default: () => [],\n },\n position: {\n type: String,\n default: 'right',\n },\n props: {\n type: Object,\n default: () => ({\n children: 'children',\n label: 'label',\n value: 'value',\n }),\n },\n returnType: {\n type: String,\n default: 'Array',\n },\n })\n\n const emits = defineEmits(['change'])\n\n defineOptions({\n name: 'HzztDropDown',\n })\n\n const toggle = ref(false)\n\n function dropToggle() {\n toggle.value = !toggle.value\n }\n\n function close() {\n toggle.value = false\n }\n\n function selectValue(val: Array<string>) {\n if (dProps.returnType === 'Array') {\n emits('change', val)\n }\n if (dProps.returnType === 'String') {\n emits('change', val[val.length-1])\n }\n }\n</script>\n"],"names":["_defineComponent","_withDirectives","_openBlock","_createElementBlock","_withModifiers","_createElementVNode"],"mappings":";;;;;;;;;;;;;;;;AAsDE,CAAA,CAAA,CAAA;AACA,MAAA,4BAA4CA,eAAA,CAAA;AAC5C,EAAA,GAAA;;;AAkCc,MACN,IAAA,EAAA,cAAA,CAAA,KAAA,CAAA;AACR,MAAA,OAAA,EAAA,MAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,KAAM;AAEN,IAAA,SAAS,WAAa,CAAA,GAAA,EAAA;AACpB,MAAO,IAAA,MAAA,CAAA,UAAgB,KAAA,OAAA,EAAA;AAAA,QACzB,KAAA,CAAA,QAAA,EAAA,GAAA,CAAA,CAAA;AAEA,OAAA;AACE,MAAA,IAAA,MAAe,CAAA,UAAA,KAAA,QAAA,EAAA;AAAA,QACjB,KAAA,CAAA,QAAA,EAAA,GAAA,CAAA,GAAA,CAAA,MAAA,GAAA,CAAA,CAAA,CAAA,CAAA;AAEA,OAAA;AACE,KAAI;AACF,IAAA,OAAA,CAAA,YAAgB,KAAG;AAAA,MACrB,OAAAC,cAAA,EAAAC,SAAA,EAAA,EAAAC,kBAAA,CAAA,IAAA,EAAA;AACA,QAAI,KAAA,EAAA;AACF,QAAA,OAAgB,EAAAC,aAAQ,CAAA,UAAQ,EAAC,CAAA,MAAA,CAAA,CAAA;AAAA,OACnC,EAAA;AAAA,QACFC,kBAAA,CAAA,IAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { OptionType } from "hzzt-plus/es/components";
|
|
1
2
|
declare const _default: import("vue").DefineComponent<{
|
|
2
3
|
options: {
|
|
3
|
-
type:
|
|
4
|
+
type: import("vue").PropType<OptionType[]>;
|
|
4
5
|
default: () => never[];
|
|
5
6
|
};
|
|
6
7
|
label: StringConstructor;
|
|
@@ -28,7 +29,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
28
29
|
}, {
|
|
29
30
|
dProps: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
30
31
|
options: {
|
|
31
|
-
type:
|
|
32
|
+
type: import("vue").PropType<OptionType[]>;
|
|
32
33
|
default: () => never[];
|
|
33
34
|
};
|
|
34
35
|
label: StringConstructor;
|
|
@@ -60,12 +61,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
60
61
|
toggle: import("vue").Ref<boolean>;
|
|
61
62
|
dropToggle: () => void;
|
|
62
63
|
close: () => void;
|
|
63
|
-
selectValue: (val:
|
|
64
|
+
selectValue: (val: Array<string>) => void;
|
|
64
65
|
vClickOutside: import("vue").ObjectDirective<any, any>;
|
|
65
66
|
isEmpty: (val: unknown) => boolean;
|
|
66
67
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "change"[], "change", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
67
68
|
options: {
|
|
68
|
-
type:
|
|
69
|
+
type: import("vue").PropType<OptionType[]>;
|
|
69
70
|
default: () => never[];
|
|
70
71
|
};
|
|
71
72
|
label: StringConstructor;
|
|
@@ -94,7 +95,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
94
95
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
95
96
|
}, {
|
|
96
97
|
props: Record<string, any>;
|
|
97
|
-
options:
|
|
98
|
+
options: OptionType[];
|
|
98
99
|
defaultValue: unknown[];
|
|
99
100
|
position: string;
|
|
100
101
|
returnType: string;
|
package/es/components/index.d.ts
CHANGED
package/es/components/index.mjs
CHANGED
|
@@ -12,10 +12,14 @@ export { HzztCheckButton } from './check-button/index.mjs';
|
|
|
12
12
|
export { HzztQuarterPicker } from './quarter-picker/index.mjs';
|
|
13
13
|
export { HzztScan } from './scan/index.mjs';
|
|
14
14
|
export { HzztSelectInput } from './select-input/index.mjs';
|
|
15
|
+
export { HzztSelectTextarea } from './select-textarea/index.mjs';
|
|
16
|
+
export { HzztInputRange } from './input-range/index.mjs';
|
|
15
17
|
export { titleProps } from './title/src/title.mjs';
|
|
16
18
|
export { configProviderProps } from './config-provider/src/config-provider-props.mjs';
|
|
17
19
|
export { configProviderContextKey } from './config-provider/src/constants.mjs';
|
|
18
20
|
export { provideGlobalConfig, useGlobalConfig } from './config-provider/src/hooks/use-global-config.mjs';
|
|
19
21
|
export { scanEmits, scanProps } from './scan/src/scan.mjs';
|
|
20
22
|
export { selectInputEmits, selectInputProps } from './select-input/src/select-input.mjs';
|
|
23
|
+
export { selectTextareaEmits, selectTextareaProps } from './select-textarea/src/select-textarea.mjs';
|
|
24
|
+
export { inputRangeEmits, inputRangeProps } from './input-range/src/input-range.mjs';
|
|
21
25
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import '../../utils/index.mjs';
|
|
2
|
+
import InputRange from './src/input-range2.mjs';
|
|
3
|
+
export { inputRangeEmits, inputRangeProps } from './src/input-range.mjs';
|
|
4
|
+
import { withInstall } from '../../utils/vue/install.mjs';
|
|
5
|
+
|
|
6
|
+
const HzztInputRange = withInstall(InputRange);
|
|
7
|
+
|
|
8
|
+
export { HzztInputRange, HzztInputRange as default };
|
|
9
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../packages/components/input-range/index.ts"],"sourcesContent":["import { withInstall } from '@hzzt-plus/utils'\nimport InputRange from './src/input-range.vue'\nimport type { SFCWithInstall } from '@hzzt-plus/utils'\n\nexport const HzztInputRange: SFCWithInstall<typeof InputRange> = withInstall(InputRange)\nexport default HzztInputRange\n\nexport * from './src/input-range'\n"],"names":[],"mappings":";;;;;AAEY,MAAC,cAAc,GAAG,WAAW,CAAC,UAAU;;;;"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { ExtractPropTypes } from 'vue';
|
|
2
|
+
import type InputRange from './input-range.vue';
|
|
3
|
+
export declare const inputRangeProps: {
|
|
4
|
+
modelValue: import("hzzt-plus/es/utils").EpPropFinalized<ArrayConstructor, unknown, unknown, () => never[], boolean>;
|
|
5
|
+
size: {
|
|
6
|
+
readonly type: import("vue").PropType<import("hzzt-plus/es/utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
7
|
+
readonly required: false;
|
|
8
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
9
|
+
__epPropKey: true;
|
|
10
|
+
};
|
|
11
|
+
disabled: BooleanConstructor;
|
|
12
|
+
clearable: import("hzzt-plus/es/utils").EpPropFinalized<BooleanConstructor, unknown, unknown, boolean, boolean>;
|
|
13
|
+
startPlaceholder: StringConstructor;
|
|
14
|
+
endPlaceholder: StringConstructor;
|
|
15
|
+
startProps: ObjectConstructor;
|
|
16
|
+
endProps: ObjectConstructor;
|
|
17
|
+
};
|
|
18
|
+
export declare type InputRangeProps = ExtractPropTypes<typeof inputRangeProps>;
|
|
19
|
+
export declare const inputRangeEmits: {
|
|
20
|
+
"update:modelValue": (val: Array<string>) => boolean;
|
|
21
|
+
change: (val: Array<string>) => boolean;
|
|
22
|
+
};
|
|
23
|
+
export declare type InputRangeEmits = typeof inputRangeEmits;
|
|
24
|
+
export declare type InputRangeInstance = InstanceType<typeof InputRange>;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import '../../../utils/index.mjs';
|
|
2
|
+
import '../../../hooks/index.mjs';
|
|
3
|
+
import '../../../constants/index.mjs';
|
|
4
|
+
import { buildProps } from '../../../utils/vue/props/runtime.mjs';
|
|
5
|
+
import { useSizeProp } from '../../../hooks/use-size/index.mjs';
|
|
6
|
+
import { UPDATE_MODEL_EVENT, CHANGE_EVENT } from '../../../constants/event.mjs';
|
|
7
|
+
import { isArray } from '@vue/shared';
|
|
8
|
+
|
|
9
|
+
const inputRangeProps = buildProps({
|
|
10
|
+
modelValue: {
|
|
11
|
+
type: Array,
|
|
12
|
+
default: () => []
|
|
13
|
+
},
|
|
14
|
+
size: useSizeProp,
|
|
15
|
+
disabled: Boolean,
|
|
16
|
+
clearable: {
|
|
17
|
+
type: Boolean,
|
|
18
|
+
default: false
|
|
19
|
+
},
|
|
20
|
+
startPlaceholder: String,
|
|
21
|
+
endPlaceholder: String,
|
|
22
|
+
startProps: Object,
|
|
23
|
+
endProps: Object
|
|
24
|
+
});
|
|
25
|
+
const inputRangeEmits = {
|
|
26
|
+
[UPDATE_MODEL_EVENT]: (val) => isArray(val),
|
|
27
|
+
[CHANGE_EVENT]: (val) => isArray(val)
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
export { inputRangeEmits, inputRangeProps };
|
|
31
|
+
//# sourceMappingURL=input-range.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"input-range.mjs","sources":["../../../../../../packages/components/input-range/src/input-range.ts"],"sourcesContent":["import {buildProps, isArray} from '@hzzt-plus/utils'\n\nimport type { ExtractPropTypes } from 'vue'\nimport type InputRange from './input-range.vue'\nimport {useSizeProp} from \"@hzzt-plus/hooks\";\nimport {CHANGE_EVENT, UPDATE_MODEL_EVENT} from \"@hzzt-plus/constants\";\n\nexport const inputRangeProps = buildProps({\n modelValue: {\n type: Array,\n default: () => [],\n },\n size: useSizeProp,\n disabled: Boolean,\n clearable: {\n type: Boolean,\n default: false,\n },\n startPlaceholder: String,\n endPlaceholder: String,\n startProps: Object,\n endProps: Object,\n})\n\nexport type InputRangeProps = ExtractPropTypes<typeof inputRangeProps>\n\nexport const inputRangeEmits = {\n [UPDATE_MODEL_EVENT]: (val: Array<string>) => isArray(val),\n [CHANGE_EVENT]: (val: Array<string>) => isArray(val),\n}\nexport type InputRangeEmits = typeof inputRangeEmits\n\nexport type InputRangeInstance = InstanceType<typeof InputRange>\n"],"names":[],"mappings":";;;;;;;;AAGY,MAAC,eAAe,GAAG,UAAU,CAAC;AAC1C,EAAE,UAAU,EAAE;AACd,IAAI,IAAI,EAAE,KAAK;AACf,IAAI,OAAO,EAAE,MAAM,EAAE;AACrB,GAAG;AACH,EAAE,IAAI,EAAE,WAAW;AACnB,EAAE,QAAQ,EAAE,OAAO;AACnB,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,EAAE,gBAAgB,EAAE,MAAM;AAC1B,EAAE,cAAc,EAAE,MAAM;AACxB,EAAE,UAAU,EAAE,MAAM;AACpB,EAAE,QAAQ,EAAE,MAAM;AAClB,CAAC,EAAE;AACS,MAAC,eAAe,GAAG;AAC/B,EAAE,CAAC,kBAAkB,GAAG,CAAC,GAAG,KAAK,OAAO,CAAC,GAAG,CAAC;AAC7C,EAAE,CAAC,YAAY,GAAG,CAAC,GAAG,KAAK,OAAO,CAAC,GAAG,CAAC;AACvC;;;;"}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
modelValue: import("../../../utils").EpPropFinalized<ArrayConstructor, unknown, unknown, () => never[], boolean>;
|
|
3
|
+
size: {
|
|
4
|
+
readonly type: import("vue").PropType<import("../../../utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
5
|
+
readonly required: false;
|
|
6
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
7
|
+
__epPropKey: true;
|
|
8
|
+
};
|
|
9
|
+
disabled: BooleanConstructor;
|
|
10
|
+
clearable: import("../../../utils").EpPropFinalized<BooleanConstructor, unknown, unknown, boolean, boolean>;
|
|
11
|
+
startPlaceholder: StringConstructor;
|
|
12
|
+
endPlaceholder: StringConstructor;
|
|
13
|
+
startProps: ObjectConstructor;
|
|
14
|
+
endProps: ObjectConstructor;
|
|
15
|
+
}, {
|
|
16
|
+
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
17
|
+
modelValue: import("../../../utils").EpPropFinalized<ArrayConstructor, unknown, unknown, () => never[], boolean>;
|
|
18
|
+
size: {
|
|
19
|
+
readonly type: import("vue").PropType<import("../../../utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
20
|
+
readonly required: false;
|
|
21
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
22
|
+
__epPropKey: true;
|
|
23
|
+
};
|
|
24
|
+
disabled: BooleanConstructor;
|
|
25
|
+
clearable: import("../../../utils").EpPropFinalized<BooleanConstructor, unknown, unknown, boolean, boolean>;
|
|
26
|
+
startPlaceholder: StringConstructor;
|
|
27
|
+
endPlaceholder: StringConstructor;
|
|
28
|
+
startProps: ObjectConstructor;
|
|
29
|
+
endProps: ObjectConstructor;
|
|
30
|
+
}>> & {
|
|
31
|
+
"onUpdate:modelValue"?: ((val: string[]) => any) | undefined;
|
|
32
|
+
onChange?: ((val: string[]) => any) | undefined;
|
|
33
|
+
}>>;
|
|
34
|
+
emit: ((event: "update:modelValue", val: string[]) => void) & ((event: "change", val: string[]) => void);
|
|
35
|
+
startValue: import("vue").Ref<unknown>;
|
|
36
|
+
endValue: import("vue").Ref<unknown>;
|
|
37
|
+
nsInput: {
|
|
38
|
+
namespace: import("vue").ComputedRef<string>;
|
|
39
|
+
b: (blockSuffix?: string) => string;
|
|
40
|
+
e: (element?: string | undefined) => string;
|
|
41
|
+
m: (modifier?: string | undefined) => string;
|
|
42
|
+
be: (blockSuffix?: string | undefined, element?: string | undefined) => string;
|
|
43
|
+
em: (element?: string | undefined, modifier?: string | undefined) => string;
|
|
44
|
+
bm: (blockSuffix?: string | undefined, modifier?: string | undefined) => string;
|
|
45
|
+
bem: (blockSuffix?: string | undefined, element?: string | undefined, modifier?: string | undefined) => string;
|
|
46
|
+
is: {
|
|
47
|
+
(name: string, state: boolean | undefined): string;
|
|
48
|
+
(name: string): string;
|
|
49
|
+
};
|
|
50
|
+
cssVar: (object: Record<string, string>) => Record<string, string>;
|
|
51
|
+
cssVarName: (name: string) => string;
|
|
52
|
+
cssVarBlock: (object: Record<string, string>) => Record<string, string>;
|
|
53
|
+
cssVarBlockName: (name: string) => string;
|
|
54
|
+
};
|
|
55
|
+
formSize: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
56
|
+
formDisabled: import("vue").ComputedRef<boolean>;
|
|
57
|
+
trueSize: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
58
|
+
trueDisabled: import("vue").ComputedRef<boolean>;
|
|
59
|
+
containerCls: import("vue").ComputedRef<string[]>;
|
|
60
|
+
change: () => void;
|
|
61
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
62
|
+
"update:modelValue": (val: string[]) => boolean;
|
|
63
|
+
change: (val: string[]) => boolean;
|
|
64
|
+
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
65
|
+
modelValue: import("../../../utils").EpPropFinalized<ArrayConstructor, unknown, unknown, () => never[], boolean>;
|
|
66
|
+
size: {
|
|
67
|
+
readonly type: import("vue").PropType<import("../../../utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
68
|
+
readonly required: false;
|
|
69
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
70
|
+
__epPropKey: true;
|
|
71
|
+
};
|
|
72
|
+
disabled: BooleanConstructor;
|
|
73
|
+
clearable: import("../../../utils").EpPropFinalized<BooleanConstructor, unknown, unknown, boolean, boolean>;
|
|
74
|
+
startPlaceholder: StringConstructor;
|
|
75
|
+
endPlaceholder: StringConstructor;
|
|
76
|
+
startProps: ObjectConstructor;
|
|
77
|
+
endProps: ObjectConstructor;
|
|
78
|
+
}>> & {
|
|
79
|
+
"onUpdate:modelValue"?: ((val: string[]) => any) | undefined;
|
|
80
|
+
onChange?: ((val: string[]) => any) | undefined;
|
|
81
|
+
}, {
|
|
82
|
+
modelValue: unknown[];
|
|
83
|
+
disabled: boolean;
|
|
84
|
+
clearable: import("../../../utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
85
|
+
}>;
|
|
86
|
+
export default _default;
|