@spectrum-web-components/progress-bar 0.5.4-express.12 → 0.5.5

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/progress-bar",
3
- "version": "0.5.4-express.12+27420d682",
3
+ "version": "0.5.5",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -44,17 +44,17 @@
44
44
  "lit-html"
45
45
  ],
46
46
  "dependencies": {
47
- "@spectrum-web-components/base": "^0.5.1",
48
- "@spectrum-web-components/field-label": "^0.7.4-express.12+27420d682",
47
+ "@spectrum-web-components/base": "^0.5.3",
48
+ "@spectrum-web-components/field-label": "^0.7.5",
49
49
  "tslib": "^2.0.0"
50
50
  },
51
51
  "devDependencies": {
52
- "@spectrum-css/progressbar": "^1.0.14"
52
+ "@spectrum-css/progressbar": "^1.0.18"
53
53
  },
54
54
  "types": "./src/index.d.ts",
55
55
  "customElements": "custom-elements.json",
56
56
  "sideEffects": [
57
57
  "./sp-*.js"
58
58
  ],
59
- "gitHead": "27420d682bb3b3f679875e1f4148c10df0bd738c"
59
+ "gitHead": "57aba8030b6af96af4015a0aa830e342a17dc219"
60
60
  }
@@ -1,6 +0,0 @@
1
- import { ProgressBar } from './src/ProgressBar.js';
2
- declare global {
3
- interface HTMLElementTagNameMap {
4
- 'sp-progress-bar': ProgressBar;
5
- }
6
- }
@@ -1,14 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { ProgressBar } from './src/ProgressBar.js';
13
- customElements.define('sp-progress-bar', ProgressBar);
14
- //# sourceMappingURL=sp-progress-bar.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"sp-progress-bar.js","sourceRoot":"","sources":["sp-progress-bar.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AAEF,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,cAAc,CAAC,MAAM,CAAC,iBAAiB,EAAE,WAAW,CAAC,CAAC","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 { ProgressBar } from './src/ProgressBar.js';\n\ncustomElements.define('sp-progress-bar', ProgressBar);\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'sp-progress-bar': ProgressBar;\n }\n}\n"]}
@@ -1,21 +0,0 @@
1
- import { CSSResultArray, PropertyValues, SpectrumElement, TemplateResult } from '@spectrum-web-components/base';
2
- import '@spectrum-web-components/field-label/sp-field-label.js';
3
- declare const ProgressBar_base: typeof SpectrumElement & {
4
- new (...args: any[]): import("@spectrum-web-components/base").SizedElementInterface;
5
- prototype: import("@spectrum-web-components/base").SizedElementInterface;
6
- };
7
- /**
8
- * @element sp-progress-bar
9
- */
10
- export declare class ProgressBar extends ProgressBar_base {
11
- static get styles(): CSSResultArray;
12
- indeterminate: boolean;
13
- label: string;
14
- overBackground: boolean;
15
- sideLabel: boolean;
16
- progress: number;
17
- protected render(): TemplateResult;
18
- protected firstUpdated(changes: PropertyValues): void;
19
- protected updated(changes: PropertyValues): void;
20
- }
21
- export {};
@@ -1,103 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { __decorate } from "tslib";
13
- import { html, SizedMixin, SpectrumElement, } from '@spectrum-web-components/base';
14
- import { property } from '@spectrum-web-components/base/src/decorators.js';
15
- import '@spectrum-web-components/field-label/sp-field-label.js';
16
- import styles from './progress-bar.css.js';
17
- /**
18
- * @element sp-progress-bar
19
- */
20
- export class ProgressBar extends SizedMixin(SpectrumElement) {
21
- constructor() {
22
- super(...arguments);
23
- this.indeterminate = false;
24
- this.label = '';
25
- this.overBackground = false;
26
- this.sideLabel = false;
27
- this.progress = 0;
28
- }
29
- static get styles() {
30
- return [styles];
31
- }
32
- render() {
33
- return html `
34
- ${this.label
35
- ? html `
36
- <sp-field-label size=${this.size} class="label">
37
- ${this.label}
38
- </sp-field-label>
39
- ${this.indeterminate
40
- ? html ``
41
- : html `
42
- <sp-field-label
43
- size=${this.size}
44
- class="percentage"
45
- >
46
- ${this.progress}%
47
- </sp-field-label>
48
- `}
49
- `
50
- : html ``}
51
- <div class="track">
52
- <div
53
- class="fill"
54
- style="transform: scaleX(calc(${this.progress} / 100));"
55
- ></div>
56
- </div>
57
- `;
58
- }
59
- firstUpdated(changes) {
60
- super.firstUpdated(changes);
61
- if (!this.hasAttribute('role')) {
62
- this.setAttribute('role', 'progressbar');
63
- }
64
- }
65
- updated(changes) {
66
- super.updated(changes);
67
- if (changes.has('indeterminate')) {
68
- if (this.indeterminate) {
69
- this.removeAttribute('aria-valuemin');
70
- this.removeAttribute('aria-valuemax');
71
- }
72
- else {
73
- this.setAttribute('aria-valuemin', '0');
74
- this.setAttribute('aria-valuemax', '100');
75
- }
76
- }
77
- if (!this.indeterminate && changes.has('progress')) {
78
- this.setAttribute('aria-valuenow', '' + this.progress);
79
- }
80
- else if (this.hasAttribute('aria-valuenow')) {
81
- this.removeAttribute('aria-valuenow');
82
- }
83
- if (this.label && changes.has('label')) {
84
- this.setAttribute('aria-label', this.label);
85
- }
86
- }
87
- }
88
- __decorate([
89
- property({ type: Boolean, reflect: true })
90
- ], ProgressBar.prototype, "indeterminate", void 0);
91
- __decorate([
92
- property({ type: String })
93
- ], ProgressBar.prototype, "label", void 0);
94
- __decorate([
95
- property({ type: Boolean, reflect: true, attribute: 'over-background' })
96
- ], ProgressBar.prototype, "overBackground", void 0);
97
- __decorate([
98
- property({ type: Boolean, reflect: true, attribute: 'side-label' })
99
- ], ProgressBar.prototype, "sideLabel", void 0);
100
- __decorate([
101
- property({ type: Number })
102
- ], ProgressBar.prototype, "progress", void 0);
103
- //# sourceMappingURL=ProgressBar.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ProgressBar.js","sourceRoot":"","sources":["ProgressBar.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;AAE3E,OAAO,wDAAwD,CAAC;AAChE,OAAO,MAAM,MAAM,uBAAuB,CAAC;AAE3C;;GAEG;AACH,MAAM,OAAO,WAAY,SAAQ,UAAU,CAAC,eAAe,CAAC;IAA5D;;QAMW,kBAAa,GAAG,KAAK,CAAC;QAGtB,UAAK,GAAG,EAAE,CAAC;QAGX,mBAAc,GAAG,KAAK,CAAC;QAGvB,cAAS,GAAG,KAAK,CAAC;QAGlB,aAAQ,GAAG,CAAC,CAAC;IAyDxB,CAAC;IA1EU,MAAM,KAAK,MAAM;QACpB,OAAO,CAAC,MAAM,CAAC,CAAC;IACpB,CAAC;IAiBS,MAAM;QACZ,OAAO,IAAI,CAAA;cACL,IAAI,CAAC,KAAK;YACR,CAAC,CAAC,IAAI,CAAA;6CACuB,IAAI,CAAC,IAAI;4BAC1B,IAAI,CAAC,KAAK;;wBAEd,IAAI,CAAC,aAAa;gBAChB,CAAC,CAAC,IAAI,CAAA,EAAE;gBACR,CAAC,CAAC,IAAI,CAAA;;2CAEW,IAAI,CAAC,IAAI;;;sCAGd,IAAI,CAAC,QAAQ;;6BAEtB;mBACV;YACH,CAAC,CAAC,IAAI,CAAA,EAAE;;;;oDAI4B,IAAI,CAAC,QAAQ;;;SAGxD,CAAC;IACN,CAAC;IAES,YAAY,CAAC,OAAuB;QAC1C,KAAK,CAAC,YAAY,CAAC,OAAO,CAAC,CAAC;QAC5B,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE;YAC5B,IAAI,CAAC,YAAY,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;SAC5C;IACL,CAAC;IAES,OAAO,CAAC,OAAuB;QACrC,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACvB,IAAI,OAAO,CAAC,GAAG,CAAC,eAAe,CAAC,EAAE;YAC9B,IAAI,IAAI,CAAC,aAAa,EAAE;gBACpB,IAAI,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC;gBACtC,IAAI,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC;aACzC;iBAAM;gBACH,IAAI,CAAC,YAAY,CAAC,eAAe,EAAE,GAAG,CAAC,CAAC;gBACxC,IAAI,CAAC,YAAY,CAAC,eAAe,EAAE,KAAK,CAAC,CAAC;aAC7C;SACJ;QACD,IAAI,CAAC,IAAI,CAAC,aAAa,IAAI,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE;YAChD,IAAI,CAAC,YAAY,CAAC,eAAe,EAAE,EAAE,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC;SAC1D;aAAM,IAAI,IAAI,CAAC,YAAY,CAAC,eAAe,CAAC,EAAE;YAC3C,IAAI,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC;SACzC;QACD,IAAI,IAAI,CAAC,KAAK,IAAI,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE;YACpC,IAAI,CAAC,YAAY,CAAC,YAAY,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC;SAC/C;IACL,CAAC;CACJ;AArEG;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;kDACd;AAG7B;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;0CACT;AAGlB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,iBAAiB,EAAE,CAAC;mDAC3C;AAG9B;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,YAAY,EAAE,CAAC;8CAC3C;AAGzB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;6CACP","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';\n\nimport '@spectrum-web-components/field-label/sp-field-label.js';\nimport styles from './progress-bar.css.js';\n\n/**\n * @element sp-progress-bar\n */\nexport class ProgressBar extends SizedMixin(SpectrumElement) {\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n @property({ type: Boolean, reflect: true })\n public indeterminate = false;\n\n @property({ type: String })\n public label = '';\n\n @property({ type: Boolean, reflect: true, attribute: 'over-background' })\n public overBackground = false;\n\n @property({ type: Boolean, reflect: true, attribute: 'side-label' })\n public sideLabel = false;\n\n @property({ type: Number })\n public progress = 0;\n\n protected render(): TemplateResult {\n return html`\n ${this.label\n ? html`\n <sp-field-label size=${this.size} class=\"label\">\n ${this.label}\n </sp-field-label>\n ${this.indeterminate\n ? html``\n : html`\n <sp-field-label\n size=${this.size}\n class=\"percentage\"\n >\n ${this.progress}%\n </sp-field-label>\n `}\n `\n : html``}\n <div class=\"track\">\n <div\n class=\"fill\"\n style=\"transform: scaleX(calc(${this.progress} / 100));\"\n ></div>\n </div>\n `;\n }\n\n protected firstUpdated(changes: PropertyValues): void {\n super.firstUpdated(changes);\n if (!this.hasAttribute('role')) {\n this.setAttribute('role', 'progressbar');\n }\n }\n\n protected updated(changes: PropertyValues): void {\n super.updated(changes);\n if (changes.has('indeterminate')) {\n if (this.indeterminate) {\n this.removeAttribute('aria-valuemin');\n this.removeAttribute('aria-valuemax');\n } else {\n this.setAttribute('aria-valuemin', '0');\n this.setAttribute('aria-valuemax', '100');\n }\n }\n if (!this.indeterminate && changes.has('progress')) {\n this.setAttribute('aria-valuenow', '' + this.progress);\n } else if (this.hasAttribute('aria-valuenow')) {\n this.removeAttribute('aria-valuenow');\n }\n if (this.label && changes.has('label')) {\n this.setAttribute('aria-label', this.label);\n }\n }\n}\n"]}
package/src/index.d.ts DELETED
@@ -1 +0,0 @@
1
- export * from './ProgressBar.js';
package/src/index.js DELETED
@@ -1,13 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- export * from './ProgressBar.js';
13
- //# sourceMappingURL=index.js.map
package/src/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AAEF,cAAc,kBAAkB,CAAC","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\nexport * from './ProgressBar.js';\n"]}
@@ -1,2 +0,0 @@
1
- declare const styles: import("@spectrum-web-components/base").CSSResult;
2
- export default styles;
@@ -1,105 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { css } from '@spectrum-web-components/base';
13
- const styles = css `
14
- :host([size=s]){--spectrum-progressbar-border-radius:var(
15
- --spectrum-progressbar-s-border-radius
16
- );--spectrum-progressbar-indeterminate-fill-width:var(
17
- --spectrum-progressbar-s-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
18
- );--spectrum-progressbar-indeterminate-duration:var(
19
- --spectrum-progressbar-s-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
20
- );--spectrum-progressbar-value-gap-y:var(
21
- --spectrum-progressbar-s-value-gap-y,0px
22
- );--spectrum-progressbar-height:var(
23
- --spectrum-progressbar-s-height,var(--spectrum-global-dimension-size-50)
24
- );--spectrum-progressbar-width:var(
25
- --spectrum-progressbar-s-width,var(--spectrum-global-dimension-static-size-2400)
26
- )}:host([size=m]){--spectrum-progressbar-border-radius:var(
27
- --spectrum-progressbar-m-border-radius
28
- );--spectrum-progressbar-indeterminate-fill-width:var(
29
- --spectrum-progressbar-m-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
30
- );--spectrum-progressbar-indeterminate-duration:var(
31
- --spectrum-progressbar-m-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
32
- );--spectrum-progressbar-value-gap-y:var(
33
- --spectrum-progressbar-m-value-gap-y,0px
34
- );--spectrum-progressbar-height:var(
35
- --spectrum-progressbar-m-height,var(--spectrum-global-dimension-size-75)
36
- );--spectrum-progressbar-width:var(
37
- --spectrum-progressbar-m-width,var(--spectrum-global-dimension-static-size-2400)
38
- );--spectrum-fieldlabel-side-padding-right:var(
39
- --spectrum-fieldlabel-m-side-padding-right,var(--spectrum-global-dimension-size-150)
40
- )}:host([size=l]){--spectrum-progressbar-indeterminate-fill-width:var(
41
- --spectrum-progressbar-l-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
42
- );--spectrum-progressbar-indeterminate-duration:var(
43
- --spectrum-progressbar-l-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
44
- );--spectrum-progressbar-value-gap-y:var(
45
- --spectrum-progressbar-l-value-gap-y,0px
46
- );--spectrum-progressbar-height:var(
47
- --spectrum-progressbar-l-height,var(--spectrum-global-dimension-size-100)
48
- );--spectrum-progressbar-border-radius:var(
49
- --spectrum-progressbar-l-border-radius,var(--spectrum-global-dimension-size-50)
50
- );--spectrum-progressbar-width:var(
51
- --spectrum-progressbar-l-width,var(--spectrum-global-dimension-static-size-2500)
52
- )}:host([size=xl]){--spectrum-progressbar-border-radius:var(
53
- --spectrum-progressbar-xl-border-radius
54
- );--spectrum-progressbar-indeterminate-fill-width:var(
55
- --spectrum-progressbar-xl-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
56
- );--spectrum-progressbar-indeterminate-duration:var(
57
- --spectrum-progressbar-xl-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
58
- );--spectrum-progressbar-value-gap-y:var(
59
- --spectrum-progressbar-xl-value-gap-y,0px
60
- );--spectrum-progressbar-height:var(
61
- --spectrum-progressbar-xl-height,var(--spectrum-global-dimension-size-125)
62
- );--spectrum-progressbar-width:var(
63
- --spectrum-progressbar-xl-width,var(--spectrum-global-dimension-static-size-2800)
64
- )}:host{align-items:center;display:inline-flex;flex-flow:row wrap;justify-content:space-between;position:relative;vertical-align:top;width:var(--spectrum-progressbar-width)}.track{border-radius:var(--spectrum-progressbar-border-radius);overflow:hidden;width:100%;z-index:1}.fill,.track{height:var(--spectrum-progressbar-height)}.fill{border:none;transition:width 1s}:host([dir=ltr]) .label,:host([dir=ltr]) .percentage{text-align:left}:host([dir=rtl]) .label,:host([dir=rtl]) .percentage{text-align:right}.label,.percentage{margin-bottom:var(
65
- --spectrum-progressbar-value-gap-y
66
- )}.label{flex:1 1 0%}:host([dir=ltr]) .percentage{margin-left:var(
67
- --spectrum-fieldlabel-side-padding-right
68
- )}:host([dir=rtl]) .percentage{margin-right:var(
69
- --spectrum-fieldlabel-side-padding-right
70
- )}.percentage{align-self:flex-start}:host([side-label]){display:inline-flex;flex-flow:row;justify-content:space-between;width:auto}:host([side-label]) .track{flex:1 1 var(--spectrum-progressbar-width);min-width:var(
71
- --spectrum-progressbar-width
72
- )}:host([dir=ltr][side-label]) .label{margin-right:var(
73
- --spectrum-fieldlabel-side-padding-right
74
- )}:host([dir=rtl][side-label]) .label{margin-left:var(
75
- --spectrum-fieldlabel-side-padding-right
76
- )}:host([side-label]) .label{flex-grow:0;margin-bottom:0}:host([dir=ltr][side-label]) .percentage{text-align:right}:host([dir=rtl][side-label]) .percentage{text-align:left}:host([dir=ltr][side-label]) .percentage{margin-left:var(
77
- --spectrum-fieldlabel-side-padding-right
78
- )}:host([dir=rtl][side-label]) .percentage{margin-right:var(
79
- --spectrum-fieldlabel-side-padding-right
80
- )}:host([side-label]) .percentage{margin-bottom:0;order:3}:host([indeterminate]) .fill{animation-timing-function:var(
81
- --spectrum-progressbar-indeterminate-animation-ease
82
- );position:relative;width:var(
83
- --spectrum-progressbar-indeterminate-fill-width
84
- );will-change:transform}:host([dir=ltr][indeterminate]) .fill{animation:indeterminate-loop-ltr var(--spectrum-progressbar-indeterminate-duration) infinite}:host([dir=rtl][indeterminate]) .fill{animation:indeterminate-loop-rtl var(--spectrum-progressbar-indeterminate-duration) infinite}@keyframes indeterminate-loop-ltr{0%{transform:translate(calc(var(--spectrum-progressbar-indeterminate-fill-width)*-1))}to{transform:translate(var(--spectrum-progressbar-width))}}@keyframes indeterminate-loop-rtl{0%{transform:translate(var(--spectrum-progressbar-width))}to{transform:translate(calc(var(--spectrum-progressbar-width)*-1))}}.fill{background:var(
85
- --spectrum-progressbar-m-track-fill-color,var(--spectrum-semantic-informative-color-default)
86
- )}.track{background-color:var(
87
- --spectrum-progressbar-m-track-color,var(--spectrum-alias-track-color-default)
88
- )}:host([over-background]) .fill{background:var(
89
- --spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)
90
- )}:host([over-background]) .label,:host([over-background]) .percentage{color:var(
91
- --spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)
92
- )}:host([over-background]) .track{background-color:var(
93
- --spectrum-progressbar-m-overbackground-track-color,var(--spectrum-alias-track-color-overbackground)
94
- )}:host([positive]) .fill{background:var(
95
- --spectrum-meter-m-positive-track-fill-color,var(--spectrum-semantic-positive-status-color)
96
- )}:host(.is-notice) .fill{background:var(
97
- --spectrum-meter-m-notice-track-fill-color,var(--spectrum-semantic-notice-status-color)
98
- )}:host(.is-negative) .fill{background:var(
99
- --spectrum-meter-m-negative-track-fill-color,var(--spectrum-semantic-negative-status-color)
100
- )}.label,.percentage{color:var(
101
- --spectrum-fieldlabel-m-text-color,var(--spectrum-alias-label-text-color)
102
- )}.fill{transform-origin:left;width:100%}:host([dir=rtl]) .fill{transform-origin:right}
103
- `;
104
- export default styles;
105
- //# sourceMappingURL=progress-bar.css.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"progress-bar.css.js","sourceRoot":"","sources":["progress-bar.css.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AACF,OAAO,EAAE,GAAG,EAAE,MAAM,+BAA+B,CAAC;AACpD,MAAM,MAAM,GAAG,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0FjB,CAAC;AACF,eAAe,MAAM,CAAC","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*/\nimport { css } from '@spectrum-web-components/base';\nconst styles = css`\n:host([size=s]){--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-s-border-radius\n);--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-s-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-s-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-s-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-s-height,var(--spectrum-global-dimension-size-50)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-s-width,var(--spectrum-global-dimension-static-size-2400)\n)}:host([size=m]){--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-m-border-radius\n);--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-m-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-m-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-m-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-m-height,var(--spectrum-global-dimension-size-75)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-m-width,var(--spectrum-global-dimension-static-size-2400)\n);--spectrum-fieldlabel-side-padding-right:var(\n--spectrum-fieldlabel-m-side-padding-right,var(--spectrum-global-dimension-size-150)\n)}:host([size=l]){--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-l-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-l-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-l-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-l-height,var(--spectrum-global-dimension-size-100)\n);--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-l-border-radius,var(--spectrum-global-dimension-size-50)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-l-width,var(--spectrum-global-dimension-static-size-2500)\n)}:host([size=xl]){--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-xl-border-radius\n);--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-xl-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-xl-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-xl-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-xl-height,var(--spectrum-global-dimension-size-125)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-xl-width,var(--spectrum-global-dimension-static-size-2800)\n)}:host{align-items:center;display:inline-flex;flex-flow:row wrap;justify-content:space-between;position:relative;vertical-align:top;width:var(--spectrum-progressbar-width)}.track{border-radius:var(--spectrum-progressbar-border-radius);overflow:hidden;width:100%;z-index:1}.fill,.track{height:var(--spectrum-progressbar-height)}.fill{border:none;transition:width 1s}:host([dir=ltr]) .label,:host([dir=ltr]) .percentage{text-align:left}:host([dir=rtl]) .label,:host([dir=rtl]) .percentage{text-align:right}.label,.percentage{margin-bottom:var(\n--spectrum-progressbar-value-gap-y\n)}.label{flex:1 1 0%}:host([dir=ltr]) .percentage{margin-left:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([dir=rtl]) .percentage{margin-right:var(\n--spectrum-fieldlabel-side-padding-right\n)}.percentage{align-self:flex-start}:host([side-label]){display:inline-flex;flex-flow:row;justify-content:space-between;width:auto}:host([side-label]) .track{flex:1 1 var(--spectrum-progressbar-width);min-width:var(\n--spectrum-progressbar-width\n)}:host([dir=ltr][side-label]) .label{margin-right:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([dir=rtl][side-label]) .label{margin-left:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([side-label]) .label{flex-grow:0;margin-bottom:0}:host([dir=ltr][side-label]) .percentage{text-align:right}:host([dir=rtl][side-label]) .percentage{text-align:left}:host([dir=ltr][side-label]) .percentage{margin-left:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([dir=rtl][side-label]) .percentage{margin-right:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([side-label]) .percentage{margin-bottom:0;order:3}:host([indeterminate]) .fill{animation-timing-function:var(\n--spectrum-progressbar-indeterminate-animation-ease\n);position:relative;width:var(\n--spectrum-progressbar-indeterminate-fill-width\n);will-change:transform}:host([dir=ltr][indeterminate]) .fill{animation:indeterminate-loop-ltr var(--spectrum-progressbar-indeterminate-duration) infinite}:host([dir=rtl][indeterminate]) .fill{animation:indeterminate-loop-rtl var(--spectrum-progressbar-indeterminate-duration) infinite}@keyframes indeterminate-loop-ltr{0%{transform:translate(calc(var(--spectrum-progressbar-indeterminate-fill-width)*-1))}to{transform:translate(var(--spectrum-progressbar-width))}}@keyframes indeterminate-loop-rtl{0%{transform:translate(var(--spectrum-progressbar-width))}to{transform:translate(calc(var(--spectrum-progressbar-width)*-1))}}.fill{background:var(\n--spectrum-progressbar-m-track-fill-color,var(--spectrum-semantic-informative-color-default)\n)}.track{background-color:var(\n--spectrum-progressbar-m-track-color,var(--spectrum-alias-track-color-default)\n)}:host([over-background]) .fill{background:var(\n--spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)\n)}:host([over-background]) .label,:host([over-background]) .percentage{color:var(\n--spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)\n)}:host([over-background]) .track{background-color:var(\n--spectrum-progressbar-m-overbackground-track-color,var(--spectrum-alias-track-color-overbackground)\n)}:host([positive]) .fill{background:var(\n--spectrum-meter-m-positive-track-fill-color,var(--spectrum-semantic-positive-status-color)\n)}:host(.is-notice) .fill{background:var(\n--spectrum-meter-m-notice-track-fill-color,var(--spectrum-semantic-notice-status-color)\n)}:host(.is-negative) .fill{background:var(\n--spectrum-meter-m-negative-track-fill-color,var(--spectrum-semantic-negative-status-color)\n)}.label,.percentage{color:var(\n--spectrum-fieldlabel-m-text-color,var(--spectrum-alias-label-text-color)\n)}.fill{transform-origin:left;width:100%}:host([dir=rtl]) .fill{transform-origin:right}\n`;\nexport default styles;"]}
@@ -1,2 +0,0 @@
1
- declare const styles: import("@spectrum-web-components/base").CSSResult;
2
- export default styles;
@@ -1,105 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { css } from '@spectrum-web-components/base';
13
- const styles = css `
14
- :host([size=s]){--spectrum-progressbar-border-radius:var(
15
- --spectrum-progressbar-s-border-radius
16
- );--spectrum-progressbar-indeterminate-fill-width:var(
17
- --spectrum-progressbar-s-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
18
- );--spectrum-progressbar-indeterminate-duration:var(
19
- --spectrum-progressbar-s-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
20
- );--spectrum-progressbar-value-gap-y:var(
21
- --spectrum-progressbar-s-value-gap-y,0px
22
- );--spectrum-progressbar-height:var(
23
- --spectrum-progressbar-s-height,var(--spectrum-global-dimension-size-50)
24
- );--spectrum-progressbar-width:var(
25
- --spectrum-progressbar-s-width,var(--spectrum-global-dimension-static-size-2400)
26
- )}:host([size=m]){--spectrum-progressbar-border-radius:var(
27
- --spectrum-progressbar-m-border-radius
28
- );--spectrum-progressbar-indeterminate-fill-width:var(
29
- --spectrum-progressbar-m-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
30
- );--spectrum-progressbar-indeterminate-duration:var(
31
- --spectrum-progressbar-m-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
32
- );--spectrum-progressbar-value-gap-y:var(
33
- --spectrum-progressbar-m-value-gap-y,0px
34
- );--spectrum-progressbar-height:var(
35
- --spectrum-progressbar-m-height,var(--spectrum-global-dimension-size-75)
36
- );--spectrum-progressbar-width:var(
37
- --spectrum-progressbar-m-width,var(--spectrum-global-dimension-static-size-2400)
38
- );--spectrum-fieldlabel-side-padding-right:var(
39
- --spectrum-fieldlabel-m-side-padding-right,var(--spectrum-global-dimension-size-150)
40
- )}:host([size=l]){--spectrum-progressbar-indeterminate-fill-width:var(
41
- --spectrum-progressbar-l-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
42
- );--spectrum-progressbar-indeterminate-duration:var(
43
- --spectrum-progressbar-l-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
44
- );--spectrum-progressbar-value-gap-y:var(
45
- --spectrum-progressbar-l-value-gap-y,0px
46
- );--spectrum-progressbar-height:var(
47
- --spectrum-progressbar-l-height,var(--spectrum-global-dimension-size-100)
48
- );--spectrum-progressbar-border-radius:var(
49
- --spectrum-progressbar-l-border-radius,var(--spectrum-global-dimension-size-50)
50
- );--spectrum-progressbar-width:var(
51
- --spectrum-progressbar-l-width,var(--spectrum-global-dimension-static-size-2500)
52
- )}:host([size=xl]){--spectrum-progressbar-border-radius:var(
53
- --spectrum-progressbar-xl-border-radius
54
- );--spectrum-progressbar-indeterminate-fill-width:var(
55
- --spectrum-progressbar-xl-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)
56
- );--spectrum-progressbar-indeterminate-duration:var(
57
- --spectrum-progressbar-xl-indeterminate-duration,var(--spectrum-global-animation-duration-2000)
58
- );--spectrum-progressbar-value-gap-y:var(
59
- --spectrum-progressbar-xl-value-gap-y,0px
60
- );--spectrum-progressbar-height:var(
61
- --spectrum-progressbar-xl-height,var(--spectrum-global-dimension-size-125)
62
- );--spectrum-progressbar-width:var(
63
- --spectrum-progressbar-xl-width,var(--spectrum-global-dimension-static-size-2800)
64
- )}:host{align-items:center;display:inline-flex;flex-flow:row wrap;justify-content:space-between;position:relative;vertical-align:top;width:var(--spectrum-progressbar-width)}.track{border-radius:var(--spectrum-progressbar-border-radius);overflow:hidden;width:100%;z-index:1}.fill,.track{height:var(--spectrum-progressbar-height)}.fill{border:none;transition:width 1s}:host([dir=ltr]) .label,:host([dir=ltr]) .percentage{text-align:left}:host([dir=rtl]) .label,:host([dir=rtl]) .percentage{text-align:right}.label,.percentage{margin-bottom:var(
65
- --spectrum-progressbar-value-gap-y
66
- )}.label{flex:1 1 0%}:host([dir=ltr]) .percentage{margin-left:var(
67
- --spectrum-fieldlabel-side-padding-right
68
- )}:host([dir=rtl]) .percentage{margin-right:var(
69
- --spectrum-fieldlabel-side-padding-right
70
- )}.percentage{align-self:flex-start}:host([side-label]){display:inline-flex;flex-flow:row;justify-content:space-between;width:auto}:host([side-label]) .track{flex:1 1 var(--spectrum-progressbar-width);min-width:var(
71
- --spectrum-progressbar-width
72
- )}:host([dir=ltr][side-label]) .label{margin-right:var(
73
- --spectrum-fieldlabel-side-padding-right
74
- )}:host([dir=rtl][side-label]) .label{margin-left:var(
75
- --spectrum-fieldlabel-side-padding-right
76
- )}:host([side-label]) .label{flex-grow:0;margin-bottom:0}:host([dir=ltr][side-label]) .percentage{text-align:right}:host([dir=rtl][side-label]) .percentage{text-align:left}:host([dir=ltr][side-label]) .percentage{margin-left:var(
77
- --spectrum-fieldlabel-side-padding-right
78
- )}:host([dir=rtl][side-label]) .percentage{margin-right:var(
79
- --spectrum-fieldlabel-side-padding-right
80
- )}:host([side-label]) .percentage{margin-bottom:0;order:3}:host([indeterminate]) .fill{animation-timing-function:var(
81
- --spectrum-progressbar-indeterminate-animation-ease
82
- );position:relative;width:var(
83
- --spectrum-progressbar-indeterminate-fill-width
84
- );will-change:transform}:host([dir=ltr][indeterminate]) .fill{animation:indeterminate-loop-ltr var(--spectrum-progressbar-indeterminate-duration) infinite}:host([dir=rtl][indeterminate]) .fill{animation:indeterminate-loop-rtl var(--spectrum-progressbar-indeterminate-duration) infinite}@keyframes indeterminate-loop-ltr{0%{transform:translate(calc(var(--spectrum-progressbar-indeterminate-fill-width)*-1))}to{transform:translate(var(--spectrum-progressbar-width))}}@keyframes indeterminate-loop-rtl{0%{transform:translate(var(--spectrum-progressbar-width))}to{transform:translate(calc(var(--spectrum-progressbar-width)*-1))}}.fill{background:var(
85
- --spectrum-progressbar-m-track-fill-color,var(--spectrum-semantic-informative-color-default)
86
- )}.track{background-color:var(
87
- --spectrum-progressbar-m-track-color,var(--spectrum-alias-track-color-default)
88
- )}:host([over-background]) .fill{background:var(
89
- --spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)
90
- )}:host([over-background]) .label,:host([over-background]) .percentage{color:var(
91
- --spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)
92
- )}:host([over-background]) .track{background-color:var(
93
- --spectrum-progressbar-m-overbackground-track-color,var(--spectrum-alias-track-color-overbackground)
94
- )}:host([positive]) .fill{background:var(
95
- --spectrum-meter-m-positive-track-fill-color,var(--spectrum-semantic-positive-status-color)
96
- )}:host(.is-notice) .fill{background:var(
97
- --spectrum-meter-m-notice-track-fill-color,var(--spectrum-semantic-notice-status-color)
98
- )}:host(.is-negative) .fill{background:var(
99
- --spectrum-meter-m-negative-track-fill-color,var(--spectrum-semantic-negative-status-color)
100
- )}.label,.percentage{color:var(
101
- --spectrum-fieldlabel-m-text-color,var(--spectrum-alias-label-text-color)
102
- )}
103
- `;
104
- export default styles;
105
- //# sourceMappingURL=spectrum-progress-bar.css.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"spectrum-progress-bar.css.js","sourceRoot":"","sources":["spectrum-progress-bar.css.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AACF,OAAO,EAAE,GAAG,EAAE,MAAM,+BAA+B,CAAC;AACpD,MAAM,MAAM,GAAG,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0FjB,CAAC;AACF,eAAe,MAAM,CAAC","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*/\nimport { css } from '@spectrum-web-components/base';\nconst styles = css`\n:host([size=s]){--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-s-border-radius\n);--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-s-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-s-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-s-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-s-height,var(--spectrum-global-dimension-size-50)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-s-width,var(--spectrum-global-dimension-static-size-2400)\n)}:host([size=m]){--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-m-border-radius\n);--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-m-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-m-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-m-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-m-height,var(--spectrum-global-dimension-size-75)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-m-width,var(--spectrum-global-dimension-static-size-2400)\n);--spectrum-fieldlabel-side-padding-right:var(\n--spectrum-fieldlabel-m-side-padding-right,var(--spectrum-global-dimension-size-150)\n)}:host([size=l]){--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-l-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-l-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-l-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-l-height,var(--spectrum-global-dimension-size-100)\n);--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-l-border-radius,var(--spectrum-global-dimension-size-50)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-l-width,var(--spectrum-global-dimension-static-size-2500)\n)}:host([size=xl]){--spectrum-progressbar-border-radius:var(\n--spectrum-progressbar-xl-border-radius\n);--spectrum-progressbar-indeterminate-fill-width:var(\n--spectrum-progressbar-xl-indeterminate-fill-width,var(--spectrum-global-dimension-static-percent-70)\n);--spectrum-progressbar-indeterminate-duration:var(\n--spectrum-progressbar-xl-indeterminate-duration,var(--spectrum-global-animation-duration-2000)\n);--spectrum-progressbar-value-gap-y:var(\n--spectrum-progressbar-xl-value-gap-y,0px\n);--spectrum-progressbar-height:var(\n--spectrum-progressbar-xl-height,var(--spectrum-global-dimension-size-125)\n);--spectrum-progressbar-width:var(\n--spectrum-progressbar-xl-width,var(--spectrum-global-dimension-static-size-2800)\n)}:host{align-items:center;display:inline-flex;flex-flow:row wrap;justify-content:space-between;position:relative;vertical-align:top;width:var(--spectrum-progressbar-width)}.track{border-radius:var(--spectrum-progressbar-border-radius);overflow:hidden;width:100%;z-index:1}.fill,.track{height:var(--spectrum-progressbar-height)}.fill{border:none;transition:width 1s}:host([dir=ltr]) .label,:host([dir=ltr]) .percentage{text-align:left}:host([dir=rtl]) .label,:host([dir=rtl]) .percentage{text-align:right}.label,.percentage{margin-bottom:var(\n--spectrum-progressbar-value-gap-y\n)}.label{flex:1 1 0%}:host([dir=ltr]) .percentage{margin-left:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([dir=rtl]) .percentage{margin-right:var(\n--spectrum-fieldlabel-side-padding-right\n)}.percentage{align-self:flex-start}:host([side-label]){display:inline-flex;flex-flow:row;justify-content:space-between;width:auto}:host([side-label]) .track{flex:1 1 var(--spectrum-progressbar-width);min-width:var(\n--spectrum-progressbar-width\n)}:host([dir=ltr][side-label]) .label{margin-right:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([dir=rtl][side-label]) .label{margin-left:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([side-label]) .label{flex-grow:0;margin-bottom:0}:host([dir=ltr][side-label]) .percentage{text-align:right}:host([dir=rtl][side-label]) .percentage{text-align:left}:host([dir=ltr][side-label]) .percentage{margin-left:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([dir=rtl][side-label]) .percentage{margin-right:var(\n--spectrum-fieldlabel-side-padding-right\n)}:host([side-label]) .percentage{margin-bottom:0;order:3}:host([indeterminate]) .fill{animation-timing-function:var(\n--spectrum-progressbar-indeterminate-animation-ease\n);position:relative;width:var(\n--spectrum-progressbar-indeterminate-fill-width\n);will-change:transform}:host([dir=ltr][indeterminate]) .fill{animation:indeterminate-loop-ltr var(--spectrum-progressbar-indeterminate-duration) infinite}:host([dir=rtl][indeterminate]) .fill{animation:indeterminate-loop-rtl var(--spectrum-progressbar-indeterminate-duration) infinite}@keyframes indeterminate-loop-ltr{0%{transform:translate(calc(var(--spectrum-progressbar-indeterminate-fill-width)*-1))}to{transform:translate(var(--spectrum-progressbar-width))}}@keyframes indeterminate-loop-rtl{0%{transform:translate(var(--spectrum-progressbar-width))}to{transform:translate(calc(var(--spectrum-progressbar-width)*-1))}}.fill{background:var(\n--spectrum-progressbar-m-track-fill-color,var(--spectrum-semantic-informative-color-default)\n)}.track{background-color:var(\n--spectrum-progressbar-m-track-color,var(--spectrum-alias-track-color-default)\n)}:host([over-background]) .fill{background:var(\n--spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)\n)}:host([over-background]) .label,:host([over-background]) .percentage{color:var(\n--spectrum-progressbar-m-overbackground-track-fill-color,var(--spectrum-alias-track-fill-color-overbackground)\n)}:host([over-background]) .track{background-color:var(\n--spectrum-progressbar-m-overbackground-track-color,var(--spectrum-alias-track-color-overbackground)\n)}:host([positive]) .fill{background:var(\n--spectrum-meter-m-positive-track-fill-color,var(--spectrum-semantic-positive-status-color)\n)}:host(.is-notice) .fill{background:var(\n--spectrum-meter-m-notice-track-fill-color,var(--spectrum-semantic-notice-status-color)\n)}:host(.is-negative) .fill{background:var(\n--spectrum-meter-m-negative-track-fill-color,var(--spectrum-semantic-negative-status-color)\n)}.label,.percentage{color:var(\n--spectrum-fieldlabel-m-text-color,var(--spectrum-alias-label-text-color)\n)}\n`;\nexport default styles;"]}
@@ -1,54 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { html } from '@spectrum-web-components/base';
13
- import '../sp-progress-bar.js';
14
- export default {
15
- title: 'Progress Bar/Sizes',
16
- component: 'sp-progress-bar',
17
- };
18
- export const s = () => {
19
- return html `
20
- <sp-progress-bar
21
- label="Loading"
22
- progress="50"
23
- size="s"
24
- ></sp-progress-bar>
25
- `;
26
- };
27
- export const m = () => {
28
- return html `
29
- <sp-progress-bar
30
- label="Loading"
31
- progress="50"
32
- size="m"
33
- ></sp-progress-bar>
34
- `;
35
- };
36
- export const l = () => {
37
- return html `
38
- <sp-progress-bar
39
- label="Loading"
40
- progress="50"
41
- size="l"
42
- ></sp-progress-bar>
43
- `;
44
- };
45
- export const XL = () => {
46
- return html `
47
- <sp-progress-bar
48
- label="Loading"
49
- progress="50"
50
- size="xl"
51
- ></sp-progress-bar>
52
- `;
53
- };
54
- //# sourceMappingURL=progress-bar-sizes.stories.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"progress-bar-sizes.stories.js","sourceRoot":"","sources":["progress-bar-sizes.stories.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AAEF,OAAO,EAAE,IAAI,EAAkB,MAAM,+BAA+B,CAAC;AAErE,OAAO,uBAAuB,CAAC;AAE/B,eAAe;IACX,KAAK,EAAE,oBAAoB;IAC3B,SAAS,EAAE,iBAAiB;CAC/B,CAAC;AAEF,MAAM,CAAC,MAAM,CAAC,GAAG,GAAmB,EAAE;IAClC,OAAO,IAAI,CAAA;;;;;;KAMV,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,CAAC,GAAG,GAAmB,EAAE;IAClC,OAAO,IAAI,CAAA;;;;;;KAMV,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,CAAC,GAAG,GAAmB,EAAE;IAClC,OAAO,IAAI,CAAA;;;;;;KAMV,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,EAAE,GAAG,GAAmB,EAAE;IACnC,OAAO,IAAI,CAAA;;;;;;KAMV,CAAC;AACN,CAAC,CAAC","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 { html, TemplateResult } from '@spectrum-web-components/base';\n\nimport '../sp-progress-bar.js';\n\nexport default {\n title: 'Progress Bar/Sizes',\n component: 'sp-progress-bar',\n};\n\nexport const s = (): TemplateResult => {\n return html`\n <sp-progress-bar\n label=\"Loading\"\n progress=\"50\"\n size=\"s\"\n ></sp-progress-bar>\n `;\n};\n\nexport const m = (): TemplateResult => {\n return html`\n <sp-progress-bar\n label=\"Loading\"\n progress=\"50\"\n size=\"m\"\n ></sp-progress-bar>\n `;\n};\n\nexport const l = (): TemplateResult => {\n return html`\n <sp-progress-bar\n label=\"Loading\"\n progress=\"50\"\n size=\"l\"\n ></sp-progress-bar>\n `;\n};\n\nexport const XL = (): TemplateResult => {\n return html`\n <sp-progress-bar\n label=\"Loading\"\n progress=\"50\"\n size=\"xl\"\n ></sp-progress-bar>\n `;\n};\n"]}
@@ -1,96 +0,0 @@
1
- /*
2
- Copyright 2020 Adobe. All rights reserved.
3
- This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License. You may obtain a copy
5
- of the License at http://www.apache.org/licenses/LICENSE-2.0
6
-
7
- Unless required by applicable law or agreed to in writing, software distributed under
8
- the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- OF ANY KIND, either express or implied. See the License for the specific language
10
- governing permissions and limitations under the License.
11
- */
12
- import { html } from '@spectrum-web-components/base';
13
- import '../sp-progress-bar.js';
14
- export default {
15
- title: 'Progress Bar',
16
- component: 'sp-progress-bar',
17
- };
18
- export const label = () => {
19
- return html `
20
- <sp-progress-bar label="Loading" progress="50"></sp-progress-bar>
21
- `;
22
- };
23
- export const indeterminate = () => {
24
- return html `
25
- <sp-progress-bar label="Loading" indeterminate></sp-progress-bar>
26
- `;
27
- };
28
- export const sideLabel = () => {
29
- return html `
30
- <sp-progress-bar
31
- side-label
32
- label="Loading"
33
- progress="50"
34
- ></sp-progress-bar>
35
- `;
36
- };
37
- export const sideIndeterminate = () => {
38
- return html `
39
- <sp-progress-bar
40
- side-label
41
- label="Loading"
42
- indeterminate
43
- ></sp-progress-bar>
44
- `;
45
- };
46
- const makeOverBackground = (story) => html `
47
- <div
48
- style="background-color: var(--spectrum-global-color-seafoam-600); color: var(--spectrum-global-color-seafoam-600); padding: var(--spectrum-global-dimension-size-175) var(--spectrum-global-dimension-size-250); display: inline-block"
49
- >
50
- ${story}
51
- </div>
52
- `;
53
- export const overBackground = () => {
54
- return makeOverBackground(html `
55
- <sp-progress-bar progress="50" over-background></sp-progress-bar>
56
- `);
57
- };
58
- export const overBackgroundLabel = () => {
59
- return makeOverBackground(html `
60
- <sp-progress-bar
61
- label="Loading"
62
- progress="50"
63
- over-background
64
- ></sp-progress-bar>
65
- `);
66
- };
67
- export const overBackgroundIndeterminate = () => {
68
- return makeOverBackground(html `
69
- <sp-progress-bar
70
- label="Loading"
71
- indeterminate
72
- over-background
73
- ></sp-progress-bar>
74
- `);
75
- };
76
- export const overBackgroundSideLabel = () => {
77
- return makeOverBackground(html `
78
- <sp-progress-bar
79
- label="Loading"
80
- progress="50"
81
- over-background
82
- side-label
83
- ></sp-progress-bar>
84
- `);
85
- };
86
- export const overBackgroundSideLabelIndeterminate = () => {
87
- return makeOverBackground(html `
88
- <sp-progress-bar
89
- label="Loading"
90
- indeterminate
91
- over-background
92
- side-label
93
- ></sp-progress-bar>
94
- `);
95
- };
96
- //# sourceMappingURL=progress-bar.stories.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"progress-bar.stories.js","sourceRoot":"","sources":["progress-bar.stories.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;AAEF,OAAO,EAAE,IAAI,EAAkB,MAAM,+BAA+B,CAAC;AAErE,OAAO,uBAAuB,CAAC;AAE/B,eAAe;IACX,KAAK,EAAE,cAAc;IACrB,SAAS,EAAE,iBAAiB;CAC/B,CAAC;AAEF,MAAM,CAAC,MAAM,KAAK,GAAG,GAAmB,EAAE;IACtC,OAAO,IAAI,CAAA;;KAEV,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG,GAAmB,EAAE;IAC9C,OAAO,IAAI,CAAA;;KAEV,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,SAAS,GAAG,GAAmB,EAAE;IAC1C,OAAO,IAAI,CAAA;;;;;;KAMV,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAmB,EAAE;IAClD,OAAO,IAAI,CAAA;;;;;;KAMV,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,kBAAkB,GAAG,CAAC,KAAqB,EAAkB,EAAE,CAAC,IAAI,CAAA;;;;UAIhE,KAAK;;CAEd,CAAC;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,GAAmB,EAAE;IAC/C,OAAO,kBAAkB,CAAC,IAAI,CAAA;;KAE7B,CAAC,CAAC;AACP,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG,GAAmB,EAAE;IACpD,OAAO,kBAAkB,CAAC,IAAI,CAAA;;;;;;KAM7B,CAAC,CAAC;AACP,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,2BAA2B,GAAG,GAAmB,EAAE;IAC5D,OAAO,kBAAkB,CAAC,IAAI,CAAA;;;;;;KAM7B,CAAC,CAAC;AACP,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,uBAAuB,GAAG,GAAmB,EAAE;IACxD,OAAO,kBAAkB,CAAC,IAAI,CAAA;;;;;;;KAO7B,CAAC,CAAC;AACP,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,oCAAoC,GAAG,GAAmB,EAAE;IACrE,OAAO,kBAAkB,CAAC,IAAI,CAAA;;;;;;;KAO7B,CAAC,CAAC;AACP,CAAC,CAAC","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 { html, TemplateResult } from '@spectrum-web-components/base';\n\nimport '../sp-progress-bar.js';\n\nexport default {\n title: 'Progress Bar',\n component: 'sp-progress-bar',\n};\n\nexport const label = (): TemplateResult => {\n return html`\n <sp-progress-bar label=\"Loading\" progress=\"50\"></sp-progress-bar>\n `;\n};\n\nexport const indeterminate = (): TemplateResult => {\n return html`\n <sp-progress-bar label=\"Loading\" indeterminate></sp-progress-bar>\n `;\n};\n\nexport const sideLabel = (): TemplateResult => {\n return html`\n <sp-progress-bar\n side-label\n label=\"Loading\"\n progress=\"50\"\n ></sp-progress-bar>\n `;\n};\n\nexport const sideIndeterminate = (): TemplateResult => {\n return html`\n <sp-progress-bar\n side-label\n label=\"Loading\"\n indeterminate\n ></sp-progress-bar>\n `;\n};\n\nconst makeOverBackground = (story: TemplateResult): TemplateResult => html`\n <div\n style=\"background-color: var(--spectrum-global-color-seafoam-600); color: var(--spectrum-global-color-seafoam-600); padding: var(--spectrum-global-dimension-size-175) var(--spectrum-global-dimension-size-250); display: inline-block\"\n >\n ${story}\n </div>\n`;\n\nexport const overBackground = (): TemplateResult => {\n return makeOverBackground(html`\n <sp-progress-bar progress=\"50\" over-background></sp-progress-bar>\n `);\n};\n\nexport const overBackgroundLabel = (): TemplateResult => {\n return makeOverBackground(html`\n <sp-progress-bar\n label=\"Loading\"\n progress=\"50\"\n over-background\n ></sp-progress-bar>\n `);\n};\n\nexport const overBackgroundIndeterminate = (): TemplateResult => {\n return makeOverBackground(html`\n <sp-progress-bar\n label=\"Loading\"\n indeterminate\n over-background\n ></sp-progress-bar>\n `);\n};\n\nexport const overBackgroundSideLabel = (): TemplateResult => {\n return makeOverBackground(html`\n <sp-progress-bar\n label=\"Loading\"\n progress=\"50\"\n over-background\n side-label\n ></sp-progress-bar>\n `);\n};\n\nexport const overBackgroundSideLabelIndeterminate = (): TemplateResult => {\n return makeOverBackground(html`\n <sp-progress-bar\n label=\"Loading\"\n indeterminate\n over-background\n side-label\n ></sp-progress-bar>\n `);\n};\n"]}