New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@axa-ch/icon

Package Overview
Dependencies
Maintainers
48
Versions
102
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@axa-ch/icon - npm Package Compare versions

Comparing version 8.0.9 to 8.0.10

4

lib/index.js

@@ -1,3 +0,3 @@

import{LitElement as e,css as t,unsafeCSS as r}from"lit";import{unsafeHTML as n}from"lit/directives/unsafe-html.js";import{Expand_lessSvg as o,Insert_drive_fileSvg as s,File_downloadSvg as a,EmailSvg as i,Expand_moreSvg as c,Phone_iphoneSvg as l,Local_phoneSvg as u,AddSvg as d,SearchSvg as g,File_uploadSvg as p,Cloud_uploadSvg as m,Check_circleSvg as h,CheckSvg as f,Info_outlineSvg as v,Warning_amberSvg as w,CloudySvg as x,CloseSvg as y}from"@axa-ch/materials/icons/material-design";import{ArrowLeftSvg as E,ArrowRightSvg as b}from"@axa-ch/materials/icons";import{AxaLogoSvg as S,AxaLogoOpenSvg as N}from"@axa-ch/materials/images";var $=(e,t)=>{const r=e.toLowerCase();return window.customElements.get(r)||window.customElements.define(r,t),r};const M=e=>!(null==e),T=new Map;[[String,""],[Boolean,!1],[Object,{}],[Array,[]],[Number,0],[Function,()=>{}]].forEach((([e,t])=>{T.set(e,t)}));const _=()=>{},j=e=>{const{constructor:{properties:t}}=e;Object.keys(t).forEach((r=>{const n=t[r],{type:o,converter:s,defaultValue:a}=n;if(!o){if(!s)throw new Error(`<${e.nodeName}> property "${r}" is missing a type!`);return}let i=e[r];M(i)||(i=o===Boolean?e.hasAttribute(r):e.getAttribute(r),M(i)?e[r]=((e,t)=>t===Number?parseFloat(e):t===Function?_:t===Array||t===Object?JSON.parse(e):e)(i,o):void 0===a&&"defaultValue"in n||(e[r]="defaultValue"in n?a:T.get(o)))}))};class z extends e{static get tagName(){return"axa-icon"}static get styles(){return t`
import{LitElement as e,css as t,unsafeCSS as r}from"lit";import{unsafeHTML as s}from"lit/directives/unsafe-html.js";import{Expand_lessSvg as n,Insert_drive_fileSvg as o,File_downloadSvg as a,EmailSvg as i,Expand_moreSvg as c,Phone_iphoneSvg as l,Local_phoneSvg as d,AddSvg as g,SearchSvg as u,File_uploadSvg as p,Cloud_uploadSvg as m,Check_circleSvg as h,CheckSvg as f,Info_outlineSvg as v,Warning_amberSvg as w,CloudySvg as x,CloseSvg as y}from"@axa-ch/materials/icons/material-design";import{ArrowLeftSvg as E,ArrowRightSvg as b}from"@axa-ch/materials/icons";import{AxaLogoSvg as N,AxaLogoOpenSvg as S}from"@axa-ch/materials/images";var $=(e,t)=>{const r=e.toLowerCase();return window.customElements.get(r)||window.customElements.define(r,t),r};const _=(e,t)=>{return`${e}-${r=t,`${r}`.replace(/\./g,"-").replace(/[^A-Za-z0-9-]/g,"")}`;var r},z=e=>!(null==e),A=new Map;[[String,""],[Boolean,!1],[Object,{}],[Array,[]],[Number,0],[Function,()=>{}]].forEach((([e,t])=>{A.set(e,t)}));const M=()=>{},T=e=>{const{constructor:{properties:t}}=e;Object.keys(t).forEach((r=>{const s=t[r],{type:n,converter:o,defaultValue:a}=s;if(!n){if(!o)throw new Error(`<${e.nodeName}> property "${r}" is missing a type!`);return}let i=e[r];z(i)||(i=n===Boolean?e.hasAttribute(r):e.getAttribute(r),z(i)?e[r]=((e,t)=>t===Number?parseFloat(e):t===Function?M:t===Array||t===Object?JSON.parse(e):e)(i,n):void 0===a&&"defaultValue"in s||(e[r]="defaultValue"in s?a:A.get(n)))}))};class j extends e{static get tagName(){return"axa-icon"}static get styles(){return t`
${r(":host(:not([size=original])) svg {\n width: 24px;\n height: 24px;\n}\n\n:host([size=small]) svg {\n width: 20px;\n height: 20px;\n}\n\n:host([size=large]) svg {\n width: 32px;\n height: 32px;\n}")}
`}static get iconsMapping(){return{"arrow-left":E,"arrow-right":b,collapse:o,document:s,download:a,email:i,expand:c,mobile:l,phone:u,add:d,search:g,upload:p,"cloud-upload":m,"axa-logo":S,"axa-logo-open":N,"check-circle":h,check:f,"info-outline":v,"warning-amber":w,cloudy:x,close:y}}static get properties(){return{icon:{type:String},size:{type:String,reflect:!0,defaultValue:"medium"},_loadedSvg:{type:String}}}constructor(){super(),j(this)}updated(){const{icon:e}=this;var t;/\.svg/.test(e)?(t=e,new Promise(((e,r)=>{const n=new XMLHttpRequest;n.open("GET",t),n.onload=()=>e(n.responseText),n.onerror=()=>r(n.statusText),n.send()}))).then((e=>{this._loadedSvg=e})):/<svg/.test(e)?this._loadedSvg=e:this._loadedSvg=z.iconsMapping[e]||""}render(){return this._loadedSvg&&n((e=>{const t=document.createElement("div");t.innerHTML=e;const r=t.firstElementChild;if(!r||"svg"!==r.tagName.toLowerCase())return"";if(r.getElementsByTagName("script").length)return"";for(let e=0,t=r.attributes,n=t.length;e<n;e++)if(t[e].name.startsWith("on"))return"";return e})(this._loadedSvg))}}((e,t,r)=>{const n="string"==typeof t&&t;let o="";e.forEach((e=>{const s=e instanceof HTMLElement?e.constructor:e,{tagName:a}=s,i=!n&&t[a];if(i){if(!window.customElements.get(a)&&s.versions)throw Error(`'versions' is a reserved class property, but was found in ${a}'s class`);s.versions=i,$(a,s)}let{versions:c}=s;!c&&r&&(c=t[r.constructor.tagName],c[a]=Object.values(c)[0]);const l=n||c[a];o=((e,t)=>{return`${e}-${r=t,`${r}`.replace(/\./g,"-").replace(/[^A-Za-z0-9-]/g,"")}`;var r})(a,l),$(o,class extends s{})}))})([z],{"axa-icon":{"axa-icon":"8.0.8"}});export{z as default};
`}static get iconsMapping(){return{"arrow-left":E,"arrow-right":b,collapse:n,document:o,download:a,email:i,expand:c,mobile:l,phone:d,add:g,search:u,upload:p,"cloud-upload":m,"axa-logo":N,"axa-logo-open":S,"check-circle":h,check:f,"info-outline":v,"warning-amber":w,cloudy:x,close:y}}static get properties(){return{icon:{type:String},size:{type:String,reflect:!0,defaultValue:"medium"},_loadedSvg:{type:String}}}constructor(){super(),T(this)}updated(){const{icon:e}=this;var t;/\.svg/.test(e)?(t=e,new Promise(((e,r)=>{const s=new XMLHttpRequest;s.open("GET",t),s.onload=()=>e(s.responseText),s.onerror=()=>r(s.statusText),s.send()}))).then((e=>{this._loadedSvg=e})):/<svg/.test(e)?this._loadedSvg=e:this._loadedSvg=j.iconsMapping[e]||""}render(){return this._loadedSvg&&s((e=>{const t=document.createElement("div");t.innerHTML=e;const r=t.firstElementChild;if(!r||"svg"!==r.tagName.toLowerCase())return"";if(r.getElementsByTagName("script").length)return"";for(let e=0,t=r.attributes,s=t.length;e<s;e++)if(t[e].name.startsWith("on"))return"";return e})(this._loadedSvg))}}var L,O,V;L=[j],O={"axa-icon":{"axa-icon":"8.0.9"}},V?((e,t,r)=>{const s=r.constructor,{tagName:n}=s,o=t[n];if(!window.customElements.get(n)&&s.versions)throw Error(`'versions' is a reserved class property, but was found in ${n}'s class`);s.versions=o,e.forEach((e=>{const{tagName:t}=e,r=o[t],s=_(t,r);$(s,class extends e{})}))})(L,O,V):"string"==typeof O?((e,t)=>{let r;e.forEach((e=>{const{tagName:s}=e;r=_(s,t),$(r,class extends e{})}))})(L,O):((e,t)=>{const{tagName:r}=e,s=t[r][r],n=_(r,s);$(r,e),$(n,class extends e{})})(L[0],O);export{j as default};

@@ -1,3 +0,3 @@

import{LitElement as e,css as t,unsafeCSS as r}from"lit";import{unsafeHTML as s}from"lit/directives/unsafe-html.js";import{Expand_lessSvg as n,Insert_drive_fileSvg as o,File_downloadSvg as a,EmailSvg as i,Expand_moreSvg as c,Phone_iphoneSvg as l,Local_phoneSvg as u,AddSvg as p,SearchSvg as d,File_uploadSvg as m,Cloud_uploadSvg as g,Check_circleSvg as h,CheckSvg as f,Info_outlineSvg as v,Warning_amberSvg as w,CloudySvg as y,CloseSvg as b}from"@axa-ch/materials/icons/material-design";import{ArrowLeftSvg as x,ArrowRightSvg as E}from"@axa-ch/materials/icons";import{AxaLogoSvg as j,AxaLogoOpenSvg as N}from"@axa-ch/materials/images";const{customElements:k}=window,O=new Map,S=new WeakMap;if(k){const{define:e}=k;k.define=(t,r)=>(O.set(r,t),e.call(k,t,r))}const A=({attrs:e,events:t,props:r,ref:s})=>n=>{n&&(((e,t)=>{t&&Object.keys(t).forEach((r=>{const s=t[r];null==s?e.removeAttribute(r):e.setAttribute(r,s)}))})(n,e),((e,t={})=>{const r=S.get(e)||{};S.set(e,t),Object.keys(r).forEach((s=>{r[s]&&r[s]!==t[s]&&e.removeEventListener(s,r[s])})),Object.keys(t).forEach((s=>{t[s]!==r[s]&&e.addEventListener(s,t[s])}))})(n,t),((e,t)=>{Object.keys(t||{}).forEach((r=>{e[r]=t[r]}))})(n,r)),((e,t)=>{t&&t(e)})(n,s)},L=e=>(t,r,...s)=>{const n=(e=>O.get(e)||e)(t),o=(e=>{const{attrs:t,events:r,ref:s,key:n,dangerouslySetInnerHTML:o,...a}=e||{};return{ref:A({attrs:t,events:r,props:a,ref:s}),key:n,dangerouslySetInnerHTML:o}})(r);return e(n,o,...s)};var M=(e,t)=>{const r=e.toLowerCase();return window.customElements.get(r)||window.customElements.define(r,t),r};const $=(e,t,r)=>{const s="string"==typeof t&&t;let n="";return e.forEach((e=>{const o=e instanceof HTMLElement?e.constructor:e,{tagName:a}=o,i=!s&&t[a];if(i){if(!window.customElements.get(a)&&o.versions)throw Error(`'versions' is a reserved class property, but was found in ${a}'s class`);o.versions=i,M(a,o)}let{versions:c}=o;!c&&r&&(c=t[r.constructor.tagName],c[a]=Object.values(c)[0]);const l=s||c[a];n=((e,t)=>{return`${e}-${r=t,`${r}`.replace(/\./g,"-").replace(/[^A-Za-z0-9-]/g,"")}`;var r})(a,l),M(n,class extends o{})})),n},T=(e,t)=>{const r={},s={};let n;return Object.keys(e).forEach((o=>{const a=e[o];let i;const c=t.properties[o]||{},{type:l}=c;switch(i=0===o.indexOf("on")&&o.charAt(2)===o.charAt(2).toUpperCase()?Function:"className"===o?"className":l,i){case"className":case Array:case Object:case Function:case Boolean:n=s;break;default:n=l?s:r}void 0!==a&&(n[o]="style"===o?(e=>Object.keys(e).reduce(((t,r)=>{let s=t;return`${s+=r.split(/(?=[A-Z])/).join("-").toLowerCase()}:${e[r]};`}),""))(a):a)})),{attrs:r,props:s}};const C=e=>!(null==e),_=new Map;[[String,""],[Boolean,!1],[Object,{}],[Array,[]],[Number,0],[Function,()=>{}]].forEach((([e,t])=>{_.set(e,t)}));const z=()=>{},F=e=>{const{constructor:{properties:t}}=e;Object.keys(t).forEach((r=>{const s=t[r],{type:n,converter:o,defaultValue:a}=s;if(!n){if(!o)throw new Error(`<${e.nodeName}> property "${r}" is missing a type!`);return}let i=e[r];C(i)||(i=n===Boolean?e.hasAttribute(r):e.getAttribute(r),C(i)?e[r]=((e,t)=>t===Number?parseFloat(e):t===Function?z:t===Array||t===Object?JSON.parse(e):e)(i,n):void 0===a&&"defaultValue"in s||(e[r]="defaultValue"in s?a:_.get(n)))}))};class H extends e{static get tagName(){return"axa-icon"}static get styles(){return t`
${r(":host(:not([size=original])) svg {\n width: 24px;\n height: 24px;\n}\n\n:host([size=small]) svg {\n width: 20px;\n height: 20px;\n}\n\n:host([size=large]) svg {\n width: 32px;\n height: 32px;\n}")}
`}static get iconsMapping(){return{"arrow-left":x,"arrow-right":E,collapse:n,document:o,download:a,email:i,expand:c,mobile:l,phone:u,add:p,search:d,upload:m,"cloud-upload":g,"axa-logo":j,"axa-logo-open":N,"check-circle":h,check:f,"info-outline":v,"warning-amber":w,cloudy:y,close:b}}static get properties(){return{icon:{type:String},size:{type:String,reflect:!0,defaultValue:"medium"},_loadedSvg:{type:String}}}constructor(){super(),F(this)}updated(){const{icon:e}=this;var t;/\.svg/.test(e)?(t=e,new Promise(((e,r)=>{const s=new XMLHttpRequest;s.open("GET",t),s.onload=()=>e(s.responseText),s.onerror=()=>r(s.statusText),s.send()}))).then((e=>{this._loadedSvg=e})):/<svg/.test(e)?this._loadedSvg=e:this._loadedSvg=H.iconsMapping[e]||""}render(){return this._loadedSvg&&s((e=>{const t=document.createElement("div");t.innerHTML=e;const r=t.firstElementChild;if(!r||"svg"!==r.tagName.toLowerCase())return"";if(r.getElementsByTagName("script").length)return"";for(let e=0,t=r.attributes,s=t.length;e<s;e++)if(t[e].name.startsWith("on"))return"";return e})(this._loadedSvg))}}$([H],{"axa-icon":{"axa-icon":"8.0.8"}});var B=(e,t)=>((e,t,r)=>{const{tagName:s}=t,n=r?$([t],r):s,o=n.split("-").map((e=>e.charAt(0).toUpperCase()+e.slice(1))).join(""),a=({children:r,...s})=>{const{attrs:o,props:a}=T(s,t);return L(e)(n,{isReact:!0,attrs:o,...a},r)};return a.displayName=o,a})(e,H,t);export{B as default};
import{LitElement as e,css as t,unsafeCSS as s}from"lit";import{unsafeHTML as r}from"lit/directives/unsafe-html.js";import{Expand_lessSvg as n,Insert_drive_fileSvg as a,File_downloadSvg as o,EmailSvg as i,Expand_moreSvg as c,Phone_iphoneSvg as l,Local_phoneSvg as p,AddSvg as u,SearchSvg as d,File_uploadSvg as g,Cloud_uploadSvg as m,Check_circleSvg as h,CheckSvg as f,Info_outlineSvg as v,Warning_amberSvg as w,CloudySvg as y,CloseSvg as x}from"@axa-ch/materials/icons/material-design";import{ArrowLeftSvg as b,ArrowRightSvg as E}from"@axa-ch/materials/icons";import{AxaLogoSvg as N,AxaLogoOpenSvg as j}from"@axa-ch/materials/images";const{customElements:k}=window,S=new Map,A=new WeakMap;if(k){const{define:e}=k;k.define=(t,s)=>(S.set(s,t),e.call(k,t,s))}const O=({attrs:e,events:t,props:s,ref:r})=>n=>{n&&(((e,t)=>{t&&Object.keys(t).forEach((s=>{const r=t[s];null==r?e.removeAttribute(s):e.setAttribute(s,r)}))})(n,e),((e,t={})=>{const s=A.get(e)||{};A.set(e,t),Object.keys(s).forEach((r=>{s[r]&&s[r]!==t[r]&&e.removeEventListener(r,s[r])})),Object.keys(t).forEach((r=>{t[r]!==s[r]&&e.addEventListener(r,t[r])}))})(n,t),((e,t)=>{Object.keys(t||{}).forEach((s=>{e[s]=t[s]}))})(n,s)),((e,t)=>{t&&t(e)})(n,r)},L=e=>(t,s,...r)=>{const n=(e=>S.get(e)||e)(t),a=(e=>{const{attrs:t,events:s,ref:r,key:n,dangerouslySetInnerHTML:a,...o}=e||{};return{ref:O({attrs:t,events:s,props:o,ref:r}),key:n,dangerouslySetInnerHTML:a}})(s);return e(n,a,...r)};var M=(e,t)=>{const s=e.toLowerCase();return window.customElements.get(s)||window.customElements.define(s,t),s};const $=(e,t)=>{return`${e}-${s=t,`${s}`.replace(/\./g,"-").replace(/[^A-Za-z0-9-]/g,"")}`;var s},T=(e,t,s)=>s?((e,t,s)=>{const r=s.constructor,{tagName:n}=r,a=t[n];if(!window.customElements.get(n)&&r.versions)throw Error(`'versions' is a reserved class property, but was found in ${n}'s class`);r.versions=a,e.forEach((e=>{const{tagName:t}=e,s=a[t],r=$(t,s);M(r,class extends e{})}))})(e,t,s):"string"==typeof t?((e,t)=>{let s;return e.forEach((e=>{const{tagName:r}=e;s=$(r,t),M(s,class extends e{})})),s})(e,t):((e,t)=>{const{tagName:s}=e,r=t[s][s],n=$(s,r);M(s,e),M(n,class extends e{})})(e[0],t),C=(e,t)=>{const s={},r={};let n;return Object.keys(e).forEach((a=>{const o=e[a];let i;const c=t.properties[a]||{},{type:l}=c;switch(i=0===a.indexOf("on")&&a.charAt(2)===a.charAt(2).toUpperCase()?Function:"className"===a?"className":l,i){case"className":case Array:case Object:case Function:case Boolean:n=r;break;default:n=l?r:s}void 0!==o&&(n[a]="style"===a?(e=>Object.keys(e).reduce(((t,s)=>{let r=t;return`${r+=s.split(/(?=[A-Z])/).join("-").toLowerCase()}:${e[s]};`}),""))(o):o)})),{attrs:s,props:r}};const _=e=>!(null==e),z=new Map;[[String,""],[Boolean,!1],[Object,{}],[Array,[]],[Number,0],[Function,()=>{}]].forEach((([e,t])=>{z.set(e,t)}));const F=()=>{},B=e=>{const{constructor:{properties:t}}=e;Object.keys(t).forEach((s=>{const r=t[s],{type:n,converter:a,defaultValue:o}=r;if(!n){if(!a)throw new Error(`<${e.nodeName}> property "${s}" is missing a type!`);return}let i=e[s];_(i)||(i=n===Boolean?e.hasAttribute(s):e.getAttribute(s),_(i)?e[s]=((e,t)=>t===Number?parseFloat(e):t===Function?F:t===Array||t===Object?JSON.parse(e):e)(i,n):void 0===o&&"defaultValue"in r||(e[s]="defaultValue"in r?o:z.get(n)))}))};class H extends e{static get tagName(){return"axa-icon"}static get styles(){return t`
${s(":host(:not([size=original])) svg {\n width: 24px;\n height: 24px;\n}\n\n:host([size=small]) svg {\n width: 20px;\n height: 20px;\n}\n\n:host([size=large]) svg {\n width: 32px;\n height: 32px;\n}")}
`}static get iconsMapping(){return{"arrow-left":b,"arrow-right":E,collapse:n,document:a,download:o,email:i,expand:c,mobile:l,phone:p,add:u,search:d,upload:g,"cloud-upload":m,"axa-logo":N,"axa-logo-open":j,"check-circle":h,check:f,"info-outline":v,"warning-amber":w,cloudy:y,close:x}}static get properties(){return{icon:{type:String},size:{type:String,reflect:!0,defaultValue:"medium"},_loadedSvg:{type:String}}}constructor(){super(),B(this)}updated(){const{icon:e}=this;var t;/\.svg/.test(e)?(t=e,new Promise(((e,s)=>{const r=new XMLHttpRequest;r.open("GET",t),r.onload=()=>e(r.responseText),r.onerror=()=>s(r.statusText),r.send()}))).then((e=>{this._loadedSvg=e})):/<svg/.test(e)?this._loadedSvg=e:this._loadedSvg=H.iconsMapping[e]||""}render(){return this._loadedSvg&&r((e=>{const t=document.createElement("div");t.innerHTML=e;const s=t.firstElementChild;if(!s||"svg"!==s.tagName.toLowerCase())return"";if(s.getElementsByTagName("script").length)return"";for(let e=0,t=s.attributes,r=t.length;e<r;e++)if(t[e].name.startsWith("on"))return"";return e})(this._loadedSvg))}}T([H],{"axa-icon":{"axa-icon":"8.0.9"}});var V=(e,t)=>((e,t,s)=>{const{tagName:r}=t,n=s?T([t],s):r,a=n.split("-").map((e=>e.charAt(0).toUpperCase()+e.slice(1))).join(""),o=({children:s,...r})=>{const{attrs:a,props:o}=C(r,t);return L(e)(n,{isReact:!0,attrs:a,...o},s)};return o.displayName=a,o})(e,H,t);export{V as default};
{
"name": "@axa-ch/icon",
"version": "8.0.9",
"version": "8.0.10",
"description": "The icon component for the AXA Pattern Library",

@@ -37,4 +37,4 @@ "author": "Pattern Warriors",

},
"gitHead": "41a7cd3001474688cd2c5a4d2d8bbafec075bc62",
"gitHead": "db21f21d628c6fc8bf354e0646e26c73198e7163",
"main": "lib/index.js"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc