hs-admin-ui 16.0.5 → 16.0.7

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.
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-BNZPT0nM.js");exports.default=e._sfc_main;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-Btv-sh19.js");exports.default=e._sfc_main;
@@ -0,0 +1,4 @@
1
+ import { _ as f } from "./index-CbchlOT_.mjs";
2
+ export {
3
+ f as default
4
+ };
package/dist/h5.js CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./_plugin-vue_export-helper-DU3rAEJM.js"),e=require("vue"),h={class:"upload-wrapper"},v={class:"upload-wrapper-inner"},w=e.defineComponent({__name:"Upload",props:{action:{type:String,default:""},headers:{type:Object,default:()=>({})},limit:{type:Number,default:100}},emits:["success"],setup(i,{emit:l}){const s=i,d=l,r=e.shallowRef(),o=e.reactive({loading:!1,headers:s.headers,fileList:[{name:"food.jpeg",url:"https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100"}]});e.watch(()=>o.fileList.length,n=>{setTimeout(()=>{const t=document.querySelector(".upload-wrapper .el-upload--picture-card");t&&(t.style.display=n>=s.limit&&n>0?"none":"inline-flex")},100)},{immediate:!0});async function u(){r.value.submit()}function p(n,t,a){d("success",{result:n,file:t,files:a})}return(n,t)=>{const a=e.resolveComponent("el-upload"),f=e.resolveComponent("el-button"),m=e.resolveDirective("loading");return e.withDirectives((e.openBlock(),e.createElementBlock("div",h,[e.createElementVNode("div",v,[e.createVNode(a,{ref_key:"uploadRef",ref:r,"file-list":o.fileList,"onUpdate:fileList":t[0]||(t[0]=g=>o.fileList=g),"list-type":"picture-card",accept:"image/*",name:"file",action:i.action,headers:o.headers,limit:i.limit,"auto-upload":!1,"on-success":p},{default:e.withCtx(()=>[...t[1]||(t[1]=[e.createElementVNode("svg",{width:"34",height:"34",viewBox:"0 0 100 100",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("rect",{x:"45",y:"20",width:"10",height:"60",rx:"2",fill:"#1677ff"}),e.createElementVNode("rect",{x:"20",y:"45",width:"60",height:"10",rx:"2",fill:"#1677ff"})],-1)])]),_:1},8,["file-list","action","headers","limit"])]),e.createVNode(f,{size:"large",type:"primary",onClick:u},{default:e.withCtx(()=>[...t[2]||(t[2]=[e.createTextVNode("上传",-1)])]),_:1})])),[[m,o.loading]])}}}),y=c._export_sfc(w,[["__scopeId","data-v-63137847"]]),_={Upload:y};function x(i){for(const[l,s]of Object.entries(_))i.component(`H${l}`,s)}function b(i){i.directive("loading",c.ElLoading.directive),i.use(x)}exports.useHsAdminUi=b;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./_plugin-vue_export-helper-Dk80_hr9.js"),e=require("vue"),m={class:"upload-wrapper"},g={class:"upload-wrapper-inner"},h=e.defineComponent({__name:"Upload",props:{action:{type:String,default:""},headers:{type:Object,default:()=>({})},limit:{type:Number,default:100}},emits:["success"],setup(i,{emit:a}){const s=i,d=a,c=e.shallowRef(),o=e.reactive({loading:!1,headers:s.headers,fileList:[{name:"food.jpeg",url:"https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100"}]});e.watch(()=>o.fileList.length,n=>{setTimeout(()=>{const t=document.querySelector(".upload-wrapper .el-upload--picture-card");t&&(t.style.display=n>=s.limit&&n>0?"none":"inline-flex")},100)},{immediate:!0});async function u(){c.value.submit()}function f(n,t,r){d("success",{result:n,file:t,files:r})}return(n,t)=>{const r=e.resolveDirective("loading");return e.withDirectives((e.openBlock(),e.createElementBlock("div",m,[e.createElementVNode("div",g,[e.createVNode(e.unref(l.ElUpload),{ref_key:"uploadRef",ref:c,"file-list":o.fileList,"onUpdate:fileList":t[0]||(t[0]=p=>o.fileList=p),"list-type":"picture-card",accept:"image/*",name:"file",action:i.action,headers:o.headers,limit:i.limit,"auto-upload":!1,"on-success":f},{default:e.withCtx(()=>[...t[1]||(t[1]=[e.createElementVNode("svg",{width:"34",height:"34",viewBox:"0 0 100 100",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("rect",{x:"45",y:"20",width:"10",height:"60",rx:"2",fill:"#1677ff"}),e.createElementVNode("rect",{x:"20",y:"45",width:"60",height:"10",rx:"2",fill:"#1677ff"})],-1)])]),_:1},8,["file-list","action","headers","limit"])]),e.createVNode(e.unref(l.ElButton),{size:"large",type:"primary",onClick:u},{default:e.withCtx(()=>[...t[2]||(t[2]=[e.createTextVNode("上传",-1)])]),_:1})])),[[r,o.loading]])}}}),w=l._export_sfc$1(h,[["__scopeId","data-v-b7ef01a9"]]),y={Upload:w};function v(i){for(const[a,s]of Object.entries(y))i.component(`H${a}`,s)}function x(i){i.directive("loading",l.ElLoading.directive),i.use(v)}exports.useHsAdminUi=x;
package/dist/h5.mjs CHANGED
@@ -1,6 +1,6 @@
1
- import { az as y, aA as _ } from "./_plugin-vue_export-helper-Dgg0dZKM.mjs";
2
- import { defineComponent as v, shallowRef as x, reactive as b, watch as L, resolveComponent as r, resolveDirective as j, withDirectives as k, createElementBlock as C, openBlock as U, createElementVNode as n, createVNode as d, withCtx as p, createTextVNode as B } from "vue";
3
- const N = { class: "upload-wrapper" }, E = { class: "upload-wrapper-inner" }, H = /* @__PURE__ */ v({
1
+ import { bT as h, a$ as w, bS as y, bY as b } from "./_plugin-vue_export-helper-CZTmULB5.mjs";
2
+ import { defineComponent as v, shallowRef as x, reactive as _, watch as L, resolveDirective as U, withDirectives as j, createElementBlock as k, openBlock as B, createElementVNode as a, createVNode as c, unref as d, withCtx as f, createTextVNode as E } from "vue";
3
+ const C = { class: "upload-wrapper" }, N = { class: "upload-wrapper-inner" }, S = /* @__PURE__ */ v({
4
4
  __name: "Upload",
5
5
  props: {
6
6
  action: {
@@ -18,7 +18,7 @@ const N = { class: "upload-wrapper" }, E = { class: "upload-wrapper-inner" }, H
18
18
  },
19
19
  emits: ["success"],
20
20
  setup(t, { emit: l }) {
21
- const s = t, u = l, c = x(), i = b({
21
+ const s = t, u = l, r = x(), i = _({
22
22
  loading: !1,
23
23
  headers: s.headers,
24
24
  fileList: [
@@ -40,21 +40,21 @@ const N = { class: "upload-wrapper" }, E = { class: "upload-wrapper-inner" }, H
40
40
  immediate: !0
41
41
  }
42
42
  );
43
- async function f() {
44
- c.value.submit();
43
+ async function p() {
44
+ r.value.submit();
45
45
  }
46
- function m(o, e, a) {
47
- u("success", { result: o, file: e, files: a });
46
+ function m(o, e, n) {
47
+ u("success", { result: o, file: e, files: n });
48
48
  }
49
49
  return (o, e) => {
50
- const a = r("el-upload"), g = r("el-button"), h = j("loading");
51
- return k((U(), C("div", N, [
52
- n("div", E, [
53
- d(a, {
50
+ const n = U("loading");
51
+ return j((B(), k("div", C, [
52
+ a("div", N, [
53
+ c(d(h), {
54
54
  ref_key: "uploadRef",
55
- ref: c,
55
+ ref: r,
56
56
  "file-list": i.fileList,
57
- "onUpdate:fileList": e[0] || (e[0] = (w) => i.fileList = w),
57
+ "onUpdate:fileList": e[0] || (e[0] = (g) => i.fileList = g),
58
58
  "list-type": "picture-card",
59
59
  accept: "image/*",
60
60
  name: "file",
@@ -64,14 +64,14 @@ const N = { class: "upload-wrapper" }, E = { class: "upload-wrapper-inner" }, H
64
64
  "auto-upload": !1,
65
65
  "on-success": m
66
66
  }, {
67
- default: p(() => [...e[1] || (e[1] = [
68
- n("svg", {
67
+ default: f(() => [...e[1] || (e[1] = [
68
+ a("svg", {
69
69
  width: "34",
70
70
  height: "34",
71
71
  viewBox: "0 0 100 100",
72
72
  xmlns: "http://www.w3.org/2000/svg"
73
73
  }, [
74
- n("rect", {
74
+ a("rect", {
75
75
  x: "45",
76
76
  y: "20",
77
77
  width: "10",
@@ -79,7 +79,7 @@ const N = { class: "upload-wrapper" }, E = { class: "upload-wrapper-inner" }, H
79
79
  rx: "2",
80
80
  fill: "#1677ff"
81
81
  }),
82
- n("rect", {
82
+ a("rect", {
83
83
  x: "20",
84
84
  y: "45",
85
85
  width: "60",
@@ -92,31 +92,31 @@ const N = { class: "upload-wrapper" }, E = { class: "upload-wrapper-inner" }, H
92
92
  _: 1
93
93
  }, 8, ["file-list", "action", "headers", "limit"])
94
94
  ]),
95
- d(g, {
95
+ c(d(w), {
96
96
  size: "large",
97
97
  type: "primary",
98
- onClick: f
98
+ onClick: p
99
99
  }, {
100
- default: p(() => [...e[2] || (e[2] = [
101
- B("上传", -1)
100
+ default: f(() => [...e[2] || (e[2] = [
101
+ E("上传", -1)
102
102
  ])]),
103
103
  _: 1
104
104
  })
105
105
  ])), [
106
- [h, i.loading]
106
+ [n, i.loading]
107
107
  ]);
108
108
  };
109
109
  }
110
- }), R = /* @__PURE__ */ y(H, [["__scopeId", "data-v-63137847"]]), S = {
111
- Upload: R
110
+ }), H = /* @__PURE__ */ y(S, [["__scopeId", "data-v-b7ef01a9"]]), R = {
111
+ Upload: H
112
112
  };
113
- function V(t) {
114
- for (const [l, s] of Object.entries(S))
113
+ function T(t) {
114
+ for (const [l, s] of Object.entries(R))
115
115
  t.component(`H${l}`, s);
116
116
  }
117
- function A(t) {
118
- t.directive("loading", _.directive), t.use(V);
117
+ function D(t) {
118
+ t.directive("loading", b.directive), t.use(T);
119
119
  }
120
120
  export {
121
- A as useHsAdminUi
121
+ D as useHsAdminUi
122
122
  };