@assaabloy/amarr-wc-button 3.0.13 → 3.0.14
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.
- package/button.js +1 -1
- package/package.json +2 -2
package/button.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e){function n(n){for(var a,i,c=n[0],l=n[1],u=n[2],s=0,m=[];s<c.length;s++)i=c[s],Object.prototype.hasOwnProperty.call(r,i)&&r[i]&&m.push(r[i][0]),r[i]=0;for(a in l)Object.prototype.hasOwnProperty.call(l,a)&&(e[a]=l[a]);for(d&&d(n);m.length;)m.shift()();return o.push.apply(o,u||[]),t()}function t(){for(var e,n=0;n<o.length;n++){for(var t=o[n],a=!0,c=1;c<t.length;c++){var l=t[c];0!==r[l]&&(a=!1)}a&&(o.splice(n--,1),e=i(i.s=t[0]))}return e}var a={},r={3:0},o=[];function i(n){if(a[n])return a[n].exports;var t=a[n]={i:n,l:!1,exports:{}};return e[n].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.m=e,i.c=a,i.d=function(e,n,t){i.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:t})},i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,n){if(1&n&&(e=i(e)),8&n)return e;if(4&n&&"object"===typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var a in e)i.d(t,a,function(n){return e[n]}.bind(null,a));return t},i.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(n,"a",n),n},i.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},i.p="/";var c=this["webpackJsonpamarr-frontend-components"]=this["webpackJsonpamarr-frontend-components"]||[],l=c.push.bind(c);c.push=n,c=c.slice();for(var u=0;u<c.length;u++)n(c[u]);var d=l;o.push([793,0]),t()}({0:function(e,n){e.exports=React},1:function(e,n,t){"use strict";t.d(n,"g",(function(){return r})),t.d(n,"V",(function(){return o})),t.d(n,"i",(function(){return i})),t.d(n,"D",(function(){return c})),t.d(n,"G",(function(){return l})),t.d(n,"v",(function(){return u})),t.d(n,"B",(function(){return d})),t.d(n,"o",(function(){return s})),t.d(n,"r",(function(){return m})),t.d(n,"I",(function(){return f})),t.d(n,"H",(function(){return p})),t.d(n,"Q",(function(){return g})),t.d(n,"E",(function(){return b})),t.d(n,"u",(function(){return h})),t.d(n,"h",(function(){return x})),t.d(n,"t",(function(){return w})),t.d(n,"y",(function(){return v})),t.d(n,"w",(function(){return y})),t.d(n,"C",(function(){return k})),t.d(n,"s",(function(){return E})),t.d(n,"R",(function(){return A})),t.d(n,"q",(function(){return O})),t.d(n,"J",(function(){return j})),t.d(n,"F",(function(){return z})),t.d(n,"S",(function(){return I})),t.d(n,"m",(function(){return C})),t.d(n,"j",(function(){return M})),t.d(n,"n",(function(){return D})),t.d(n,"k",(function(){return H})),t.d(n,"l",(function(){return S})),t.d(n,"z",(function(){return Z})),t.d(n,"L",(function(){return P})),t.d(n,"x",(function(){return $})),t.d(n,"T",(function(){return T})),t.d(n,"U",(function(){return q})),t.d(n,"b",(function(){return B})),t.d(n,"O",(function(){return L})),t.d(n,"A",(function(){return U})),t.d(n,"a",(function(){return R})),t.d(n,"d",(function(){return W})),t.d(n,"f",(function(){return F})),t.d(n,"e",(function(){return J})),t.d(n,"X",(function(){return G})),t.d(n,"c",(function(){return V})),t.d(n,"W",(function(){return K})),t.d(n,"K",(function(){return Q})),t.d(n,"M",(function(){return X})),t.d(n,"N",(function(){return Y})),t.d(n,"p",(function(){return ee})),t.d(n,"P",(function(){return ne}));var a=t(3),r=function(e){return JSON.parse(decodeURIComponent(escape(atob(e))))},o=function(e){return btoa(unescape(encodeURIComponent(e)))},i=function(e){return e.toUpperCase()},c=function(e){return e.replaceAll(" ","-").toLowerCase()},l=new a.a(!1),u=new a.a(!1),d=new a.a(!1),s=new a.a(!1),m=new a.a(""),f=new a.a(!1),p=new a.a(!1),g=new a.a(!1),b=new a.a(!1),h=new a.a(!1),x=new a.a(!1),w=new a.a(""),v=new a.a(!0),y=new a.a(!0),k=new a.a(!0),E=new a.a(!0),A=new a.a(!0),O=new a.a(!0),j=new a.a({}),N=new a.a(!1),_=0,z=new a.a(!1),I=new a.a(""),C=new a.a(""),M=new a.a(""),D=new a.a(""),H=new a.a(""),S=new a.a(""),Z=new a.a(""),P=new a.a(""),$=new a.a(!1),T=new a.a(!1),q=new a.a(!1),B=function(){setTimeout((function(){_++,N.next(!0)}),0)},L=function(){setTimeout((function(){_>0&&_--,0==_&&N.next(!1)}),0)},U=function(){return N.asObservable()},R=function(e){return!!/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e)},W=function(e){return e.match(/^[a-zA-Z\xc0-\xff-. ]*$/)},F=function(e){return/^[0-9a-zA-Z !@#\$%\^\&*\)\(+=._-]+$/.test(e)},J=function(e){return/^\(?([0-9]{3})\)\s[0-9]{3}-[0-9]{4}$/.test(e)},G=function(e){return/((([A-Za-z]{3,9}:(?:\/\/)?)(?:[-;:&=\+\$,\w]+@)?[A-Za-z0-9.-]+|(?:www.|[-;:&=\+\$,\w]+@)[A-Za-z0-9.-]+)((?:\/[\+~%\/.\w-_]*)?\??(?:[-\+=&;%@.\w_]*)#?(?:[\w]*))?)/.test(e)},V=function(e){return/^[0-9]*$/.test(e)},K=function(e){return!!/^[-a-zA-Z0-9+&@#/%?=~|!:,.;]*[-a-zA-Z0-9+&@#/%=~|]$/.test(e)},Q=function(e){if(e&&""!==e&&-1===e.indexOf("(")&&-1===e.indexOf(") ")&&-1===e.indexOf("-")){return"("+e.substring(0,3)+") "+e.substring(3,6)+"-"+e.substring(6,e.length)}return e},X=function(e){return e&&(e=e.toFixed(2).replace(/\d(?=(\d{3})+\.)/g,"$&,")),0!==e&&"0"!==e||(e=e.toFixed(2)),e},Y=function(e,n){return e=e?Number(e):0,(0===(n=n?Number(n):0)||"0"===n?0:(e-n)/n*100).toFixed(2)},ee=function(e){var n={tabs:!0,type:"designer",clavos:!1,download:!0,quote:!0,srcUrl:"/DoorApp",id:"AmarrDoorDesigner",panel:e.selectedPanel,brand:"",myGuid:"d-608280c6f378f8.36911414",email:!0,height:e.selectedHeight,glass:e.selectedGlass,collection:e.selectedCollection,print:!0,baseUrl:"",gplacement:e.selectedWindowPlacement,width:e.selectedWidth,srcDir:"DoorApp",MosaicName:"Mosaic",logooption:""};return e.selectedColor&&(n.color=e.selectedColor),e.colorHex&&(n.colorHex=e.colorHex),e.colorZone&&(n.colorZone=e.colorZone),e.selectedConstruction&&(n.model=e.selectedConstruction),e.selectedWindowDesign&&(n.top=e.selectedWindowDesign),e.glazepattern&&(n.glazepattern=e.glazepattern),e.selectedHardware&&(n.hardware=e.selectedHardware),n},ne=function(e,n,t){var a="",r=e.split(n);return r.forEach((function(e,n){"undefined"!==e&&e&&(a+=e,n!==r.length-1&&(a+=t))})),a}},19:function(e,n){e.exports=ReactDOM},21:function(e,n,t){"use strict";t.d(n,"a",(function(){return c}));var a=t(15),r=t(0),o=t.n(r),i=t(4).default.div.withConfig({displayName:"styles__View",componentId:"zfm3w6-0"})([".divider{width:100%;height:6px;@media screen and (min-width:1281px){height:8px;}@media screen and (min-width:1681px){height:10px;}}"]),c=function(e){return Object(a.a)(e),o.a.createElement(i,null,o.a.createElement("div",{className:"divider"},"\xa0"))}},5:function(e,n,t){"use strict";t.d(n,"a",(function(){return s}));var a=t(22),r=t(0),o=t.n(r),i=t(4),c=i.default.div.withConfig({displayName:"styles__View",componentId:"sc-1jt3i0i-0"})([""]),l=i.default.button.withConfig({displayName:"styles__Button",componentId:"sc-1jt3i0i-1"})(['font-size:12px;font-family:"Open Sans";font-weight:600;font-stretch:normal;font-style:normal;line-height:1.5;letter-spacing:normal;text-align:center;color:#fff;padding:12px 19px 12px 20px;border-radius:4px;background-color:#006166;box-shadow:none;border:none;transition:all ease 300ms;&:hover{transform:scale(1.1);background-color:#338084;color:#fff;}&:focus{transform:scale(1);box-shadow:none !important;background-color:#004347;}&:active{background-color:#006166 !important;box-shadow:none !important;transform:scale(1);border:none !important;}&.btn-inverse{color:#333333;background:#b2cfd1;&:hover{background:#8EB8BB;}&:focus{background:#8EA5A7;border:none;transform:scale(1);box-shadow:none !important;}&:active{background-color:#8EA5A7 !important;border:none !important;transform:scale(1.1);box-shadow:none !important;}}@media(min-width:1201px){font-size:16px;}.button-icon{vertical-align:top;padding-right:8px;}']),u=t(18),d=t(17),s=function(e){var n=e.label,t=void 0===n?"label":n,r=e.classStyle,i=void 0===r?"default":r,s=e.link,m=void 0!==s&&s,f=e.disabled,p=void 0!==f&&f,g=e.datatoggle,b=void 0===g?"":g,h=e.datatarget,x=void 0===h?"":h,w=e.linkHref,v=e.target,y=void 0===v?"_self":v,k=e.downloadLink,E=void 0!==k&&k,A=e.inverse,O=void 0!==A&&A,j=e.icon,N=void 0===j?"":j,_=e.iconAlt,z=void 0===_?"":_,I=e.dataItemName,C=void 0===I?"":I,M=e.id,D=void 0===M?"":M,H=e.type,S=void 0===H?"button":H,Z=e.showDisabledMessage,P=void 0===Z?"":Z,$=e.ariaLabel,T=void 0===$?"":$,q=Object(a.a)(e,["label","classStyle","link","disabled","datatoggle","datatarget","linkHref","target","downloadLink","inverse","icon","iconAlt","dataItemName","id","type","showDisabledMessage","ariaLabel"]);return o.a.createElement(c,null,o.a.createElement("div",{className:"".concat(p&&P&&"disabled-button-parent")},m?o.a.createElement("a",{href:w,download:E,target:y,"data-item-name":C,id:D,"aria-label":T},o.a.createElement(l,Object.assign({role:"presentation",disabled:p,classStyle:"".concat(i)},q,{type:S,className:O?"btn-inverse btn btn-success":"btn btn-success"}),""!=N?o.a.createElement("div",{"data-toggle":b,"data-target":x},o.a.createElement("img",{loading:"lazy",className:"button-icon",src:N,alt:z}),o.a.createElement("span",null,t)):o.a.createElement("span",null,t))):o.a.createElement(l,Object.assign({disabled:p,classStyle:i,className:O?"btn-inverse btn btn-success":"btn btn-success",id:D,"data-item-name":C,type:S},q),o.a.createElement("span",null,t)),p&&P&&o.a.createElement(u.a,{placement:"top",delay:{show:250,hide:250},overlay:o.a.createElement(d.a,{id:"button-tooltip"},o.a.createElement("div",{className:"p-1 amarr-h6"},P))},o.a.createElement("div",{className:"disabled-button-overlay"}))))}},55:function(e,n,t){"use strict";var a=t(0),r=t.n(a),o=t(5),i=t(1),c=t(21),l=t(4).default.section.withConfig({displayName:"styles__Content",componentId:"mqdtio-0"})([".button-container-style{display:flex;flex-wrap:wrap;&.text-left-alignment{justify-content:left;}&.text-right-alignment{justify-content:flex-end;}&.text-center-alignment{justify-content:center;}}.button-container-style-block{@media screen and (max-width:767px){display:flex;flex-direction:column;}}.mobile-margin{&.text-left-alignment{justify-content:left;}&.text-right-alignment{justify-content:flex-end;}&.text-center-alignment{justify-content:center;}@media screen and (max-width:767px){margin-left:0;}}.button-container-style > *{margin:20px 0 0 0px;}.button-container-style{margin:-20px 0 0 0px;}.mobile-margin:not(:last-child){@media screen and (min-width:1681px){margin-right:25px;}@media screen and (max-width:1680px){margin-right:20px;}}.quick-links{border:solid 1px #8d8d8d;border-radius:4px;padding:0px 16px 18px;margin-top:10px;.mobile-margin:not(:last-child){margin-right:20px;@media screen and (min-width:1681px){margin-right:25px;}@media screen and (max-width:767px){margin-right:0px;}}.mobile-margin:nth-child(odd){@media screen and (max-width:767px){padding-right:20px;}}}@media screen and (max-width:991px){.button-auto-height{button.btn{height:min-content;white-space:break-spaces;text-align:left;}}}@media screen and (max-width:991px){.button-container-style.quick-links{flex-wrap:wrap;.mobile-margin{flex:0 0 50%;max-width:calc(50% - 20px);}}}@media screen and (max-width:1025px){.quick-links{padding:0px 18px 16px 18px;margin-top:10px;}.quick-links.button-container-style > *{margin:18px 0px 0px;}}"]),u=function(e){var n=e.buttonData,t=Object(i.g)(n);return r.a.createElement(l,null,"default"!==t.topMargin&&!t.addBorder&&r.a.createElement("span",null,r.a.createElement(c.a,null)),r.a.createElement("div",{className:"".concat(t.addBorder&&t.addContainer&&"container")},r.a.createElement("div",{className:"button-container-style container mb-4\n ".concat("left"===t.alignment&&"text-left-alignment"," ").concat("right"===t.alignment&&"text-right-alignment"," ").concat("center"===t.alignment&&"text-center-alignment","\n ").concat("block"===t.mobileAlignment&&"button-container-style-block","\n ").concat("medium"===t.topMargin&&"mt-1 mt-sm-2","\n ").concat("extra"===t.topMargin&&"mt-2 mt-sm-4","\n ").concat("medium"===t.bottomMargin&&"mb-4 mb-sm-5","\n ").concat("extra"===t.bottomMargin&&"mb-5 pb-2","\n ").concat(t.addBorder&&"quick-links","\n ")},t.ctaItems&&t.ctaItems.map((function(e,n,t){return r.a.createElement("div",{key:n,className:"".concat(e.label.length>25&&"button-auto-height"," mobile-margin")},"tertiary"!==e.color&&"noTheme"!==e.color&&r.a.createElement(o.a,{label:Object(i.i)(e.label),link:!0,linkHref:e.url,target:e.linkAction,inverse:"inverse"===e.color}),"tertiary"===e.color&&e.isInternal&&r.a.createElement("a",{href:e.cta.url,target:e.cta.linkAction}),"tertiary"===e.color&&!e.isInternal&&"_self"===e.cta.linkAction&&r.a.createElement("a",{href:e.cta.url,target:e.cta.linkAction}),"tertiary"===e.color&&e.isInternal&&"_blank"===e.cta.linkAction&&r.a.createElement("a",{href:e.cta.url,target:e.cta.linkAction,rel:"noopener"}),"noTheme"===e.color&&e.isInternal&&r.a.createElement("a",{className:"amarrHighlight",href:e.url,target:e.linkAction},e.label),"noTheme"===e.color&&!e.isInternal&&"_self"===e.linkAction&&r.a.createElement("a",{className:"amarrHighlight",href:e.url,target:e.linkAction},e.label),"noTheme"===e.color&&!e.isInternal&&"_blank"===e.linkAction&&r.a.createElement("a",{className:"amarrHighlight",href:e.url,target:e.linkAction,rel:"noopener"},e.label))})))),"extra"===t.bottomMargin&&r.a.createElement(c.a,null))};u.defaultProps={theme:"",buttonData:""};n.a=u},699:function(e,n,t){"use strict";t.r(n);var a=t(14),r=t(55);n.default=a.a.create({component:r.a,configuration:{tagname:"amarr-button",useShadow:!1},plugins:[]})}});
|
|
1
|
+
!function(e){function n(n){for(var a,i,c=n[0],l=n[1],u=n[2],s=0,m=[];s<c.length;s++)i=c[s],Object.prototype.hasOwnProperty.call(r,i)&&r[i]&&m.push(r[i][0]),r[i]=0;for(a in l)Object.prototype.hasOwnProperty.call(l,a)&&(e[a]=l[a]);for(d&&d(n);m.length;)m.shift()();return o.push.apply(o,u||[]),t()}function t(){for(var e,n=0;n<o.length;n++){for(var t=o[n],a=!0,c=1;c<t.length;c++){var l=t[c];0!==r[l]&&(a=!1)}a&&(o.splice(n--,1),e=i(i.s=t[0]))}return e}var a={},r={3:0},o=[];function i(n){if(a[n])return a[n].exports;var t=a[n]={i:n,l:!1,exports:{}};return e[n].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.m=e,i.c=a,i.d=function(e,n,t){i.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:t})},i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,n){if(1&n&&(e=i(e)),8&n)return e;if(4&n&&"object"===typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var a in e)i.d(t,a,function(n){return e[n]}.bind(null,a));return t},i.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(n,"a",n),n},i.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},i.p="/";var c=this["webpackJsonpamarr-frontend-components"]=this["webpackJsonpamarr-frontend-components"]||[],l=c.push.bind(c);c.push=n,c=c.slice();for(var u=0;u<c.length;u++)n(c[u]);var d=l;o.push([792,0]),t()}({0:function(e,n){e.exports=React},1:function(e,n,t){"use strict";t.d(n,"g",(function(){return r})),t.d(n,"V",(function(){return o})),t.d(n,"i",(function(){return i})),t.d(n,"D",(function(){return c})),t.d(n,"G",(function(){return l})),t.d(n,"v",(function(){return u})),t.d(n,"B",(function(){return d})),t.d(n,"o",(function(){return s})),t.d(n,"r",(function(){return m})),t.d(n,"I",(function(){return f})),t.d(n,"H",(function(){return p})),t.d(n,"Q",(function(){return g})),t.d(n,"E",(function(){return b})),t.d(n,"u",(function(){return h})),t.d(n,"h",(function(){return x})),t.d(n,"t",(function(){return w})),t.d(n,"y",(function(){return v})),t.d(n,"w",(function(){return y})),t.d(n,"C",(function(){return k})),t.d(n,"s",(function(){return E})),t.d(n,"R",(function(){return A})),t.d(n,"q",(function(){return O})),t.d(n,"J",(function(){return j})),t.d(n,"F",(function(){return z})),t.d(n,"S",(function(){return I})),t.d(n,"m",(function(){return C})),t.d(n,"j",(function(){return M})),t.d(n,"n",(function(){return D})),t.d(n,"k",(function(){return H})),t.d(n,"l",(function(){return S})),t.d(n,"z",(function(){return Z})),t.d(n,"L",(function(){return P})),t.d(n,"x",(function(){return $})),t.d(n,"T",(function(){return T})),t.d(n,"U",(function(){return q})),t.d(n,"b",(function(){return B})),t.d(n,"O",(function(){return L})),t.d(n,"A",(function(){return U})),t.d(n,"a",(function(){return R})),t.d(n,"d",(function(){return W})),t.d(n,"f",(function(){return F})),t.d(n,"e",(function(){return J})),t.d(n,"X",(function(){return G})),t.d(n,"c",(function(){return V})),t.d(n,"W",(function(){return K})),t.d(n,"K",(function(){return Q})),t.d(n,"M",(function(){return X})),t.d(n,"N",(function(){return Y})),t.d(n,"p",(function(){return ee})),t.d(n,"P",(function(){return ne}));var a=t(3),r=function(e){return JSON.parse(decodeURIComponent(escape(atob(e))))},o=function(e){return btoa(unescape(encodeURIComponent(e)))},i=function(e){return e.toUpperCase()},c=function(e){return e.replaceAll(" ","-").toLowerCase()},l=new a.a(!1),u=new a.a(!1),d=new a.a(!1),s=new a.a(!1),m=new a.a(""),f=new a.a(!1),p=new a.a(!1),g=new a.a(!1),b=new a.a(!1),h=new a.a(!1),x=new a.a(!1),w=new a.a(""),v=new a.a(!0),y=new a.a(!0),k=new a.a(!0),E=new a.a(!0),A=new a.a(!0),O=new a.a(!0),j=new a.a({}),N=new a.a(!1),_=0,z=new a.a(!1),I=new a.a(""),C=new a.a(""),M=new a.a(""),D=new a.a(""),H=new a.a(""),S=new a.a(""),Z=new a.a(""),P=new a.a(""),$=new a.a(!1),T=new a.a(!1),q=new a.a(!1),B=function(){setTimeout((function(){_++,N.next(!0)}),0)},L=function(){setTimeout((function(){_>0&&_--,0==_&&N.next(!1)}),0)},U=function(){return N.asObservable()},R=function(e){return!!/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e)},W=function(e){return e.match(/^[a-zA-Z\xc0-\xff-. ]*$/)},F=function(e){return/^[0-9a-zA-Z !@#\$%\^\&*\)\(+=._-]+$/.test(e)},J=function(e){return/^\(?([0-9]{3})\)\s[0-9]{3}-[0-9]{4}$/.test(e)},G=function(e){return/((([A-Za-z]{3,9}:(?:\/\/)?)(?:[-;:&=\+\$,\w]+@)?[A-Za-z0-9.-]+|(?:www.|[-;:&=\+\$,\w]+@)[A-Za-z0-9.-]+)((?:\/[\+~%\/.\w-_]*)?\??(?:[-\+=&;%@.\w_]*)#?(?:[\w]*))?)/.test(e)},V=function(e){return/^[0-9]*$/.test(e)},K=function(e){return!!/^[-a-zA-Z0-9+&@#/%?=~|!:,.;]*[-a-zA-Z0-9+&@#/%=~|]$/.test(e)},Q=function(e){if(e&&""!==e&&-1===e.indexOf("(")&&-1===e.indexOf(") ")&&-1===e.indexOf("-")){return"("+e.substring(0,3)+") "+e.substring(3,6)+"-"+e.substring(6,e.length)}return e},X=function(e){return e&&(e=e.toFixed(2).replace(/\d(?=(\d{3})+\.)/g,"$&,")),0!==e&&"0"!==e||(e=e.toFixed(2)),e},Y=function(e,n){return e=e?Number(e):0,(0===(n=n?Number(n):0)||"0"===n?0:(e-n)/n*100).toFixed(2)},ee=function(e){var n={tabs:!0,type:"designer",clavos:!1,download:!0,quote:!0,srcUrl:"/DoorApp",id:"AmarrDoorDesigner",panel:e.selectedPanel,brand:"",myGuid:"d-608280c6f378f8.36911414",email:!0,height:e.selectedHeight,glass:e.selectedGlass,collection:e.selectedCollection,print:!0,baseUrl:"",gplacement:e.selectedWindowPlacement,width:e.selectedWidth,srcDir:"DoorApp",MosaicName:"Mosaic",logooption:""};return e.selectedColor&&(n.color=e.selectedColor),e.colorHex&&(n.colorHex=e.colorHex),e.colorZone&&(n.colorZone=e.colorZone),e.selectedConstruction&&(n.model=e.selectedConstruction),e.selectedWindowDesign&&(n.top=e.selectedWindowDesign),e.glazepattern&&(n.glazepattern=e.glazepattern),e.selectedHardware&&(n.hardware=e.selectedHardware),n},ne=function(e,n,t){var a="",r=e.split(n);return r.forEach((function(e,n){"undefined"!==e&&e&&(a+=e,n!==r.length-1&&(a+=t))})),a}},19:function(e,n){e.exports=ReactDOM},21:function(e,n,t){"use strict";t.d(n,"a",(function(){return c}));var a=t(16),r=t(0),o=t.n(r),i=t(4).default.div.withConfig({displayName:"styles__View",componentId:"zfm3w6-0"})([".divider{width:100%;height:6px;@media screen and (min-width:1281px){height:8px;}@media screen and (min-width:1681px){height:10px;}}"]),c=function(e){return Object(a.a)(e),o.a.createElement(i,null,o.a.createElement("div",{className:"divider"},"\xa0"))}},5:function(e,n,t){"use strict";t.d(n,"a",(function(){return s}));var a=t(23),r=t(0),o=t.n(r),i=t(4),c=i.default.div.withConfig({displayName:"styles__View",componentId:"sc-1jt3i0i-0"})([""]),l=i.default.button.withConfig({displayName:"styles__Button",componentId:"sc-1jt3i0i-1"})(['font-size:12px;font-family:"Open Sans";font-weight:600;font-stretch:normal;font-style:normal;line-height:1.5;letter-spacing:normal;text-align:center;color:#fff;padding:12px 19px 12px 20px;border-radius:4px;background-color:#006166;box-shadow:none;border:none;transition:all ease 300ms;&:hover{transform:scale(1.1);background-color:#338084;color:#fff;}&:focus{transform:scale(1);box-shadow:none !important;background-color:#004347;}&:active{background-color:#006166 !important;box-shadow:none !important;transform:scale(1);border:none !important;}&.btn-inverse{color:#333333;background:#b2cfd1;&:hover{background:#8EB8BB;}&:focus{background:#8EA5A7;border:none;transform:scale(1);box-shadow:none !important;}&:active{background-color:#8EA5A7 !important;border:none !important;transform:scale(1.1);box-shadow:none !important;}}@media(min-width:1201px){font-size:16px;}.button-icon{vertical-align:top;padding-right:8px;}']),u=t(18),d=t(17),s=function(e){var n=e.label,t=void 0===n?"label":n,r=e.classStyle,i=void 0===r?"default":r,s=e.link,m=void 0!==s&&s,f=e.disabled,p=void 0!==f&&f,g=e.datatoggle,b=void 0===g?"":g,h=e.datatarget,x=void 0===h?"":h,w=e.linkHref,v=e.target,y=void 0===v?"_self":v,k=e.downloadLink,E=void 0!==k&&k,A=e.inverse,O=void 0!==A&&A,j=e.icon,N=void 0===j?"":j,_=e.iconAlt,z=void 0===_?"":_,I=e.dataItemName,C=void 0===I?"":I,M=e.id,D=void 0===M?"":M,H=e.type,S=void 0===H?"button":H,Z=e.showDisabledMessage,P=void 0===Z?"":Z,$=e.ariaLabel,T=void 0===$?"":$,q=Object(a.a)(e,["label","classStyle","link","disabled","datatoggle","datatarget","linkHref","target","downloadLink","inverse","icon","iconAlt","dataItemName","id","type","showDisabledMessage","ariaLabel"]);return o.a.createElement(c,null,o.a.createElement("div",{className:"".concat(p&&P&&"disabled-button-parent")},m?o.a.createElement("a",{href:w,download:E,target:y,"data-item-name":C,id:D,"aria-label":T},o.a.createElement(l,Object.assign({role:"presentation",disabled:p,classStyle:"".concat(i)},q,{type:S,className:O?"btn-inverse btn btn-success":"btn btn-success"}),""!=N?o.a.createElement("div",{"data-toggle":b,"data-target":x},o.a.createElement("img",{loading:"lazy",className:"button-icon",src:N,alt:z}),o.a.createElement("span",null,t)):o.a.createElement("span",null,t))):o.a.createElement(l,Object.assign({disabled:p,classStyle:i,className:O?"btn-inverse btn btn-success":"btn btn-success",id:D,"data-item-name":C,type:S},q),o.a.createElement("span",null,t)),p&&P&&o.a.createElement(u.a,{placement:"top",delay:{show:250,hide:250},overlay:o.a.createElement(d.a,{id:"button-tooltip"},o.a.createElement("div",{className:"p-1 amarr-h6"},P))},o.a.createElement("div",{className:"disabled-button-overlay"}))))}},55:function(e,n,t){"use strict";var a=t(0),r=t.n(a),o=t(5),i=t(1),c=t(21),l=t(4).default.section.withConfig({displayName:"styles__Content",componentId:"mqdtio-0"})([".button-container-style{display:flex;flex-wrap:wrap;&.text-left-alignment{justify-content:left;}&.text-right-alignment{justify-content:flex-end;}&.text-center-alignment{justify-content:center;}}.button-container-style-block{@media screen and (max-width:767px){display:flex;flex-direction:column;}}.mobile-margin{&.text-left-alignment{justify-content:left;}&.text-right-alignment{justify-content:flex-end;}&.text-center-alignment{justify-content:center;}@media screen and (max-width:767px){margin-left:0;}}.button-container-style > *{margin:20px 0 0 0px;}.button-container-style{margin:-20px 0 0 0px;}.mobile-margin:not(:last-child){@media screen and (min-width:1681px){margin-right:25px;}@media screen and (max-width:1680px){margin-right:20px;}}.quick-links{border:solid 1px #8d8d8d;border-radius:4px;padding:0px 16px 18px;margin-top:10px;.mobile-margin:not(:last-child){margin-right:20px;@media screen and (min-width:1681px){margin-right:25px;}@media screen and (max-width:767px){margin-right:0px;}}.mobile-margin:nth-child(odd){@media screen and (max-width:767px){padding-right:20px;}}}@media screen and (max-width:991px){.button-auto-height{button.btn{height:min-content;white-space:break-spaces;text-align:left;}}}@media screen and (max-width:991px){.button-container-style.quick-links{flex-wrap:wrap;.mobile-margin{flex:0 0 50%;max-width:calc(50% - 20px);}}}@media screen and (max-width:1025px){.quick-links{padding:0px 18px 16px 18px;margin-top:10px;}.quick-links.button-container-style > *{margin:18px 0px 0px;}}"]),u=function(e){var n=e.buttonData,t=Object(i.g)(n);return r.a.createElement(l,null,"default"!==t.topMargin&&!t.addBorder&&r.a.createElement("span",null,r.a.createElement(c.a,null)),r.a.createElement("div",{className:"".concat(t.addBorder&&t.addContainer&&"container")},r.a.createElement("div",{className:"button-container-style container mb-4\n ".concat("left"===t.alignment&&"text-left-alignment"," ").concat("right"===t.alignment&&"text-right-alignment"," ").concat("center"===t.alignment&&"text-center-alignment","\n ").concat("block"===t.mobileAlignment&&"button-container-style-block","\n ").concat("medium"===t.topMargin&&"mt-1 mt-sm-2","\n ").concat("extra"===t.topMargin&&"mt-2 mt-sm-4","\n ").concat("medium"===t.bottomMargin&&"mb-4 mb-sm-5","\n ").concat("extra"===t.bottomMargin&&"mb-5 pb-2","\n ").concat(t.addBorder&&"quick-links","\n ")},t.ctaItems&&t.ctaItems.map((function(e,n,t){return r.a.createElement("div",{key:n,className:"".concat(e.label.length>25&&"button-auto-height"," mobile-margin")},"tertiary"!==e.color&&"noTheme"!==e.color&&r.a.createElement(o.a,{label:Object(i.i)(e.label),link:!0,linkHref:e.url,target:e.linkAction,inverse:"inverse"===e.color}),"tertiary"===e.color&&e.isInternal&&r.a.createElement("a",{href:e.cta.url,target:e.cta.linkAction}),"tertiary"===e.color&&!e.isInternal&&"_self"===e.cta.linkAction&&r.a.createElement("a",{href:e.cta.url,target:e.cta.linkAction}),"tertiary"===e.color&&e.isInternal&&"_blank"===e.cta.linkAction&&r.a.createElement("a",{href:e.cta.url,target:e.cta.linkAction,rel:"noopener"}),"noTheme"===e.color&&e.isInternal&&r.a.createElement("a",{className:"amarrHighlight",href:e.url,target:e.linkAction},e.label),"noTheme"===e.color&&!e.isInternal&&"_self"===e.linkAction&&r.a.createElement("a",{className:"amarrHighlight",href:e.url,target:e.linkAction},e.label),"noTheme"===e.color&&!e.isInternal&&"_blank"===e.linkAction&&r.a.createElement("a",{className:"amarrHighlight",href:e.url,target:e.linkAction,rel:"noopener"},e.label))})))),"extra"===t.bottomMargin&&r.a.createElement(c.a,null))};u.defaultProps={theme:"",buttonData:""};n.a=u},699:function(e,n,t){"use strict";t.r(n);var a=t(14),r=t(55);n.default=a.a.create({component:r.a,configuration:{tagname:"amarr-button",useShadow:!1},plugins:[]})}});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@assaabloy/amarr-wc-button",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.14",
|
|
4
4
|
"description": "Web component - Button",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "button.js",
|
|
@@ -11,5 +11,5 @@
|
|
|
11
11
|
},
|
|
12
12
|
"author": "Nagarro",
|
|
13
13
|
"license": "MIT",
|
|
14
|
-
"gitHead": "
|
|
14
|
+
"gitHead": "a050fed67625ff5bd34612fff8b26380e0caa831"
|
|
15
15
|
}
|