xrk-components 2.0.0-beta.73 → 2.0.0-beta.75
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/lib/index.esm.js
CHANGED
|
@@ -74141,7 +74141,7 @@ script$i.__file = "packages/xrk/search/search.vue";
|
|
|
74141
74141
|
|
|
74142
74142
|
var __default__$f = { name: 'base-cascader' };
|
|
74143
74143
|
var script$h = /*#__PURE__*/ defineComponent(__assign(__assign({}, __default__$f), { props: {
|
|
74144
|
-
options: { type: [Array, Function], required:
|
|
74144
|
+
options: { type: [Array, Function], required: false },
|
|
74145
74145
|
modelValue: { type: null, required: false },
|
|
74146
74146
|
size: { type: String, required: false },
|
|
74147
74147
|
placeholder: { type: String, required: false },
|
|
@@ -74177,6 +74177,8 @@ var script$h = /*#__PURE__*/ defineComponent(__assign(__assign({}, __default__$f
|
|
|
74177
74177
|
});
|
|
74178
74178
|
var cascaderOptions = computed(function () {
|
|
74179
74179
|
var _a;
|
|
74180
|
+
if (!_props.options)
|
|
74181
|
+
return [];
|
|
74180
74182
|
if (typeof _props.options === 'function') {
|
|
74181
74183
|
return (_a = _props.options) === null || _a === void 0 ? void 0 : _a.call(_props, _props.modelValue);
|
|
74182
74184
|
}
|
|
@@ -76918,11 +76920,12 @@ var script$2 = /*#__PURE__*/ defineComponent(__assign(__assign({}, __default__$2
|
|
|
76918
76920
|
}
|
|
76919
76921
|
return !props.hideMenu;
|
|
76920
76922
|
});
|
|
76923
|
+
var dateNow = Date.now();
|
|
76921
76924
|
var menusMap = new Map();
|
|
76922
76925
|
var currentMenu = ref();
|
|
76923
76926
|
var menuBase = computed(function () {
|
|
76924
76927
|
var menuArr = props.menus.map(function (menu, index) {
|
|
76925
|
-
return __assign(__assign({}, menu), { menuKey: (menu === null || menu === void 0 ? void 0 : menu.menuKey) || index +
|
|
76928
|
+
return __assign(__assign({}, menu), { menuKey: (menu === null || menu === void 0 ? void 0 : menu.menuKey) || index + dateNow, url: (menu === null || menu === void 0 ? void 0 : menu.url) || index + dateNow });
|
|
76926
76929
|
});
|
|
76927
76930
|
setMenuMap(menuArr, menusMap);
|
|
76928
76931
|
return menuArr;
|
package/lib/index.umd.js
CHANGED
|
@@ -74144,7 +74144,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
|
|
|
74144
74144
|
|
|
74145
74145
|
var __default__$f = { name: 'base-cascader' };
|
|
74146
74146
|
var script$h = /*#__PURE__*/ vue.defineComponent(__assign(__assign({}, __default__$f), { props: {
|
|
74147
|
-
options: { type: [Array, Function], required:
|
|
74147
|
+
options: { type: [Array, Function], required: false },
|
|
74148
74148
|
modelValue: { type: null, required: false },
|
|
74149
74149
|
size: { type: String, required: false },
|
|
74150
74150
|
placeholder: { type: String, required: false },
|
|
@@ -74180,6 +74180,8 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
|
|
|
74180
74180
|
});
|
|
74181
74181
|
var cascaderOptions = vue.computed(function () {
|
|
74182
74182
|
var _a;
|
|
74183
|
+
if (!_props.options)
|
|
74184
|
+
return [];
|
|
74183
74185
|
if (typeof _props.options === 'function') {
|
|
74184
74186
|
return (_a = _props.options) === null || _a === void 0 ? void 0 : _a.call(_props, _props.modelValue);
|
|
74185
74187
|
}
|
|
@@ -76921,11 +76923,12 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
|
|
|
76921
76923
|
}
|
|
76922
76924
|
return !props.hideMenu;
|
|
76923
76925
|
});
|
|
76926
|
+
var dateNow = Date.now();
|
|
76924
76927
|
var menusMap = new Map();
|
|
76925
76928
|
var currentMenu = vue.ref();
|
|
76926
76929
|
var menuBase = vue.computed(function () {
|
|
76927
76930
|
var menuArr = props.menus.map(function (menu, index) {
|
|
76928
|
-
return __assign(__assign({}, menu), { menuKey: (menu === null || menu === void 0 ? void 0 : menu.menuKey) || index +
|
|
76931
|
+
return __assign(__assign({}, menu), { menuKey: (menu === null || menu === void 0 ? void 0 : menu.menuKey) || index + dateNow, url: (menu === null || menu === void 0 ? void 0 : menu.url) || index + dateNow });
|
|
76929
76932
|
});
|
|
76930
76933
|
setMenuMap(menuArr, menusMap);
|
|
76931
76934
|
return menuArr;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<{
|
|
2
2
|
options: {
|
|
3
3
|
type: (ArrayConstructor | FunctionConstructor)[];
|
|
4
|
-
required:
|
|
4
|
+
required: false;
|
|
5
5
|
};
|
|
6
6
|
modelValue: {
|
|
7
7
|
type: null;
|
|
@@ -122,7 +122,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
122
122
|
}>, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "change" | "expand-change" | "blur" | "focus" | "visible-change" | "remove-tag")[], "update:modelValue" | "change" | "expand-change" | "blur" | "focus" | "visible-change" | "remove-tag", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
123
123
|
options: {
|
|
124
124
|
type: (ArrayConstructor | FunctionConstructor)[];
|
|
125
|
-
required:
|
|
125
|
+
required: false;
|
|
126
126
|
};
|
|
127
127
|
modelValue: {
|
|
128
128
|
type: null;
|
|
@@ -26,7 +26,7 @@ export interface BaseCascaderProps extends BaseCascaderListener, Omit<CascaderPr
|
|
|
26
26
|
* 选择项
|
|
27
27
|
* 可通过函数形式,动态修改选择项的配置(activeValue 是当前 选择的内容)
|
|
28
28
|
*/
|
|
29
|
-
options
|
|
29
|
+
options?: Array<OptionProps> | ((activeValue: Array<any>) => Array<OptionProps>);
|
|
30
30
|
size?: 'large' | 'default' | 'small';
|
|
31
31
|
placeholder?: string;
|
|
32
32
|
disabled?: boolean;
|