mrxy-yk 1.8.2 → 1.8.4

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.
@@ -2,8 +2,10 @@ import { ObjectUtil } from "../../utils/prototype/lib/ObjectUtil.js";
2
2
  import { EmptyGlobal } from "./index.js";
3
3
  import { EmptyStatusExtendConfig } from "../../config/index.js";
4
4
  import { EmptyStatusConfig } from "./config.js";
5
- import { computed, createCommentVNode, createElementBlock, createElementVNode, defineComponent, normalizeClass, normalizeStyle, onMounted, openBlock, ref, renderSlot, toDisplayString, unref, watch, withDirectives } from "vue";
6
- import { ElLoadingDirective } from "element-plus/es";
5
+ import { computed, createCommentVNode, createElementBlock, createElementVNode, defineComponent, normalizeClass, normalizeStyle, onMounted, openBlock, ref, renderSlot, toDisplayString, unref, useTemplateRef, watch, watchEffect } from "vue";
6
+ import { ElLoading } from "element-plus/es";
7
+ import "element-plus/es/components/base/style/css";
8
+ import "element-plus/es/components/loading/style/css";
7
9
  //#region src/components/empty/Empty.vue?vue&type=script&setup=true&lang.ts
8
10
  var _hoisted_1 = {
9
11
  key: 0,
@@ -56,16 +58,27 @@ var Empty_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComp
56
58
  });
57
59
  watch(() => props.hook?.state.value, updateStatus, { deep: true });
58
60
  watch(() => props.state, updateStatus, { deep: true });
61
+ const ykEmptyRef = useTemplateRef("yk-empty");
62
+ let ykEmptyLoading = null;
63
+ watchEffect(() => {
64
+ if (currentEmpty.value.type === "LOADING") ykEmptyLoading = ElLoading.service({ target: ykEmptyRef.value });
65
+ else if (ykEmptyLoading) {
66
+ ykEmptyLoading.close();
67
+ ykEmptyLoading = null;
68
+ }
69
+ });
59
70
  return (_ctx, _cache) => {
60
- const _directive_loading = ElLoadingDirective;
61
- return withDirectives((openBlock(), createElementBlock("div", { class: normalizeClass(["yk-empty", [`yk-empty--${unref(currentEmpty).type}`]]) }, [unref(isShowEmpty) ? (openBlock(), createElementBlock("div", _hoisted_1, [
71
+ return openBlock(), createElementBlock("div", {
72
+ ref: "yk-empty",
73
+ class: normalizeClass(["yk-empty", [`yk-empty--${unref(currentEmpty).type}`]])
74
+ }, [unref(isShowEmpty) ? (openBlock(), createElementBlock("div", _hoisted_1, [
62
75
  createElementVNode("div", {
63
76
  class: "empty__image",
64
77
  style: normalizeStyle(unref(emptyImageStyle))
65
78
  }, null, 4),
66
79
  createElementVNode("div", _hoisted_2, toDisplayString(unref(currentEmpty).description), 1),
67
80
  createElementVNode("div", _hoisted_3, [renderSlot(_ctx.$slots, "footer", { type: unref(currentEmpty).type })])
68
- ])) : createCommentVNode("", true), createElementVNode("div", { class: normalizeClass(["empty_content", { "is-hide": unref(isShowEmpty) }]) }, [renderSlot(_ctx.$slots, "default")], 2)], 2)), [[_directive_loading, unref(currentEmpty).type === "LOADING"]]);
81
+ ])) : createCommentVNode("", true), createElementVNode("div", { class: normalizeClass(["empty_content", { "is-hide": unref(isShowEmpty) }]) }, [renderSlot(_ctx.$slots, "default")], 2)], 2);
69
82
  };
70
83
  }
71
84
  });
@@ -104,7 +104,7 @@ var DatePicker_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defin
104
104
  placeholder: "选择日期",
105
105
  "start-placeholder": "开始日期",
106
106
  "end-placeholder": "结束日期",
107
- "default-time": defaultTime,
107
+ "default-time": props.type === "datetimerange" ? defaultTime : void 0,
108
108
  "disabled-date": disabledDate,
109
109
  shortcuts: unref(dateShortcuts),
110
110
  "unlink-panels": props.unlinkPanels,
@@ -114,6 +114,7 @@ var DatePicker_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defin
114
114
  "type",
115
115
  "clearable",
116
116
  "editable",
117
+ "default-time",
117
118
  "shortcuts",
118
119
  "unlink-panels"
119
120
  ]);
@@ -1,9 +1,9 @@
1
1
  import { ObjectUtil } from "../../../utils/prototype/lib/ObjectUtil.js";
2
2
  import { createBlock, createElementVNode, createTextVNode, createVNode, defineComponent, normalizeClass, openBlock, provide, renderSlot, shallowRef, toRefs, unref, useTemplateRef, watchEffect, withCtx } from "vue";
3
3
  import { ElButton, ElDialog, ElForm, ElLoading } from "element-plus/es";
4
- import mitt from "mitt";
5
4
  import "element-plus/es/components/base/style/css";
6
5
  import "element-plus/es/components/loading/style/css";
6
+ import mitt from "mitt";
7
7
  //#region src/element-plus/components/form-dialog/FormDialog.vue?vue&type=script&setup=true&lang.ts
8
8
  var _hoisted_1 = { class: "c_form__submit-btn" };
9
9
  var FormDialog_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent({
@@ -1,10 +1,23 @@
1
1
  import { TableColumnCtx } from 'element-plus';
2
2
  import { VNode, DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
+ import { DefaultRow } from 'element-plus/es/components/table/src/table/defaults.mjs';
3
4
  type __VLS_Props = {
4
5
  emptyStr?: string;
5
6
  formatter?: ((row: any, column: TableColumnCtx, cellValue: any, index: number) => VNode) | string;
6
7
  };
7
- declare var __VLS_9: any, __VLS_12: any, __VLS_15: any, __VLS_18: any;
8
+ declare var __VLS_9: {
9
+ filterOpened: boolean;
10
+ }, __VLS_12: {
11
+ expanded: boolean;
12
+ expandable: boolean;
13
+ }, __VLS_15: {
14
+ column: TableColumnCtx< DefaultRow>;
15
+ $index: number;
16
+ }, __VLS_18: {
17
+ row: DefaultRow;
18
+ column: TableColumnCtx< DefaultRow>;
19
+ $index: number;
20
+ };
8
21
  type __VLS_Slots = {} & {
9
22
  'filter-icon'?: (props: typeof __VLS_9) => any;
10
23
  } & {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mrxy-yk",
3
- "version": "1.8.2",
3
+ "version": "1.8.4",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "A collection of Vue 3 components and utilities",