@swisspost/design-system-components 1.3.3 → 1.3.4

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.
Files changed (34) hide show
  1. package/dist/cjs/loader.cjs.js +1 -1
  2. package/dist/cjs/{package-f1eacd4f.js → package-3838cb5b.js} +2 -2
  3. package/dist/cjs/{package-f1eacd4f.js.map → package-3838cb5b.js.map} +1 -1
  4. package/dist/cjs/post-collapsible.cjs.entry.js +1 -1
  5. package/dist/cjs/post-components.cjs.js +1 -1
  6. package/dist/cjs/post-icon.cjs.entry.js +33 -19
  7. package/dist/cjs/post-icon.cjs.entry.js.map +1 -1
  8. package/dist/collection/components/post-icon/post-icon.css +10 -10
  9. package/dist/collection/components/post-icon/post-icon.js +59 -34
  10. package/dist/collection/components/post-icon/post-icon.js.map +1 -1
  11. package/dist/components/package.js +1 -1
  12. package/dist/components/post-icon.js +33 -18
  13. package/dist/components/post-icon.js.map +1 -1
  14. package/dist/docs.json +34 -7
  15. package/dist/esm/loader.js +1 -1
  16. package/dist/esm/{package-144d0036.js → package-fb4a74d0.js} +2 -2
  17. package/dist/esm/{package-144d0036.js.map → package-fb4a74d0.js.map} +1 -1
  18. package/dist/esm/post-collapsible.entry.js +1 -1
  19. package/dist/esm/post-components.js +1 -1
  20. package/dist/esm/post-icon.entry.js +34 -20
  21. package/dist/esm/post-icon.entry.js.map +1 -1
  22. package/dist/post-components/p-6e225c16.entry.js +2 -0
  23. package/dist/post-components/p-6e225c16.entry.js.map +1 -0
  24. package/dist/post-components/{p-72fc6cda.entry.js → p-7dd960f1.entry.js} +2 -2
  25. package/dist/post-components/{p-d2e9b37c.js → p-87bf3416.js} +2 -2
  26. package/dist/post-components/post-components.esm.js +1 -1
  27. package/dist/post-components/post-components.esm.js.map +1 -1
  28. package/dist/types/components/post-icon/post-icon.d.ts +16 -9
  29. package/dist/types/components.d.ts +17 -17
  30. package/package.json +7 -7
  31. package/dist/post-components/p-20d342a4.entry.js +0 -2
  32. package/dist/post-components/p-20d342a4.entry.js.map +0 -1
  33. /package/dist/post-components/{p-72fc6cda.entry.js.map → p-7dd960f1.entry.js.map} +0 -0
  34. /package/dist/post-components/{p-d2e9b37c.js.map → p-87bf3416.js.map} +0 -0
