@purpurds/cta-link 3.0.0

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.
@@ -0,0 +1,10 @@
1
+ System.register(["react","react/jsx-runtime"],function(v,L){"use strict";var o,_;return{setters:[p=>{o=p.default},p=>{_=p.jsx}],execute:function(){const p={SM:"sm",MD:"md",LG:"lg"};function g(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var f={exports:{}};/*!
2
+ Copyright (c) 2018 Jed Watson.
3
+ Licensed under the MIT License (MIT), see
4
+ http://jedwatson.github.io/classnames
5
+ */(function(t){(function(){var a={}.hasOwnProperty;function u(){for(var r="",e=0;e<arguments.length;e++){var n=arguments[e];n&&(r=i(r,s.call(this,n)))}return r}function s(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return u.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var e="";for(var n in r)a.call(r,n)&&r[n]&&(e=i(e,this&&this[n]||n));return e}function i(r,e){return e?r?r+" "+e:r+e:r}t.exports?(u.default=u,t.exports=u):window.classNames=u})()})(f);var y=f.exports;const k=g(y),x={"purpur-icon":"_purpur-icon_8u1lq_1","purpur-icon--xxs":"_purpur-icon--xxs_8u1lq_4","purpur-icon--xs":"_purpur-icon--xs_8u1lq_8","purpur-icon--sm":"_purpur-icon--sm_8u1lq_12","purpur-icon--md":"_purpur-icon--md_8u1lq_16","purpur-icon--lg":"_purpur-icon--lg_8u1lq_20","purpur-icon--xl":"_purpur-icon--xl_8u1lq_24"},b={name:"arrow-right",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M20.9 12a.9.9 0 0 1-.264.636l-5.5 5.5a.9.9 0 0 1-1.272-1.272l3.963-3.964H4a.9.9 0 0 1 0-1.8h13.827l-3.963-3.964a.9.9 0 1 1 1.272-1.272l5.5 5.5A.9.9 0 0 1 20.9 12Z" clip-rule="evenodd"/></svg>',keywords:["arrow-right"],category:"utility"},h=k.bind(x),d="purpur-icon",w="md",$=t=>t.filter(a=>Object.keys(a).length>=1).map(a=>`${a.name}="${a.value}"`).join(" "),S=({content:t="",title:a}={})=>{const u=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},{name:"viewBox",value:"0 0 24 24"},a?{name:"role",value:"img"}:{name:"aria-hidden",value:"true"}],s=a?`<title>${a}</title>`:"";return`<svg ${$(u)}>${s}${t}</svg>`},j=t=>t.replace(/<(\/?)svg([^>]*)>/g,"").trim(),O=({["data-testid"]:t,svg:a,allyTitle:u,className:s="",size:i=w,...r})=>{const e=S({content:j(a.svg),title:u}),n=h(s,d,`${d}--${i}`);return _("span",{"aria-label":u,className:n,"data-testid":t,dangerouslySetInnerHTML:{__html:e},...r})};function q(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var m={exports:{}};/*!
6
+ Copyright (c) 2018 Jed Watson.
7
+ Licensed under the MIT License (MIT), see
8
+ http://jedwatson.github.io/classnames
9
+ */(function(t){(function(){var a={}.hasOwnProperty;function u(){for(var r="",e=0;e<arguments.length;e++){var n=arguments[e];n&&(r=i(r,s(n)))}return r}function s(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return u.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var e="";for(var n in r)a.call(r,n)&&r[n]&&(e=i(e,n));return e}function i(r,e){return e?r?r+" "+e:r+e:r}t.exports?(u.default=u,t.exports=u):window.classNames=u})()})(m);var M=m.exports;const N=q(M),l={"purpur-cta-link":"_purpur-cta-link_e7abc_1","purpur-cta-link--sm":"_purpur-cta-link--sm_e7abc_33","purpur-cta-link--icon-only":"_purpur-cta-link--icon-only_e7abc_36","purpur-cta-link--md":"_purpur-cta-link--md_e7abc_39","purpur-cta-link--lg":"_purpur-cta-link--lg_e7abc_45","purpur-cta-link--full-width":"_purpur-cta-link--full-width_e7abc_51","purpur-cta-link--primary":"_purpur-cta-link--primary_e7abc_54","purpur-cta-link--disabled":"_purpur-cta-link--disabled_e7abc_58","purpur-cta-link--primary-negative":"_purpur-cta-link--primary-negative_e7abc_64","purpur-cta-link--secondary":"_purpur-cta-link--secondary_e7abc_76","purpur-cta-link--secondary-negative":"_purpur-cta-link--secondary-negative_e7abc_87","purpur-cta-link--expressive":"_purpur-cta-link--expressive_e7abc_98","purpur-cta-link--expressive-negative":"_purpur-cta-link--expressive-negative_e7abc_108"},c="purpur-cta-link",E=v("CtaLink",({children:t,className:a,["data-testid"]:u,fullWidth:s=!1,iconOnly:i,size:r=p.MD,variant:e,...n})=>{const C=N([a,l[c],l[`${c}--${e}`],l[`${c}--${r}`]],{[l[`${c}--icon-only`]]:i,[l[`${c}--negative`]]:e.endsWith("negative"),[l[`${c}--full-width`]]:s}),A=n.href?"a":"span";return o.createElement(A,{className:C,"data-testid":u,...n},t&&!i&&t," ",o.createElement(O,{svg:b,size:r===p.LG?"sm":"xs"}))})}}});
10
+ //# sourceMappingURL=cta-link.system.js.map