@salutejs/plasma-new-hope 0.197.0-dev.0 → 0.197.1-canary.1569.11973386056.0
Sign up to get free protection for your applications and to get access to all the features.
- package/cjs/components/Switch/Switch.css +2 -2
- package/cjs/components/Switch/Switch.tokens.js +9 -7
- package/cjs/components/Switch/Switch.tokens.js.map +1 -1
- package/cjs/components/Switch/_toggleSize/base.js +1 -1
- package/cjs/components/Switch/_toggleSize/base.js.map +1 -1
- package/cjs/components/Switch/_toggleSize/base_1e2ou53.css +1 -0
- package/cjs/components/Switch/_view/base.js +1 -1
- package/cjs/components/Switch/_view/{base_15atbyp.css → base_qbpw2g.css} +1 -1
- package/cjs/index.css +2 -2
- package/emotion/cjs/components/Switch/Switch.tokens.js +9 -7
- package/emotion/cjs/components/Switch/_toggleSize/base.js +1 -1
- package/emotion/cjs/examples/plasma_b2c/components/Switch/Switch.config.js +8 -8
- package/emotion/cjs/examples/plasma_b2c/components/Switch/Switch.outline.config.js +8 -8
- package/emotion/cjs/examples/plasma_web/components/Switch/Switch.config.js +8 -8
- package/emotion/cjs/examples/plasma_web/components/Switch/Switch.outline.config.js +8 -8
- package/emotion/es/components/Switch/Switch.tokens.js +9 -7
- package/emotion/es/components/Switch/_toggleSize/base.js +2 -2
- package/emotion/es/examples/plasma_b2c/components/Switch/Switch.config.js +8 -8
- package/emotion/es/examples/plasma_b2c/components/Switch/Switch.outline.config.js +8 -8
- package/emotion/es/examples/plasma_web/components/Switch/Switch.config.js +8 -8
- package/emotion/es/examples/plasma_web/components/Switch/Switch.outline.config.js +8 -8
- package/es/components/Switch/Switch.css +2 -2
- package/es/components/Switch/Switch.tokens.js +9 -7
- package/es/components/Switch/Switch.tokens.js.map +1 -1
- package/es/components/Switch/_toggleSize/base.js +1 -1
- package/es/components/Switch/_toggleSize/base.js.map +1 -1
- package/es/components/Switch/_toggleSize/base_1e2ou53.css +1 -0
- package/es/components/Switch/_view/base.js +1 -1
- package/es/components/Switch/_view/{base_15atbyp.css → base_qbpw2g.css} +1 -1
- package/es/index.css +2 -2
- package/package.json +2 -2
- package/styled-components/cjs/components/Switch/Switch.tokens.js +9 -7
- package/styled-components/cjs/components/Switch/_toggleSize/base.js +1 -1
- package/styled-components/cjs/examples/plasma_b2c/components/Switch/Switch.config.js +3 -3
- package/styled-components/cjs/examples/plasma_b2c/components/Switch/Switch.outline.config.js +3 -3
- package/styled-components/cjs/examples/plasma_web/components/Switch/Switch.config.js +3 -3
- package/styled-components/cjs/examples/plasma_web/components/Switch/Switch.outline.config.js +3 -3
- package/styled-components/es/components/Switch/Switch.tokens.js +9 -7
- package/styled-components/es/components/Switch/_toggleSize/base.js +2 -2
- package/styled-components/es/examples/plasma_b2c/components/Switch/Switch.config.js +3 -3
- package/styled-components/es/examples/plasma_b2c/components/Switch/Switch.outline.config.js +3 -3
- package/styled-components/es/examples/plasma_web/components/Switch/Switch.config.js +3 -3
- package/styled-components/es/examples/plasma_web/components/Switch/Switch.outline.config.js +3 -3
- package/types/components/Switch/Switch.tokens.d.ts +4 -2
- package/types/components/Switch/Switch.tokens.d.ts.map +1 -1
- package/types/components/Switch/_toggleSize/base.d.ts.map +1 -1
- package/types/examples/plasma_b2c/components/Switch/Switch.config.d.ts.map +1 -1
- package/types/examples/plasma_b2c/components/Switch/Switch.outline.config.d.ts.map +1 -1
- package/types/examples/plasma_web/components/Switch/Switch.config.d.ts.map +1 -1
- package/types/examples/plasma_web/components/Switch/Switch.outline.config.d.ts.map +1 -1
- package/cjs/components/Switch/_toggleSize/base_1d0b3t4.css +0 -1
- package/es/components/Switch/_toggleSize/base_1d0b3t4.css +0 -1
@@ -1,8 +1,8 @@
|
|
1
1
|
.base_1tcl212_bm1v11h__e2c572a3 .base_1tcl212_s10fscgc__e2c572a3{font-family:var(--plasma-switch-font-family);font-style:var(--plasma-switch-font-style);font-weight:var(--plasma-switch-font-weight);-webkit-letter-spacing:var(--plasma-switch-letter-spacing);-moz-letter-spacing:var(--plasma-switch-letter-spacing);-ms-letter-spacing:var(--plasma-switch-letter-spacing);letter-spacing:var(--plasma-switch-letter-spacing);line-height:var(--plasma-switch-line-height);font-size:var(--plasma-switch-font-size);}.base_1tcl212_bm1v11h__e2c572a3 .base_1tcl212_sdjnckq__e2c572a3{font-family:var(--plasma-switch-description-font-family);font-style:var(--plasma-switch-description-font-style);font-weight:var(--plasma-switch-description-font-weight);-webkit-letter-spacing:var(--plasma-switch-description-letter-spacing);-moz-letter-spacing:var(--plasma-switch-description-letter-spacing);-ms-letter-spacing:var(--plasma-switch-description-letter-spacing);letter-spacing:var(--plasma-switch-description-letter-spacing);line-height:var(--plasma-switch-description-line-height);font-size:var(--plasma-switch-description-font-size);}.base_1tcl212_bm1v11h__e2c572a3 .base_1tcl212_s1ilr5eq__e2c572a3{margin:var(--plasma_private-switch__label-offset,0);}
|
2
2
|
|
3
|
-
.
|
3
|
+
.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_s2cs3kf__301e5c69{box-sizing:border-box;-webkit-flex:0 0 var(--plasma-switch__track-width);-ms-flex:0 0 var(--plasma-switch__track-width);flex:0 0 var(--plasma-switch__track-width);border-style:solid;border-width:var(--plasma-switch__track_checked_false-border-width);border-radius:var(--plasma-switch__track-border-radius);width:var(--plasma-switch__track-width);height:var(--plasma-switch__track-height);}.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_s2cs3kf__301e5c69::after{width:var(--plasma-switch__thumb-size);height:var(--plasma-switch__thumb-size);border-radius:var(--plasma-switch__thumb-border-radius);margin:auto var(--plasma-switch__thumb_checked_false-offset);}.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_ssthlx1__301e5c69:checked ~ .base_1e2ou53_s2cs3kf__301e5c69{border-width:var(--plasma-switch__track_checked_true-border-width,var(--plasma-switch__track_checked_false-border-width));}.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_ssthlx1__301e5c69:checked ~ .base_1e2ou53_s2cs3kf__301e5c69::after{margin:auto var(--plasma-switch__thumb_checked_true-offset);}.base_1e2ou53_b1wld3h3__301e5c69:active:not([disabled]) .base_1e2ou53_s2cs3kf__301e5c69::after{width:calc(var(--plasma-switch__thumb-size) * var(--plasma-switch__thumb-scale,1));}
|
4
4
|
|
5
|
-
.
|
5
|
+
.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_s2cs3kf__f31e8aee{background-color:var(--plasma-switch__track_checked_false-bg-color);border-color:var(--plasma-switch__track_checked_false-border-color);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:not([disabled]) ~ .base_qbpw2g_s2cs3kf__f31e8aee:hover{background-color:var(--plasma-switch__track_checked_false_hovered_true-bg-color,var(--plasma-switch__track_checked_false-bg-color));border-color:var(--plasma-switch__track_checked_false_hovered_true-border-color,var(--plasma-switch__track_checked_false-border-color));}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:checked ~ .base_qbpw2g_s2cs3kf__f31e8aee{background-color:var(--plasma-switch__track_checked_true-bg-color);border-color:var(--plasma-switch__track_checked_true-border-color);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:checked:not([disabled]) ~ .base_qbpw2g_s2cs3kf__f31e8aee:hover{background-color:var(--plasma-switch__track_checked_true_hovered_true-bg-color,var(--plasma-switch__track_checked_true-bg-color));border-color:var(--plasma-switch__track_checked_true_hovered_true-border-color,var(--plasma-switch__track_checked_true-border-color));}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_s2cs3kf__f31e8aee::after{background-color:var(--plasma-switch__thumb_checked_false-bg-color);box-shadow:var(--plasma-switch__thumb-box-shadow);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:checked ~ .base_qbpw2g_s2cs3kf__f31e8aee::after{background-color:var(--plasma-switch__thumb_checked_true-bg-color);box-shadow:var(--plasma-switch__thumb-box-shadow_checked_true,var(--plasma-switch__thumb-box-shadow));}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_s1ilr5eq__f31e8aee{color:var(--plasma-switch__label-color);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_sdjnckq__f31e8aee{color:var(--plasma-switch__description-color);}
|
6
6
|
|
7
7
|
.base_sz3n0x_bvwxj2r__a36bed54 .base_sz3n0x_s2cs3kf__a36bed54::before{content:'';position:absolute;inset:-0.125rem;display:block;box-sizing:content-box;border-radius:calc(0.125rem + var(--plasma-switch__track-border-radius));border:0.125rem solid transparent;pointer-events:none;-webkit-transition:box-shadow 0.2s ease-in-out;transition:box-shadow 0.2s ease-in-out;}.base_sz3n0x_bvwxj2r__a36bed54 .base_sz3n0x_ssthlx1__a36bed54.base_sz3n0x_focusVisible__a36bed54 ~ .base_sz3n0x_s2cs3kf__a36bed54::before{box-shadow:0 0 0 0.125rem var(--plasma-switch__track-focus-color);}
|
8
8
|
|
@@ -27,11 +27,12 @@ var tokens = {
|
|
27
27
|
verticalGap: '--plasma-switch-vertical-gap',
|
28
28
|
trackWidth: '--plasma-switch__track-width',
|
29
29
|
trackHeight: '--plasma-switch__track-height',
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
30
|
+
trackBorderWidthOn: '--plasma-switch__track_checked_true-border-width',
|
31
|
+
trackBorderWidthOff: '--plasma-switch__track_checked_false-border-width',
|
32
|
+
trackBorderColorOn: '--plasma-switch__track_checked_true-border-color',
|
33
|
+
trackBorderColorOnHover: '--plasma-switch__track_checked_true_hovered_true-border-color',
|
34
|
+
trackBorderColorOff: '--plasma-switch__track_checked_false-border-color',
|
35
|
+
trackBorderColorOffHover: '--plasma-switch__track_checked_false_hovered_true-border-color',
|
35
36
|
trackBorderRadius: '--plasma-switch__track-border-radius',
|
36
37
|
// NOTE: could be intersection with checked
|
37
38
|
trackBackgroundColorOn: '--plasma-switch__track_checked_true-bg-color',
|
@@ -40,11 +41,12 @@ var tokens = {
|
|
40
41
|
trackBackgroundColorOffHover: '--plasma-switch__track_checked_false_hovered_true-bg-color',
|
41
42
|
trackFocusColor: '--plasma-switch__track-focus-color',
|
42
43
|
thumbSize: '--plasma-switch__thumb-size',
|
43
|
-
|
44
|
+
thumbOffsetOn: '--plasma-switch__thumb_checked_true-offset',
|
45
|
+
thumbOffsetOff: '--plasma-switch__thumb_checked_false-offset',
|
44
46
|
thumbBorderRadius: '--plasma-switch__thumb-border-radius',
|
45
47
|
thumbPressScale: '--plasma-switch__thumb-scale',
|
46
48
|
thumbBackgroundColorOn: '--plasma-switch__thumb_checked_true-bg-color',
|
47
|
-
thumbBackgroundColorOff: '--plasma-
|
49
|
+
thumbBackgroundColorOff: '--plasma-switch__thumb_checked_false-bg-color',
|
48
50
|
thumbBoxShadow: '--plasma-switch__thumb-box-shadow',
|
49
51
|
thumbBoxShadowOn: '--plasma-switch__thumb-box-shadow_checked_true',
|
50
52
|
labelOffsetPrivate: '--plasma_private-switch__label-offset'
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Switch.tokens.js","sources":["../../../src/components/Switch/Switch.tokens.ts"],"sourcesContent":["export const tokens = {\n fontFamily: '--plasma-switch-font-family',\n fontStyle: '--plasma-switch-font-style',\n fontSize: '--plasma-switch-font-size',\n fontWeight: '--plasma-switch-font-weight',\n letterSpacing: '--plasma-switch-letter-spacing',\n lineHeight: '--plasma-switch-line-height',\n\n /* Токены description */\n descriptionFontFamily: '--plasma-switch-description-font-family',\n descriptionFontStyle: '--plasma-switch-description-font-style',\n descriptionFontSize: '--plasma-switch-description-font-size',\n descriptionFontWeight: '--plasma-switch-description-font-weight',\n descriptionLetterSpacing: '--plasma-switch-description-letter-spacing',\n descriptionLineHeight: '--plasma-switch-description-line-height',\n\n /* Цвет подписи */\n labelColor: '--plasma-switch__label-color',\n labelOffset: '--plasma-switch__label-offset',\n\n /* Цвет описания */\n descriptionColor: '--plasma-switch__description-color',\n descriptionOffset: '--plasma-switch__description-offset',\n\n /** Прозрачность для всего компонента в состоянии disabled */\n disabledOpacity: '--plasma-switch-disabled-opacity',\n\n verticalGap: '--plasma-switch-vertical-gap',\n trackWidth: '--plasma-switch__track-width',\n trackHeight: '--plasma-switch__track-height',\n
|
1
|
+
{"version":3,"file":"Switch.tokens.js","sources":["../../../src/components/Switch/Switch.tokens.ts"],"sourcesContent":["export const tokens = {\n fontFamily: '--plasma-switch-font-family',\n fontStyle: '--plasma-switch-font-style',\n fontSize: '--plasma-switch-font-size',\n fontWeight: '--plasma-switch-font-weight',\n letterSpacing: '--plasma-switch-letter-spacing',\n lineHeight: '--plasma-switch-line-height',\n\n /* Токены description */\n descriptionFontFamily: '--plasma-switch-description-font-family',\n descriptionFontStyle: '--plasma-switch-description-font-style',\n descriptionFontSize: '--plasma-switch-description-font-size',\n descriptionFontWeight: '--plasma-switch-description-font-weight',\n descriptionLetterSpacing: '--plasma-switch-description-letter-spacing',\n descriptionLineHeight: '--plasma-switch-description-line-height',\n\n /* Цвет подписи */\n labelColor: '--plasma-switch__label-color',\n labelOffset: '--plasma-switch__label-offset',\n\n /* Цвет описания */\n descriptionColor: '--plasma-switch__description-color',\n descriptionOffset: '--plasma-switch__description-offset',\n\n /** Прозрачность для всего компонента в состоянии disabled */\n disabledOpacity: '--plasma-switch-disabled-opacity',\n\n verticalGap: '--plasma-switch-vertical-gap',\n trackWidth: '--plasma-switch__track-width',\n trackHeight: '--plasma-switch__track-height',\n trackBorderWidthOn: '--plasma-switch__track_checked_true-border-width',\n trackBorderWidthOff: '--plasma-switch__track_checked_false-border-width',\n trackBorderColorOn: '--plasma-switch__track_checked_true-border-color',\n trackBorderColorOnHover: '--plasma-switch__track_checked_true_hovered_true-border-color',\n trackBorderColorOff: '--plasma-switch__track_checked_false-border-color',\n trackBorderColorOffHover: '--plasma-switch__track_checked_false_hovered_true-border-color',\n\n trackBorderRadius: '--plasma-switch__track-border-radius',\n // NOTE: could be intersection with checked\n trackBackgroundColorOn: '--plasma-switch__track_checked_true-bg-color',\n trackBackgroundColorOnHover: '--plasma-switch__track_checked_true_hovered_true-bg-color',\n trackBackgroundColorOff: '--plasma-switch__track_checked_false-bg-color',\n trackBackgroundColorOffHover: '--plasma-switch__track_checked_false_hovered_true-bg-color',\n\n trackFocusColor: '--plasma-switch__track-focus-color',\n\n thumbSize: '--plasma-switch__thumb-size',\n thumbOffsetOn: '--plasma-switch__thumb_checked_true-offset',\n thumbOffsetOff: '--plasma-switch__thumb_checked_false-offset',\n thumbBorderRadius: '--plasma-switch__thumb-border-radius',\n\n thumbPressScale: '--plasma-switch__thumb-scale',\n\n thumbBackgroundColorOn: '--plasma-switch__thumb_checked_true-bg-color',\n thumbBackgroundColorOff: '--plasma-switch__thumb_checked_false-bg-color',\n thumbBoxShadow: '--plasma-switch__thumb-box-shadow',\n thumbBoxShadowOn: '--plasma-switch__thumb-box-shadow_checked_true',\n\n labelOffsetPrivate: '--plasma_private-switch__label-offset',\n};\n\nexport const classes = {\n beforeSwitchLabelPosition: 'switch-label-position-before',\n afterSwitchLabelPosition: 'switch-label-position-after',\n};\n"],"names":["tokens","fontFamily","fontStyle","fontSize","fontWeight","letterSpacing","lineHeight","descriptionFontFamily","descriptionFontStyle","descriptionFontSize","descriptionFontWeight","descriptionLetterSpacing","descriptionLineHeight","labelColor","labelOffset","descriptionColor","descriptionOffset","disabledOpacity","verticalGap","trackWidth","trackHeight","trackBorderWidthOn","trackBorderWidthOff","trackBorderColorOn","trackBorderColorOnHover","trackBorderColorOff","trackBorderColorOffHover","trackBorderRadius","trackBackgroundColorOn","trackBackgroundColorOnHover","trackBackgroundColorOff","trackBackgroundColorOffHover","trackFocusColor","thumbSize","thumbOffsetOn","thumbOffsetOff","thumbBorderRadius","thumbPressScale","thumbBackgroundColorOn","thumbBackgroundColorOff","thumbBoxShadow","thumbBoxShadowOn","labelOffsetPrivate","classes","beforeSwitchLabelPosition","afterSwitchLabelPosition"],"mappings":";;;;AAAO,IAAMA,MAAM,GAAG;AAClBC,EAAAA,UAAU,EAAE,6BAA6B;AACzCC,EAAAA,SAAS,EAAE,4BAA4B;AACv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6C;AAC7DC,EAAAA,iBAAiB,EAAE,sCAAsC;AAEzDC,EAAAA,eAAe,EAAE,8BAA8B;AAE/CC,EAAAA,sBAAsB,EAAE,8CAA8C;AACtEC,EAAAA,uBAAuB,EAAE,+CAA+C;AACxEC,EAAAA,cAAc,EAAE,mCAAmC;AACnDC,EAAAA,gBAAgB,EAAE,gDAAgD;AAElEC,EAAAA,kBAAkB,EAAE,uCAAA;AACxB,EAAC;AAEM,IAAMC,OAAO,GAAG;AACnBC,EAAAA,yBAAyB,EAAE,8BAA8B;AACzDC,EAAAA,wBAAwB,EAAE,6BAAA;AAC9B;;;;;"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"base.js","sources":["../../../../src/components/Switch/_toggleSize/base.ts"],"sourcesContent":["import { css } from '@linaria/core';\n\nimport { tokens } from '../Switch.tokens';\nimport { StyledTrigger } from '../Switch.styles';\n\nexport const base = css`\n ${StyledTrigger} {\n box-sizing: border-box;\n flex: 0 0 var(${tokens.trackWidth});\n\n border-style: solid;\n border-width: var(${tokens.
|
1
|
+
{"version":3,"file":"base.js","sources":["../../../../src/components/Switch/_toggleSize/base.ts"],"sourcesContent":["import { css } from '@linaria/core';\n\nimport { tokens } from '../Switch.tokens';\nimport { StyledInput, StyledTrigger } from '../Switch.styles';\n\nexport const base = css`\n ${StyledTrigger} {\n box-sizing: border-box;\n flex: 0 0 var(${tokens.trackWidth});\n\n border-style: solid;\n border-width: var(${tokens.trackBorderWidthOff});\n border-radius: var(${tokens.trackBorderRadius});\n\n width: var(${tokens.trackWidth});\n height: var(${tokens.trackHeight});\n\n &::after {\n width: var(${tokens.thumbSize});\n height: var(${tokens.thumbSize});\n border-radius: var(${tokens.thumbBorderRadius});\n margin: auto var(${tokens.thumbOffsetOff});\n }\n }\n\n ${StyledInput}:checked ~ ${StyledTrigger} {\n border-width: var(${tokens.trackBorderWidthOn}, var(${tokens.trackBorderWidthOff}));\n\n &::after {\n margin: auto var(${tokens.thumbOffsetOn});\n }\n }\n\n :active:not([disabled]) ${StyledTrigger}::after {\n width: calc(var(${tokens.thumbSize}) * var(${tokens.thumbPressScale}, 1));\n }\n`;\n"],"names":["base"],"mappings":";;;;AAKO,IAAMA,IAAI,GA+BhB;;;;"}
|
@@ -0,0 +1 @@
|
|
1
|
+
.b1wld3h3 .s2cs3kf{box-sizing:border-box;-webkit-flex:0 0 var(--plasma-switch__track-width);-ms-flex:0 0 var(--plasma-switch__track-width);flex:0 0 var(--plasma-switch__track-width);border-style:solid;border-width:var(--plasma-switch__track_checked_false-border-width);border-radius:var(--plasma-switch__track-border-radius);width:var(--plasma-switch__track-width);height:var(--plasma-switch__track-height);}.b1wld3h3 .s2cs3kf::after{width:var(--plasma-switch__thumb-size);height:var(--plasma-switch__thumb-size);border-radius:var(--plasma-switch__thumb-border-radius);margin:auto var(--plasma-switch__thumb_checked_false-offset);}.b1wld3h3 .ssthlx1:checked ~ .s2cs3kf{border-width:var(--plasma-switch__track_checked_true-border-width,var(--plasma-switch__track_checked_false-border-width));}.b1wld3h3 .ssthlx1:checked ~ .s2cs3kf::after{margin:auto var(--plasma-switch__thumb_checked_true-offset);}.b1wld3h3:active:not([disabled]) .s2cs3kf::after{width:calc(var(--plasma-switch__thumb-size) * var(--plasma-switch__thumb-scale,1));}
|
@@ -1 +1 @@
|
|
1
|
-
.b1g0jmh3 .s2cs3kf{background-color:var(--plasma-switch__track_checked_false-bg-color);border-color:var(--plasma-
|
1
|
+
.b1g0jmh3 .s2cs3kf{background-color:var(--plasma-switch__track_checked_false-bg-color);border-color:var(--plasma-switch__track_checked_false-border-color);}.b1g0jmh3 .ssthlx1:not([disabled]) ~ .s2cs3kf:hover{background-color:var(--plasma-switch__track_checked_false_hovered_true-bg-color,var(--plasma-switch__track_checked_false-bg-color));border-color:var(--plasma-switch__track_checked_false_hovered_true-border-color,var(--plasma-switch__track_checked_false-border-color));}.b1g0jmh3 .ssthlx1:checked ~ .s2cs3kf{background-color:var(--plasma-switch__track_checked_true-bg-color);border-color:var(--plasma-switch__track_checked_true-border-color);}.b1g0jmh3 .ssthlx1:checked:not([disabled]) ~ .s2cs3kf:hover{background-color:var(--plasma-switch__track_checked_true_hovered_true-bg-color,var(--plasma-switch__track_checked_true-bg-color));border-color:var(--plasma-switch__track_checked_true_hovered_true-border-color,var(--plasma-switch__track_checked_true-border-color));}.b1g0jmh3 .s2cs3kf::after{background-color:var(--plasma-switch__thumb_checked_false-bg-color);box-shadow:var(--plasma-switch__thumb-box-shadow);}.b1g0jmh3 .ssthlx1:checked ~ .s2cs3kf::after{background-color:var(--plasma-switch__thumb_checked_true-bg-color);box-shadow:var(--plasma-switch__thumb-box-shadow_checked_true,var(--plasma-switch__thumb-box-shadow));}.b1g0jmh3 .s1ilr5eq{color:var(--plasma-switch__label-color);}.b1g0jmh3 .sdjnckq{color:var(--plasma-switch__description-color);}
|
package/cjs/index.css
CHANGED
@@ -216,9 +216,9 @@
|
|
216
216
|
|
217
217
|
.base_1tcl212_bm1v11h__e2c572a3 .base_1tcl212_s10fscgc__e2c572a3{font-family:var(--plasma-switch-font-family);font-style:var(--plasma-switch-font-style);font-weight:var(--plasma-switch-font-weight);-webkit-letter-spacing:var(--plasma-switch-letter-spacing);-moz-letter-spacing:var(--plasma-switch-letter-spacing);-ms-letter-spacing:var(--plasma-switch-letter-spacing);letter-spacing:var(--plasma-switch-letter-spacing);line-height:var(--plasma-switch-line-height);font-size:var(--plasma-switch-font-size);}.base_1tcl212_bm1v11h__e2c572a3 .base_1tcl212_sdjnckq__e2c572a3{font-family:var(--plasma-switch-description-font-family);font-style:var(--plasma-switch-description-font-style);font-weight:var(--plasma-switch-description-font-weight);-webkit-letter-spacing:var(--plasma-switch-description-letter-spacing);-moz-letter-spacing:var(--plasma-switch-description-letter-spacing);-ms-letter-spacing:var(--plasma-switch-description-letter-spacing);letter-spacing:var(--plasma-switch-description-letter-spacing);line-height:var(--plasma-switch-description-line-height);font-size:var(--plasma-switch-description-font-size);}.base_1tcl212_bm1v11h__e2c572a3 .base_1tcl212_s1ilr5eq__e2c572a3{margin:var(--plasma_private-switch__label-offset,0);}
|
218
218
|
|
219
|
-
.
|
219
|
+
.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_s2cs3kf__301e5c69{box-sizing:border-box;-webkit-flex:0 0 var(--plasma-switch__track-width);-ms-flex:0 0 var(--plasma-switch__track-width);flex:0 0 var(--plasma-switch__track-width);border-style:solid;border-width:var(--plasma-switch__track_checked_false-border-width);border-radius:var(--plasma-switch__track-border-radius);width:var(--plasma-switch__track-width);height:var(--plasma-switch__track-height);}.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_s2cs3kf__301e5c69::after{width:var(--plasma-switch__thumb-size);height:var(--plasma-switch__thumb-size);border-radius:var(--plasma-switch__thumb-border-radius);margin:auto var(--plasma-switch__thumb_checked_false-offset);}.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_ssthlx1__301e5c69:checked ~ .base_1e2ou53_s2cs3kf__301e5c69{border-width:var(--plasma-switch__track_checked_true-border-width,var(--plasma-switch__track_checked_false-border-width));}.base_1e2ou53_b1wld3h3__301e5c69 .base_1e2ou53_ssthlx1__301e5c69:checked ~ .base_1e2ou53_s2cs3kf__301e5c69::after{margin:auto var(--plasma-switch__thumb_checked_true-offset);}.base_1e2ou53_b1wld3h3__301e5c69:active:not([disabled]) .base_1e2ou53_s2cs3kf__301e5c69::after{width:calc(var(--plasma-switch__thumb-size) * var(--plasma-switch__thumb-scale,1));}
|
220
220
|
|
221
|
-
.
|
221
|
+
.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_s2cs3kf__f31e8aee{background-color:var(--plasma-switch__track_checked_false-bg-color);border-color:var(--plasma-switch__track_checked_false-border-color);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:not([disabled]) ~ .base_qbpw2g_s2cs3kf__f31e8aee:hover{background-color:var(--plasma-switch__track_checked_false_hovered_true-bg-color,var(--plasma-switch__track_checked_false-bg-color));border-color:var(--plasma-switch__track_checked_false_hovered_true-border-color,var(--plasma-switch__track_checked_false-border-color));}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:checked ~ .base_qbpw2g_s2cs3kf__f31e8aee{background-color:var(--plasma-switch__track_checked_true-bg-color);border-color:var(--plasma-switch__track_checked_true-border-color);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:checked:not([disabled]) ~ .base_qbpw2g_s2cs3kf__f31e8aee:hover{background-color:var(--plasma-switch__track_checked_true_hovered_true-bg-color,var(--plasma-switch__track_checked_true-bg-color));border-color:var(--plasma-switch__track_checked_true_hovered_true-border-color,var(--plasma-switch__track_checked_true-border-color));}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_s2cs3kf__f31e8aee::after{background-color:var(--plasma-switch__thumb_checked_false-bg-color);box-shadow:var(--plasma-switch__thumb-box-shadow);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_ssthlx1__f31e8aee:checked ~ .base_qbpw2g_s2cs3kf__f31e8aee::after{background-color:var(--plasma-switch__thumb_checked_true-bg-color);box-shadow:var(--plasma-switch__thumb-box-shadow_checked_true,var(--plasma-switch__thumb-box-shadow));}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_s1ilr5eq__f31e8aee{color:var(--plasma-switch__label-color);}.base_qbpw2g_b1g0jmh3__f31e8aee .base_qbpw2g_sdjnckq__f31e8aee{color:var(--plasma-switch__description-color);}
|
222
222
|
|
223
223
|
.base_sz3n0x_bvwxj2r__a36bed54 .base_sz3n0x_s2cs3kf__a36bed54::before{content:'';position:absolute;inset:-0.125rem;display:block;box-sizing:content-box;border-radius:calc(0.125rem + var(--plasma-switch__track-border-radius));border:0.125rem solid transparent;pointer-events:none;-webkit-transition:box-shadow 0.2s ease-in-out;transition:box-shadow 0.2s ease-in-out;}.base_sz3n0x_bvwxj2r__a36bed54 .base_sz3n0x_ssthlx1__a36bed54.base_sz3n0x_focusVisible__a36bed54 ~ .base_sz3n0x_s2cs3kf__a36bed54::before{box-shadow:0 0 0 0.125rem var(--plasma-switch__track-focus-color);}
|
224
224
|
|
@@ -29,11 +29,12 @@ var tokens = exports.tokens = {
|
|
29
29
|
verticalGap: '--plasma-switch-vertical-gap',
|
30
30
|
trackWidth: '--plasma-switch__track-width',
|
31
31
|
trackHeight: '--plasma-switch__track-height',
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
32
|
+
trackBorderWidthOn: '--plasma-switch__track_checked_true-border-width',
|
33
|
+
trackBorderWidthOff: '--plasma-switch__track_checked_false-border-width',
|
34
|
+
trackBorderColorOn: '--plasma-switch__track_checked_true-border-color',
|
35
|
+
trackBorderColorOnHover: '--plasma-switch__track_checked_true_hovered_true-border-color',
|
36
|
+
trackBorderColorOff: '--plasma-switch__track_checked_false-border-color',
|
37
|
+
trackBorderColorOffHover: '--plasma-switch__track_checked_false_hovered_true-border-color',
|
37
38
|
trackBorderRadius: '--plasma-switch__track-border-radius',
|
38
39
|
// NOTE: could be intersection with checked
|
39
40
|
trackBackgroundColorOn: '--plasma-switch__track_checked_true-bg-color',
|
@@ -42,11 +43,12 @@ var tokens = exports.tokens = {
|
|
42
43
|
trackBackgroundColorOffHover: '--plasma-switch__track_checked_false_hovered_true-bg-color',
|
43
44
|
trackFocusColor: '--plasma-switch__track-focus-color',
|
44
45
|
thumbSize: '--plasma-switch__thumb-size',
|
45
|
-
|
46
|
+
thumbOffsetOn: '--plasma-switch__thumb_checked_true-offset',
|
47
|
+
thumbOffsetOff: '--plasma-switch__thumb_checked_false-offset',
|
46
48
|
thumbBorderRadius: '--plasma-switch__thumb-border-radius',
|
47
49
|
thumbPressScale: '--plasma-switch__thumb-scale',
|
48
50
|
thumbBackgroundColorOn: '--plasma-switch__thumb_checked_true-bg-color',
|
49
|
-
thumbBackgroundColorOff: '--plasma-
|
51
|
+
thumbBackgroundColorOff: '--plasma-switch__thumb_checked_false-bg-color',
|
50
52
|
thumbBoxShadow: '--plasma-switch__thumb-box-shadow',
|
51
53
|
thumbBoxShadowOn: '--plasma-switch__thumb-box-shadow_checked_true',
|
52
54
|
labelOffsetPrivate: '--plasma_private-switch__label-offset'
|
@@ -7,4 +7,4 @@ exports.base = void 0;
|
|
7
7
|
var _react = /*#__PURE__*/require("@emotion/react");
|
8
8
|
var _Switch = /*#__PURE__*/require("../Switch.tokens");
|
9
9
|
var _Switch2 = /*#__PURE__*/require("../Switch.styles");
|
10
|
-
var base = exports.base = /*#__PURE__*/(0, _react.css)(_Switch2.StyledTrigger, "{box-sizing:border-box;flex:0 0 var(", _Switch.tokens.trackWidth, ");border-style:solid;border-width:var(", _Switch.tokens.
|
10
|
+
var base = exports.base = /*#__PURE__*/(0, _react.css)(_Switch2.StyledTrigger, "{box-sizing:border-box;flex:0 0 var(", _Switch.tokens.trackWidth, ");border-style:solid;border-width:var(", _Switch.tokens.trackBorderWidthOff, ");border-radius:var(", _Switch.tokens.trackBorderRadius, ");width:var(", _Switch.tokens.trackWidth, ");height:var(", _Switch.tokens.trackHeight, ");&::after{width:var(", _Switch.tokens.thumbSize, ");height:var(", _Switch.tokens.thumbSize, ");border-radius:var(", _Switch.tokens.thumbBorderRadius, ");margin:auto var(", _Switch.tokens.thumbOffsetOff, ");}}", _Switch2.StyledInput, ":checked~", _Switch2.StyledTrigger, "{border-width:var(", _Switch.tokens.trackBorderWidthOn, ", var(", _Switch.tokens.trackBorderWidthOff, "));&::after{margin:auto var(", _Switch.tokens.thumbOffsetOn, ");}}:active:not([disabled]) ", _Switch2.StyledTrigger, "::after{width:calc(var(", _Switch.tokens.thumbSize, ") * var(", _Switch.tokens.thumbPressScale, ", 1));};label:plasma-new-hope__base;" + (process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3NyYy1lbW90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