1 line
26 KiB
Plaintext
1 line
26 KiB
Plaintext
{"version":3,"sources":["webpack:///webpack/universalModuleDefinition","webpack:///webpack/bootstrap","webpack:///./projects/icons/src/clr-icons-api.ts","webpack:///./projects/icons/src/clr-icons-element.ts","webpack:///./projects/icons/src/utils/shape-template-observer.ts"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;QCVA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;;;;;;;AClFA;;;;GAIG;;;AAGH,oJAAwE;AAExE,IAAM,gBAAgB,GAAqB,EAAE,CAAC;AAE9C;IAAA;IA6GA,CAAC;IA1GC,sBAAW,2BAAQ;aAAnB;YACE,IAAI,CAAC,eAAe,CAAC,cAAc,EAAE;gBACnC,eAAe,CAAC,cAAc,GAAG,IAAI,eAAe,EAAE,CAAC;aACxD;YAED,OAAO,eAAe,CAAC,cAAc,CAAC;QACxC,CAAC;;;OAAA;IAEO,sCAAY,GAApB,UAAqB,IAAY;QAC/B,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;YACrB,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;SACpE;QAED,IAAI,IA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;IACJ,CAAC;IAEM,2CAAW,GAAlB,UAAmB,SAAiB,EAAE,QAAgB;QACpD,IAAI,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,EAAE;YAC7B,0CAA0C;YAC1C,0DAA0D;YAC1D,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,GAAG,CAAC,UAAC,qBAA6C;gBAC1E,qBAAqB,CAAC,QAAQ,CAAC,CAAC;YAClC,CAAC,CAAC,CAAC;SACJ;IACH,CAAC;IACH,4BAAC;AAAD,CAAC;AA3CY,sDAAqB","file":"clr-icons-element.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse {\n\t\tvar a = factory();\n\t\tfor(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];\n\t}\n})(this, function() {\nreturn "," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"./projects/icons/src/clr-icons-element.ts\");\n","/*\n * Copyright (c) 2016-2021 VMware, Inc. All Rights Reserved.\n * This software is released under MIT license.\n * The full license information can be found in LICENSE in the root directory of this project.\n */\n\nimport { IconAlias, IconShapeSources } from './interfaces/icon-interfaces';\nimport { ShapeTemplateObserver } from './utils/shape-template-observer';\n\nconst iconShapeSources: IconShapeSources = {};\n\nexport class ClarityIconsApi {\n private static singleInstance: ClarityIconsApi;\n\n static get instance(): ClarityIconsApi {\n if (!ClarityIconsApi.singleInstance) {\n ClarityIconsApi.singleInstance = new ClarityIconsApi();\n }\n\n return ClarityIconsApi.singleInstance;\n }\n\n private validateName(name: string): boolean {\n if (name.length === 0) {\n throw new Error('Shape name or alias must be a non-empty string!');\n }\n\n if (/\\s/.test(name)) {\n throw new Error('Shape name or alias must not contain any whitespace characters!');\n }\n\n return true;\n }\n\n private normalizeShapeName(shapeName: string) {\n return shapeName.toLowerCase();\n }\n\n private setIconTemplate(shapeName: string, shapeTemplate: string): void {\n const trimmedShapeTemplate = shapeTemplate.trim();\n\n if (this.validateName(shapeName)) {\n // Make sure the shapeName don't contain uppercase characters\n // when registering it\n shapeName = this.normalizeShapeName(shapeName);\n\n // if the shape name exists, delete it.\n if (iconShapeSources[shapeName]) {\n delete iconShapeSources[shapeName];\n }\n\n iconShapeSources[shapeName] = trimmedShapeTemplate;\n\n ShapeTemplateObserver.instance.emitChanges(shapeName, trimmedShapeTemplate);\n }\n }\n\n private setIconAliases(templates: IconShapeSources, shapeName: string, aliasNames: string[]): void {\n for (const aliasName of aliasNames) {\n if (this.validateName(aliasName)) {\n Object.defineProperty(templates, aliasName, {\n get: function () {\n return templates[shapeName];\n },\n enumerable: true,\n configurable: true,\n });\n }\n }\n }\n\n add(icons?: IconShapeSources): void {\n if (typeof icons !== 'object') {\n throw new Error(`The argument must be an object literal passed in the following pattern:\n { \"shape-name\": \"shape-template\" }`);\n }\n\n for (const shapeName in icons) {\n if (icons.hasOwnProperty(shapeName)) {\n this.setIconTemplate(shapeName, icons[shapeName]);\n }\n }\n }\n\n has(shapeName: string): boolean {\n return !!iconShapeSources[this.normalizeShapeName(shapeName)];\n }\n\n get(shapeName?: string): any {\n // if shapeName is not given, return all icon templates.\n if (!shapeName) {\n return iconShapeSources;\n }\n\n if (typeof shapeName !== 'string') {\n throw new TypeError('Only string argument is allowed in this method.');\n }\n\n return iconShapeSources[this.normalizeShapeName(shapeName)];\n }\n\n alias(aliases?: IconAlias): void {\n if (typeof aliases !== 'object') {\n throw new Error(`The argument must be an object literal passed in the following pattern:\n { \"shape-name\": [\"alias-name\", ...] }`);\n }\n\n for (const shapeName in aliases) {\n if (aliases.hasOwnProperty(shapeName)) {\n if (iconShapeSources.hasOwnProperty(shapeName)) {\n // set an alias to the icon if it exists in iconShapeSources.\n this.setIconAliases(iconShapeSources, shapeName, aliases[shapeName]);\n } else {\n throw new Error(\n `An icon \"${shapeName}\" you are trying to set aliases to doesn't exist in the Clarity Icons sets!`\n );\n }\n }\n }\n }\n}\n","/*\n * Copyright (c) 2016-2021 VMware, Inc. All Rights Reserved.\n * This software is released under MIT license.\n * The full license information can be found in LICENSE in the root directory of this project.\n */\nimport { ClarityIconsApi } from './clr-icons-api';\nimport { ShapeTemplateObserver } from './utils/shape-template-observer';\n\n/* CLR-ICON CUSTOM ELEMENT */\n\nlet clrIconId = 0;\nconst offScreenSpan = document.createElement('span');\noffScreenSpan.className = 'is-off-screen';\n\nlet parentConstructor = function (this: any) {\n // eslint-disable-next-line prefer-rest-params\n return HTMLElement.apply(this, arguments);\n};\nif (typeof Reflect === 'object') {\n parentConstructor = function () {\n // eslint-disable-next-line prefer-rest-params\n return (Reflect as any).construct(HTMLElement, arguments, this.constructor);\n };\n}\n\nexport function ClarityIconElement(this: any) {\n 'use strict';\n\n // eslint-disable-next-line prefer-rest-params\n const _instance = (parentConstructor as any).apply(this, arguments);\n\n _instance.clrIconUniqId = '_clr_icon_' + clrIconId;\n clrIconId++;\n\n return _instance;\n}\n\n(ClarityIconElement as any).observedAttributes = ['shape', 'size', 'title'];\n\nClarityIconElement.prototype = Object.create(HTMLElement.prototype, {\n constructor: { configurable: true, writable: true, value: ClarityIconElement },\n});\n\nClarityIconElement.prototype.constructor = ClarityIconElement;\n\nClarityIconElement.prototype._appendCustomTitle = function () {\n const cloneOffScreenSpan = offScreenSpan.cloneNode(false) as HTMLElement;\n cloneOffScreenSpan.id = this.clrIconUniqId;\n cloneOffScreenSpan.textContent = this.currentTitleAttrVal;\n this.appendChild(cloneOffScreenSpan);\n};\n\nClarityIconElement.prototype._setIconSize = function (size: string) {\n if (!Number(size) || Number(size) < 0) {\n this.style.width = null; // fallback to the original stylesheet value\n this.style.height = null; // fallback to the original stylesheet value\n } else {\n this.style.width = size + 'px';\n this.style.height = size + 'px';\n }\n};\n\nClarityIconElement.prototype._normalizeShape = function (value: string): string {\n return value.split(/\\s/)[0].toLowerCase();\n};\n\nClarityIconElement.prototype.connectedCallback = function () {\n // One thing to note here is that the attributeChangedCallback method is called for every attribute first\n // before this connectedCallback method called only once when the custom element is inserted into the DOM.\n // So we could check whether the attribute values really changed or not.\n // If not, we don't need to execute the same codes again.\n\n // We want to hide the custom element from screen readers but allow the svg/img content to still be read inline\n // Adding role=none allows the screen reader to skip the custom element as if it were a div or span.\n // https://www.scottohara.me/blog/2018/05/05/hidden-vs-none.html\n if (!this.getAttribute('role')) {\n this.setAttribute('role', 'none');\n }\n\n if (this.hasAttribute('size')) {\n const sizeAttrValue = this.getAttribute('size');\n\n if (this.currentSizeAttrVal !== sizeAttrValue) {\n this.currentSizeAttrVal = sizeAttrValue;\n this._setIconSize(sizeAttrValue);\n }\n }\n\n // Note: the size attribute is irrelevant from the shape template;\n // That's why the size checking placed before detecting changes in shape and title attributes.\n // This means even if the shape is not found, the injected shape will have the user-given size.\n\n if (this.hasAttribute('shape')) {\n const shapeAttrValue = this._normalizeShape(this.getAttribute('shape'));\n\n this._shapeTemplateSubscription = ShapeTemplateObserver.instance.subscribeTo(\n shapeAttrValue,\n (updatedTemplate: string) => {\n this._injectTemplate(updatedTemplate);\n }\n );\n\n this.currentShapeAttrVal = shapeAttrValue;\n\n if (ClarityIconsApi.instance.has(this.currentShapeAttrVal)) {\n const currentShapeTemplate = ClarityIconsApi.instance.get(this.currentShapeAttrVal);\n if (currentShapeTemplate === this.currentShapeTemplate) {\n return;\n } else {\n this.currentShapeTemplate = currentShapeTemplate;\n }\n } else {\n this._injectErrorTemplate();\n return;\n }\n }\n\n if (this.hasAttribute('title')) {\n const titleAttrValue = this.getAttribute('title');\n\n if (this.currentTitleAttrVal !== titleAttrValue) {\n this.currentTitleAttrVal = titleAttrValue;\n }\n\n if (!this.currentShapeAttrVal) {\n return;\n }\n }\n\n this._injectTemplate();\n};\n\nClarityIconElement.prototype.attributeChangedCallback = function (\n attributeName: string,\n _oldValue: string,\n newValue: string\n) {\n if (attributeName === 'size') {\n this._setIconSize(newValue);\n }\n\n // Note: the size attribute is irrelevant from the shape template;\n // That's why the size checking placed before detecting changes in shape and title attributes.\n // This means even if the shape is not found, the injected shape will have the user-given size.\n\n if (attributeName === 'shape') {\n this.currentShapeAttrVal = this._normalizeShape(newValue);\n\n // transfer change handler callback to new shape name\n if (this._shapeTemplateSubscription) {\n // remove the existing change handler callback on the old shape name\n this._shapeTemplateSubscription();\n // create a new subscription on the new shape name\n this._shapeTemplateSubscription = ShapeTemplateObserver.instance.subscribeTo(\n this.currentShapeAttrVal,\n (updatedTemplate: string) => {\n this._injectTemplate(updatedTemplate);\n }\n );\n }\n\n if (ClarityIconsApi.instance.has(this.currentShapeAttrVal)) {\n this.currentShapeTemplate = ClarityIconsApi.instance.get(this.currentShapeAttrVal);\n } else {\n this._injectErrorTemplate();\n return;\n }\n }\n if (attributeName === 'title') {\n this.currentTitleAttrVal = newValue;\n\n if (!this.currentShapeAttrVal) {\n return;\n }\n }\n\n this._injectTemplate();\n};\n\nClarityIconElement.prototype.disconnectedCallback = function () {\n // as the icon element is removed from the DOM,\n // remove its listener callback function as well.\n if (this._shapeTemplateSubscription) {\n this._shapeTemplateSubscription();\n }\n};\n\nClarityIconElement.prototype._setAriaLabelledBy = function () {\n const existingAriaLabelledBy: string = this.getAttribute('aria-labelledby');\n const svgElement: SVGElement = this.querySelector('svg');\n const elementToSet = svgElement ? svgElement : this;\n\n if (!existingAriaLabelledBy) {\n elementToSet.setAttribute('aria-labelledby', this.clrIconUniqId);\n } else if (existingAriaLabelledBy && existingAriaLabelledBy.indexOf(this.clrIconUniqId) < 0) {\n elementToSet.setAttribute('aria-labelledby', existingAriaLabelledBy + ' ' + this.clrIconUniqId);\n }\n};\n\nClarityIconElement.prototype._injectTemplate = function (shapeTemplate?: string) {\n // Accepting the argument, shapeTemplate, will help us to update the shape template\n // right before the injection.\n if (shapeTemplate && shapeTemplate !== this.currentShapeTemplate) {\n this.currentShapeTemplate = shapeTemplate;\n }\n\n this.innerHTML = this.currentShapeTemplate;\n\n if (this.currentTitleAttrVal) {\n this._setAriaLabelledBy();\n this._appendCustomTitle();\n }\n};\n\nClarityIconElement.prototype._injectErrorTemplate = function () {\n this.currentShapeTemplate = ClarityIconsApi.instance.get('error');\n this._injectTemplate();\n};\n","/**\n * Copyright (c) 2016-2021 VMware, Inc. All Rights Reserved.\n * This software is released under MIT license.\n * The full license information can be found in LICENSE in the root directory of this project.\n */\nimport { ShapeTemplateObservables } from '../interfaces/icon-interfaces';\n\nexport const changeHandlerCallbacks: ShapeTemplateObservables = {};\n\nexport class ShapeTemplateObserver {\n private static singleInstance: ShapeTemplateObserver;\n\n private callbacks: ShapeTemplateObservables = changeHandlerCallbacks;\n\n public static get instance(): ShapeTemplateObserver {\n if (!ShapeTemplateObserver.singleInstance) {\n ShapeTemplateObserver.singleInstance = new ShapeTemplateObserver();\n }\n\n return ShapeTemplateObserver.singleInstance;\n }\n\n public subscribeTo(shapeName: string, changeHandlerCallback: (arg0: string) => void) {\n if (!this.callbacks[shapeName]) {\n this.callbacks[shapeName] = [changeHandlerCallback];\n } else {\n if (this.callbacks[shapeName].indexOf(changeHandlerCallback) === -1) {\n this.callbacks[shapeName].push(changeHandlerCallback);\n }\n }\n\n // this returned function give users an ability to remove the subscription\n return () => {\n const removeAt = this.callbacks[shapeName].indexOf(changeHandlerCallback);\n this.callbacks[shapeName].splice(removeAt, 1);\n\n // if the array is empty, remove the property from the callbacks\n if (this.callbacks[shapeName].length === 0) {\n delete this.callbacks[shapeName];\n }\n };\n }\n\n public emitChanges(shapeName: string, template: string) {\n if (this.callbacks[shapeName]) {\n // this will emit changes to all observers\n // by calling their callback functions on template changes\n this.callbacks[shapeName].map((changeHandlerCallback: (arg0: string) => void) => {\n changeHandlerCallback(template);\n });\n }\n }\n}\n"],"sourceRoot":""} |