@hh.ru/magritte-ui-switch 2.0.43 → 2.0.44

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.
@@ -2,11 +2,11 @@ import './index.css';
2
2
  import { jsx } from 'react/jsx-runtime';
3
3
  import { Skeleton } from '@hh.ru/magritte-ui-skeleton';
4
4
 
5
- var styles = {"switch":"magritte-switch___0AZYC_2-0-43","slider":"magritte-slider___YN62u_2-0-43","checked":"magritte-checked___QEAn5_2-0-43","switch-skeleton":"magritte-switch-skeleton___g1MEY_2-0-43","switchSkeleton":"magritte-switch-skeleton___g1MEY_2-0-43"};
5
+ var styles = {"switch":"magritte-switch___0AZYC_2-0-44","slider":"magritte-slider___YN62u_2-0-44","checked":"magritte-checked___QEAn5_2-0-44","switch-skeleton":"magritte-switch-skeleton___g1MEY_2-0-44","switchSkeleton":"magritte-switch-skeleton___g1MEY_2-0-44"};
6
6
 
7
7
  const SwitchSkeleton = ({ Component: Switch,
8
8
  // skeleton props
9
9
  width, height, borderRadius, inline, additionalClass, loading, ...switchProps }) => (jsx(Skeleton, { loading: loading, additionalClass: styles.switchSkeleton, inline: true, children: jsx(Switch, { ...switchProps }) }));
10
10
 
11
11
  export { SwitchSkeleton as S, styles as s };
12
- //# sourceMappingURL=Skeleton-BHt-gq28.js.map
12
+ //# sourceMappingURL=Skeleton-1GNGXk8u.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Skeleton-BHt-gq28.js","sources":["../src/Skeleton.tsx"],"sourcesContent":["import { IncompleteSkeletonComponent, Skeleton } from '@hh.ru/magritte-ui-skeleton';\nimport { SwitchProps } from '@hh.ru/magritte-ui-switch/types';\n\nimport styles from './switch.less';\n\nexport const SwitchSkeleton: IncompleteSkeletonComponent<SwitchProps> = ({\n Component: Switch,\n\n // skeleton props\n width,\n height,\n borderRadius,\n inline,\n additionalClass,\n loading,\n\n ...switchProps\n}) => (\n <Skeleton loading={loading} additionalClass={styles.switchSkeleton} inline>\n <Switch {...switchProps} />\n </Skeleton>\n);\n"],"names":["_jsx"],"mappings":";;;;;MAKa,cAAc,GAA6C,CAAC,EACrE,SAAS,EAAE,MAAM;AAEjB;AACA,KAAK,EACL,MAAM,EACN,YAAY,EACZ,MAAM,EACN,eAAe,EACf,OAAO,EAEP,GAAG,WAAW,EACjB,MACGA,GAAC,CAAA,QAAQ,EAAC,EAAA,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,CAAC,cAAc,EAAE,MAAM,EAAA,IAAA,EAAA,QAAA,EACtEA,IAAC,MAAM,EAAA,EAAA,GAAK,WAAW,EAAI,CAAA,EAAA,CACpB;;;;"}
1
+ {"version":3,"file":"Skeleton-1GNGXk8u.js","sources":["../src/Skeleton.tsx"],"sourcesContent":["import { IncompleteSkeletonComponent, Skeleton } from '@hh.ru/magritte-ui-skeleton';\nimport { SwitchProps } from '@hh.ru/magritte-ui-switch/types';\n\nimport styles from './switch.less';\n\nexport const SwitchSkeleton: IncompleteSkeletonComponent<SwitchProps> = ({\n Component: Switch,\n\n // skeleton props\n width,\n height,\n borderRadius,\n inline,\n additionalClass,\n loading,\n\n ...switchProps\n}) => (\n <Skeleton loading={loading} additionalClass={styles.switchSkeleton} inline>\n <Switch {...switchProps} />\n </Skeleton>\n);\n"],"names":["_jsx"],"mappings":";;;;;MAKa,cAAc,GAA6C,CAAC,EACrE,SAAS,EAAE,MAAM;AAEjB;AACA,KAAK,EACL,MAAM,EACN,YAAY,EACZ,MAAM,EACN,eAAe,EACf,OAAO,EAEP,GAAG,WAAW,EACjB,MACGA,GAAC,CAAA,QAAQ,EAAC,EAAA,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,CAAC,cAAc,EAAE,MAAM,EAAA,IAAA,EAAA,QAAA,EACtEA,IAAC,MAAM,EAAA,EAAA,GAAK,WAAW,EAAI,CAAA,EAAA,CACpB;;;;"}
package/Skeleton.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import './index.css';
2
2
  import 'react/jsx-runtime';
3
3
  import '@hh.ru/magritte-ui-skeleton';
