@nutui/nutui 4.3.0 → 4.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +21 -0
- package/dist/nutui.es.js +1 -1
- package/dist/nutui.js +5242 -5326
- package/dist/nutui.umd.js +1 -1
- package/dist/packages/actionsheet/ActionSheet.js +0 -2
- package/dist/packages/address/Address.js +0 -3
- package/dist/packages/addresslist/AddressList.js +0 -4
- package/dist/packages/audio/Audio.js +0 -3
- package/dist/packages/audiooperate/AudioOperate.js +0 -4
- package/dist/packages/avatar/Avatar.js +0 -1
- package/dist/packages/avatarcropper/AvatarCropper.js +0 -1
- package/dist/packages/calendar/Calendar.js +0 -6
- package/dist/packages/calendarcard/CalendarCard.js +0 -2
- package/dist/packages/calendaritem/CalendarItem.js +0 -2
- package/dist/packages/card/Card.js +0 -1
- package/dist/packages/cascader/Cascader.js +0 -9
- package/dist/packages/checkbox/Checkbox.js +4 -2
- package/dist/packages/collapse/Collapse.js +40 -28
- package/dist/packages/collapseitem/CollapseItem.js +112 -125
- package/dist/packages/comment/Comment.js +0 -5
- package/dist/packages/common-LvGbU-A3.js +13 -0
- package/dist/packages/countdown/Countdown.js +3 -4
- package/dist/packages/datepicker/DatePicker.js +0 -4
- package/dist/packages/dialog/Dialog.js +0 -4
- package/dist/packages/ecard/Ecard.js +0 -4
- package/dist/packages/empty/Empty.js +0 -2
- package/dist/packages/fixednav/FixedNav.js +0 -2
- package/dist/packages/form/Form.js +161 -157
- package/dist/packages/formitem/FormItem.js +76 -107
- package/dist/packages/grid/Grid.js +0 -1
- package/dist/packages/imagepreview/ImagePreview.js +0 -4
- package/dist/packages/{index.vue_vue_type_script_lang-MJYVRFbp.js → index.vue_vue_type_script_lang-w2sgcysj.js} +6 -4
- package/dist/packages/infiniteloading/InfiniteLoading.js +0 -1
- package/dist/packages/input/Input.js +10 -7
- package/dist/packages/inputnumber/InputNumber.js +11 -8
- package/dist/packages/invoice/Invoice.js +10 -21
- package/dist/packages/locale/lang/index.js +0 -1
- package/dist/packages/menuitem/MenuItem.js +0 -2
- package/dist/packages/notify/Notify.js +0 -3
- package/dist/packages/numberkeyboard/NumberKeyboard.js +0 -4
- package/dist/packages/pagination/Pagination.js +0 -2
- package/dist/packages/picker/Picker.js +10 -5
- package/dist/packages/popover/Popover.js +0 -3
- package/dist/packages/popup/Popup.js +0 -4
- package/dist/packages/pullrefresh/PullRefresh.js +0 -1
- package/dist/packages/radio/Radio.js +1 -6
- package/dist/packages/radiogroup/RadioGroup.js +0 -3
- package/dist/packages/range/Range.js +10 -7
- package/dist/packages/rate/Rate.js +6 -3
- package/dist/packages/searchbar/Searchbar.js +5 -4
- package/dist/packages/shortpassword/ShortPassword.js +0 -3
- package/dist/packages/signature/Signature.js +0 -4
- package/dist/packages/sku/Sku.js +5 -9
- package/dist/packages/switch/Switch.js +5 -3
- package/dist/packages/table/Table.js +0 -2
- package/dist/packages/tabs/Tabs.js +0 -1
- package/dist/packages/textarea/Textarea.js +7 -6
- package/dist/packages/timepannel/TimePannel.js +2 -2
- package/dist/packages/timeselect/TimeSelect.js +0 -4
- package/dist/packages/toast/Toast.js +3 -3
- package/dist/packages/tour/Tour.js +0 -4
- package/dist/packages/uploader/Uploader.js +7 -5
- package/dist/packages/video/Video.js +0 -2
- package/dist/smartips/web-types.json +11 -2
- package/dist/types/__VUE/address/index.vue.d.ts +43 -3
- package/dist/types/__VUE/collapse/collapse.vue.d.ts +60 -0
- package/dist/types/__VUE/collapse/index.d.ts +6 -0
- package/dist/types/__VUE/collapse/types.d.ts +3 -2
- package/dist/types/__VUE/collapseitem/collapse-item.vue.d.ts +201 -0
- package/dist/types/__VUE/collapseitem/index.d.ts +5 -0
- package/dist/types/__VUE/countdown/index.vue.d.ts +23 -1
- package/dist/types/__VUE/fixednav/index.vue.d.ts +2 -2
- package/dist/types/__VUE/form/common.d.ts +2 -30
- package/dist/types/__VUE/form/form.vue.d.ts +80 -0
- package/dist/types/__VUE/form/index.d.ts +6 -0
- package/dist/types/__VUE/form/types.d.ts +12 -4
- package/dist/types/__VUE/formitem/form-item.vue.d.ts +97 -0
- package/dist/types/__VUE/formitem/index.d.ts +5 -0
- package/dist/types/__VUE/input/index.vue.d.ts +2 -1
- package/dist/types/__VUE/inputnumber/index.vue.d.ts +1 -0
- package/dist/types/__VUE/picker/index.vue.d.ts +1 -0
- package/dist/types/__VUE/picker/types.d.ts +1 -0
- package/dist/types/__VUE/picker/usePicker.d.ts +1 -0
- package/dist/types/__VUE/range/index.vue.d.ts +1 -1
- package/dist/types/__VUE/rate/index.vue.d.ts +1 -0
- package/dist/types/__VUE/searchbar/index.vue.d.ts +1 -0
- package/dist/types/__VUE/skeleton/index.vue.d.ts +3 -3
- package/dist/types/__VUE/sku/components/SkuStepper.vue.d.ts +1 -1
- package/dist/types/__VUE/sku/index.vue.d.ts +1 -1
- package/dist/types/__VUE/table/index.vue.d.ts +4 -4
- package/dist/types/__VUE/tabs/index.vue.d.ts +4 -4
- package/dist/types/__VUE/textarea/index.vue.d.ts +1 -0
- package/dist/types/__VUE/toast/index.vue.d.ts +21 -1
- package/dist/types/index.d.ts +9 -5
- package/dist/types/utils/index.d.ts +1 -0
- package/package.json +1 -1
- package/dist/types/__VUE/collapse/index.vue.d.ts +0 -39
- package/dist/types/__VUE/collapseitem/index.vue.d.ts +0 -212
- package/dist/types/__VUE/form/index.vue.d.ts +0 -58
- package/dist/types/__VUE/formitem/index.vue.d.ts +0 -134
- package/dist/types/__VUE/formitem/types.d.ts +0 -11
|
@@ -22,8 +22,6 @@ import { useSlots, resolveComponent, openBlock, createBlock, withCtx, createElem
|
|
|
22
22
|
import { N as NutPopup, p as popupProps } from "../index-wY4t0zYt.js";
|
|
23
23
|
import { Loading } from "@nutui/icons-vue";
|
|
24
24
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
25
|
-
import "../overlay/Overlay.js";
|
|
26
|
-
import "../util-4Jkyw4BJ.js";
|
|
27
25
|
const { create } = createComponent("action-sheet");
|
|
28
26
|
const _sfc_main = create({
|
|
29
27
|
components: {
|
|
@@ -24,9 +24,6 @@ import { N as NutPopup, p as popupProps } from "../index-wY4t0zYt.js";
|
|
|
24
24
|
import NutElevator from "../elevator/Elevator.js";
|
|
25
25
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
26
26
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
27
|
-
import "../overlay/Overlay.js";
|
|
28
|
-
import "../util-4Jkyw4BJ.js";
|
|
29
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
30
27
|
const { create } = createComponent("address");
|
|
31
28
|
const cN = "NutAddress";
|
|
32
29
|
const _sfc_main = create({
|
|
@@ -6,10 +6,6 @@ import { Del, Edit } from "@nutui/icons-vue";
|
|
|
6
6
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
7
7
|
import { Button as _sfc_main$3 } from "../button/Button.js";
|
|
8
8
|
import NutSwipe from "../swipe/Swipe.js";
|
|
9
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
10
|
-
import "../with-install-p59gYYU_.js";
|
|
11
|
-
import "../index-084nl_oE.js";
|
|
12
|
-
import "../types-qOrhXtA_.js";
|
|
13
9
|
const { create: create$2 } = createComponent("address-list-item");
|
|
14
10
|
const cN$1 = "NutAddressList";
|
|
15
11
|
const _sfc_main$2 = create$2({
|
|
@@ -22,9 +22,6 @@ import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
|
22
22
|
import { Service } from "@nutui/icons-vue";
|
|
23
23
|
import NutRange from "../range/Range.js";
|
|
24
24
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
25
|
-
import "../util-4Jkyw4BJ.js";
|
|
26
|
-
import "../index-084nl_oE.js";
|
|
27
|
-
import "../index-cp6Ms_Qe.js";
|
|
28
25
|
const { create } = createComponent("audio");
|
|
29
26
|
const _sfc_main = create({
|
|
30
27
|
props: {
|
|
@@ -22,10 +22,6 @@ import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
|
22
22
|
import { Button as _sfc_main$1 } from "../button/Button.js";
|
|
23
23
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
24
24
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
25
|
-
import "@nutui/icons-vue";
|
|
26
|
-
import "../with-install-p59gYYU_.js";
|
|
27
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
28
|
-
import "../util-4Jkyw4BJ.js";
|
|
29
25
|
const { create } = createComponent("audio-operate");
|
|
30
26
|
const cN = "NutAudioOperate";
|
|
31
27
|
const _sfc_main = create({
|
|
@@ -46,7 +46,6 @@ import { Refresh2, Retweet } from "@nutui/icons-vue";
|
|
|
46
46
|
import { u as useTouch } from "../index-084nl_oE.js";
|
|
47
47
|
import { u as useRect } from "../index-cp6Ms_Qe.js";
|
|
48
48
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
49
|
-
import "../with-install-p59gYYU_.js";
|
|
50
49
|
const { create } = createComponent("avatar-cropper");
|
|
51
50
|
const _sfc_main = create({
|
|
52
51
|
components: {
|
|
@@ -4,12 +4,6 @@ import NutCalendarItem from "../calendaritem/CalendarItem.js";
|
|
|
4
4
|
import { N as NutPopup } from "../index-wY4t0zYt.js";
|
|
5
5
|
import { U as Utils } from "../date-djiVNSnJ.js";
|
|
6
6
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
7
|
-
import "../raf-MQjoO-Ag.js";
|
|
8
|
-
import "../index-s3RgMhc7.js";
|
|
9
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
10
|
-
import "../util-4Jkyw4BJ.js";
|
|
11
|
-
import "@nutui/icons-vue";
|
|
12
|
-
import "../overlay/Overlay.js";
|
|
13
7
|
const { create } = createComponent("calendar");
|
|
14
8
|
const _sfc_main = create({
|
|
15
9
|
components: {
|
|
@@ -21,8 +21,6 @@ import { h, defineComponent, ref, computed, watchEffect, withDirectives, openBlo
|
|
|
21
21
|
import { U as Utils } from "../date-djiVNSnJ.js";
|
|
22
22
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
23
23
|
import { w as withInstall } from "../with-install-p59gYYU_.js";
|
|
24
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
25
|
-
import "../util-4Jkyw4BJ.js";
|
|
26
24
|
const Left = () => {
|
|
27
25
|
return h(
|
|
28
26
|
"svg",
|
|
@@ -23,8 +23,6 @@ import { U as Utils } from "../date-djiVNSnJ.js";
|
|
|
23
23
|
import { r as requestAniFrame } from "../raf-MQjoO-Ag.js";
|
|
24
24
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
25
25
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
26
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
27
|
-
import "../util-4Jkyw4BJ.js";
|
|
28
26
|
const { create } = createComponent("calendar-item");
|
|
29
27
|
const cN = "NutCalendarItem";
|
|
30
28
|
const _sfc_main = create({
|
|
@@ -3,7 +3,6 @@ import { resolveComponent, openBlock, createElementBlock, createElementVNode, to
|
|
|
3
3
|
import NutPrice from "../price/Price.js";
|
|
4
4
|
import NutTag from "../tag/Tag.js";
|
|
5
5
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
6
|
-
import "@nutui/icons-vue";
|
|
7
6
|
const { create } = createComponent("card");
|
|
8
7
|
const _sfc_main = create({
|
|
9
8
|
components: {
|
|
@@ -62,15 +62,6 @@ import NutTabs from "../tabs/Tabs.js";
|
|
|
62
62
|
import NutTabPane from "../tabpane/TabPane.js";
|
|
63
63
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
64
64
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
65
|
-
import "../overlay/Overlay.js";
|
|
66
|
-
import "../util-4Jkyw4BJ.js";
|
|
67
|
-
import "../sticky/Sticky.js";
|
|
68
|
-
import "../index-xDfQLRen.js";
|
|
69
|
-
import "../index-cp6Ms_Qe.js";
|
|
70
|
-
import "../pxCheck-OnXlN1NC.js";
|
|
71
|
-
import "../raf-MQjoO-Ag.js";
|
|
72
|
-
import "../index-084nl_oE.js";
|
|
73
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
74
65
|
const formatTree = (tree, parent, config) => tree.map((node) => {
|
|
75
66
|
const { value: valueKey = "value", text: textKey = "text", children: childrenKey = "children" } = config;
|
|
76
67
|
const _a = node, { [valueKey]: value, [textKey]: text, [childrenKey]: children } = _a, others = __objRest(_a, [__restKey(valueKey), __restKey(textKey), __restKey(childrenKey)]);
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { inject, reactive, computed, watch, onMounted, getCurrentInstance, onBeforeUnmount, h } from "vue";
|
|
1
|
+
import { toRef, inject, reactive, computed, watch, onMounted, getCurrentInstance, onBeforeUnmount, h } from "vue";
|
|
2
2
|
import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
3
3
|
import { CheckNormal, Checked, CheckDisabled } from "@nutui/icons-vue";
|
|
4
4
|
import { p as pxCheck } from "../pxCheck-OnXlN1NC.js";
|
|
5
5
|
import { C as CHECKBOX_KEY } from "../types-zeKkNDAq.js";
|
|
6
|
+
import { u as useFormDisabled } from "../common-LvGbU-A3.js";
|
|
6
7
|
const { create, componentName } = createComponent("checkbox");
|
|
7
8
|
const _sfc_main = create({
|
|
8
9
|
props: {
|
|
@@ -38,6 +39,7 @@ const _sfc_main = create({
|
|
|
38
39
|
},
|
|
39
40
|
emits: ["change", "update:modelValue"],
|
|
40
41
|
setup(props, { emit, slots }) {
|
|
42
|
+
const disabled = useFormDisabled(toRef(props, "disabled"));
|
|
41
43
|
const parent = inject(CHECKBOX_KEY, null);
|
|
42
44
|
const state = reactive({
|
|
43
45
|
partialSelect: props.indeterminate
|
|
@@ -51,7 +53,7 @@ const _sfc_main = create({
|
|
|
51
53
|
}
|
|
52
54
|
});
|
|
53
55
|
const pDisabled = computed(() => {
|
|
54
|
-
return hasParent.value ? parent.disabled.value ? parent.disabled.value :
|
|
56
|
+
return hasParent.value ? parent.disabled.value ? parent.disabled.value : disabled.value : disabled.value;
|
|
55
57
|
});
|
|
56
58
|
const checked = computed(() => !!props.modelValue);
|
|
57
59
|
const color = computed(() => {
|
|
@@ -1,22 +1,38 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
import { defineComponent, ref, watch, provide, openBlock, createElementBlock, renderSlot } from "vue";
|
|
3
21
|
import { C as COLLAPSE_KEY } from "../types-4IflWeQO.js";
|
|
4
|
-
import {
|
|
5
|
-
const
|
|
6
|
-
const _sfc_main =
|
|
22
|
+
import { w as withInstall } from "../with-install-p59gYYU_.js";
|
|
23
|
+
const _hoisted_1 = { class: "nut-collapse" };
|
|
24
|
+
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
25
|
+
name: "NutCollapse"
|
|
26
|
+
}), {
|
|
27
|
+
__name: "collapse",
|
|
7
28
|
props: {
|
|
8
|
-
modelValue: {
|
|
9
|
-
|
|
10
|
-
default: ""
|
|
11
|
-
},
|
|
12
|
-
accordion: {
|
|
13
|
-
type: Boolean,
|
|
14
|
-
default: false
|
|
15
|
-
}
|
|
29
|
+
modelValue: { default: "" },
|
|
30
|
+
accordion: { type: Boolean, default: false }
|
|
16
31
|
},
|
|
17
32
|
emits: ["update:modelValue", "change"],
|
|
18
|
-
setup(
|
|
19
|
-
const
|
|
33
|
+
setup(__props, { emit: __emit }) {
|
|
34
|
+
const props = __props;
|
|
35
|
+
const emit = __emit;
|
|
20
36
|
const innerValue = ref(props.modelValue || (props.accordion ? "" : []));
|
|
21
37
|
watch(
|
|
22
38
|
() => props.modelValue,
|
|
@@ -62,19 +78,15 @@ const _sfc_main = create({
|
|
|
62
78
|
updateVal,
|
|
63
79
|
isExpanded
|
|
64
80
|
});
|
|
65
|
-
return
|
|
81
|
+
return (_ctx, _cache) => {
|
|
82
|
+
return openBlock(), createElementBlock("view", _hoisted_1, [
|
|
83
|
+
renderSlot(_ctx.$slots, "default")
|
|
84
|
+
]);
|
|
85
|
+
};
|
|
66
86
|
}
|
|
67
|
-
});
|
|
68
|
-
|
|
69
|
-
ref: "nutCollapseRef",
|
|
70
|
-
class: "nut-collapse"
|
|
71
|
-
};
|
|
72
|
-
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
73
|
-
return openBlock(), createElementBlock("view", _hoisted_1, [
|
|
74
|
-
renderSlot(_ctx.$slots, "default")
|
|
75
|
-
], 512);
|
|
76
|
-
}
|
|
77
|
-
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
87
|
+
}));
|
|
88
|
+
withInstall(_sfc_main);
|
|
78
89
|
export {
|
|
79
|
-
|
|
90
|
+
_sfc_main as Collapse,
|
|
91
|
+
_sfc_main as default
|
|
80
92
|
};
|
|
@@ -1,47 +1,60 @@
|
|
|
1
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
import { defineComponent, ref, inject, computed, watch, openBlock, createElementBlock, normalizeClass, createElementVNode, renderSlot, toDisplayString, createCommentVNode, normalizeStyle, createBlock, resolveDynamicComponent, unref } from "vue";
|
|
2
21
|
import { DownArrow } from "@nutui/icons-vue";
|
|
3
|
-
import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
4
22
|
import { r as renderIcon } from "../renderIcon--EgZu5_5.js";
|
|
5
23
|
import { C as COLLAPSE_KEY } from "../types-4IflWeQO.js";
|
|
6
|
-
import {
|
|
7
|
-
const
|
|
8
|
-
const
|
|
24
|
+
import { w as withInstall } from "../with-install-p59gYYU_.js";
|
|
25
|
+
const _hoisted_1 = { class: "nut-collapse-item__title-main" };
|
|
26
|
+
const _hoisted_2 = { class: "nut-collapse-item__title-main-value" };
|
|
27
|
+
const _hoisted_3 = ["innerHTML"];
|
|
28
|
+
const _hoisted_4 = {
|
|
29
|
+
key: 2,
|
|
30
|
+
class: "nut-collapse-item__title-label"
|
|
31
|
+
};
|
|
32
|
+
const _hoisted_5 = {
|
|
33
|
+
key: 0,
|
|
34
|
+
class: "nut-collapse-item__title-sub"
|
|
35
|
+
};
|
|
36
|
+
const _hoisted_6 = ["innerHTML"];
|
|
37
|
+
const _hoisted_7 = {
|
|
38
|
+
key: 0,
|
|
39
|
+
class: "nut-collapse__item-extraWrapper"
|
|
40
|
+
};
|
|
41
|
+
const _hoisted_8 = { class: "nut-collapse__item-extraWrapper__extraRender" };
|
|
42
|
+
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
43
|
+
name: "NutCollapseItem"
|
|
44
|
+
}), {
|
|
45
|
+
__name: "collapse-item",
|
|
9
46
|
props: {
|
|
10
|
-
title: {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
},
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
18
|
-
label: {
|
|
19
|
-
type: String,
|
|
20
|
-
default: ""
|
|
21
|
-
},
|
|
22
|
-
disabled: {
|
|
23
|
-
type: Boolean,
|
|
24
|
-
default: false
|
|
25
|
-
},
|
|
26
|
-
name: {
|
|
27
|
-
type: [Number, String],
|
|
28
|
-
default: -1,
|
|
29
|
-
required: true
|
|
30
|
-
},
|
|
31
|
-
border: {
|
|
32
|
-
type: Boolean,
|
|
33
|
-
default: true
|
|
34
|
-
},
|
|
35
|
-
icon: {
|
|
36
|
-
type: Object,
|
|
37
|
-
default: () => DownArrow
|
|
38
|
-
},
|
|
39
|
-
rotate: {
|
|
40
|
-
type: [String, Number],
|
|
41
|
-
default: 180
|
|
42
|
-
}
|
|
47
|
+
title: { default: "" },
|
|
48
|
+
value: { default: "" },
|
|
49
|
+
label: { default: "" },
|
|
50
|
+
disabled: { type: Boolean, default: false },
|
|
51
|
+
name: { default: -1 },
|
|
52
|
+
border: { type: Boolean, default: true },
|
|
53
|
+
icon: { default: () => DownArrow },
|
|
54
|
+
rotate: { default: 180 }
|
|
43
55
|
},
|
|
44
|
-
setup(
|
|
56
|
+
setup(__props) {
|
|
57
|
+
const props = __props;
|
|
45
58
|
const wrapperRef = ref(null);
|
|
46
59
|
const contentRef = ref(null);
|
|
47
60
|
const parent = inject(COLLAPSE_KEY);
|
|
@@ -90,93 +103,67 @@ const _sfc_main = create({
|
|
|
90
103
|
watch(expanded, (value) => {
|
|
91
104
|
value ? open() : close();
|
|
92
105
|
});
|
|
93
|
-
return {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
106
|
+
return (_ctx, _cache) => {
|
|
107
|
+
return openBlock(), createElementBlock("view", {
|
|
108
|
+
class: normalizeClass(classes.value)
|
|
109
|
+
}, [
|
|
110
|
+
createElementVNode("view", {
|
|
111
|
+
class: normalizeClass(["nut-collapse-item__title", { "nut-collapse-item__title--disabled": _ctx.disabled }]),
|
|
112
|
+
onClick: toggle
|
|
113
|
+
}, [
|
|
114
|
+
createElementVNode("view", _hoisted_1, [
|
|
115
|
+
createElementVNode("view", _hoisted_2, [
|
|
116
|
+
_ctx.$slots.title ? renderSlot(_ctx.$slots, "title", { key: 0 }) : (openBlock(), createElementBlock("view", {
|
|
117
|
+
key: 1,
|
|
118
|
+
class: "nut-collapse-item__title-mtitle",
|
|
119
|
+
innerHTML: _ctx.title
|
|
120
|
+
}, null, 8, _hoisted_3)),
|
|
121
|
+
_ctx.label ? (openBlock(), createElementBlock("view", _hoisted_4, toDisplayString(_ctx.label), 1)) : createCommentVNode("", true)
|
|
122
|
+
])
|
|
123
|
+
]),
|
|
124
|
+
_ctx.$slots.value ? (openBlock(), createElementBlock("view", _hoisted_5, [
|
|
125
|
+
renderSlot(_ctx.$slots, "value")
|
|
126
|
+
])) : (openBlock(), createElementBlock("view", {
|
|
127
|
+
key: 1,
|
|
128
|
+
class: "nut-collapse-item__title-sub",
|
|
129
|
+
innerHTML: _ctx.value
|
|
130
|
+
}, null, 8, _hoisted_6)),
|
|
131
|
+
createElementVNode("view", {
|
|
132
|
+
class: normalizeClass(["nut-collapse-item__title-icon", { "nut-collapse-item__title-icon--expanded": expanded.value }]),
|
|
133
|
+
style: normalizeStyle({ transform: "rotate(" + (expanded.value ? _ctx.rotate : 0) + "deg)" })
|
|
134
|
+
}, [
|
|
135
|
+
_ctx.$slots.icon ? renderSlot(_ctx.$slots, "icon", { key: 0 }) : (openBlock(), createBlock(resolveDynamicComponent(unref(renderIcon)(_ctx.icon)), { key: 1 }))
|
|
136
|
+
], 6)
|
|
137
|
+
], 2),
|
|
138
|
+
_ctx.$slots.extra ? (openBlock(), createElementBlock("view", _hoisted_7, [
|
|
139
|
+
createElementVNode("div", _hoisted_8, [
|
|
140
|
+
renderSlot(_ctx.$slots, "extra")
|
|
141
|
+
])
|
|
142
|
+
])) : createCommentVNode("", true),
|
|
143
|
+
createElementVNode("view", {
|
|
144
|
+
ref_key: "wrapperRef",
|
|
145
|
+
ref: wrapperRef,
|
|
146
|
+
class: "nut-collapse__item-wrapper",
|
|
147
|
+
style: normalizeStyle({
|
|
148
|
+
willChange: "height",
|
|
149
|
+
height: wrapperHeight.value
|
|
150
|
+
}),
|
|
151
|
+
onTransitionend: onTransitionEnd
|
|
152
|
+
}, [
|
|
153
|
+
createElementVNode("view", {
|
|
154
|
+
ref_key: "contentRef",
|
|
155
|
+
ref: contentRef,
|
|
156
|
+
class: "nut-collapse__item-wrapper__content"
|
|
157
|
+
}, [
|
|
158
|
+
renderSlot(_ctx.$slots, "default")
|
|
159
|
+
], 512)
|
|
160
|
+
], 36)
|
|
161
|
+
], 2);
|
|
103
162
|
};
|
|
104
163
|
}
|
|
105
|
-
});
|
|
106
|
-
|
|
107
|
-
const _hoisted_2 = { class: "nut-collapse-item__title-main-value" };
|
|
108
|
-
const _hoisted_3 = ["innerHTML"];
|
|
109
|
-
const _hoisted_4 = {
|
|
110
|
-
key: 2,
|
|
111
|
-
class: "nut-collapse-item__title-label"
|
|
112
|
-
};
|
|
113
|
-
const _hoisted_5 = {
|
|
114
|
-
key: 0,
|
|
115
|
-
class: "nut-collapse-item__title-sub"
|
|
116
|
-
};
|
|
117
|
-
const _hoisted_6 = ["innerHTML"];
|
|
118
|
-
const _hoisted_7 = {
|
|
119
|
-
key: 0,
|
|
120
|
-
class: "nut-collapse__item-extraWrapper"
|
|
121
|
-
};
|
|
122
|
-
const _hoisted_8 = { class: "nut-collapse__item-extraWrapper__extraRender" };
|
|
123
|
-
const _hoisted_9 = {
|
|
124
|
-
ref: "contentRef",
|
|
125
|
-
class: "nut-collapse__item-wrapper__content"
|
|
126
|
-
};
|
|
127
|
-
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
128
|
-
return openBlock(), createElementBlock("view", {
|
|
129
|
-
class: normalizeClass(_ctx.classes)
|
|
130
|
-
}, [
|
|
131
|
-
createElementVNode("view", {
|
|
132
|
-
class: normalizeClass(["nut-collapse-item__title", { "nut-collapse-item__title--disabled": _ctx.disabled }]),
|
|
133
|
-
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.toggle && _ctx.toggle(...args))
|
|
134
|
-
}, [
|
|
135
|
-
createElementVNode("view", _hoisted_1, [
|
|
136
|
-
createElementVNode("view", _hoisted_2, [
|
|
137
|
-
_ctx.$slots.title ? renderSlot(_ctx.$slots, "title", { key: 0 }) : (openBlock(), createElementBlock("view", {
|
|
138
|
-
key: 1,
|
|
139
|
-
class: "nut-collapse-item__title-mtitle",
|
|
140
|
-
innerHTML: _ctx.title
|
|
141
|
-
}, null, 8, _hoisted_3)),
|
|
142
|
-
_ctx.label ? (openBlock(), createElementBlock("view", _hoisted_4, toDisplayString(_ctx.label), 1)) : createCommentVNode("", true)
|
|
143
|
-
])
|
|
144
|
-
]),
|
|
145
|
-
_ctx.$slots.value ? (openBlock(), createElementBlock("view", _hoisted_5, [
|
|
146
|
-
renderSlot(_ctx.$slots, "value")
|
|
147
|
-
])) : (openBlock(), createElementBlock("view", {
|
|
148
|
-
key: 1,
|
|
149
|
-
class: "nut-collapse-item__title-sub",
|
|
150
|
-
innerHTML: _ctx.value
|
|
151
|
-
}, null, 8, _hoisted_6)),
|
|
152
|
-
createElementVNode("view", {
|
|
153
|
-
class: normalizeClass(["nut-collapse-item__title-icon", { "nut-collapse-item__title-icon--expanded": _ctx.expanded }]),
|
|
154
|
-
style: normalizeStyle({ transform: "rotate(" + (_ctx.expanded ? _ctx.rotate : 0) + "deg)" })
|
|
155
|
-
}, [
|
|
156
|
-
_ctx.$slots.icon ? renderSlot(_ctx.$slots, "icon", { key: 0 }) : (openBlock(), createBlock(resolveDynamicComponent(_ctx.renderIcon(_ctx.icon)), { key: 1 }))
|
|
157
|
-
], 6)
|
|
158
|
-
], 2),
|
|
159
|
-
_ctx.$slots.extra ? (openBlock(), createElementBlock("view", _hoisted_7, [
|
|
160
|
-
createElementVNode("div", _hoisted_8, [
|
|
161
|
-
renderSlot(_ctx.$slots, "extra")
|
|
162
|
-
])
|
|
163
|
-
])) : createCommentVNode("", true),
|
|
164
|
-
createElementVNode("view", {
|
|
165
|
-
ref: "wrapperRef",
|
|
166
|
-
class: "nut-collapse__item-wrapper",
|
|
167
|
-
style: normalizeStyle({
|
|
168
|
-
willChange: "height",
|
|
169
|
-
height: _ctx.wrapperHeight
|
|
170
|
-
}),
|
|
171
|
-
onTransitionend: _cache[1] || (_cache[1] = (...args) => _ctx.onTransitionEnd && _ctx.onTransitionEnd(...args))
|
|
172
|
-
}, [
|
|
173
|
-
createElementVNode("view", _hoisted_9, [
|
|
174
|
-
renderSlot(_ctx.$slots, "default")
|
|
175
|
-
], 512)
|
|
176
|
-
], 36)
|
|
177
|
-
], 2);
|
|
178
|
-
}
|
|
179
|
-
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
164
|
+
}));
|
|
165
|
+
withInstall(_sfc_main);
|
|
180
166
|
export {
|
|
181
|
-
|
|
167
|
+
_sfc_main as CollapseItem,
|
|
168
|
+
_sfc_main as default
|
|
182
169
|
};
|
|
@@ -4,11 +4,6 @@ import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
|
4
4
|
import NutRate from "../rate/Rate.js";
|
|
5
5
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
6
6
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
7
|
-
import "../renderIcon--EgZu5_5.js";
|
|
8
|
-
import "../pxCheck-OnXlN1NC.js";
|
|
9
|
-
import "../index-084nl_oE.js";
|
|
10
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
11
|
-
import "../util-4Jkyw4BJ.js";
|
|
12
7
|
const { create: create$3 } = createComponent("comment-header");
|
|
13
8
|
const _sfc_main$3 = create$3({
|
|
14
9
|
components: {
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { computed } from "vue";
|
|
2
|
+
import { u as useParent } from "./useParent-KIxqkovs.js";
|
|
3
|
+
import { F as FORM_KEY } from "./types-Ynmct7na.js";
|
|
4
|
+
const useFormDisabled = (disabled) => {
|
|
5
|
+
const { parent } = useParent(FORM_KEY);
|
|
6
|
+
return computed(() => {
|
|
7
|
+
var _a;
|
|
8
|
+
return disabled.value || ((_a = parent == null ? void 0 : parent.props) == null ? void 0 : _a.disabled) || false;
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
export {
|
|
12
|
+
useFormDisabled as u
|
|
13
|
+
};
|
|
@@ -22,7 +22,6 @@ import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
|
22
22
|
import { p as padZero } from "../util-4Jkyw4BJ.js";
|
|
23
23
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
24
24
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
25
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
26
25
|
const getTimeStamp = (timeStr) => {
|
|
27
26
|
if (!timeStr)
|
|
28
27
|
return Date.now();
|
|
@@ -107,7 +106,7 @@ const _sfc_main = create({
|
|
|
107
106
|
return formatRemainTime(state.restTime);
|
|
108
107
|
});
|
|
109
108
|
const initTime = () => {
|
|
110
|
-
state.handleEndTime = props.endTime;
|
|
109
|
+
state.handleEndTime = Number(props.endTime);
|
|
111
110
|
state.diffTime = Date.now() - getTimeStamp(props.startTime);
|
|
112
111
|
if (!state.counting)
|
|
113
112
|
state.counting = true;
|
|
@@ -208,14 +207,14 @@ const _sfc_main = create({
|
|
|
208
207
|
const reset = () => {
|
|
209
208
|
if (!props.autoStart) {
|
|
210
209
|
pause();
|
|
211
|
-
state.restTime = props.time;
|
|
210
|
+
state.restTime = Number(props.time);
|
|
212
211
|
}
|
|
213
212
|
};
|
|
214
213
|
onBeforeMount(() => {
|
|
215
214
|
if (props.autoStart) {
|
|
216
215
|
initTime();
|
|
217
216
|
} else {
|
|
218
|
-
state.restTime = props.time;
|
|
217
|
+
state.restTime = Number(props.time);
|
|
219
218
|
}
|
|
220
219
|
});
|
|
221
220
|
watch(
|
|
@@ -22,10 +22,6 @@ import NutPicker from "../picker/Picker.js";
|
|
|
22
22
|
import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
23
23
|
import { c as isDate$1, p as padZero } from "../util-4Jkyw4BJ.js";
|
|
24
24
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
25
|
-
import "../pxCheck-OnXlN1NC.js";
|
|
26
|
-
import "../index-084nl_oE.js";
|
|
27
|
-
import "../index-s3RgMhc7.js";
|
|
28
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
29
25
|
const { create } = createComponent("date-picker");
|
|
30
26
|
const currentYear = (/* @__PURE__ */ new Date()).getFullYear();
|
|
31
27
|
function isDate(val) {
|
|
@@ -30,10 +30,6 @@ import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
|
30
30
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
31
31
|
import NutOverlay from "../overlay/Overlay.js";
|
|
32
32
|
import { C as CreateComponent } from "../mountComponent-uInXoTMp.js";
|
|
33
|
-
import "../util-4Jkyw4BJ.js";
|
|
34
|
-
import "@nutui/icons-vue";
|
|
35
|
-
import "../with-install-p59gYYU_.js";
|
|
36
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
37
33
|
const { create } = createComponent("dialog");
|
|
38
34
|
const cN = "NutDialog";
|
|
39
35
|
const _sfc_main = create({
|
|
@@ -3,10 +3,6 @@ import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
|
3
3
|
import NutInputNumber from "../inputnumber/InputNumber.js";
|
|
4
4
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
5
5
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
6
|
-
import "../pxCheck-OnXlN1NC.js";
|
|
7
|
-
import "@nutui/icons-vue";
|
|
8
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
9
|
-
import "../util-4Jkyw4BJ.js";
|
|
10
6
|
const { create } = createComponent("ecard");
|
|
11
7
|
const cN = "NutEcard";
|
|
12
8
|
const _sfc_main = create({
|
|
@@ -3,8 +3,6 @@ import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
|
3
3
|
import { p as pxCheck } from "../pxCheck-OnXlN1NC.js";
|
|
4
4
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
5
5
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
6
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
7
|
-
import "../util-4Jkyw4BJ.js";
|
|
8
6
|
const { create } = createComponent("empty");
|
|
9
7
|
const cN = "NutEmpty";
|
|
10
8
|
const defaultStatus = {
|
|
@@ -4,8 +4,6 @@ import NutOverlay from "../overlay/Overlay.js";
|
|
|
4
4
|
import { c as createComponent } from "../component-TCzwHGVq.js";
|
|
5
5
|
import { u as useLocale } from "../index-s3RgMhc7.js";
|
|
6
6
|
import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
|
|
7
|
-
import "../util-4Jkyw4BJ.js";
|
|
8
|
-
import "@nutui/nutui/dist/packages/locale/lang";
|
|
9
7
|
const { create } = createComponent("fixed-nav");
|
|
10
8
|
const cN = "NutFixedNav";
|
|
11
9
|
const _sfc_main = create({
|