@khanacademy/wonder-blocks-switch 3.3.34 → 3.4.1
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/.turbo/turbo-build$colon$css.log +1 -1
- package/CHANGELOG.md +26 -0
- package/dist/css/vars.css +14 -10
- package/dist/es/index.js +2 -2
- package/dist/index.js +2 -2
- package/dist/theme/default.d.ts +0 -8
- package/dist/theme/index.d.ts +0 -8
- package/dist/theme/syl-dark.d.ts +32 -0
- package/dist/theme/thunderblocks.d.ts +0 -8
- package/package.json +6 -6
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @khanacademy/wonder-blocks-switch@3.
|
|
2
|
+
> @khanacademy/wonder-blocks-switch@3.4.1 build:css /home/runner/work/wonder-blocks/wonder-blocks/packages/wonder-blocks-switch
|
|
3
3
|
> pnpm exec wonder-blocks-tokens .
|
|
4
4
|
|
|
5
5
|
CSS variables generated successfully in: /home/runner/work/wonder-blocks/wonder-blocks/packages/wonder-blocks-switch/dist/css
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,31 @@
|
|
|
1
1
|
# @khanacademy/wonder-blocks-switch
|
|
2
2
|
|
|
3
|
+
## 3.4.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 40cb70f: Add `require-logical-properties-for-rtl` ESLint rule to `eslint-plugin-wonder-blocks` recommended config, and migrate all Wonder Blocks component source files to use CSS logical properties for improved RTL layout support.
|
|
8
|
+
- 40cb70f: Enable RTL logical-properties ESLint rule in recommended config
|
|
9
|
+
- Updated dependencies [40cb70f]
|
|
10
|
+
- Updated dependencies [40cb70f]
|
|
11
|
+
- @khanacademy/wonder-blocks-core@12.4.4
|
|
12
|
+
- @khanacademy/wonder-blocks-icon@5.3.15
|
|
13
|
+
|
|
14
|
+
## 3.4.0
|
|
15
|
+
|
|
16
|
+
### Minor Changes
|
|
17
|
+
|
|
18
|
+
- 27a211d: Add support for SYL Dark theme
|
|
19
|
+
|
|
20
|
+
### Patch Changes
|
|
21
|
+
|
|
22
|
+
- Updated dependencies [44bde5e]
|
|
23
|
+
- Updated dependencies [27a211d]
|
|
24
|
+
- @khanacademy/wonder-blocks-tokens@16.5.0
|
|
25
|
+
- @khanacademy/wonder-blocks-theming@4.1.0
|
|
26
|
+
- @khanacademy/wonder-blocks-icon@5.3.14
|
|
27
|
+
- @khanacademy/wonder-blocks-styles@0.2.45
|
|
28
|
+
|
|
3
29
|
## 3.3.34
|
|
4
30
|
|
|
5
31
|
### Patch Changes
|
package/dist/css/vars.css
CHANGED
|
@@ -7,12 +7,20 @@
|
|
|
7
7
|
--wb-c-switch-slider-sizing-width: var(--wb-sizing-size_200);
|
|
8
8
|
--wb-c-switch-slider-position-top: var(--wb-sizing-size_020);
|
|
9
9
|
--wb-c-switch-slider-position-left: var(--wb-sizing-size_020);
|
|
10
|
-
--wb-c-switch-slider-transform-default: translateX(var(--wb-sizing-size_160));
|
|
11
|
-
--wb-c-switch-slider-transform-transition: transform 0.15s ease-in-out;
|
|
12
10
|
--wb-c-switch-icon-position-top: var(--wb-sizing-size_040);
|
|
13
|
-
--wb-c-switch-icon-position-left: var(--wb-sizing-size_040);
|
|
14
|
-
|
|
15
|
-
--wb-c-switch-
|
|
11
|
+
--wb-c-switch-icon-position-left: var(--wb-sizing-size_040);}
|
|
12
|
+
|
|
13
|
+
[data-wb-theme='syl-dark'] {--wb-c-switch-root-border-radius-default: var(--wb-border-radius-radius_240);
|
|
14
|
+
--wb-c-switch-root-border-radius-hover: var(--wb-border-radius-radius_120);
|
|
15
|
+
--wb-c-switch-root-border-radius-press: var(--wb-border-radius-radius_120);
|
|
16
|
+
--wb-c-switch-root-sizing-height: var(--wb-sizing-size_240);
|
|
17
|
+
--wb-c-switch-root-sizing-width: var(--wb-sizing-size_440);
|
|
18
|
+
--wb-c-switch-slider-sizing-height: var(--wb-sizing-size_200);
|
|
19
|
+
--wb-c-switch-slider-sizing-width: var(--wb-sizing-size_200);
|
|
20
|
+
--wb-c-switch-slider-position-top: var(--wb-sizing-size_020);
|
|
21
|
+
--wb-c-switch-slider-position-left: var(--wb-sizing-size_020);
|
|
22
|
+
--wb-c-switch-icon-position-top: var(--wb-sizing-size_040);
|
|
23
|
+
--wb-c-switch-icon-position-left: var(--wb-sizing-size_040);}
|
|
16
24
|
|
|
17
25
|
[data-wb-theme='thunderblocks'] {--wb-c-switch-root-border-radius-default: var(--wb-border-radius-radius_240);
|
|
18
26
|
--wb-c-switch-root-border-radius-hover: var(--wb-border-radius-radius_120);
|
|
@@ -23,9 +31,5 @@
|
|
|
23
31
|
--wb-c-switch-slider-sizing-width: var(--wb-sizing-size_200);
|
|
24
32
|
--wb-c-switch-slider-position-top: var(--wb-sizing-size_020);
|
|
25
33
|
--wb-c-switch-slider-position-left: var(--wb-sizing-size_020);
|
|
26
|
-
--wb-c-switch-slider-transform-default: translateX(var(--wb-sizing-size_200));
|
|
27
|
-
--wb-c-switch-slider-transform-transition: transform 0.15s ease-in-out;
|
|
28
34
|
--wb-c-switch-icon-position-top: var(--wb-sizing-size_040);
|
|
29
|
-
--wb-c-switch-icon-position-left: var(--wb-sizing-size_040);
|
|
30
|
-
--wb-c-switch-icon-transform-default: translateX(var(--wb-sizing-size_200));
|
|
31
|
-
--wb-c-switch-icon-transform-transition: transform 0.15s ease-in-out;}
|
|
35
|
+
--wb-c-switch-icon-position-left: var(--wb-sizing-size_040);}
|
package/dist/es/index.js
CHANGED
|
@@ -6,10 +6,10 @@ import { addStyle, View } from '@khanacademy/wonder-blocks-core';
|
|
|
6
6
|
import { border, sizing, mapValuesToCssVars, semanticColor } from '@khanacademy/wonder-blocks-tokens';
|
|
7
7
|
import { focusStyles } from '@khanacademy/wonder-blocks-styles';
|
|
8
8
|
|
|
9
|
-
var themeDefault = {root:{border:{radius:{default:border.radius.radius_120,hover:border.radius.radius_120,press:border.radius.radius_120}},sizing:{height:sizing.size_240,width:sizing.size_400}},slider:{sizing:{height:sizing.size_200,width:sizing.size_200},position:{top:sizing.size_020,left:sizing.size_020}
|
|
9
|
+
var themeDefault = {root:{border:{radius:{default:border.radius.radius_120,hover:border.radius.radius_120,press:border.radius.radius_120}},sizing:{height:sizing.size_240,width:sizing.size_400}},slider:{sizing:{height:sizing.size_200,width:sizing.size_200},position:{top:sizing.size_020,left:sizing.size_020}},icon:{position:{top:sizing.size_040,left:sizing.size_040}}};
|
|
10
10
|
|
|
11
11
|
var theme = mapValuesToCssVars(themeDefault,"--wb-c-switch-");
|
|
12
12
|
|
|
13
|
-
const StyledSpan=addStyle("span");const StyledInput=addStyle("input");const focusStylesObject=focusStyles.focus[":focus-visible"];const baseStyles={color:{bg:{switch:{off:semanticColor.core.border.neutral.default,disabledOff:semanticColor.core.border.disabled.strong,activeOff:semanticColor.core.border.neutral.strong,on:semanticColor.core.background.instructive.default,disabledOn:semanticColor.core.border.instructive.subtle,activeOn:semanticColor.core.background.instructive.strong},slider:{on:semanticColor.core.foreground.knockout.default,off:semanticColor.core.foreground.knockout.default},icon:{on:semanticColor.core.foreground.instructive.default,disabledOn:semanticColor.core.border.instructive.subtle,off:semanticColor.core.border.neutral.default,disabledOff:semanticColor.core.foreground.disabled.default}}}};const sharedStyles=StyleSheet.create({hidden:{opacity:0,height:0,width:0},switch:{display:"inline-flex",height:theme.root.sizing.height,width:theme.root.sizing.width,borderRadius:theme.root.border.radius.default,flexShrink:0},switchFocus:{":focus-within":focusStylesObject},disabled:{cursor:"not-allowed",":hover":{outline:"none"},":active":{outline:"none"}},disabledFocus:{":focus-within":focusStylesObject},slider:{position:"absolute",
|
|
13
|
+
const StyledSpan=addStyle("span");const StyledInput=addStyle("input");const focusStylesObject=focusStyles.focus[":focus-visible"];const baseStyles={color:{bg:{switch:{off:semanticColor.core.border.neutral.default,disabledOff:semanticColor.core.border.disabled.strong,activeOff:semanticColor.core.border.neutral.strong,on:semanticColor.core.background.instructive.default,disabledOn:semanticColor.core.border.instructive.subtle,activeOn:semanticColor.core.background.instructive.strong},slider:{on:semanticColor.core.foreground.knockout.default,off:semanticColor.core.foreground.knockout.default},icon:{on:semanticColor.core.foreground.instructive.default,disabledOn:semanticColor.core.border.instructive.subtle,off:semanticColor.core.border.neutral.default,disabledOff:semanticColor.core.foreground.disabled.default}}}};const sharedStyles=StyleSheet.create({hidden:{opacity:0,height:0,width:0},switch:{display:"inline-flex",height:theme.root.sizing.height,width:theme.root.sizing.width,borderRadius:theme.root.border.radius.default,flexShrink:0},switchFocus:{":focus-within":focusStylesObject},disabled:{cursor:"not-allowed",":hover":{outline:"none"},":active":{outline:"none"}},disabledFocus:{":focus-within":focusStylesObject},slider:{position:"absolute",insetBlockStart:theme.slider.position.top,insetInlineStart:theme.slider.position.left,height:theme.slider.sizing.height,width:theme.slider.sizing.width,borderRadius:theme.root.border.radius.default,backgroundColor:baseStyles.color.bg.slider.on,transition:"inset-inline-start 0.15s ease-in-out"},icon:{position:"absolute",insetBlockStart:theme.icon.position.top,insetInlineStart:theme.icon.position.left,zIndex:1,transition:"inset-inline-start 0.15s ease-in-out"}});const Switch=React.forwardRef(function Switch(props,ref){const{"aria-label":ariaLabel,"aria-labelledby":ariaLabelledBy,"aria-describedby":ariaDescribedBy,checked,className,disabled=false,icon,id,onChange,testId}=props;const generatedUniqueId=useId();const uniqueId=id??generatedUniqueId;const handleClick=()=>{if(!disabled&&onChange){onChange(!checked);}};const handleChange=()=>{};const stateStyles=_generateStyles(checked,onChange!==undefined,disabled);const combinedStyles=[sharedStyles.switch,sharedStyles.switchFocus,stateStyles.switch,disabled&&sharedStyles.disabled,disabled&&sharedStyles.disabledFocus];let styledIcon;if(icon){styledIcon=React.cloneElement(icon,{size:"small",style:[sharedStyles.icon,stateStyles.icon],"aria-hidden":true});}return jsxs(View,{onClick:handleClick,style:combinedStyles,className:className,testId:testId,children:[jsx(StyledInput,{"aria-describedby":ariaDescribedBy,"aria-label":ariaLabel,"aria-labelledby":ariaLabelledBy,checked:checked,"aria-disabled":disabled,id:uniqueId,onChange:handleChange,ref:ref,role:"switch",style:sharedStyles.hidden,type:"checkbox"}),icon&&styledIcon,jsx(StyledSpan,{style:[sharedStyles.slider,stateStyles.slider]})]})});const styles={};const _generateStyles=(checked,clickable,disabled)=>{const checkedStyle=`${checked}-${clickable}-${disabled}`;if(styles[checkedStyle]){return styles[checkedStyle]}let newStyles={};const sharedSwitchStyles={cursor:clickable?"pointer":"auto",":hover":{...focusStylesObject,outline:clickable?focusStylesObject.outline:"none"}};if(checked){newStyles={switch:{backgroundColor:disabled?baseStyles.color.bg.switch.disabledOn:baseStyles.color.bg.switch.on,":active":{backgroundColor:!disabled&&clickable?baseStyles.color.bg.switch.activeOn:undefined,...focusStylesObject,outline:clickable?focusStylesObject.outline:"none"},...sharedSwitchStyles},slider:{insetInlineStart:`calc(100% - ${sizing.size_200} - ${sizing.size_020})`},icon:{color:disabled?baseStyles.color.bg.icon.disabledOn:baseStyles.color.bg.icon.on,insetInlineStart:`calc(100% - ${sizing.size_160} - ${sizing.size_040})`}};}else {newStyles={switch:{backgroundColor:disabled?baseStyles.color.bg.switch.disabledOff:baseStyles.color.bg.switch.off,":active":{backgroundColor:!disabled&&clickable?baseStyles.color.bg.switch.activeOff:undefined,...focusStylesObject,outline:clickable?focusStylesObject.outline:"none"},...sharedSwitchStyles},slider:{backgroundColor:baseStyles.color.bg.slider.off},icon:{color:disabled?baseStyles.color.bg.icon.disabledOff:baseStyles.color.bg.icon.off}};}styles[checkedStyle]=StyleSheet.create(newStyles);return styles[checkedStyle]};
|
|
14
14
|
|
|
15
15
|
export { Switch as default };
|
package/dist/index.js
CHANGED
|
@@ -27,10 +27,10 @@ function _interopNamespace(e) {
|
|
|
27
27
|
|
|
28
28
|
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
29
29
|
|
|
30
|
-
var themeDefault = {root:{border:{radius:{default:wonderBlocksTokens.border.radius.radius_120,hover:wonderBlocksTokens.border.radius.radius_120,press:wonderBlocksTokens.border.radius.radius_120}},sizing:{height:wonderBlocksTokens.sizing.size_240,width:wonderBlocksTokens.sizing.size_400}},slider:{sizing:{height:wonderBlocksTokens.sizing.size_200,width:wonderBlocksTokens.sizing.size_200},position:{top:wonderBlocksTokens.sizing.size_020,left:wonderBlocksTokens.sizing.size_020}
|
|
30
|
+
var themeDefault = {root:{border:{radius:{default:wonderBlocksTokens.border.radius.radius_120,hover:wonderBlocksTokens.border.radius.radius_120,press:wonderBlocksTokens.border.radius.radius_120}},sizing:{height:wonderBlocksTokens.sizing.size_240,width:wonderBlocksTokens.sizing.size_400}},slider:{sizing:{height:wonderBlocksTokens.sizing.size_200,width:wonderBlocksTokens.sizing.size_200},position:{top:wonderBlocksTokens.sizing.size_020,left:wonderBlocksTokens.sizing.size_020}},icon:{position:{top:wonderBlocksTokens.sizing.size_040,left:wonderBlocksTokens.sizing.size_040}}};
|
|
31
31
|
|
|
32
32
|
var theme = wonderBlocksTokens.mapValuesToCssVars(themeDefault,"--wb-c-switch-");
|
|
33
33
|
|
|
34
|
-
const StyledSpan=wonderBlocksCore.addStyle("span");const StyledInput=wonderBlocksCore.addStyle("input");const focusStylesObject=wonderBlocksStyles.focusStyles.focus[":focus-visible"];const baseStyles={color:{bg:{switch:{off:wonderBlocksTokens.semanticColor.core.border.neutral.default,disabledOff:wonderBlocksTokens.semanticColor.core.border.disabled.strong,activeOff:wonderBlocksTokens.semanticColor.core.border.neutral.strong,on:wonderBlocksTokens.semanticColor.core.background.instructive.default,disabledOn:wonderBlocksTokens.semanticColor.core.border.instructive.subtle,activeOn:wonderBlocksTokens.semanticColor.core.background.instructive.strong},slider:{on:wonderBlocksTokens.semanticColor.core.foreground.knockout.default,off:wonderBlocksTokens.semanticColor.core.foreground.knockout.default},icon:{on:wonderBlocksTokens.semanticColor.core.foreground.instructive.default,disabledOn:wonderBlocksTokens.semanticColor.core.border.instructive.subtle,off:wonderBlocksTokens.semanticColor.core.border.neutral.default,disabledOff:wonderBlocksTokens.semanticColor.core.foreground.disabled.default}}}};const sharedStyles=aphrodite.StyleSheet.create({hidden:{opacity:0,height:0,width:0},switch:{display:"inline-flex",height:theme.root.sizing.height,width:theme.root.sizing.width,borderRadius:theme.root.border.radius.default,flexShrink:0},switchFocus:{":focus-within":focusStylesObject},disabled:{cursor:"not-allowed",":hover":{outline:"none"},":active":{outline:"none"}},disabledFocus:{":focus-within":focusStylesObject},slider:{position:"absolute",
|
|
34
|
+
const StyledSpan=wonderBlocksCore.addStyle("span");const StyledInput=wonderBlocksCore.addStyle("input");const focusStylesObject=wonderBlocksStyles.focusStyles.focus[":focus-visible"];const baseStyles={color:{bg:{switch:{off:wonderBlocksTokens.semanticColor.core.border.neutral.default,disabledOff:wonderBlocksTokens.semanticColor.core.border.disabled.strong,activeOff:wonderBlocksTokens.semanticColor.core.border.neutral.strong,on:wonderBlocksTokens.semanticColor.core.background.instructive.default,disabledOn:wonderBlocksTokens.semanticColor.core.border.instructive.subtle,activeOn:wonderBlocksTokens.semanticColor.core.background.instructive.strong},slider:{on:wonderBlocksTokens.semanticColor.core.foreground.knockout.default,off:wonderBlocksTokens.semanticColor.core.foreground.knockout.default},icon:{on:wonderBlocksTokens.semanticColor.core.foreground.instructive.default,disabledOn:wonderBlocksTokens.semanticColor.core.border.instructive.subtle,off:wonderBlocksTokens.semanticColor.core.border.neutral.default,disabledOff:wonderBlocksTokens.semanticColor.core.foreground.disabled.default}}}};const sharedStyles=aphrodite.StyleSheet.create({hidden:{opacity:0,height:0,width:0},switch:{display:"inline-flex",height:theme.root.sizing.height,width:theme.root.sizing.width,borderRadius:theme.root.border.radius.default,flexShrink:0},switchFocus:{":focus-within":focusStylesObject},disabled:{cursor:"not-allowed",":hover":{outline:"none"},":active":{outline:"none"}},disabledFocus:{":focus-within":focusStylesObject},slider:{position:"absolute",insetBlockStart:theme.slider.position.top,insetInlineStart:theme.slider.position.left,height:theme.slider.sizing.height,width:theme.slider.sizing.width,borderRadius:theme.root.border.radius.default,backgroundColor:baseStyles.color.bg.slider.on,transition:"inset-inline-start 0.15s ease-in-out"},icon:{position:"absolute",insetBlockStart:theme.icon.position.top,insetInlineStart:theme.icon.position.left,zIndex:1,transition:"inset-inline-start 0.15s ease-in-out"}});const Switch=React__namespace.forwardRef(function Switch(props,ref){const{"aria-label":ariaLabel,"aria-labelledby":ariaLabelledBy,"aria-describedby":ariaDescribedBy,checked,className,disabled=false,icon,id,onChange,testId}=props;const generatedUniqueId=React.useId();const uniqueId=id??generatedUniqueId;const handleClick=()=>{if(!disabled&&onChange){onChange(!checked);}};const handleChange=()=>{};const stateStyles=_generateStyles(checked,onChange!==undefined,disabled);const combinedStyles=[sharedStyles.switch,sharedStyles.switchFocus,stateStyles.switch,disabled&&sharedStyles.disabled,disabled&&sharedStyles.disabledFocus];let styledIcon;if(icon){styledIcon=React__namespace.cloneElement(icon,{size:"small",style:[sharedStyles.icon,stateStyles.icon],"aria-hidden":true});}return jsxRuntime.jsxs(wonderBlocksCore.View,{onClick:handleClick,style:combinedStyles,className:className,testId:testId,children:[jsxRuntime.jsx(StyledInput,{"aria-describedby":ariaDescribedBy,"aria-label":ariaLabel,"aria-labelledby":ariaLabelledBy,checked:checked,"aria-disabled":disabled,id:uniqueId,onChange:handleChange,ref:ref,role:"switch",style:sharedStyles.hidden,type:"checkbox"}),icon&&styledIcon,jsxRuntime.jsx(StyledSpan,{style:[sharedStyles.slider,stateStyles.slider]})]})});const styles={};const _generateStyles=(checked,clickable,disabled)=>{const checkedStyle=`${checked}-${clickable}-${disabled}`;if(styles[checkedStyle]){return styles[checkedStyle]}let newStyles={};const sharedSwitchStyles={cursor:clickable?"pointer":"auto",":hover":{...focusStylesObject,outline:clickable?focusStylesObject.outline:"none"}};if(checked){newStyles={switch:{backgroundColor:disabled?baseStyles.color.bg.switch.disabledOn:baseStyles.color.bg.switch.on,":active":{backgroundColor:!disabled&&clickable?baseStyles.color.bg.switch.activeOn:undefined,...focusStylesObject,outline:clickable?focusStylesObject.outline:"none"},...sharedSwitchStyles},slider:{insetInlineStart:`calc(100% - ${wonderBlocksTokens.sizing.size_200} - ${wonderBlocksTokens.sizing.size_020})`},icon:{color:disabled?baseStyles.color.bg.icon.disabledOn:baseStyles.color.bg.icon.on,insetInlineStart:`calc(100% - ${wonderBlocksTokens.sizing.size_160} - ${wonderBlocksTokens.sizing.size_040})`}};}else {newStyles={switch:{backgroundColor:disabled?baseStyles.color.bg.switch.disabledOff:baseStyles.color.bg.switch.off,":active":{backgroundColor:!disabled&&clickable?baseStyles.color.bg.switch.activeOff:undefined,...focusStylesObject,outline:clickable?focusStylesObject.outline:"none"},...sharedSwitchStyles},slider:{backgroundColor:baseStyles.color.bg.slider.off},icon:{color:disabled?baseStyles.color.bg.icon.disabledOff:baseStyles.color.bg.icon.off}};}styles[checkedStyle]=aphrodite.StyleSheet.create(newStyles);return styles[checkedStyle]};
|
|
35
35
|
|
|
36
36
|
module.exports = Switch;
|
package/dist/theme/default.d.ts
CHANGED
|
@@ -21,20 +21,12 @@ declare const _default: {
|
|
|
21
21
|
top: string;
|
|
22
22
|
left: string;
|
|
23
23
|
};
|
|
24
|
-
transform: {
|
|
25
|
-
default: string;
|
|
26
|
-
transition: string;
|
|
27
|
-
};
|
|
28
24
|
};
|
|
29
25
|
icon: {
|
|
30
26
|
position: {
|
|
31
27
|
top: string;
|
|
32
28
|
left: string;
|
|
33
29
|
};
|
|
34
|
-
transform: {
|
|
35
|
-
default: string;
|
|
36
|
-
transition: string;
|
|
37
|
-
};
|
|
38
30
|
};
|
|
39
31
|
};
|
|
40
32
|
export default _default;
|
package/dist/theme/index.d.ts
CHANGED
|
@@ -21,20 +21,12 @@ declare const _default: {
|
|
|
21
21
|
top: string;
|
|
22
22
|
left: string;
|
|
23
23
|
};
|
|
24
|
-
transform: {
|
|
25
|
-
default: string;
|
|
26
|
-
transition: string;
|
|
27
|
-
};
|
|
28
24
|
};
|
|
29
25
|
icon: {
|
|
30
26
|
position: {
|
|
31
27
|
top: string;
|
|
32
28
|
left: string;
|
|
33
29
|
};
|
|
34
|
-
transform: {
|
|
35
|
-
default: string;
|
|
36
|
-
transition: string;
|
|
37
|
-
};
|
|
38
30
|
};
|
|
39
31
|
};
|
|
40
32
|
export default _default;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
root: {
|
|
3
|
+
border: {
|
|
4
|
+
radius: {
|
|
5
|
+
default: string;
|
|
6
|
+
hover: string;
|
|
7
|
+
press: string;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
sizing: {
|
|
11
|
+
height: string;
|
|
12
|
+
width: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
slider: {
|
|
16
|
+
sizing: {
|
|
17
|
+
height: string;
|
|
18
|
+
width: string;
|
|
19
|
+
};
|
|
20
|
+
position: {
|
|
21
|
+
top: string;
|
|
22
|
+
left: string;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
icon: {
|
|
26
|
+
position: {
|
|
27
|
+
top: string;
|
|
28
|
+
left: string;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
export default _default;
|
|
@@ -21,20 +21,12 @@ declare const _default: {
|
|
|
21
21
|
top: string;
|
|
22
22
|
left: string;
|
|
23
23
|
};
|
|
24
|
-
transform: {
|
|
25
|
-
default: string;
|
|
26
|
-
transition: string;
|
|
27
|
-
};
|
|
28
24
|
};
|
|
29
25
|
icon: {
|
|
30
26
|
position: {
|
|
31
27
|
top: string;
|
|
32
28
|
left: string;
|
|
33
29
|
};
|
|
34
|
-
transform: {
|
|
35
|
-
default: string;
|
|
36
|
-
transition: string;
|
|
37
|
-
};
|
|
38
30
|
};
|
|
39
31
|
};
|
|
40
32
|
export default _default;
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Switch components for Wonder Blocks.",
|
|
4
4
|
"author": "Khan Academy",
|
|
5
5
|
"license": "MIT",
|
|
6
|
-
"version": "3.
|
|
6
|
+
"version": "3.4.1",
|
|
7
7
|
"publishConfig": {
|
|
8
8
|
"access": "public"
|
|
9
9
|
},
|
|
@@ -28,11 +28,11 @@
|
|
|
28
28
|
"./styles.css": "./dist/css/vars.css"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@khanacademy/wonder-blocks-core": "12.4.
|
|
32
|
-
"@khanacademy/wonder-blocks-icon": "5.3.
|
|
33
|
-
"@khanacademy/wonder-blocks-styles": "0.2.
|
|
34
|
-
"@khanacademy/wonder-blocks-theming": "4.0
|
|
35
|
-
"@khanacademy/wonder-blocks-tokens": "16.
|
|
31
|
+
"@khanacademy/wonder-blocks-core": "12.4.4",
|
|
32
|
+
"@khanacademy/wonder-blocks-icon": "5.3.15",
|
|
33
|
+
"@khanacademy/wonder-blocks-styles": "0.2.45",
|
|
34
|
+
"@khanacademy/wonder-blocks-theming": "4.1.0",
|
|
35
|
+
"@khanacademy/wonder-blocks-tokens": "16.5.0"
|
|
36
36
|
},
|
|
37
37
|
"peerDependencies": {
|
|
38
38
|
"aphrodite": "^1.2.5",
|