@vaadin/progress-bar 24.0.0-beta1 → 24.0.0-beta2

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaadin/progress-bar",
3
- "version": "24.0.0-beta1",
3
+ "version": "24.0.0-beta2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -21,6 +21,8 @@
21
21
  "type": "module",
22
22
  "files": [
23
23
  "src",
24
+ "!src/vaadin-lit-progress-bar.d.ts",
25
+ "!src/vaadin-lit-progress-bar.js",
24
26
  "theme",
25
27
  "vaadin-*.d.ts",
26
28
  "vaadin-*.js",
@@ -38,10 +40,11 @@
38
40
  "dependencies": {
39
41
  "@open-wc/dedupe-mixin": "^1.3.0",
40
42
  "@polymer/polymer": "^3.0.0",
41
- "@vaadin/component-base": "24.0.0-beta1",
42
- "@vaadin/vaadin-lumo-styles": "24.0.0-beta1",
43
- "@vaadin/vaadin-material-styles": "24.0.0-beta1",
44
- "@vaadin/vaadin-themable-mixin": "24.0.0-beta1"
43
+ "@vaadin/component-base": "24.0.0-beta2",
44
+ "@vaadin/vaadin-lumo-styles": "24.0.0-beta2",
45
+ "@vaadin/vaadin-material-styles": "24.0.0-beta2",
46
+ "@vaadin/vaadin-themable-mixin": "24.0.0-beta2",
47
+ "lit": "^2.0.0"
45
48
  },
46
49
  "devDependencies": {
47
50
  "@esm-bundle/chai": "^4.3.4",
@@ -51,5 +54,5 @@
51
54
  "web-types.json",
52
55
  "web-types.lit.json"
53
56
  ],
54
- "gitHead": "c5b48921a62482746df8e46994b37e1490fec27e"
57
+ "gitHead": "00086f1f6d487f042f189c9b9ecd7ba736960888"
55
58
  }
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2017 - 2023 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ import type { CSSResult } from 'lit';
7
+
8
+ export const progressBarStyles: CSSResult;
@@ -0,0 +1,32 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2017 - 2023 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ import { css } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
7
+
8
+ export const progressBarStyles = css`
9
+ :host {
10
+ display: block;
11
+ width: 100%; /* prevent collapsing inside non-stretching column flex */
12
+ height: 8px;
13
+ }
14
+
15
+ :host([hidden]) {
16
+ display: none !important;
17
+ }
18
+
19
+ [part='bar'] {
20
+ height: 100%;
21
+ }
22
+
23
+ [part='value'] {
24
+ height: 100%;
25
+ transform-origin: 0 50%;
26
+ transform: scaleX(var(--vaadin-progress-value));
27
+ }
28
+
29
+ :host([dir='rtl']) [part='value'] {
30
+ transform-origin: 100% 50%;
31
+ }
32
+ `;
@@ -5,9 +5,12 @@
5
5
  */
6
6
  import { html, PolymerElement } from '@polymer/polymer/polymer-element.js';
7
7
  import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
8
- import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
8
+ import { registerStyles, ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
9
+ import { progressBarStyles } from './vaadin-progress-bar-styles.js';
9
10
  import { ProgressMixin } from './vaadin-progress-mixin.js';
10
11
 
12
+ registerStyles('vaadin-progress-bar', progressBarStyles, { moduleId: 'vaadin-progress-bar-styles' });
13
+
11
14
  /**
12
15
  * `<vaadin-progress-bar>` is a Web Component for progress bars.
13
16
  *
@@ -45,45 +48,17 @@ import { ProgressMixin } from './vaadin-progress-mixin.js';
45
48
  * @mixes ElementMixin
46
49
  */
47
50
  class ProgressBar extends ElementMixin(ThemableMixin(ProgressMixin(PolymerElement))) {
51
+ static get is() {
52
+ return 'vaadin-progress-bar';
53
+ }
54
+
48
55
  static get template() {
49
56
  return html`
50
- <style>
51
- :host {
52
- display: block;
53
- width: 100%; /* prevent collapsing inside non-stretching column flex */
54
- height: 8px;
55
- }
56
-
57
- :host([hidden]) {
58
- display: none !important;
59
- }
60
-
61
- [part='bar'] {
62
- height: 100%;
63
- }
64
-
65
- [part='value'] {
66
- height: 100%;
67
- transform-origin: 0 50%;
68
- transform: scaleX(var(--vaadin-progress-value));
69
- }
70
-
71
- /* RTL specific styles */
72
-
73
- :host([dir='rtl']) [part='value'] {
74
- transform-origin: 100% 50%;
75
- }
76
- </style>
77
-
78
57
  <div part="bar">
79
58
  <div part="value"></div>
80
59
  </div>
81
60
  `;
82
61
  }
83
-
84
- static get is() {
85
- return 'vaadin-progress-bar';
86
- }
87
62
  }
88
63
 
89
64
  customElements.define(ProgressBar.is, ProgressBar);
package/web-types.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/progress-bar",
4
- "version": "24.0.0-beta1",
4
+ "version": "24.0.0-beta2",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "name": "@vaadin/progress-bar",
4
- "version": "24.0.0-beta1",
4
+ "version": "24.0.0-beta2",
5
5
  "description-markup": "markdown",
6
6
  "framework": "lit",
7
7
  "framework-config": {