sinosoft-common-button 1.0.4 → 1.0.5

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,9 +1,9 @@
1
- import { openBlock as d, createElementBlock as c, createElementVNode as p, defineComponent as g, resolveComponent as u, createVNode as r, normalizeClass as $, normalizeStyle as f, withCtx as l, createCommentVNode as _, renderSlot as S, createBlock as z, createTextVNode as a } from "vue";
1
+ import { openBlock as d, createElementBlock as c, createElementVNode as p, defineComponent as g, resolveComponent as u, createVNode as r, normalizeClass as $, normalizeStyle as f, withCtx as l, createCommentVNode as _, renderSlot as S, createBlock as z, createTextVNode as n } from "vue";
2
2
  /*! Element Plus Icons Vue v2.1.0 */
3
3
  var k = (e, t) => {
4
4
  let o = e.__vccOpts || e;
5
- for (let [i, n] of t)
6
- o[i] = n;
5
+ for (let [i, s] of t)
6
+ o[i] = s;
7
7
  return o;
8
8
  }, F = {
9
9
  name: "Loading"
@@ -22,7 +22,7 @@ var k = (e, t) => {
22
22
  ), D = [
23
23
  w
24
24
  ];
25
- function E(e, t, o, i, n, y) {
25
+ function E(e, t, o, i, s, y) {
26
26
  return d(), c("svg", B, D);
27
27
  }
28
28
  var L = /* @__PURE__ */ k(F, [["render", E], ["__file", "loading.vue"]]);
@@ -145,14 +145,14 @@ const x = g({
145
145
  });
146
146
  const O = (e, t) => {
147
147
  const o = e.__vccOpts || e;
148
- for (const [i, n] of t)
149
- o[i] = n;
148
+ for (const [i, s] of t)
149
+ o[i] = s;
150
150
  return o;
151
151
  }, V = {
152
152
  key: 0,
153
153
  class: "s-icon"
154
154
  }, N = ["src"];
155
- function j(e, t, o, i, n, y) {
155
+ function j(e, t, o, i, s, y) {
156
156
  const m = u("Loading"), v = u("el-icon"), C = u("el-button");
157
157
  return d(), c("div", null, [
158
158
  r(C, {
@@ -189,51 +189,57 @@ function j(e, t, o, i, n, y) {
189
189
  }, 8, ["class", "disabled", "style"])
190
190
  ]);
191
191
  }
192
- const s = /* @__PURE__ */ O(x, [["render", j], ["__scopeId", "data-v-22aae99b"]]), W = { class: "table-button" }, b = /* @__PURE__ */ g({
192
+ const a = /* @__PURE__ */ O(x, [["render", j], ["__scopeId", "data-v-22aae99b"]]), W = { class: "table-button" }, b = /* @__PURE__ */ g({
193
193
  __name: "index",
194
194
  setup(e) {
195
195
  const t = () => {
196
196
  console.log(11111);
197
197
  };
198
198
  return (o, i) => (d(), c("div", W, [
199
- r(s, {
199
+ r(a, {
200
200
  plain: "",
201
- onHandleClick: t,
202
201
  icon: "icon-add",
203
202
  size: 16,
204
- loading: !0
203
+ loading: !0,
204
+ onHandleClick: t
205
205
  }, {
206
206
  default: l(() => [
207
- a("提交")
207
+ n("提交")
208
208
  ]),
209
209
  _: 1
210
210
  }),
211
- r(s, {
211
+ r(a, {
212
212
  bgColor: "#f00",
213
213
  height: "80px",
214
214
  circle: "60px",
215
215
  color: "#000"
216
216
  }, {
217
217
  default: l(() => [
218
- a("提交提交提交提交提交提交提交提交提交提交提交提交提交")
218
+ n("自定义")
219
219
  ]),
220
220
  _: 1
221
221
  }),
222
- r(s, { primary: "" }, {
222
+ r(a, { primary: "" }, {
223
223
  default: l(() => [
224
- a("提交提交提交提交提交提交提交提交提交提交提交提交提交")
224
+ n("提交")
225
225
  ]),
226
226
  _: 1
227
227
  }),
228
- r(s, { default: "" }, {
228
+ r(a, { default: "" }, {
229
229
  default: l(() => [
230
- a("提交提交提交提交提交提交提交提交提交提交提交提交提交")
230
+ n("重置")
231
231
  ]),
232
232
  _: 1
233
233
  }),
234
- r(s, { info: "" }, {
234
+ r(a, { info: "" }, {
235
235
  default: l(() => [
236
- a("提交提交提交提交提交提交提交提交提交提交提交提交提交")
236
+ n("置灰")
237
+ ]),
238
+ _: 1
239
+ }),
240
+ r(a, null, {
241
+ default: l(() => [
242
+ n("置灰")
237
243
  ]),
238
244
  _: 1
239
245
  })
@@ -1 +1 @@
1
- (function(e,l){typeof exports=="object"&&typeof module<"u"?module.exports=l(require("vue")):typeof define=="function"&&define.amd?define(["vue"],l):(e=typeof globalThis<"u"?globalThis:e||self,e.button=l(e.Vue))})(this,function(e){"use strict";/*! Element Plus Icons Vue v2.1.0 */var l=(t,o)=>{let r=t.__vccOpts||t;for(let[n,a]of o)r[n]=a;return r},c={name:"Loading"},f={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},p=e.createElementVNode("path",{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32zm0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32zm448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32zm-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32zM195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248zm452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248zM828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0zm-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0z"},null,-1),h=[p];function u(t,o,r,n,a,S){return e.openBlock(),e.createElementBlock("svg",f,h)}var _=l(c,[["render",u],["__file","loading.vue"]]);const g=e.defineComponent({components:{Loading:_},props:{plain:{type:Boolean,default:!1},primary:{type:Boolean,default:!1},default:{type:Boolean,default:!1},info:{type:Boolean,default:!1},circle:{type:String,default:""},height:{type:String,default:""},width:{type:String,default:""},color:{type:String,default:""},loadingColor:{type:String,default:"#333333"},bgColor:{type:String,default:""},loading:{type:Boolean,default:!1},borderStyle:{type:String,default:"solid"},icon:{type:String,required:!1},size:{type:[Number,String],default:"auto"}},computed:{styleOjb(){return this.plain?{background:"#fff",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#216FED"}`,color:this.color||"#216FED"}:this.primary?{background:"#216FED",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#4E6DFD"}`,color:this.color||"#ffffff"}:this.default?{background:"#ffffff",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#DDE2E6"}`,color:this.color||"#2C3C4D"}:this.info?{background:"#C4C4C4",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#C4C4C4"}`,color:this.color||"#FFFFFF"}:{color:this.color||"#ffffff",background:this.bgColor||"#216FED",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#216FED"}`,height:this.height,width:this.width,borderRadius:this.circle}},geturl(){if(this.icon){if(this.icon.includes("/")||this.icon.includes("base64"))return this.icon;if(this.icon.includes("svg"))return`@icons/svg/${this.icon}`}else return"";return`@icons/png/${this.icon}.png`},styleObject:function(){return{width:typeof this.size=="string"?this.size:this.size+"px",height:typeof this.size=="string"?this.size:this.size+"px"}}}}),x="",y=(t,o)=>{const r=t.__vccOpts||t;for(const[n,a]of o)r[n]=a;return r},m={key:0,class:"s-icon"},b=["src"];function C(t,o,r,n,a,S){const k=e.resolveComponent("Loading"),z=e.resolveComponent("el-icon"),V=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(V,{class:e.normalizeClass(["s-button",{plain:t.plain,btnhover:!t.plain,loading:t.loading}]),disabled:t.loading,style:e.normalizeStyle(t.styleOjb),onClick:o[0]||(o[0]=B=>t.$emit("handleClick"))},{default:e.withCtx(()=>[t.icon?(e.openBlock(),e.createElementBlock("i",m,[e.createElementVNode("img",{src:t.geturl,alt:"",style:e.normalizeStyle(t.styleObject)},null,12,b)])):e.createCommentVNode("",!0),e.createElementVNode("span",{style:e.normalizeStyle({color:t.color})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],4),t.loading?(e.openBlock(),e.createBlock(z,{key:1,class:"is-loading",color:t.loadingColor},{default:e.withCtx(()=>[e.createVNode(k)]),_:1},8,["color"])):e.createCommentVNode("",!0)]),_:3},8,["class","disabled","style"])])}const i=y(g,[["render",C],["__scopeId","data-v-22aae99b"]]),$={class:"table-button"},s=e.defineComponent({__name:"index",setup(t){const o=()=>{console.log(11111)};return(r,n)=>(e.openBlock(),e.createElementBlock("div",$,[e.createVNode(i,{plain:"",onHandleClick:o,icon:"icon-add",size:16,loading:!0},{default:e.withCtx(()=>[e.createTextVNode("提交")]),_:1}),e.createVNode(i,{bgColor:"#f00",height:"80px",circle:"60px",color:"#000"},{default:e.withCtx(()=>[e.createTextVNode("提交提交提交提交提交提交提交提交提交提交提交提交提交")]),_:1}),e.createVNode(i,{primary:""},{default:e.withCtx(()=>[e.createTextVNode("提交提交提交提交提交提交提交提交提交提交提交提交提交")]),_:1}),e.createVNode(i,{default:""},{default:e.withCtx(()=>[e.createTextVNode("提交提交提交提交提交提交提交提交提交提交提交提交提交")]),_:1}),e.createVNode(i,{info:""},{default:e.withCtx(()=>[e.createTextVNode("提交提交提交提交提交提交提交提交提交提交提交提交提交")]),_:1})]))}});function d(t,o={}){d.installed||(d.installed=!0,t.component("common-button",s))}return s.install=d,s});
1
+ (function(e,i){typeof exports=="object"&&typeof module<"u"?module.exports=i(require("vue")):typeof define=="function"&&define.amd?define(["vue"],i):(e=typeof globalThis<"u"?globalThis:e||self,e.button=i(e.Vue))})(this,function(e){"use strict";/*! Element Plus Icons Vue v2.1.0 */var i=(t,o)=>{let r=t.__vccOpts||t;for(let[n,a]of o)r[n]=a;return r},c={name:"Loading"},f={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},p=e.createElementVNode("path",{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32zm0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32zm448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32zm-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32zM195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248zm452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248zM828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0zm-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0z"},null,-1),h=[p];function _(t,o,r,n,a,S){return e.openBlock(),e.createElementBlock("svg",f,h)}var u=i(c,[["render",_],["__file","loading.vue"]]);const g=e.defineComponent({components:{Loading:u},props:{plain:{type:Boolean,default:!1},primary:{type:Boolean,default:!1},default:{type:Boolean,default:!1},info:{type:Boolean,default:!1},circle:{type:String,default:""},height:{type:String,default:""},width:{type:String,default:""},color:{type:String,default:""},loadingColor:{type:String,default:"#333333"},bgColor:{type:String,default:""},loading:{type:Boolean,default:!1},borderStyle:{type:String,default:"solid"},icon:{type:String,required:!1},size:{type:[Number,String],default:"auto"}},computed:{styleOjb(){return this.plain?{background:"#fff",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#216FED"}`,color:this.color||"#216FED"}:this.primary?{background:"#216FED",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#4E6DFD"}`,color:this.color||"#ffffff"}:this.default?{background:"#ffffff",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#DDE2E6"}`,color:this.color||"#2C3C4D"}:this.info?{background:"#C4C4C4",borderWidth:"1px",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#C4C4C4"}`,color:this.color||"#FFFFFF"}:{color:this.color||"#ffffff",background:this.bgColor||"#216FED",borderStyle:`${this.borderStyle}`,borderColor:`${this.color||"#216FED"}`,height:this.height,width:this.width,borderRadius:this.circle}},geturl(){if(this.icon){if(this.icon.includes("/")||this.icon.includes("base64"))return this.icon;if(this.icon.includes("svg"))return`@icons/svg/${this.icon}`}else return"";return`@icons/png/${this.icon}.png`},styleObject:function(){return{width:typeof this.size=="string"?this.size:this.size+"px",height:typeof this.size=="string"?this.size:this.size+"px"}}}}),z="",y=(t,o)=>{const r=t.__vccOpts||t;for(const[n,a]of o)r[n]=a;return r},m={key:0,class:"s-icon"},b=["src"];function C(t,o,r,n,a,S){const k=e.resolveComponent("Loading"),V=e.resolveComponent("el-icon"),x=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(x,{class:e.normalizeClass(["s-button",{plain:t.plain,btnhover:!t.plain,loading:t.loading}]),disabled:t.loading,style:e.normalizeStyle(t.styleOjb),onClick:o[0]||(o[0]=N=>t.$emit("handleClick"))},{default:e.withCtx(()=>[t.icon?(e.openBlock(),e.createElementBlock("i",m,[e.createElementVNode("img",{src:t.geturl,alt:"",style:e.normalizeStyle(t.styleObject)},null,12,b)])):e.createCommentVNode("",!0),e.createElementVNode("span",{style:e.normalizeStyle({color:t.color})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],4),t.loading?(e.openBlock(),e.createBlock(V,{key:1,class:"is-loading",color:t.loadingColor},{default:e.withCtx(()=>[e.createVNode(k)]),_:1},8,["color"])):e.createCommentVNode("",!0)]),_:3},8,["class","disabled","style"])])}const l=y(g,[["render",C],["__scopeId","data-v-22aae99b"]]),$={class:"table-button"},s=e.defineComponent({__name:"index",setup(t){const o=()=>{console.log(11111)};return(r,n)=>(e.openBlock(),e.createElementBlock("div",$,[e.createVNode(l,{plain:"",icon:"icon-add",size:16,loading:!0,onHandleClick:o},{default:e.withCtx(()=>[e.createTextVNode("提交")]),_:1}),e.createVNode(l,{bgColor:"#f00",height:"80px",circle:"60px",color:"#000"},{default:e.withCtx(()=>[e.createTextVNode("自定义")]),_:1}),e.createVNode(l,{primary:""},{default:e.withCtx(()=>[e.createTextVNode("提交")]),_:1}),e.createVNode(l,{default:""},{default:e.withCtx(()=>[e.createTextVNode("重置")]),_:1}),e.createVNode(l,{info:""},{default:e.withCtx(()=>[e.createTextVNode("置灰")]),_:1}),e.createVNode(l,null,{default:e.withCtx(()=>[e.createTextVNode("置灰")]),_:1})]))}});function d(t,o={}){d.installed||(d.installed=!0,t.component("common-button",s))}return s.install=d,s});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sinosoft-common-button",
3
- "version": "1.0.4",
3
+ "version": "1.0.5",
4
4
  "description": "",
5
5
  "main": "common-button.es.js",
6
6
  "scripts": {