@moment-design/material-library 0.1.21 → 0.1.22

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.
@@ -37,8 +37,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
37
37
  default: () => {};
38
38
  };
39
39
  }>> & Readonly<{}>, {
40
- datas: unknown[];
41
40
  config: Record<string, any>;
41
+ datas: unknown[];
42
42
  }, {}, {
43
43
  IconMore: {
44
44
  new (...args: any[]): {
@@ -36,8 +36,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
36
36
  default: () => {};
37
37
  };
38
38
  }>> & Readonly<{}>, {
39
- datas: unknown[];
40
39
  config: Record<string, any>;
40
+ datas: unknown[];
41
41
  }, {}, {
42
42
  LTableOperate: any;
43
43
  }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
package/dist/c-right.d.ts CHANGED
@@ -554,8 +554,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
554
554
  default: () => {};
555
555
  };
556
556
  }>> & Readonly<{}>, {
557
- datas: unknown[];
558
557
  config: Record<string, any>;
558
+ datas: unknown[];
559
559
  }, {}, {
560
560
  IconMore: {
561
561
  new (...args: any[]): {
@@ -752,8 +752,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
752
752
  default: () => {};
753
753
  };
754
754
  }>> & Readonly<{}>, {
755
- datas: unknown[];
756
755
  config: Record<string, any>;
756
+ datas: unknown[];
757
757
  }, {}, {
758
758
  LTableOperate: any;
759
759
  }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -286,40 +286,40 @@
286
286
  .l-material-library-upload .upload[data-v-6b18ee10] .mo-upload-progress {
287
287
  display: none;
288
288
  }
289
- .l-material-library-right-content[data-v-2b9787ae] {
289
+ .l-material-library-right-content[data-v-6d3cc084] {
290
290
  flex: 1;
291
291
  }
292
- .l-material-library-right-content .header[data-v-2b9787ae] {
292
+ .l-material-library-right-content .header[data-v-6d3cc084] {
293
293
  display: flex;
294
294
  justify-content: space-between;
295
295
  }
296
- .l-material-library-right-content .header .left[data-v-2b9787ae] {
296
+ .l-material-library-right-content .header .left[data-v-6d3cc084] {
297
297
  display: flex;
298
298
  justify-content: space-between;
299
299
  }
300
- .l-material-library-right-content .header .more-icon-down[data-v-2b9787ae] {
300
+ .l-material-library-right-content .header .more-icon-down[data-v-6d3cc084] {
301
301
  position: relative;
302
302
  top: -1px;
303
303
  margin-left: 6px;
304
304
  font-size: 15px;
305
305
  stroke-width: 5;
306
306
  }
307
- .l-material-library-right-content .toolbar[data-v-2b9787ae] {
307
+ .l-material-library-right-content .toolbar[data-v-6d3cc084] {
308
308
  margin: 16px 0;
309
309
  display: flex;
310
310
  align-items: center;
311
311
  justify-content: space-between;
312
312
  }
313
- .l-material-library-right-content .toolbar .apps[data-v-2b9787ae],
314
- .l-material-library-right-content .toolbar .menu[data-v-2b9787ae] {
313
+ .l-material-library-right-content .toolbar .apps[data-v-6d3cc084],
314
+ .l-material-library-right-content .toolbar .menu[data-v-6d3cc084] {
315
315
  margin-left: 8px;
316
316
  font-size: 20px;
317
317
  stroke-width: 5;
318
318
  }
319
- .l-material-library-right-content .toolbar .apps[data-v-2b9787ae]:hover,
320
- .l-material-library-right-content .toolbar .menu[data-v-2b9787ae]:hover,
321
- .l-material-library-right-content .toolbar .apps.active[data-v-2b9787ae],
322
- .l-material-library-right-content .toolbar .menu.active[data-v-2b9787ae] {
319
+ .l-material-library-right-content .toolbar .apps[data-v-6d3cc084]:hover,
320
+ .l-material-library-right-content .toolbar .menu[data-v-6d3cc084]:hover,
321
+ .l-material-library-right-content .toolbar .apps.active[data-v-6d3cc084],
322
+ .l-material-library-right-content .toolbar .menu.active[data-v-6d3cc084] {
323
323
  color: #1966ff;
324
324
  cursor: pointer;
325
325
  }
package/dist/index.cjs.js CHANGED
@@ -7358,21 +7358,21 @@ const _sfc_main$1 = vue.defineComponent({
7358
7358
  emit("group:init");
7359
7359
  };
7360
7360
  const init = async (id) => {
7361
- var _a2, _b2, _c;
7361
+ var _a2, _b2, _c, _d, _e;
7362
7362
  try {
7363
7363
  groupId.value = id;
7364
7364
  loading.value = true;
7365
- if (fileName.value) {
7366
- pageNum.value = 1;
7367
- }
7368
- const res = await ((_b2 = (_a2 = deepConfig.value) == null ? void 0 : _a2.apis) == null ? void 0 : _b2.getFileList({
7365
+ pageNum.value = 1;
7366
+ (_a2 = refCRightMenus.value) == null ? void 0 : _a2.resetCurrent();
7367
+ (_b2 = refCRightApps.value) == null ? void 0 : _b2.resetCurrent();
7368
+ const res = await ((_d = (_c = deepConfig.value) == null ? void 0 : _c.apis) == null ? void 0 : _d.getFileList({
7369
7369
  groupId: groupId.value,
7370
7370
  fileName: fileName.value,
7371
7371
  fileType: fileType.value,
7372
7372
  pageNum: pageNum.value,
7373
7373
  pageSize: pageSize.value
7374
7374
  }));
7375
- if (((_c = [0, 200]) == null ? void 0 : _c.includes(+(res == null ? void 0 : res.code))) && (res == null ? void 0 : res.data)) {
7375
+ if (((_e = [0, 200]) == null ? void 0 : _e.includes(+(res == null ? void 0 : res.code))) && (res == null ? void 0 : res.data)) {
7376
7376
  datas.value = res == null ? void 0 : res.data;
7377
7377
  refCRightApps.value.initCheckbox();
7378
7378
  }
@@ -7625,7 +7625,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
7625
7625
  }, null, 8, ["visible", "src"])
7626
7626
  ], 64);
7627
7627
  }
7628
- var CRight = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-2b9787ae"]]);
7628
+ var CRight = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-6d3cc084"]]);
7629
7629
  var index_vue_vue_type_style_index_0_scoped_true_lang = "";
7630
7630
  const _sfc_main = vue.defineComponent({
7631
7631
  name: "MaterialLibrary",
package/dist/index.d.ts CHANGED
@@ -1102,8 +1102,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
1102
1102
  default: () => {};
1103
1103
  };
1104
1104
  }>> & Readonly<{}>, {
1105
- datas: unknown[];
1106
1105
  config: Record<string, any>;
1106
+ datas: unknown[];
1107
1107
  }, {}, {
1108
1108
  IconMore: {
1109
1109
  new (...args: any[]): {
@@ -1300,8 +1300,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
1300
1300
  default: () => {};
1301
1301
  };
1302
1302
  }>> & Readonly<{}>, {
1303
- datas: unknown[];
1304
1303
  config: Record<string, any>;
1304
+ datas: unknown[];
1305
1305
  }, {}, {
1306
1306
  LTableOperate: any;
1307
1307
  }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
package/dist/index.esm.js CHANGED
@@ -7357,21 +7357,21 @@ const _sfc_main$1 = defineComponent({
7357
7357
  emit("group:init");
7358
7358
  };
7359
7359
  const init = async (id) => {
7360
- var _a2, _b2, _c;
7360
+ var _a2, _b2, _c, _d, _e;
7361
7361
  try {
7362
7362
  groupId.value = id;
7363
7363
  loading.value = true;
7364
- if (fileName.value) {
7365
- pageNum.value = 1;
7366
- }
7367
- const res = await ((_b2 = (_a2 = deepConfig.value) == null ? void 0 : _a2.apis) == null ? void 0 : _b2.getFileList({
7364
+ pageNum.value = 1;
7365
+ (_a2 = refCRightMenus.value) == null ? void 0 : _a2.resetCurrent();
7366
+ (_b2 = refCRightApps.value) == null ? void 0 : _b2.resetCurrent();
7367
+ const res = await ((_d = (_c = deepConfig.value) == null ? void 0 : _c.apis) == null ? void 0 : _d.getFileList({
7368
7368
  groupId: groupId.value,
7369
7369
  fileName: fileName.value,
7370
7370
  fileType: fileType.value,
7371
7371
  pageNum: pageNum.value,
7372
7372
  pageSize: pageSize.value
7373
7373
  }));
7374
- if (((_c = [0, 200]) == null ? void 0 : _c.includes(+(res == null ? void 0 : res.code))) && (res == null ? void 0 : res.data)) {
7374
+ if (((_e = [0, 200]) == null ? void 0 : _e.includes(+(res == null ? void 0 : res.code))) && (res == null ? void 0 : res.data)) {
7375
7375
  datas.value = res == null ? void 0 : res.data;
7376
7376
  refCRightApps.value.initCheckbox();
7377
7377
  }
@@ -7624,7 +7624,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
7624
7624
  }, null, 8, ["visible", "src"])
7625
7625
  ], 64);
7626
7626
  }
7627
- var CRight = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-2b9787ae"]]);
7627
+ var CRight = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-6d3cc084"]]);
7628
7628
  var index_vue_vue_type_style_index_0_scoped_true_lang = "";
7629
7629
  const _sfc_main = defineComponent({
7630
7630
  name: "MaterialLibrary",
package/dist/index.min.js CHANGED
@@ -3341,11 +3341,11 @@
3341
3341
  var _a2, _b2, _c, _d;
3342
3342
  g2.value = "", p2.value = (_b2 = (_a2 = n2.config) == null ? void 0 : _a2.fileType) != null ? _b2 : "", h2.value = 1, G2(d2.value), (_c = f2.value) == null ? void 0 : _c.resetCurrent(), (_d = c2.value) == null ? void 0 : _d.resetCurrent(), r2("group:init");
3343
3343
  }, G2 = async (e2) => {
3344
- var _a2, _b2, _c;
3344
+ var _a2, _b2, _c, _d, _e2;
3345
3345
  try {
3346
- d2.value = e2, i2.value = true, g2.value && (h2.value = 1);
3347
- const t2 = await ((_b2 = (_a2 = o2.value) == null ? void 0 : _a2.apis) == null ? void 0 : _b2.getFileList({ groupId: d2.value, fileName: g2.value, fileType: p2.value, pageNum: h2.value, pageSize: w2.value }));
3348
- ((_c = [0, 200]) == null ? void 0 : _c.includes(+(t2 == null ? void 0 : t2.code))) && (t2 == null ? void 0 : t2.data) && (C2.value = t2 == null ? void 0 : t2.data, c2.value.initCheckbox());
3346
+ d2.value = e2, i2.value = true, h2.value = 1, (_a2 = f2.value) == null ? void 0 : _a2.resetCurrent(), (_b2 = c2.value) == null ? void 0 : _b2.resetCurrent();
3347
+ const t2 = await ((_d = (_c = o2.value) == null ? void 0 : _c.apis) == null ? void 0 : _d.getFileList({ groupId: d2.value, fileName: g2.value, fileType: p2.value, pageNum: h2.value, pageSize: w2.value }));
3348
+ ((_e2 = [0, 200]) == null ? void 0 : _e2.includes(+(t2 == null ? void 0 : t2.code))) && (t2 == null ? void 0 : t2.data) && (C2.value = t2 == null ? void 0 : t2.data, c2.value.initCheckbox());
3349
3349
  } catch (e3) {
3350
3350
  console.log(e3);
3351
3351
  } finally {
@@ -3399,7 +3399,7 @@
3399
3399
  var _a;
3400
3400
  return [e.createVNode(a2, { modelValue: t2.fileName, "onUpdate:modelValue": n2[0] || (n2[0] = (e2) => t2.fileName = e2), class: "input", "allow-clear": "", placeholder: "\u8BF7\u8F93\u5165\u7D20\u6750\u540D\u79F0", style: { width: "160px" } }, null, 8, ["modelValue"]), e.createVNode(l2, { modelValue: t2.fileType, "onUpdate:modelValue": n2[1] || (n2[1] = (e2) => t2.fileType = e2), class: "select", options: t2.fileTypes, disabled: [1, 2, 3, 4].includes((_a = t2.config) == null ? void 0 : _a.fileType), "allow-clear": "", placeholder: "\u8BF7\u9009\u62E9\u7D20\u6750\u7C7B\u578B", style: { width: "160px" } }, null, 8, ["modelValue", "options", "disabled"]), e.createVNode(c2, { type: "primary", onClick: n2[2] || (n2[2] = (e2) => t2.init(t2.groupId)) }, { default: e.withCtx(() => n2[12] || (n2[12] = [e.createTextVNode("\u67E5\u8BE2")])), _: 1 }), e.createVNode(c2, { onClick: t2.reset }, { default: e.withCtx(() => n2[13] || (n2[13] = [e.createTextVNode("\u91CD\u7F6E")])), _: 1 }, 8, ["onClick"])];
3401
3401
  }), _: 1 })) : e.createCommentVNode("v-if", true)]), t2.isShowUploadLocalMaterials || t2.isShowRemoveGroup || t2.isShowDeleteMaterials ? (e.openBlock(), e.createElementBlock("div", st, [e.createVNode(g2, { position: "br", trigger: "hover" }, { content: e.withCtx(() => [t2.isShowUploadLocalMaterials ? (e.openBlock(), e.createBlock(A2, { key: 0, onClick: n2[3] || (n2[3] = (e2) => t2.refCUpload.open(t2.groupId)) }, { default: e.withCtx(() => n2[15] || (n2[15] = [e.createTextVNode("\u4E0A\u4F20\u672C\u5730\u7D20\u6750")])), _: 1 })) : e.createCommentVNode("v-if", true), t2.isShowRemoveGroup ? (e.openBlock(), e.createBlock(A2, { key: 1, onClick: n2[4] || (n2[4] = (e2) => t2.getIds("\u79FB\u52A8\u5206\u7EC4")) }, { default: e.withCtx(() => n2[16] || (n2[16] = [e.createTextVNode("\u79FB\u52A8\u5206\u7EC4")])), _: 1 })) : e.createCommentVNode("v-if", true), t2.isShowDeleteMaterials ? (e.openBlock(), e.createBlock(A2, { key: 2, onClick: n2[5] || (n2[5] = (e2) => t2.getIds("\u5220\u9664")) }, { default: e.withCtx(() => n2[17] || (n2[17] = [e.createTextVNode("\u5220\u9664")])), _: 1 })) : e.createCommentVNode("v-if", true)]), default: e.withCtx(() => [e.createVNode(c2, { type: "primary" }, { default: e.withCtx(() => [n2[14] || (n2[14] = e.createTextVNode(" \u66F4\u591A\u64CD\u4F5C ")), e.createVNode(s2, { class: "more-icon-down" })]), _: 1 })]), _: 1 })])) : e.createCommentVNode("v-if", true)]), e.createCommentVNode(" toolbar "), e.createElementVNode("div", At, [n2[18] || (n2[18] = e.createElementVNode("div", null, null, -1)), e.createElementVNode("div", null, [e.createVNode(p2, { class: e.normalizeClass(["apps", 1 === t2.showType ? "active" : ""]), onClick: n2[6] || (n2[6] = (e2) => t2.showType = 1) }, null, 8, ["class"]), e.createVNode(v2, { class: e.normalizeClass(["menu", 2 === t2.showType ? "active" : ""]), onClick: n2[7] || (n2[7] = (e2) => t2.showType = 2) }, null, 8, ["class"])])]), e.createCommentVNode(" content "), e.createVNode(w2, { loading: t2.loading, style: { width: "100%" } }, { default: e.withCtx(() => [1 === t2.showType ? (e.openBlock(), e.createBlock(d2, { key: 0, ref: "refCRightApps", config: t2.config, datas: t2.datas, "onHandle:page": t2.handlePage, "onHandle:page:sizes": t2.handlePageSizes, "onHandle:preview": t2.handlePreview, "onHandle:remove": t2.handleRemove, "onHandle:move": n2[8] || (n2[8] = (e2) => t2.refCChangeGroup.open([e2.id])) }, null, 8, ["config", "datas", "onHandle:page", "onHandle:page:sizes", "onHandle:preview", "onHandle:remove"])) : e.createCommentVNode("v-if", true), 2 === t2.showType ? (e.openBlock(), e.createBlock(h2, { key: 1, ref: "refCRightMenus", config: t2.config, datas: t2.datas, "onHandle:page": t2.handlePage, "onHandle:page:sizes": t2.handlePageSizes, "onHandle:preview": t2.handlePreview, "onHandle:remove": t2.handleRemove, "onHandle:move": n2[9] || (n2[9] = (e2) => t2.refCChangeGroup.open([e2.id])) }, null, 8, ["config", "datas", "onHandle:page", "onHandle:page:sizes", "onHandle:preview", "onHandle:remove"])) : e.createCommentVNode("v-if", true)]), _: 1 }, 8, ["loading"])]), e.createVNode(C2, { title: "\u5220\u9664\u63D0\u793A", visible: t2.visible, others: { width: 390, okLoading: t2.removeLoading }, "onHandle:cancel": n2[10] || (n2[10] = (e2) => t2.visible = false), "onHandle:ok": t2.handleRemoveOk }, { default: e.withCtx(() => n2[19] || (n2[19] = [e.createTextVNode(" \u5220\u9664\u7D20\u6750\u540E\uFF0C\u5C06\u65E0\u6CD5\u88AB\u6062\u590D\u3002 ")])), _: 1 }, 8, ["visible", "others", "onHandle:ok"]), e.createCommentVNode(" \u4FEE\u6539\u5206\u7EC4 "), e.createVNode(B2, { ref: "refCChangeGroup", config: t2.deepConfig, "onMove:success": t2.reset }, null, 8, ["config", "onMove:success"]), e.createCommentVNode(" \u4E0A\u4F20\u7D20\u6750 "), e.createVNode(m2, { ref: "refCUpload", config: t2.deepConfig, "onUpload:success": t2.reset }, null, 8, ["config", "onUpload:success"]), e.createCommentVNode(" \u9884\u89C8 "), e.createVNode(y2, { visible: t2.visiblePreview, "onUpdate:visible": n2[11] || (n2[11] = (e2) => t2.visiblePreview = e2), src: t2.previewUrl }, null, 8, ["visible", "src"])], 64);
3402
- }], ["__scopeId", "data-v-2b9787ae"]]);
3402
+ }], ["__scopeId", "data-v-6d3cc084"]]);
3403
3403
  const pt = e.defineComponent({ name: "MaterialLibrary", components: { CLeft: L, CRight: gt, LModal: o }, props: { config: { type: Object, default: () => ({}) } }, setup(n2, { emit: r2 }) {
3404
3404
  const o2 = e.ref(n2.config), i2 = e.ref(), u2 = e.ref(), a2 = e.ref(false);
3405
3405
  e.watch(() => n2.config, (e2) => o2.value = e2, { immediate: true, deep: true });