@semcore/progress-bar 2.2.2 → 2.3.0

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/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  CHANGELOG.md standards are inspired by [keepachangelog.com](https://keepachangelog.com/en/1.0.0/).
4
4
 
5
+ ## [2.3.0] - 2021-03-04
6
+
7
+ ### Added
8
+
9
+ - Disabled animation if reduce motion is preferred.
10
+
5
11
  ## [2.2.2] - 2022-02-24
6
12
 
7
13
  ### Added
@@ -54,25 +54,25 @@ var style = (
54
54
  /*__reshadow_css_start__*/
55
55
  _core.sstyled.insert(
56
56
  /*__inner_css_start__*/
57
- ".___SProgressBar_k9rlr_gg_{position:relative;width:100%;overflow:hidden}.___SValue_k9rlr_gg_{position:absolute;top:0;left:0;background-image:linear-gradient(-45deg,#479d2e 25%,#4fae33 0,#4fae33 50%,#479d2e 0,#479d2e 76%,#4fae33 0);overflow:hidden;-webkit-animation-name:loading_1wbyfk1;animation-name:loading_1wbyfk1;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;transition-property:width;transition-timing-function:linear;transition-duration:1s}.___SProgressBar_k9rlr_gg_._size_s_k9rlr_gg_,.___SValue_k9rlr_gg_._size_s_k9rlr_gg_{height:4px;border-radius:2px;background-size:8px 8px}.___SProgressBar_k9rlr_gg_._size_m_k9rlr_gg_,.___SValue_k9rlr_gg_._size_m_k9rlr_gg_{height:8px;border-radius:4px;background-size:12px 12px}.___SProgressBar_k9rlr_gg_._size_l_k9rlr_gg_,.___SValue_k9rlr_gg_._size_l_k9rlr_gg_{height:12px;border-radius:6px;background-size:16px 16px}.___SProgressBar_k9rlr_gg_._theme_dark_k9rlr_gg_{background-color:hsla(0,0%,100%,.2)}.___SProgressBar_k9rlr_gg_._theme_invert_k9rlr_gg_{background-color:#dee3e5}@-webkit-keyframes loading_1wbyfk1{0%{background-position:0 0}to{background-position:60px 0}}@keyframes loading_1wbyfk1{0%{background-position:0 0}to{background-position:60px 0}}.___SProgressBar_k9rlr_gg_.__animation_k9rlr_gg_{background-image:linear-gradient(-45deg,#c8ccce 25%,#dee3e5 0,#dee3e5 50%,#c8ccce 0,#c8ccce 76%,#dee3e5 0);-webkit-animation-name:loading_1wbyfk1;animation-name:loading_1wbyfk1;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.___SProgressBar_k9rlr_gg_._theme_custom_k9rlr_gg_{background-color:var(--backgroundColor_1wbyfk1)}.___SProgressBar_k9rlr_gg_._theme_custom_k9rlr_gg_{background-image:var(--backgroundColor_1wbyfk1)}.___SProgressBar_k9rlr_gg_.__animation_k9rlr_gg_{-webkit-animation-duration:var(--duration_1wbyfk1);animation-duration:var(--duration_1wbyfk1)}.___SValue_k9rlr_gg_{width:var(--width_1wbyfk1);-webkit-animation-duration:var(--duration_1wbyfk1);animation-duration:var(--duration_1wbyfk1)}.___SValue_k9rlr_gg_.__theme_k9rlr_gg_{background-color:var(--backgroundColor_1wbyfk1);background-image:var(--backgroundColor_1wbyfk1)}"
57
+ ".___SProgressBar_1jx5f_gg_{position:relative;width:100%;overflow:hidden}.___SValue_1jx5f_gg_{position:absolute;top:0;left:0;background-image:linear-gradient(-45deg,#479d2e 25%,#4fae33 0,#4fae33 50%,#479d2e 0,#479d2e 76%,#4fae33 0);overflow:hidden;-webkit-animation-name:loading_1v03k;animation-name:loading_1v03k;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;transition-property:width;transition-timing-function:linear;transition-duration:1s}.___SProgressBar_1jx5f_gg_._size_s_1jx5f_gg_,.___SValue_1jx5f_gg_._size_s_1jx5f_gg_{height:4px;border-radius:2px;background-size:8px 8px}.___SProgressBar_1jx5f_gg_._size_m_1jx5f_gg_,.___SValue_1jx5f_gg_._size_m_1jx5f_gg_{height:8px;border-radius:4px;background-size:12px 12px}.___SProgressBar_1jx5f_gg_._size_l_1jx5f_gg_,.___SValue_1jx5f_gg_._size_l_1jx5f_gg_{height:12px;border-radius:6px;background-size:16px 16px}.___SProgressBar_1jx5f_gg_._theme_dark_1jx5f_gg_{background-color:hsla(0,0%,100%,.2)}.___SProgressBar_1jx5f_gg_._theme_invert_1jx5f_gg_{background-color:#dee3e5}@-webkit-keyframes loading_1v03k{0%{background-position:0 0}to{background-position:60px 0}}@keyframes loading_1v03k{0%{background-position:0 0}to{background-position:60px 0}}.___SProgressBar_1jx5f_gg_.__animation_1jx5f_gg_{background-image:linear-gradient(-45deg,#c8ccce 25%,#dee3e5 0,#dee3e5 50%,#c8ccce 0,#c8ccce 76%,#dee3e5 0);-webkit-animation-name:loading_1v03k;animation-name:loading_1v03k;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.___SProgressBar_1jx5f_gg_._theme_custom_1jx5f_gg_{background-color:var(--backgroundColor_1v03k)}.___SProgressBar_1jx5f_gg_._theme_custom_1jx5f_gg_{background-image:var(--backgroundColor_1v03k)}.___SProgressBar_1jx5f_gg_.__animation_1jx5f_gg_{-webkit-animation-duration:var(--duration_1v03k);animation-duration:var(--duration_1v03k)}.___SValue_1jx5f_gg_{width:var(--width_1v03k);-webkit-animation-duration:var(--duration_1v03k);animation-duration:var(--duration_1v03k)}.___SValue_1jx5f_gg_.__theme_1jx5f_gg_{background-color:var(--backgroundColor_1v03k);background-image:var(--backgroundColor_1v03k)}@media (prefers-reduced-motion){.___SValue_1jx5f_gg_{-webkit-animation-name:none;animation-name:none}.___SProgressBar_1jx5f_gg_.__animation_1jx5f_gg_{-webkit-animation-name:none;animation-name:none}}"
58
58
  /*__inner_css_end__*/
59
- , "1wbyfk1_gg_")
59
+ , "1v03k_gg_")
60
60
  /*__reshadow_css_end__*/
61
61
  , {
62
- "__SProgressBar": "___SProgressBar_k9rlr_gg_",
63
- "__SValue": "___SValue_k9rlr_gg_",
64
- "_size_s": "_size_s_k9rlr_gg_",
65
- "_size_m": "_size_m_k9rlr_gg_",
66
- "_size_l": "_size_l_k9rlr_gg_",
67
- "_theme_dark": "_theme_dark_k9rlr_gg_",
68
- "_theme_invert": "_theme_invert_k9rlr_gg_",
69
- "@loading": "loading_1wbyfk1",
70
- "_animation": "__animation_k9rlr_gg_",
71
- "_theme_custom": "_theme_custom_k9rlr_gg_",
72
- "--backgroundColor": "--backgroundColor_1wbyfk1",
73
- "--duration": "--duration_1wbyfk1",
74
- "--width": "--width_1wbyfk1",
75
- "_theme": "__theme_k9rlr_gg_"
62
+ "__SProgressBar": "___SProgressBar_1jx5f_gg_",
63
+ "__SValue": "___SValue_1jx5f_gg_",
64
+ "_size_s": "_size_s_1jx5f_gg_",
65
+ "_size_m": "_size_m_1jx5f_gg_",
66
+ "_size_l": "_size_l_1jx5f_gg_",
67
+ "_theme_dark": "_theme_dark_1jx5f_gg_",
68
+ "_theme_invert": "_theme_invert_1jx5f_gg_",
69
+ "@loading": "loading_1v03k",
70
+ "_animation": "__animation_1jx5f_gg_",
71
+ "_theme_custom": "_theme_custom_1jx5f_gg_",
72
+ "--backgroundColor": "--backgroundColor_1v03k",
73
+ "--duration": "--duration_1v03k",
74
+ "--width": "--width_1v03k",
75
+ "_theme": "__theme_1jx5f_gg_"
76
76
  });