4
- export { S as SwitchSkeleton } from './Skeleton-BHt-gq28.js';
4
+ export { S as SwitchSkeleton } from './Skeleton-1GNGXk8u.js';
5
5
  //# sourceMappingURL=Skeleton.js.map
package/Switch.js CHANGED
@@ -4,7 +4,7 @@ import classnames from 'classnames';
4
4
  import { useDisabled } from '@hh.ru/magritte-common-use-disabled';
5
5
  import { LockClosedFilledSize16 } from '@hh.ru/magritte-ui-icon/icon';
6
6
  import { enrichWithSkeleton } from '@hh.ru/magritte-ui-skeleton';
7
- import { S as SwitchSkeleton, s as styles } from './Skeleton-BHt-gq28.js';
7
+ import { S as SwitchSkeleton, s as styles } from './Skeleton-1GNGXk8u.js';
8
8
 
9
9
  const SwitchComponent = ({ onClick, 'aria-label': ariaLabel, disabled = false, checked = false, ...props }) => {
10
10
  const forceDisabled = useDisabled();
package/index.css CHANGED
@@ -46,7 +46,7 @@
46
46
  --magritte-shadow-level-1-blur-v21-3-2:12px;
47
47
  --magritte-shadow-level-1-spread-v21-3-2:0px;
48
48
  }
