@spectrum-web-components/status-light 0.10.8 → 0.10.9

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spectrum-web-components/status-light",
3
- "version": "0.10.8",
3
+ "version": "0.10.9",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -44,7 +44,7 @@
44
44
  "lit-html"
45
45
  ],
46
46
  "dependencies": {
47
- "@spectrum-web-components/base": "^0.5.6",
47
+ "@spectrum-web-components/base": "^0.5.7",
48
48
  "tslib": "^2.0.0"
49
49
  },
50
50
  "devDependencies": {
@@ -55,5 +55,5 @@
55
55
  "sideEffects": [
56
56
  "./sp-*.js"
57
57
  ],
58
- "gitHead": "8f5ea3556e160b6e30815edb2414dc5a5999a925"
58
+ "gitHead": "275ee61b152ac3eed0cd1603d8eab2aec90876a0"
59
59
  }
@@ -1 +1 @@
1
- {"version":3,"file":"StatusLight.js","sourceRoot":"","sources":["StatusLight.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;;AAEF,OAAO,EAEH,IAAI,EAEJ,UAAU,EACV,eAAe,GAElB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,iDAAiD,CAAC;AAC3E,OAAO,iBAAiB,MAAM,uBAAuB,CAAC;AAEtD;;;;GAIG;AACH,MAAM,OAAO,WAAY,SAAQ,UAAU,CAAC,eAAe,CAAC;IAA5D;;QAKI;;WAEG;QAEI,aAAQ,GAAG,KAAK,CAAC;QAExB;;WAEG;QAEI,YAAO,GAaG,MAAM,CAAC;IAkB5B,CAAC;IA7CU,MAAM,KAAK,MAAM;QACpB,OAAO,CAAC,iBAAiB,CAAC,CAAC;IAC/B,CAAC;IA2BS,MAAM;QACZ,OAAO,IAAI,CAAA;;SAEV,CAAC;IACN,CAAC;IAES,OAAO,CAAC,OAAuB;QACrC,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACvB,IAAI,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE;YACzB,IAAI,IAAI,CAAC,QAAQ,EAAE;gBACf,IAAI,CAAC,YAAY,CAAC,eAAe,EAAE,MAAM,CAAC,CAAC;aAC9C;iBAAM;gBACH,IAAI,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC;aACzC;SACJ;IACL,CAAC;CACJ;AArCG;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;6CACnB;AAMxB;IADC,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4CAcJ","sourcesContent":["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport {\n CSSResultArray,\n html,\n PropertyValues,\n SizedMixin,\n SpectrumElement,\n TemplateResult,\n} from '@spectrum-web-components/base';\nimport { property } from '@spectrum-web-components/base/src/decorators.js';\nimport statusLightStyles from './status-light.css.js';\n\n/**\n * @element sp-status-light\n *\n * @slot - text label of the Status Light\n */\nexport class StatusLight extends SizedMixin(SpectrumElement) {\n public static get styles(): CSSResultArray {\n return [statusLightStyles];\n }\n\n /**\n * A status light in a disabled state shows that a status exists, but is not available in that circumstance. This can be used to maintain layout continuity and communicate that a status may become available later.\n */\n @property({ type: Boolean, reflect: true })\n public disabled = false;\n\n /**\n * The visual variant to apply to this status light.\n */\n @property({ reflect: true })\n public variant:\n | 'negative'\n | 'notice'\n | 'positive'\n | 'info'\n | 'neutral'\n | 'yellow'\n | 'fuchsia'\n | 'indigo'\n | 'seafoam'\n | 'chartreuse'\n | 'magenta'\n | 'celery'\n | 'purple' = 'info';\n\n protected render(): TemplateResult {\n return html`\n <slot></slot>\n `;\n }\n\n protected updated(changes: PropertyValues): void {\n super.updated(changes);\n if (changes.has('disabled')) {\n if (this.disabled) {\n this.setAttribute('aria-disabled', 'true');\n } else {\n this.removeAttribute('aria-disabled');\n }\n }\n }\n}\n"]}
1
+ {"version":3,"file":"StatusLight.js","sourceRoot":"","sources":["StatusLight.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;;AAEF,OAAO,EAEH,IAAI,EAEJ,UAAU,EACV,eAAe,GAElB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,iDAAiD,CAAC;AAC3E,OAAO,iBAAiB,MAAM,uBAAuB,CAAC;AAEtD;;;;GAIG;AACH,MAAM,OAAO,WAAY,SAAQ,UAAU,CAAC,eAAe,CAAC;IAA5D;;QAKI;;WAEG;QAEI,aAAQ,GAAG,KAAK,CAAC;QAExB;;WAEG;QAEI,YAAO,GAaG,MAAM,CAAC;IAkB5B,CAAC;IA7CU,MAAM,KAAc,MAAM;QAC7B,OAAO,CAAC,iBAAiB,CAAC,CAAC;IAC/B,CAAC;IA2BkB,MAAM;QACrB,OAAO,IAAI,CAAA;;SAEV,CAAC;IACN,CAAC;IAEkB,OAAO,CAAC,OAAuB;QAC9C,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACvB,IAAI,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE;YACzB,IAAI,IAAI,CAAC,QAAQ,EAAE;gBACf,IAAI,CAAC,YAAY,CAAC,eAAe,EAAE,MAAM,CAAC,CAAC;aAC9C;iBAAM;gBACH,IAAI,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC;aACzC;SACJ;IACL,CAAC;CACJ;AArCG;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;6CACnB;AAMxB;IADC,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4CAcJ","sourcesContent":["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport {\n CSSResultArray,\n html,\n PropertyValues,\n SizedMixin,\n SpectrumElement,\n TemplateResult,\n} from '@spectrum-web-components/base';\nimport { property } from '@spectrum-web-components/base/src/decorators.js';\nimport statusLightStyles from './status-light.css.js';\n\n/**\n * @element sp-status-light\n *\n * @slot - text label of the Status Light\n */\nexport class StatusLight extends SizedMixin(SpectrumElement) {\n public static override get styles(): CSSResultArray {\n return [statusLightStyles];\n }\n\n /**\n * A status light in a disabled state shows that a status exists, but is not available in that circumstance. This can be used to maintain layout continuity and communicate that a status may become available later.\n */\n @property({ type: Boolean, reflect: true })\n public disabled = false;\n\n /**\n * The visual variant to apply to this status light.\n */\n @property({ reflect: true })\n public variant:\n | 'negative'\n | 'notice'\n | 'positive'\n | 'info'\n | 'neutral'\n | 'yellow'\n | 'fuchsia'\n | 'indigo'\n | 'seafoam'\n | 'chartreuse'\n | 'magenta'\n | 'celery'\n | 'purple' = 'info';\n\n protected override render(): TemplateResult {\n return html`\n <slot></slot>\n `;\n }\n\n protected override updated(changes: PropertyValues): void {\n super.updated(changes);\n if (changes.has('disabled')) {\n if (this.disabled) {\n this.setAttribute('aria-disabled', 'true');\n } else {\n this.removeAttribute('aria-disabled');\n }\n }\n }\n}\n"]}