77
77
 
78
78
  function isCustomTheme(theme) {
@@ -100,3 +100,12 @@ SValue[theme] {
100
100
  background-color: var(--backgroundColor);
101
101
  background-image: var(--backgroundColor);
102
102
  }
103
+
104
+ @media (prefers-reduced-motion) {
105
+ SValue {
106
+ animation-name: none;
107
+ }
108
+ SProgressBar[animation] {
109
+ animation-name: none;
110
+ }
111
+ }
@@ -30,25 +30,25 @@ var style = (
30
30
  /*__reshadow_css_start__*/
31
31
  _sstyled.insert(
32
32
  /*__inner_css_start__*/
33
- ".___SProgressBar_k9rlr_gg_{position:relative;width:100%;overflow:hidden}.___SValue_k9rlr_gg_{position:absolute;top:0;left:0;background-image:linear-gradient(-45deg,#479d2e 25%,#4fae33 0,#4fae33 50%,#479d2e 0,#479d2e 76%,#4fae33 0);overflow:hidden;-webkit-animation-name:loading_1wbyfk1;animation-name:loading_1wbyfk1;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;transition-property:width;transition-timing-function:linear;transition-duration:1s}.___SProgressBar_k9rlr_gg_._size_s_k9rlr_gg_,.___SValue_k9rlr_gg_._size_s_k9rlr_gg_{height:4px;border-radius:2px;background-size:8px 8px}.___SProgressBar_k9rlr_gg_._size_m_k9rlr_gg_,.___SValue_k9rlr_gg_._size_m_k9rlr_gg_{height:8px;border-radius:4px;background-size:12px 12px}.___SProgressBar_k9rlr_gg_._size_l_k9rlr_gg_,.___SValue_k9rlr_gg_._size_l_k9rlr_gg_{height:12px;border-radius:6px;background-size:16px 16px}.___SProgressBar_k9rlr_gg_._theme_dark_k9rlr_gg_{background-color:hsla(0,0%,100%,.2)}.___SProgressBar_k9rlr_gg_._theme_invert_k9rlr_gg_{background-color:#dee3e5}@-webkit-keyframes loading_1wbyfk1{0%{background-position:0 0}to{background-position:60px 0}}@keyframes loading_1wbyfk1{0%{background-position:0 0}to{background-position:60px 0}}.___SProgressBar_k9rlr_gg_.__animation_k9rlr_gg_{background-image:linear-gradient(-45deg,#c8ccce 25%,#dee3e5 0,#dee3e5 50%,#c8ccce 0,#c8ccce 76%,#dee3e5 0);-webkit-animation-name:loading_1wbyfk1;animation-name:loading_1wbyfk1;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.___SProgressBar_k9rlr_gg_._theme_custom_k9rlr_gg_{background-color:var(--backgroundColor_1wbyfk1)}.___SProgressBar_k9rlr_gg_._theme_custom_k9rlr_gg_{background-image:var(--backgroundColor_1wbyfk1)}.___SProgressBar_k9rlr_gg_.__animation_k9rlr_gg_{-webkit-animation-duration:var(--duration_1wbyfk1);animation-duration:var(--duration_1wbyfk1)}.___SValue_k9rlr_gg_{width:var(--width_1wbyfk1);-webkit-animation-duration:var(--duration_1wbyfk1);animation-duration:var(--duration_1wbyfk1)}.___SValue_k9rlr_gg_.__theme_k9rlr_gg_{background-color:var(--backgroundColor_1wbyfk1);background-image:var(--backgroundColor_1wbyfk1)}"
33
+ ".___SProgressBar_1jx5f_gg_{position:relative;width:100%;overflow:hidden}.___SValue_1jx5f_gg_{position:absolute;top:0;left:0;background-image:linear-gradient(-45deg,#479d2e 25%,#4fae33 0,#4fae33 50%,#479d2e 0,#479d2e 76%,#4fae33 0);overflow:hidden;-webkit-animation-name:loading_1v03k;animation-name:loading_1v03k;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;transition-property:width;transition-timing-function:linear;transition-duration:1s}.___SProgressBar_1jx5f_gg_._size_s_1jx5f_gg_,.___SValue_1jx5f_gg_._size_s_1jx5f_gg_{height:4px;border-radius:2px;background-size:8px 8px}.___SProgressBar_1jx5f_gg_._size_m_1jx5f_gg_,.___SValue_1jx5f_gg_._size_m_1jx5f_gg_{height:8px;border-radius:4px;background-size:12px 12px}.___SProgressBar_1jx5f_gg_._size_l_1jx5f_gg_,.___SValue_1jx5f_gg_._size_l_1jx5f_gg_{height:12px;border-radius:6px;background-size:16px 16px}.___SProgressBar_1jx5f_gg_._theme_dark_1jx5f_gg_{background-color:hsla(0,0%,100%,.2)}.___SProgressBar_1jx5f_gg_._theme_invert_1jx5f_gg_{background-color:#dee3e5}@-webkit-keyframes loading_1v03k{0%{background-position:0 0}to{background-position:60px 0}}@keyframes loading_1v03k{0%{background-position:0 0}to{background-position:60px 0}}.___SProgressBar_1jx5f_gg_.__animation_1jx5f_gg_{background-image:linear-gradient(-45deg,#c8ccce 25%,#dee3e5 0,#dee3e5 50%,#c8ccce 0,#c8ccce 76%,#dee3e5 0);-webkit-animation-name:loading_1v03k;animation-name:loading_1v03k;-webkit-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.___SProgressBar_1jx5f_gg_._theme_custom_1jx5f_gg_{background-color:var(--backgroundColor_1v03k)}.___SProgressBar_1jx5f_gg_._theme_custom_1jx5f_gg_{background-image:var(--backgroundColor_1v03k)}.___SProgressBar_1jx5f_gg_.__animation_1jx5f_gg_{-webkit-animation-duration:var(--duration_1v03k);animation-duration:var(--duration_1v03k)}.___SValue_1jx5f_gg_{width:var(--width_1v03k);-webkit-animation-duration:var(--duration_1v03k);animation-duration:var(--duration_1v03k)}.___SValue_1jx5f_gg_.__theme_1jx5f_gg_{background-color:var(--backgroundColor_1v03k);background-image:var(--backgroundColor_1v03k)}@media (prefers-reduced-motion){.___SValue_1jx5f_gg_{-webkit-animation-name:none;animation-name:none}.___SProgressBar_1jx5f_gg_.__animation_1jx5f_gg_{-webkit-animation-name:none;animation-name:none}}"
34
34
  /*__inner_css_end__*/
35
- , "1wbyfk1_gg_")
35
+ , "1v03k_gg_")
36
36
  /*__reshadow_css_end__*/
37
37
  , {
38
- "__SProgressBar": "___SProgressBar_k9rlr_gg_",
39
- "__SValue": "___SValue_k9rlr_gg_",
40
- "_size_s": "_size_s_k9rlr_gg_",
41
- "_size_m": "_size_m_k9rlr_gg_",
42
- "_size_l": "_size_l_k9rlr_gg_",
43
- "_theme_dark": "_theme_dark_k9rlr_gg_",
44
- "_theme_invert": "_theme_invert_k9rlr_gg_",
45
- "@loading": "loading_1wbyfk1",
46
- "_animation": "__animation_k9rlr_gg_",
47
- "_theme_custom": "_theme_custom_k9rlr_gg_",
48
- "--backgroundColor": "--backgroundColor_1wbyfk1",
49
- "--duration": "--duration_1wbyfk1",
50
- "--width": "--width_1wbyfk1",
51
- "_theme": "__theme_k9rlr_gg_"
38
+ "__SProgressBar": "___SProgressBar_1jx5f_gg_",
39
+ "__SValue": "___SValue_1jx5f_gg_",
40
+ "_size_s": "_size_s_1jx5f_gg_",
41
+ "_size_m": "_size_m_1jx5f_gg_",
42
+ "_size_l": "_size_l_1jx5f_gg_",
43
+ "_theme_dark": "_theme_dark_1jx5f_gg_",
44
+ "_theme_invert": "_theme_invert_1jx5f_gg_",
45
+ "@loading": "loading_1v03k",
46
+ "_animation": "__animation_1jx5f_gg_",
47
+ "_theme_custom": "_theme_custom_1jx5f_gg_",
48
+ "--backgroundColor": "--backgroundColor_1v03k",
49
+ "--duration": "--duration_1v03k",
50
+ "--width": "--width_1v03k",
51
+ "_theme": "__theme_1jx5f_gg_"
52
52
  });
53
53
 
54
54
  function isCustomTheme(theme) {
@@ -100,3 +100,12 @@ SValue[theme] {
100
100
  background-color: var(--backgroundColor);
101
101
  background-image: var(--backgroundColor);
102
102
  }
103
+
104
+ @media (prefers-reduced-motion) {
105
+ SValue {
106
+ animation-name: none;
107
+ }
108
+ SProgressBar[animation] {
109
+ animation-name: none;
110
+ }
111
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@semcore/progress-bar",
3
3
  "description": "SEMRush ProgressBar Component",
4
- "version": "2.2.2",
4
+ "version": "2.3.0",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/es6/index.js",
7
7
  "typings": "lib/types/index.d.ts",
@@ -100,3 +100,12 @@ SValue[theme] {
100
100
  background-color: var(--backgroundColor);
101
101
  background-image: var(--backgroundColor);
102
102
  }
103
+
104
+ @media (prefers-reduced-motion) {
105
+ SValue {
106
+ animation-name: none;
107
+ }
108
+ SProgressBar[animation] {
109
+ animation-name: none;
110
+ }
111
+ }