PluginProbe
FluentCart A New Era of eCommerce – Faster, Lighter, and Simpler / 1.3.21
FluentCart A New Era of eCommerce – Faster, Lighter, and Simpler v1.3.21
1.6.6 1.6.5 1.6.4 1.6.3 1.6.2 1.6.1 1.6.0 1.5.4 1.5.5 1.5.3 1.5.2 1.5.1 1.5.0 1.4.2 1.4.1 1.4.0 1.3.28 1.3.27 1.3.26 1.3.25 1.3.23 1.3.22 1.3.21 1.3.20 1.3.19 All 49 releases
fluent-cart / assets / chunks / IconButton.js

IconButton.js in FluentCart A New Era of eCommerce – Faster, Lighter, and Simpler 1.3.21, at assets/chunks/IconButton.js

2 lines 2.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 import{S as h}from"./Str.js?ver=1.3.21";import{A as f}from"./Arr.js?ver=1.3.21";import{c as o,w as n,n as l,E as m,r as d,o as c,m as g}from"./vue.esm-bundler.js?ver=1.3.21";import{_ as S}from"./_plugin-vue_export-helper.js?ver=1.3.21";const a=s=>"fcart-"+h.snake(f.get(window,"fluentCartAdminApp.app_config.version","1.0.0"))+"_"+s;class k{static get(e,t=""){let r=localStorage.getItem(a(e));if(r&&["{","["].indexOf(r[0])!==-1)try{r=JSON.parse(r)}catch{return t}else{if(r==="true")return!0;if(r==="false")return!1}return r||t}static set(e,t){typeof t=="object"&&(t=JSON.stringify(t)),localStorage.setItem(a(e),t)}static remove(e){localStorage.removeItem(a(e))}static clear(){localStorage.clear()}static serverMaxUploadSize(){return f.get(window,"fluentCartAdminApp.max_upload_size")||""}static readableFileSizeFromBytes(e){if(e==0)return"0 B";if(!e)return"";const t=Math.floor(Math.log(e)/Math.log(1024)),r=["B","KB","MB","GB","TB"];return(e/Math.pow(1024,t)).toFixed(2)+" "+r[t]}}const B={name:"IconButton",props:{title:{type:String},href:{type:String},target:{type:String},border:{type:String},router_link:{type:Boolean},to:{type:Object},size:{type:String},tag:{type:String},circle:{type:Boolean},bg:{type:String},hover:{type:String}},computed:{isBorder(){return this.border?"border-"+this.border:""},isSize(){return this.size?this.size:""},isTag(){return this.tag?this.tag:"div"},isCircle(){return this.circle?"is-circle":""},isBg(){return this.bg?this.bg:""},isHover(){return this.hover?"hover-"+this.hover:""}}};function y(s,e,t,r,_,i){const u=d("router-link");return t.to?(c(),o(u,{key:0,to:t.to,class:l(["icon-button",[i.isBorder,i.isSize,i.isCircle,i.isBg,i.isHover]]),title:t.title,target:t.target},{default:n(()=>[g(s.$slots,"default")]),_:3},8,["to","class","title","target"])):(c(),o(m(i.isTag),{key:1,class:l(["icon-button",[i.isBorder,i.isSize,i.isCircle,i.isBg,i.isHover]]),href:t.href,title:t.title,target:t.target},{default:n(()=>[g(s.$slots,"default")]),_:3},8,["class","href","title","target"]))}const z=S(B,[["render",y]]);export{z as I,k as S};
2