@@ -1,2 +1,2 @@
1
- function r(r,o,n){if(!o.includes(r))throw new Error(n)}function o(r,o,n){const t=o==="array";const a=Array.isArray(r);if(t||a){if(a!==t)throw new Error(n)}else{if(typeof r!==o)throw new Error(n)}}const n="1.3.3";export{r as a,o as c,n as v};
2
- //# sourceMappingURL=p-d2e9b37c.js.map
1
+ function r(r,o,n){if(!o.includes(r))throw new Error(n)}function o(r,o,n){const t=o==="array";const a=Array.isArray(r);if(t||a){if(a!==t)throw new Error(n)}else{if(typeof r!==o)throw new Error(n)}}const n="1.3.4";export{r as a,o as c,n as v};
2
+ //# sourceMappingURL=p-87bf3416.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,b as a}from"./p-0c286590.js";export{s as setNonce}from"./p-0c286590.js";const o=()=>{const a=import.meta.url;const o={};if(a!==""){o.resourcesUrl=new URL(".",a).href}return e(o)};o().then((e=>a([["p-72fc6cda",[[1,"post-collapsible",{collapsed:[4],headingLevel:[2,"heading-level"],collapseClasses:[32],collapseHeight:[32],collapsibleId:[32],hasHeader:[32],headingTag:[32],isOpen:[32],onAccordionButtonClick:[32],toggle:[64]}]]],["p-20d342a4",[[1,"post-icon",{animation:[1],base:[1],flipH:[4,"flip-h"],flipV:[4,"flip-v"],name:[1],rotate:[2],scale:[2],pathForceCDN:[32],svgOutput:[32]}]]]],e)));
1
+ import{p as e,b as o}from"./p-0c286590.js";export{s as setNonce}from"./p-0c286590.js";const l=()=>{const s=import.meta.url;const o={};if(s!==""){o.resourcesUrl=new URL(".",s).href}return e(o)};l().then((e=>o([["p-7dd960f1",[[1,"post-collapsible",{collapsed:[4],headingLevel:[2,"heading-level"],collapseClasses:[32],collapseHeight:[32],collapsibleId:[32],hasHeader:[32],headingTag:[32],isOpen:[32],onAccordionButtonClick:[32],toggle:[64]}]]],["p-6e225c16",[[1,"post-icon",{animation:[1],base:[1],flipH:[4,"flip-h"],flipV:[4,"flip-v"],name:[1],rotate:[2],scale:[2],pathForceCDN:[32],svgStyles:[32],svgOutput:[32]}]]]],e)));
2
2
  //# sourceMappingURL=post-components.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","options","bootstrapLazy","collapsed","headingLevel","collapseClasses","collapseHeight","collapsibleId","hasHeader","headingTag","isOpen","onAccordionButtonClick","toggle","animation","base","flipH","flipV","name","rotate","scale","pathForceCDN","svgOutput"],"sources":["../../node_modules/.pnpm/@stencil+core@3.2.0/node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v3.2.0 | MIT Licensed | https://stenciljs.com\n */\nimport { BUILD, NAMESPACE } from '@stencil/core/internal/app-data';\nimport { consoleDevInfo, plt, win, doc, promiseResolve, H } from '@stencil/core';\n/**\n * Helper method for querying a `meta` tag that contains a nonce value\n * out of a DOM's head.\n *\n * @param doc The DOM containing the `head` to query against\n * @returns The content of the meta tag representing the nonce value, or `undefined` if no tag\n * exists or the tag has no content.\n */\nfunction queryNonceMetaTagContent(doc) {\n var _a, _b, _c;\n return (_c = (_b = (_a = doc.head) === null || _a === void 0 ? void 0 : _a.querySelector('meta[name=\"csp-nonce\"]')) === null || _b === void 0 ? void 0 : _b.getAttribute('content')) !== null && _c !== void 0 ? _c : undefined;\n}\n// TODO(STENCIL-661): Remove code related to the dynamic import shim\nconst getDynamicImportFunction = (namespace) => `__sc_import_${namespace.replace(/\\s|-/g, '_')}`;\nconst patchBrowser = () => {\n // NOTE!! This fn cannot use async/await!\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo('Running in development mode.');\n }\n // TODO(STENCIL-659): Remove code implementing the CSS variable shim\n if (BUILD.cssVarShim) {\n // shim css vars\n // TODO(STENCIL-659): Remove code implementing the CSS variable shim\n plt.$cssShim$ = win.__cssshim;\n }\n if (BUILD.cloneNodeFix) {\n // opted-in to polyfill cloneNode() for slot polyfilled components\n patchCloneNodeFix(H.prototype);\n }\n if (BUILD.profile && !performance.mark) {\n // not all browsers support performance.mark/measure (Safari 10)\n // because the mark/measure APIs are designed to write entries to a buffer in the browser that does not exist,\n // simply stub the implementations out.\n // TODO(STENCIL-323): Remove this patch when support for older browsers is removed (breaking)\n // @ts-ignore\n performance.mark = performance.measure = () => {\n /*noop*/\n };\n performance.getEntriesByName = () => [];\n }\n // @ts-ignore\n const scriptElm = \n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n BUILD.scriptDataOpts || BUILD.safari10 || BUILD.dynamicImportShim\n ? Array.from(doc.querySelectorAll('script')).find((s) => new RegExp(`\\/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) ||\n s.getAttribute('data-stencil-namespace') === NAMESPACE)\n : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})['data-opts'] || {} : {};\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n if (BUILD.safari10 && 'onbeforeload' in scriptElm && !history.scrollRestoration /* IS_ESM_BUILD */) {\n // Safari < v11 support: This IF is true if it's Safari below v11.\n // This fn cannot use async/await since Safari didn't support it until v11,\n // however, Safari 10 did support modules. Safari 10 also didn't support \"nomodule\",\n // so both the ESM file and nomodule file would get downloaded. Only Safari\n // has 'onbeforeload' in the script, and \"history.scrollRestoration\" was added\n // to Safari in v11. Return a noop then() so the async/await ESM code doesn't continue.\n // IS_ESM_BUILD is replaced at build time so this check doesn't happen in systemjs builds.\n return {\n then() {\n /* promise noop */\n },\n };\n }\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n if (!BUILD.safari10 && importMeta !== '') {\n opts.resourcesUrl = new URL('.', importMeta).href;\n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n }\n else if (BUILD.dynamicImportShim || BUILD.safari10) {\n opts.resourcesUrl = new URL('.', new URL(scriptElm.getAttribute('data-resources-url') || scriptElm.src, win.location.href)).href;\n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n if (BUILD.dynamicImportShim) {\n patchDynamicImport(opts.resourcesUrl, scriptElm);\n }\n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n if (BUILD.dynamicImportShim && !win.customElements) {\n // module support, but no custom elements support (Old Edge)\n // @ts-ignore\n return import(/* webpackChunkName: \"polyfills-dom\" */ './dom.js').then(() => opts);\n }\n }\n return promiseResolve(opts);\n};\n// TODO(STENCIL-661): Remove code related to the dynamic import shim\nconst patchDynamicImport = (base, orgScriptElm) => {\n const importFunctionName = getDynamicImportFunction(NAMESPACE);\n try {\n // test if this browser supports dynamic imports\n // There is a caching issue in V8, that breaks using import() in Function\n // By generating a random string, we can workaround it\n // Check https://bugs.chromium.org/p/chromium/issues/detail?id=990810 for more info\n win[importFunctionName] = new Function('w', `return import(w);//${Math.random()}`);\n }\n catch (e) {\n // this shim is specifically for browsers that do support \"esm\" imports\n // however, they do NOT support \"dynamic\" imports\n // basically this code is for old Edge, v18 and below\n const moduleMap = new Map();\n win[importFunctionName] = (src) => {\n var _a;\n const url = new URL(src, base).href;\n let mod = moduleMap.get(url);\n if (!mod) {\n const script = doc.createElement('script');\n script.type = 'module';\n script.crossOrigin = orgScriptElm.crossOrigin;\n script.src = URL.createObjectURL(new Blob([`import * as m from '${url}'; window.${importFunctionName}.m = m;`], {\n type: 'application/javascript',\n }));\n // Apply CSP nonce to the script tag if it exists\n const nonce = (_a = plt.$nonce$) !== null && _a !== void 0 ? _a : queryNonceMetaTagContent(doc);\n if (nonce != null) {\n script.setAttribute('nonce', nonce);\n }\n mod = new Promise((resolve) => {\n script.onload = () => {\n resolve(win[importFunctionName].m);\n script.remove();\n };\n });\n moduleMap.set(url, mod);\n doc.head.appendChild(script);\n }\n return mod;\n };\n }\n};\nconst patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function (deep) {\n if (this.nodeName === 'TEMPLATE') {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n // Node.ATTRIBUTE_NODE === 2, and checking because IE11\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport { patchBrowser };\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(options => {\n globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"sFAmBA,MAAMA,EAAe,KAkCjB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAiB3E,GAAuBF,IAAe,GAAI,CACtCE,EAAKC,aAAe,IAAIC,IAAI,IAAKJ,GAAYK,IAGrD,CAcI,OAAOC,EAAeJ,EAAK,ECrF/BH,IAAeQ,MAAKC,GAEXC,EAAc,sCAAsC,CAACC,UAAA,IAAAC,aAAA,oBAAAC,gBAAA,KAAAC,eAAA,KAAAC,cAAA,KAAAC,UAAA,KAAAC,WAAA,KAAAC,OAAA,KAAAC,uBAAA,KAAAC,OAAA,wCAAAC,UAAA,IAAAC,KAAA,IAAAC,MAAA,aAAAC,MAAA,aAAAC,KAAA,IAAAC,OAAA,IAAAC,MAAA,IAAAC,aAAA,KAAAC,UAAA,UAAApB"}