49
- .magritte-switch___0AZYC_2-0-43{
49
+ .magritte-switch___0AZYC_2-0-44{
50
50
  width:56px;
51
51
  height:36px;
52
52
  background-color:var(--magritte-color-component-switch-background-container-unchecked-v21-3-2);
@@ -54,36 +54,36 @@
54
54
  cursor:pointer;
55
55
  position:relative;
56
56
  }
57
- .magritte-switch___0AZYC_2-0-43:active:not(:disabled){
57
+ .magritte-switch___0AZYC_2-0-44:active:not(:disabled){
58
58
  background-color:var(--magritte-color-component-switch-background-state-container-unchecked-pressed-v21-3-2);
59
59
  }
60
- .magritte-switch___0AZYC_2-0-43:active:not(:disabled) .magritte-slider___YN62u_2-0-43{
60
+ .magritte-switch___0AZYC_2-0-44:active:not(:disabled) .magritte-slider___YN62u_2-0-44{
61
61
  border-radius:14px;
62
62
  background-color:var(--magritte-color-component-switch-background-state-toggle-unchecked-pressed-v21-3-2);
63
63
  width:36px;
64
64
  }
65
- .magritte-switch___0AZYC_2-0-43:disabled{
65
+ .magritte-switch___0AZYC_2-0-44:disabled{
66
66
  cursor:not-allowed;
67
67
  background-color:var(--magritte-color-component-switch-background-state-container-unchecked-disabled-v21-3-2);
68
68
  border-radius:20px;
69
69
  }
70
- .magritte-switch___0AZYC_2-0-43:disabled.magritte-checked___QEAn5_2-0-43{
70
+ .magritte-switch___0AZYC_2-0-44:disabled.magritte-checked___QEAn5_2-0-44{
71
71
  background-color:var(--magritte-color-component-switch-background-state-container-checked-disabled-v21-3-2);
72
72
  }
73
- .magritte-switch___0AZYC_2-0-43.focus-visible{
73
+ .magritte-switch___0AZYC_2-0-44.focus-visible{
74
74
  outline:var(--magritte-color-component-switch-stroke-state-focused-accessible-v21-3-2) solid 4px;
75
75
  }
76
76
  @media (min-width: 1020px){
77
- body.magritte-old-layout .magritte-switch___0AZYC_2-0-43:hover:not(:disabled):not(:active){
77
+ body.magritte-old-layout .magritte-switch___0AZYC_2-0-44:hover:not(:disabled):not(:active){
78
78
  background-color:var(--magritte-color-component-switch-background-state-container-unchecked-hovered-v21-3-2);
79
79
  }
80
80
  }
81
81
  @media (min-width: 1024px){
82
- body:not(.magritte-old-layout) .magritte-switch___0AZYC_2-0-43:hover:not(:disabled):not(:active){
82
+ body:not(.magritte-old-layout) .magritte-switch___0AZYC_2-0-44:hover:not(:disabled):not(:active){
83
83
  background-color:var(--magritte-color-component-switch-background-state-container-unchecked-hovered-v21-3-2);
84
84
  }
85
85
  }
86
- .magritte-slider___YN62u_2-0-43{
86
+ .magritte-slider___YN62u_2-0-44{
87
87
  width:28px;
88
88
  height:28px;
89
89
  background-color:var(--magritte-color-component-switch-background-toggle-unchecked-v21-3-2);
@@ -101,33 +101,33 @@
101
101
  --magritte-ui-icon-color-override:var(--magritte-color-component-switch-icon-state-toggle-unchecked-disabled-v21-3-2);
102
102
  box-shadow:var(--magritte-shadow-level-1-x-v21-3-2) var(--magritte-shadow-level-1-y-v21-3-2) var(--magritte-shadow-level-1-blur-v21-3-2) var(--magritte-shadow-level-1-spread-v21-3-2) var(--magritte-shadow-level-1-color-v21-3-2);
103
103
  }
104
- .magritte-checked___QEAn5_2-0-43{
104
+ .magritte-checked___QEAn5_2-0-44{
105
105
  background-color:var(--magritte-color-component-switch-background-container-checked-v21-3-2);
106
106
  }
107
- .magritte-checked___QEAn5_2-0-43 .magritte-slider___YN62u_2-0-43{
107
+ .magritte-checked___QEAn5_2-0-44 .magritte-slider___YN62u_2-0-44{
108
108
  background-color:var(--magritte-color-component-switch-background-toggle-checked-v21-3-2);
109
109
  left:calc(56px - (28px + 4px*2));
110
110
  --magritte-ui-icon-color-override:var(--magritte-color-component-switch-icon-state-toggle-checked-disabled-v21-3-2);
111
111
  }
112
- .magritte-checked___QEAn5_2-0-43:active:not(:disabled){
112
+ .magritte-checked___QEAn5_2-0-44:active:not(:disabled){
113
113
  background-color:var(--magritte-color-component-switch-background-state-container-checked-pressed-v21-3-2);
114
114
  }
115
- .magritte-checked___QEAn5_2-0-43:active:not(:disabled) .magritte-slider___YN62u_2-0-43{
115
+ .magritte-checked___QEAn5_2-0-44:active:not(:disabled) .magritte-slider___YN62u_2-0-44{
116
116
  background-color:var(--magritte-color-component-switch-background-state-toggle-checked-pressed-v21-3-2);
117
117
  width:36px;
118
118
  left:calc(56px - (36px + 4px*2));
119
119
  }
120
120
  @media (min-width: 1020px){
121
- body.magritte-old-layout .magritte-checked___QEAn5_2-0-43:hover:not(:disabled):not(:active){
121
+ body.magritte-old-layout .magritte-checked___QEAn5_2-0-44:hover:not(:disabled):not(:active){
122
122
  background-color:var(--magritte-color-component-switch-background-state-container-checked-hovered-v21-3-2);
123
123
  }
124
124
  }
125
125
  @media (min-width: 1024px){
126
- body:not(.magritte-old-layout) .magritte-checked___QEAn5_2-0-43:hover:not(:disabled):not(:active){
126
+ body:not(.magritte-old-layout) .magritte-checked___QEAn5_2-0-44:hover:not(:disabled):not(:active){
127
127
  background-color:var(--magritte-color-component-switch-background-state-container-checked-hovered-v21-3-2);
128
128
  }
129
129
  }
130
- .magritte-switch-skeleton___g1MEY_2-0-43{
130
+ .magritte-switch-skeleton___g1MEY_2-0-44{
131
131
  width:56px;
132
132
  height:36px;
133
133
  border-radius:18px;
package/index.js CHANGED
@@ -6,5 +6,5 @@ import 'classnames';
6
6
  import '@hh.ru/magritte-common-use-disabled';
7
7
  import '@hh.ru/magritte-ui-icon/icon';
8
8
  import '@hh.ru/magritte-ui-skeleton';
9
- import './Skeleton-BHt-gq28.js';
9
+ import './Skeleton-1GNGXk8u.js';
10
10
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hh.ru/magritte-ui-switch",
3
- "version": "2.0.43",
3
+ "version": "2.0.44",
4
4
  "main": "index.js",
5
5
  "types": "index.d.ts",
6
6
  "sideEffects": [
@@ -23,7 +23,7 @@
23
23
  "@hh.ru/magritte-common-use-disabled": "1.0.10",
24
24
  "@hh.ru/magritte-design-tokens": "21.3.2",
25
25
  "@hh.ru/magritte-ui-breakpoint": "5.0.0",
26
- "@hh.ru/magritte-ui-icon": "10.1.0",
26
+ "@hh.ru/magritte-ui-icon": "10.2.0",
27
27
  "@hh.ru/magritte-ui-skeleton": "2.1.26",
28
28
  "@hh.ru/magritte-ui-theme-provider": "1.1.41"
29
29
  },
@@ -34,5 +34,5 @@
34
34
  "publishConfig": {
35
35
  "access": "public"
36
36
  },
37
- "gitHead": "cbe1fb9e87fc21a078105505992bf64d19e9b9b5"
37
+ "gitHead": "d12e0d9910ca5fb5323a5312386cb48255aa5ca6"
38
38
  }