1
+ {"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","options","bootstrapLazy","collapsed","headingLevel","collapseClasses","collapseHeight","collapsibleId","hasHeader","headingTag","isOpen","onAccordionButtonClick","toggle","animation","base","flipH","flipV","name","rotate","scale","pathForceCDN","svgStyles","svgOutput"],"sources":["../../node_modules/.pnpm/@stencil+core@3.2.0/node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v3.2.0 | MIT Licensed | https://stenciljs.com\n */\nimport { BUILD, NAMESPACE } from '@stencil/core/internal/app-data';\nimport { consoleDevInfo, plt, win, doc, promiseResolve, H } from '@stencil/core';\n/**\n * Helper method for querying a `meta` tag that contains a nonce value\n * out of a DOM's head.\n *\n * @param doc The DOM containing the `head` to query against\n * @returns The content of the meta tag representing the nonce value, or `undefined` if no tag\n * exists or the tag has no content.\n */\nfunction queryNonceMetaTagContent(doc) {\n var _a, _b, _c;\n return (_c = (_b = (_a = doc.head) === null || _a === void 0 ? void 0 : _a.querySelector('meta[name=\"csp-nonce\"]')) === null || _b === void 0 ? void 0 : _b.getAttribute('content')) !== null && _c !== void 0 ? _c : undefined;\n}\n// TODO(STENCIL-661): Remove code related to the dynamic import shim\nconst getDynamicImportFunction = (namespace) => `__sc_import_${namespace.replace(/\\s|-/g, '_')}`;\nconst patchBrowser = () => {\n // NOTE!! This fn cannot use async/await!\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo('Running in development mode.');\n }\n // TODO(STENCIL-659): Remove code implementing the CSS variable shim\n if (BUILD.cssVarShim) {\n // shim css vars\n // TODO(STENCIL-659): Remove code implementing the CSS variable shim\n plt.$cssShim$ = win.__cssshim;\n }\n if (BUILD.cloneNodeFix) {\n // opted-in to polyfill cloneNode() for slot polyfilled components\n patchCloneNodeFix(H.prototype);\n }\n if (BUILD.profile && !performance.mark) {\n // not all browsers support performance.mark/measure (Safari 10)\n // because the mark/measure APIs are designed to write entries to a buffer in the browser that does not exist,\n // simply stub the implementations out.\n // TODO(STENCIL-323): Remove this patch when support for older browsers is removed (breaking)\n // @ts-ignore\n performance.mark = performance.measure = () => {\n /*noop*/\n };\n performance.getEntriesByName = () => [];\n }\n // @ts-ignore\n const scriptElm = \n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n BUILD.scriptDataOpts || BUILD.safari10 || BUILD.dynamicImportShim\n ? Array.from(doc.querySelectorAll('script')).find((s) => new RegExp(`\\/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) ||\n s.getAttribute('data-stencil-namespace') === NAMESPACE)\n : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})['data-opts'] || {} : {};\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n if (BUILD.safari10 && 'onbeforeload' in scriptElm && !history.scrollRestoration /* IS_ESM_BUILD */) {\n // Safari < v11 support: This IF is true if it's Safari below v11.\n // This fn cannot use async/await since Safari didn't support it until v11,\n // however, Safari 10 did support modules. Safari 10 also didn't support \"nomodule\",\n // so both the ESM file and nomodule file would get downloaded. Only Safari\n // has 'onbeforeload' in the script, and \"history.scrollRestoration\" was added\n // to Safari in v11. Return a noop then() so the async/await ESM code doesn't continue.\n // IS_ESM_BUILD is replaced at build time so this check doesn't happen in systemjs builds.\n return {\n then() {\n /* promise noop */\n },\n };\n }\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n if (!BUILD.safari10 && importMeta !== '') {\n opts.resourcesUrl = new URL('.', importMeta).href;\n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.\n }\n else if (BUILD.dynamicImportShim || BUILD.safari10) {\n opts.resourcesUrl = new URL('.', new URL(scriptElm.getAttribute('data-resources-url') || scriptElm.src, win.location.href)).href;\n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n if (BUILD.dynamicImportShim) {\n patchDynamicImport(opts.resourcesUrl, scriptElm);\n }\n // TODO(STENCIL-661): Remove code related to the dynamic import shim\n if (BUILD.dynamicImportShim && !win.customElements) {\n // module support, but no custom elements support (Old Edge)\n // @ts-ignore\n return import(/* webpackChunkName: \"polyfills-dom\" */ './dom.js').then(() => opts);\n }\n }\n return promiseResolve(opts);\n};\n// TODO(STENCIL-661): Remove code related to the dynamic import shim\nconst patchDynamicImport = (base, orgScriptElm) => {\n const importFunctionName = getDynamicImportFunction(NAMESPACE);\n try {\n // test if this browser supports dynamic imports\n // There is a caching issue in V8, that breaks using import() in Function\n // By generating a random string, we can workaround it\n // Check https://bugs.chromium.org/p/chromium/issues/detail?id=990810 for more info\n win[importFunctionName] = new Function('w', `return import(w);//${Math.random()}`);\n }\n catch (e) {\n // this shim is specifically for browsers that do support \"esm\" imports\n // however, they do NOT support \"dynamic\" imports\n // basically this code is for old Edge, v18 and below\n const moduleMap = new Map();\n win[importFunctionName] = (src) => {\n var _a;\n const url = new URL(src, base).href;\n let mod = moduleMap.get(url);\n if (!mod) {\n const script = doc.createElement('script');\n script.type = 'module';\n script.crossOrigin = orgScriptElm.crossOrigin;\n script.src = URL.createObjectURL(new Blob([`import * as m from '${url}'; window.${importFunctionName}.m = m;`], {\n type: 'application/javascript',\n }));\n // Apply CSP nonce to the script tag if it exists\n const nonce = (_a = plt.$nonce$) !== null && _a !== void 0 ? _a : queryNonceMetaTagContent(doc);\n if (nonce != null) {\n script.setAttribute('nonce', nonce);\n }\n mod = new Promise((resolve) => {\n script.onload = () => {\n resolve(win[importFunctionName].m);\n script.remove();\n };\n });\n moduleMap.set(url, mod);\n doc.head.appendChild(script);\n }\n return mod;\n };\n }\n};\nconst patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function (deep) {\n if (this.nodeName === 'TEMPLATE') {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n // Node.ATTRIBUTE_NODE === 2, and checking because IE11\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport { patchBrowser };\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(options => {\n globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"sFAmBA,MAAMA,EAAe,KAkCjB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAiB3E,GAAuBF,IAAe,GAAI,CACtCE,EAAKC,aAAe,IAAIC,IAAI,IAAKJ,GAAYK,IAGrD,CAcI,OAAOC,EAAeJ,EAAK,ECrF/BH,IAAeQ,MAAKC,GAEXC,EAAc,sCAAsC,CAACC,UAAA,IAAAC,aAAA,oBAAAC,gBAAA,KAAAC,eAAA,KAAAC,cAAA,KAAAC,UAAA,KAAAC,WAAA,KAAAC,OAAA,KAAAC,uBAAA,KAAAC,OAAA,wCAAAC,UAAA,IAAAC,KAAA,IAAAC,MAAA,aAAAC,MAAA,aAAAC,KAAA,IAAAC,OAAA,IAAAC,MAAA,IAAAC,aAAA,KAAAC,UAAA,KAAAC,UAAA,UAAArB"}
@@ -1,3 +1,5 @@
1
+ declare const ANIMATION_NAMES: readonly ["cylon", "cylon-vertical", "spin", "spin-reverse", "fade", "throb"];
2
+ type Animation = (typeof ANIMATION_NAMES)[number];
1
3
  /**
2
4
  * @class PostIcon - representing a stencil component
3
5
  */
@@ -5,17 +7,20 @@ export declare class PostIcon {
5
7
  private path;
6
8
  private loadedPath;
7
9
  private svgSource;
10
+ private svgElement;
11
+ host: HTMLPostIconElement;
8
12
  pathForceCDN: boolean;
13
+ svgStyles: string;
9
14
  svgOutput: string;
10
15
  /**
11
- * The name of the animation (`cylon`, `cylon-vertical`, `spin`, `spin-reverse`, `fade`, `throb`).
16
+ * The name of the animation.
12
17
  */
13
- readonly animation?: string;
14
- validateAnimation(newValue?: string): void;
18
+ readonly animation?: Animation | null;
19
+ validateAnimation(newValue?: "cylon" | "cylon-vertical" | "spin" | "spin-reverse" | "fade" | "throb"): void;
15
20
  /**
16
- * The base path, where the icons are located (must be a public url).
21
+ * The base path, where the icons are located (must be a public url).<br/>Leave this field empty to use the default cdn url.
17
22
  */
18
- readonly base?: string;
23
+ readonly base?: string | null;
19
24
  validateBase(newValue?: string): void;
20
25
  /**
21
26
  * When set to `true`, the icon will be flipped horizontally.
@@ -33,20 +38,22 @@ export declare class PostIcon {
33
38
  readonly name: string;
34
39
  validateName(newValue?: string): void;
35
40
  /**
36
- * The `number` of degree for the css `rotate` transformation.
41
+ * The number of degree for the css rotate transformation.
37
42
  */
38
- readonly rotate?: number;
43
+ readonly rotate?: number | null;
39
44
  validateRotate(newValue?: number): void;
40
45
  /**
41
- * The `number` for the css `scale` transformation.
46
+ * The number for the css scale transformation.
42
47
  */
43
- readonly scale?: number;
48
+ readonly scale?: number | null;
44
49
  validateScale(newValue?: number): void;
45
50
  componentWillLoad(): void;
46
51
  componentWillRender(): void;
47
52
  private setPath;
48
53
  private getPath;
49
54
  private fetchIcon;
55
+ private createIconFromStorage;
50
56
  private createIcon;
51
57
  render(): any;
52
58
  }
59
+ export {};
@@ -25,13 +25,13 @@ export namespace Components {
25
25
  */
26
26
  interface PostIcon {
27
27
  /**
28
- * The name of the animation (`cylon`, `cylon-vertical`, `spin`, `spin-reverse`, `fade`, `throb`).
28
+ * The name of the animation.
29
29
  */
30
- "animation"?: string;
30
+ "animation"?: Animation | null;
31
31
  /**
32
- * The base path, where the icons are located (must be a public url).
32
+ * The base path, where the icons are located (must be a public url).<br/>Leave this field empty to use the default cdn url.
33
33
  */
34
- "base"?: string;
34
+ "base"?: string | null;
35
35
  /**
36
36
  * When set to `true`, the icon will be flipped horizontally.
37
37
  */
@@ -45,13 +45,13 @@ export namespace Components {
45
45
  */
46
46
  "name": string;
47
47
  /**
48
- * The `number` of degree for the css `rotate` transformation.
48
+ * The number of degree for the css rotate transformation.
49
49
  */
50
- "rotate"?: number;
50
+ "rotate"?: number | null;
51
51
  /**
52
- * The `number` for the css `scale` transformation.
52
+ * The number for the css scale transformation.
53
53
  */
54
- "scale"?: number;
54
+ "scale"?: number | null;
55
55
  }
56
56
  }
57
57
  declare global {
@@ -91,13 +91,13 @@ declare namespace LocalJSX {
91
91
  */
92
92
  interface PostIcon {
93
93
  /**
94
- * The name of the animation (`cylon`, `cylon-vertical`, `spin`, `spin-reverse`, `fade`, `throb`).
94
+ * The name of the animation.
95
95
  */
96
- "animation"?: string;
96
+ "animation"?: Animation | null;
97
97
  /**
98
- * The base path, where the icons are located (must be a public url).
98
+ * The base path, where the icons are located (must be a public url).<br/>Leave this field empty to use the default cdn url.
99
99
  */
100
- "base"?: string;
100
+ "base"?: string | null;
101
101
  /**
102
102
  * When set to `true`, the icon will be flipped horizontally.
103
103
  */
@@ -109,15 +109,15 @@ declare namespace LocalJSX {
109
109
  /**
110
110
  * The name/id of the icon (e.g. 1000, 1001, ...).
111
111
  */
112
- "name"?: string;
112
+ "name": string;
113
113
  /**
114
- * The `number` of degree for the css `rotate` transformation.
114
+ * The number of degree for the css rotate transformation.
115
115
  */
116
- "rotate"?: number;
116
+ "rotate"?: number | null;
117
117
  /**
118
- * The `number` for the css `scale` transformation.
118
+ * The number for the css scale transformation.
119
119
  */
120
- "scale"?: number;
120
+ "scale"?: number | null;
121
121
  }
122
122
  interface IntrinsicElements {
123
123
  "post-collapsible": PostCollapsible;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swisspost/design-system-components",
3
- "version": "1.3.3",
3
+ "version": "1.3.4",
4
4
  "description": "A collection of web components built with Stencil JS for the Swiss Post Design System.",
5
5
  "license": "Apache-2.0",
6
6
  "main": "dist/index.cjs.js",
@@ -32,21 +32,21 @@
32
32
  "@percy/cypress": "3.1.2",
33
33
  "@popperjs/core": "2.11.7",
34
34
  "@stencil-community/eslint-plugin": "^0.5.0",
35
- "@stencil/react-output-target": "0.4.0",
35
+ "@stencil/react-output-target": "0.5.0",
36
36
  "@stencil/sass": "3.0.0",
37
37
  "@swisspost/design-system-styles": "6.1.0",
38
38
  "@types/jest": "27.5.2",
39
- "@typescript-eslint/eslint-plugin": "5.56.0",
40
- "@typescript-eslint/parser": "5.56.0",
39
+ "@typescript-eslint/eslint-plugin": "5.57.1",
40
+ "@typescript-eslint/parser": "5.57.1",
41
41
  "bootstrap": "5.2.3",
42
- "cypress": "12.8.1",
42
+ "cypress": "12.9.0",
43
43
  "cypress-storybook": "0.5.1",
44
- "eslint": "8.36.0",
44
+ "eslint": "8.37.0",
45
45
  "eslint-plugin-react": "7.32.2",
46
46
  "jest": "27.5.1",
47
47
  "jest-cli": "27.5.1",
48
48
  "npm-run-all": "4.1.5",
49
- "puppeteer": "19.8.0",
49
+ "puppeteer": "19.8.3",
50
50
  "sass": "1.60.0",
51
51
  "typescript": "4.9.5"
52
52
  },
@@ -1,2 +0,0 @@
1
- import{r as i,h as t,H as n}from"./p-0c286590.js";import{c as s,a as e,v as o}from"./p-d2e9b37c.js";const a=[undefined,null,""];function r(i){return(...t)=>{const n=t[0];if(!a.some((i=>i===n)))i(...t)}}function l(i,t){if(a.some((t=>t===i))){throw new Error(t)}}const h=r(e);const c=r(s);const m=":host{display:inline-block;width:1em;vertical-align:-0.15em}svg{display:block;width:100%;fill:currentColor}:host([flip-h]) svg{scale:-1 1}:host([flip-v]) svg{scale:1 -1}:host([flip-h][flip-v]) svg{scale:-1}:host([animation]) svg{transform-origin:center}:host([animation=cylon]) svg{animation:icon-animation-cylon 0.75s ease-in-out infinite alternate}:host([animation=cylon-vertical]) svg{animation:icon-animation-cylon-vertical 0.75s ease-in-out infinite alternate}:host([animation=spin]) svg{animation:icon-animation-spin 2s linear infinite normal}:host([animation=spin-reverse]) svg{animation:icon-animation-spin 2s linear infinite reverse}:host([animation=fade]) svg{animation:icon-animation-fade 0.75s ease-in-out infinite alternate}:host([animation=throb]) svg{animation:icon-animation-throb 0.75s ease-in-out infinite alternate}@keyframes icon-animation-cylon{from{transform:translateX(-25%)}to{transform:translateX(25%)}}@keyframes icon-animation-cylon-vertical{from{transform:translateY(25%)}to{transform:translateY(-25%)}}@keyframes icon-animation-fade{from{opacity:0.1}to{opacity:1}}@keyframes icon-animation-spin{from{transform:rotate(0deg)}to{transform:rotate(359deg)}}@keyframes icon-animation-throb{from{opacity:0.5;transform:scale(0.5)}to{opacity:1;transform:scale(1)}}";const d="https://unpkg.com/@swisspost/design-system-icons/public/post-icons";const f=["cylon","cylon-vertical","spin","spin-reverse","fade","throb"];const p=class{constructor(t){i(this,t);this.svgSource='<svg viewBox="0 0 16 16"></svg>';this.pathForceCDN=false;this.svgOutput=undefined;this.animation=undefined;this.base=undefined;this.flipH=undefined;this.flipV=undefined;this.name=undefined;this.rotate=undefined;this.scale=undefined}validateAnimation(i=this.animation){if(i!==undefined)h(i,f,`The post-icon "animation" prop requires one of the following values: ${f.join(", ")}.`)}validateBase(i=this.base){c(i,"string",'The post-icon "base" prop should be a string.')}validateFlipH(i=this.flipH){c(i,"boolean",'The post-icon "flipH" prop should be a boolean.')}validateFlipV(i=this.flipV){c(i,"boolean",'The post-icon "flipV" prop should be a boolean.')}validateName(i=this.name){l(i,'The post-icon "name" prop is required!.');s(i,"string",'The post-icon "name" prop should be a string.')}validateRotate(i=this.rotate){c(i,"number",'The post-icon "rotate" prop should be a number.')}validateScale(i=this.scale){c(i,"number",'The post-icon "scale" prop should be a number.')}componentWillLoad(){this.validateBase();this.validateName();this.validateFlipH();this.validateFlipV();this.validateScale();this.validateRotate();this.validateAnimation()}componentWillRender(){this.setPath();if(this.name&&this.path!==this.loadedPath){this.loadedPath=this.path;this.fetchIcon().then((i=>{if(i)this.createIcon()})).catch((i=>{console.error(i)}))}}setPath(){var i;let t;const n=document.head.querySelector('meta[name="design-system-settings"][data-post-icon-base]');if(this.base){t=this.base}else if(n){t=n.getAttribute("data-post-icon-base")}else{t=d}this.path=this.getPath(this.pathForceCDN?d:t);this.svgSource=(i=window.localStorage.getItem(`post-icon-${this.name}`))!==null&&i!==void 0?i:this.svgSource;this.pathForceCDN=false}getPath(i){return new URL([...i.split("/"),`${this.name}.svg#icon`].join("/"),window.location.origin).toString()}fetchIcon(){return new Promise(((i,t)=>{fetch(this.path).then((i=>i.text())).then((t=>{const n=t.match(/^<svg\b([\s\S]*)><\/svg>/);if(n!==null){this.svgSource=n[0];window.localStorage.setItem(`post-icon-${this.name}`,this.svgSource);i(true)}else if(this.path!==this.getPath(d)){console.warn(`Warning in <post-icon/>: The path "${this.path}" seems to be no svg-only content. We'll gonna try to load the icon from the cdn.`);this.pathForceCDN=true;i(false)}})).catch(t)}))}createIcon(){const i=Object.entries({scale:this.scale&&!isNaN(Number(this.scale))?`${this.scale}`:null,rotate:this.rotate&&!isNaN(Number(this.rotate))?`${this.rotate}deg`:null}).filter((([i,t])=>t!==null)).map((([i,t])=>`${i}: ${t}`)).join(";");const t=document.createElement("div");t.innerHTML=this.svgSource;const n=t.querySelector("svg");n.setAttribute("style",i);this.svgOutput=t.innerHTML}render(){return t(n,{"data-version":o},t("div",{innerHTML:this.svgOutput}))}static get watchers(){return{animation:["validateAnimation"],base:["validateBase"],flipH:["validateFlipH"],flipV:["validateFlipV"],name:["validateName"],rotate:["validateRotate"],scale:["validateScale"]}}};p.style=m;export{p as post_icon};
2
- //# sourceMappingURL=p-20d342a4.entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["EMPTY_VALUES","undefined","emptyOr","check","args","value","some","v","checkNonEmpty","error","Error","checkEmptyOrOneOf","checkOneOf","checkEmptyOrType","checkType","postIconCss","CDN_URL","ANIMATION_KEYS","PostIcon","this","svgSource","validateAnimation","newValue","animation","join","validateBase","base","validateFlipH","flipH","validateFlipV","flipV","validateName","name","validateRotate","rotate","validateScale","scale","componentWillLoad","componentWillRender","setPath","path","loadedPath","fetchIcon","then","successfullyLoaded","createIcon","catch","console","basePath","metaBase","document","head","querySelector","getAttribute","getPath","pathForceCDN","_a","window","localStorage","getItem","URL","split","location","origin","toString","Promise","resolve","reject","fetch","response","text","textResponse","match","setItem","warn","svgStyles","Object","entries","isNaN","Number","filter","_key","map","key","helperElement","createElement","innerHTML","svgElement","setAttribute","svgOutput","render","h","Host","version"],"sources":["./src/utils/property-checkers/constants.ts","./src/utils/property-checkers/empty-or.ts","./src/utils/property-checkers/check-non-empty.ts","./src/utils/property-checkers/index.ts","./src/components/post-icon/post-icon.scss?tag=post-icon&encapsulation=shadow","./src/components/post-icon/post-icon.tsx"],"sourcesContent":["export const EMPTY_VALUES = [undefined, null, ''];\n","import { EMPTY_VALUES } from './constants';\n\nexport function emptyOr<T extends unknown[]>(check: (...args: T) => void) {\n return (...args: T) => {\n const value = args[0];\n if (!EMPTY_VALUES.some(v => v === value)) check(...args);\n };\n}\n","import { EMPTY_VALUES } from './constants';\n\nexport function checkNonEmpty(value: unknown, error: string) {\n if (EMPTY_VALUES.some(v => v === value)) {\n throw new Error(error);\n }\n}\n","import { emptyOr } from './empty-or';\nimport { checkOneOf } from './check-one-of';\nimport { checkType } from './check-type';\n\nexport const checkEmptyOrOneOf = emptyOr(checkOneOf);\nexport const checkEmptyOrType = emptyOr(checkType);\n\nexport * from './check-non-empty';\nexport * from './check-one-of';\nexport * from './check-type';\n","@use 'sass:map';\n\n$post-icon-animations: (\n 'cylon': icon-animation-cylon .75s ease-in-out infinite alternate,\n 'cylon-vertical': icon-animation-cylon-vertical .75s ease-in-out infinite alternate,\n 'spin': icon-animation-spin 2s linear infinite normal,\n 'spin-reverse': icon-animation-spin 2s linear infinite reverse,\n 'fade': icon-animation-fade .75s ease-in-out infinite alternate,\n 'throb': icon-animation-throb .75s ease-in-out infinite alternate\n);\n\n:host {\n display: inline-block;\n width: 1em;\n vertical-align: -0.15em;\n}\n\nsvg {\n display: block;\n width: 100%;\n fill: currentColor;\n}\n\n// flip\n\n:host([flip-h]) {\n svg { scale: -1 1; }\n}\n\n:host([flip-v]) {\n svg { scale: 1 -1; }\n}\n\n:host([flip-h][flip-v]) {\n svg { scale: -1; }\n}\n\n// scale\n// done with inline styling\n\n// rotate\n// done with inline styling\n\n// animation\n\n:host([animation]) {\n svg {\n transform-origin: center;\n }\n}\n\n@each $key, $value in $post-icon-animations {\n :host([animation=\"#{$key}\"]) {\n svg {\n animation: $value;\n }\n }\n}\n\n@keyframes icon-animation-cylon {\n from { transform: translateX(-25%) }\n to { transform: translateX(25%) }\n}\n\n@keyframes icon-animation-cylon-vertical {\n from { transform: translateY(25%); }\n to { transform: translateY(-25%); }\n}\n\n@keyframes icon-animation-fade {\n from { opacity: .1; }\n to { opacity: 1; }\n}\n\n@keyframes icon-animation-spin {\n from { transform: rotate(0deg); }\n to { transform: rotate(359deg); }\n}\n\n@keyframes icon-animation-throb {\n from {\n opacity: .5;\n transform: scale(0.5);\n }\n to {\n opacity: 1;\n transform: scale(1);\n }\n}\n","import { Component, Host, h, Prop, State, Watch } from '@stencil/core';\nimport { checkNonEmpty, checkType, checkEmptyOrType, checkEmptyOrOneOf } from '../../utils';\nimport { version } from '../../../package.json';\n\nconst CDN_URL = 'https://unpkg.com/@swisspost/design-system-icons/public/post-icons';\nconst ANIMATION_KEYS = ['cylon', 'cylon-vertical', 'spin', 'spin-reverse', 'fade', 'throb'];\n\n/**\n * @class PostIcon - representing a stencil component\n */\n@Component({\n tag: 'post-icon',\n styleUrl: 'post-icon.scss',\n shadow: true,\n})\nexport class PostIcon {\n private path: string;\n private loadedPath: string;\n private svgSource = '<svg viewBox=\"0 0 16 16\"></svg>';\n\n @State() pathForceCDN = false;\n @State() svgOutput: string;\n\n /**\n * The name of the animation (`cylon`, `cylon-vertical`, `spin`, `spin-reverse`, `fade`, `throb`).\n */\n @Prop() readonly animation?: string;\n\n @Watch('animation')\n validateAnimation(newValue = this.animation) {\n if (newValue !== undefined)\n checkEmptyOrOneOf(\n newValue,\n ANIMATION_KEYS,\n `The post-icon \"animation\" prop requires one of the following values: ${ANIMATION_KEYS.join(\n ', ',\n )}.`,\n );\n }\n\n /**\n * The base path, where the icons are located (must be a public url).\n */\n @Prop() readonly base?: string;\n\n @Watch('base')\n validateBase(newValue = this.base) {\n checkEmptyOrType(newValue, 'string', 'The post-icon \"base\" prop should be a string.');\n }\n\n /**\n * When set to `true`, the icon will be flipped horizontally.\n */\n @Prop() readonly flipH?: boolean;\n\n @Watch('flipH')\n validateFlipH(newValue = this.flipH) {\n checkEmptyOrType(newValue, 'boolean', 'The post-icon \"flipH\" prop should be a boolean.');\n }\n\n /**\n * When set to `true`, the icon will be flipped vertically.\n */\n @Prop() readonly flipV?: boolean;\n\n @Watch('flipV')\n validateFlipV(newValue = this.flipV) {\n checkEmptyOrType(newValue, 'boolean', 'The post-icon \"flipV\" prop should be a boolean.');\n }\n\n /**\n * The name/id of the icon (e.g. 1000, 1001, ...).\n */\n @Prop() readonly name: string;\n\n @Watch('name')\n validateName(newValue = this.name) {\n checkNonEmpty(newValue, 'The post-icon \"name\" prop is required!.');\n checkType(newValue, 'string', 'The post-icon \"name\" prop should be a string.');\n }\n\n /**\n * The `number` of degree for the css `rotate` transformation.\n */\n @Prop() readonly rotate?: number;\n\n @Watch('rotate')\n validateRotate(newValue = this.rotate) {\n checkEmptyOrType(newValue, 'number', 'The post-icon \"rotate\" prop should be a number.');\n }\n\n /**\n * The `number` for the css `scale` transformation.\n */\n @Prop() readonly scale?: number;\n\n @Watch('scale')\n validateScale(newValue = this.scale) {\n checkEmptyOrType(newValue, 'number', 'The post-icon \"scale\" prop should be a number.');\n }\n\n componentWillLoad() {\n this.validateBase();\n this.validateName();\n this.validateFlipH();\n this.validateFlipV();\n this.validateScale();\n this.validateRotate();\n this.validateAnimation();\n }\n\n componentWillRender() {\n // create path dependant on the props\n this.setPath();\n\n // fetch icon if the prop \"name\" is defined and\n // the path has not allready been loaded\n if (this.name && this.path !== this.loadedPath) {\n this.loadedPath = this.path;\n\n this.fetchIcon()\n .then(successfullyLoaded => {\n // create icon only if an svg has been loaded successfully\n if (successfullyLoaded) this.createIcon();\n })\n .catch(error => {\n console.error(error);\n });\n }\n }\n\n private setPath() {\n // Construct icon path from different possible sources\n let basePath: string;\n const metaBase = document.head.querySelector(\n 'meta[name=\"design-system-settings\"][data-post-icon-base]',\n );\n\n if (this.base) {\n basePath = this.base;\n } else if (metaBase) {\n basePath = metaBase.getAttribute('data-post-icon-base');\n } else {\n basePath = CDN_URL;\n }\n\n // use \"basePath\" only if \"pathForceCDN\" state is \"false\"\n this.path = this.getPath(this.pathForceCDN ? CDN_URL : basePath);\n // try to get the \"svgSource\" from localStorage\n this.svgSource = window.localStorage.getItem(`post-icon-${this.name}`) ?? this.svgSource;\n // reset \"pathForceCDN\" after every try\n this.pathForceCDN = false;\n }\n\n private getPath(basePath: string) {\n return new URL(\n [...basePath.split('/'), `${this.name}.svg#icon`].join('/'),\n window.location.origin,\n ).toString();\n }\n\n private fetchIcon() {\n return new Promise((resolve, reject) => {\n fetch(this.path)\n .then(response => response.text())\n .then(textResponse => {\n // match \"svg\" out of \"textResponse\"\n const match = textResponse.match(/^<svg\\b([\\s\\S]*)><\\/svg>/);\n\n if (match !== null) {\n // set \"svgSource\" and return \"successfullyLoaded\" with true\n this.svgSource = match[0];\n window.localStorage.setItem(`post-icon-${this.name}`, this.svgSource);\n resolve(true);\n } else if (this.path !== this.getPath(CDN_URL)) {\n // if used \"path\" is not CDN path, and fetch has loaded something else than a \"svg\", try to reload it from the CDN\n console.warn(\n `Warning in <post-icon/>: The path \"${this.path}\" seems to be no svg-only content. We'll gonna try to load the icon from the cdn.`,\n );\n // trigger a component update, which will result in a refetch of the icon with the \"CDN_URL\"\n this.pathForceCDN = true;\n // return \"successfullyLoaded\" with false\n resolve(false);\n }\n })\n .catch(reject);\n });\n }\n\n private createIcon() {\n // create inline styles for some properties\n const svgStyles = Object.entries({\n scale: this.scale && !isNaN(Number(this.scale)) ? `${this.scale}` : null,\n rotate: this.rotate && !isNaN(Number(this.rotate)) ? `${this.rotate}deg` : null,\n })\n .filter(([_key, value]) => value !== null)\n .map(([key, value]) => `${key}: ${value}`)\n .join(';');\n\n // create svg in RAM and append the above styles, before defining the \"svgOutput\"\n const helperElement = document.createElement('div');\n helperElement.innerHTML = this.svgSource;\n const svgElement = helperElement.querySelector('svg');\n svgElement.setAttribute('style', svgStyles);\n\n this.svgOutput = helperElement.innerHTML;\n }\n\n render() {\n return (\n <Host data-version={version}>\n <div innerHTML={this.svgOutput} />\n </Host>\n );\n }\n}\n"],"mappings":"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"}