@khanacademy/wonder-blocks-toolbar 5.1.15 → 5.1.16
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 +16 -0
- package/dist/es/index.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @khanacademy/wonder-blocks-toolbar
|
|
2
2
|
|
|
3
|
+
## 5.1.16
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 9bacc1a: Replaces all existing `semanticColor.border` references to use `semanticColor.core.border`
|
|
8
|
+
- 7abcccf: Replace call sites to use `core.background` instead of `action`.
|
|
9
|
+
- Updated dependencies [b1ee2b4]
|
|
10
|
+
- Updated dependencies [7abcccf]
|
|
11
|
+
- Updated dependencies [9bacc1a]
|
|
12
|
+
- Updated dependencies [9bacc1a]
|
|
13
|
+
- Updated dependencies [1c3c335]
|
|
14
|
+
- Updated dependencies [689f5d3]
|
|
15
|
+
- Updated dependencies [7d2a646]
|
|
16
|
+
- @khanacademy/wonder-blocks-tokens@10.4.0
|
|
17
|
+
- @khanacademy/wonder-blocks-typography@4.1.0
|
|
18
|
+
|
|
3
19
|
## 5.1.15
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
package/dist/es/index.js
CHANGED
|
@@ -5,6 +5,6 @@ import { View } from '@khanacademy/wonder-blocks-core';
|
|
|
5
5
|
import { semanticColor, spacing, color } from '@khanacademy/wonder-blocks-tokens';
|
|
6
6
|
import { LabelSmall, LabelLarge, HeadingSmall } from '@khanacademy/wonder-blocks-typography';
|
|
7
7
|
|
|
8
|
-
function Toolbar({color="light",leftContent,rightContent,size="medium",subtitle,title}){const TitleComponent=subtitle?LabelLarge:HeadingSmall;return jsxs(View,{style:[sharedStyles.container,!title?sharedStyles.containerWithNoTitle:typeof title==="string"?sharedStyles.containerWithTextTitle:sharedStyles.containerWithNodeTitle,color==="dark"&&sharedStyles.dark,size==="small"&&sharedStyles.small],children:[jsx(View,{style:sharedStyles.leftColumn,children:leftContent}),title&&typeof title==="string"&&jsxs(View,{style:sharedStyles.titles,children:[jsx(TitleComponent,{id:"wb-toolbar-title",children:title}),subtitle&&jsx(LabelSmall,{style:color==="light"&&sharedStyles.subtitle,children:subtitle})]}),title&&typeof title!=="string"&&jsx(View,{style:sharedStyles.titles,children:title}),!title&&jsx(View,{style:leftContent?sharedStyles.spacer:undefined}),jsx(View,{style:sharedStyles.rightColumn,children:rightContent})]})}const sharedStyles=StyleSheet.create({container:{background:semanticColor.surface.primary,border:`1px solid ${semanticColor.border.
|
|
8
|
+
function Toolbar({color="light",leftContent,rightContent,size="medium",subtitle,title}){const TitleComponent=subtitle?LabelLarge:HeadingSmall;return jsxs(View,{style:[sharedStyles.container,!title?sharedStyles.containerWithNoTitle:typeof title==="string"?sharedStyles.containerWithTextTitle:sharedStyles.containerWithNodeTitle,color==="dark"&&sharedStyles.dark,size==="small"&&sharedStyles.small],children:[jsx(View,{style:sharedStyles.leftColumn,children:leftContent}),title&&typeof title==="string"&&jsxs(View,{style:sharedStyles.titles,children:[jsx(TitleComponent,{id:"wb-toolbar-title",children:title}),subtitle&&jsx(LabelSmall,{style:color==="light"&&sharedStyles.subtitle,children:subtitle})]}),title&&typeof title!=="string"&&jsx(View,{style:sharedStyles.titles,children:title}),!title&&jsx(View,{style:leftContent?sharedStyles.spacer:undefined}),jsx(View,{style:sharedStyles.rightColumn,children:rightContent})]})}const sharedStyles=StyleSheet.create({container:{background:semanticColor.surface.primary,border:`1px solid ${semanticColor.core.border.neutral.subtle}`,flex:1,display:"grid",alignItems:"center",minHeight:66,paddingInline:spacing.medium_16,width:"100%"},containerWithTextTitle:{gridTemplateColumns:"1fr minmax(auto, 67%) 1fr"},containerWithNodeTitle:{gridTemplateColumns:"minmax(max-content, 1fr) auto minmax(max-content, 1fr)"},containerWithNoTitle:{gridTemplateColumns:"auto auto 1fr"},small:{minHeight:50},dark:{background:semanticColor.surface.inverse,boxShadow:`0 1px 0 0 ${color.white64}`,color:semanticColor.text.inverse},leftColumn:{alignItems:"center",flexDirection:"row",justifyContent:"flex-start"},rightColumn:{alignItems:"center",flexDirection:"row",justifyContent:"flex-end",flexGrow:1},subtitle:{color:semanticColor.text.secondary},titles:{padding:spacing.small_12,textAlign:"center",justifySelf:"center",maxWidth:"100%"},spacer:{minWidth:spacing.small_12}});
|
|
9
9
|
|
|
10
10
|
export { Toolbar as default };
|
package/dist/index.js
CHANGED
|
@@ -7,6 +7,6 @@ var wonderBlocksCore = require('@khanacademy/wonder-blocks-core');
|
|
|
7
7
|
var wonderBlocksTokens = require('@khanacademy/wonder-blocks-tokens');
|
|
8
8
|
var wonderBlocksTypography = require('@khanacademy/wonder-blocks-typography');
|
|
9
9
|
|
|
10
|
-
function Toolbar({color="light",leftContent,rightContent,size="medium",subtitle,title}){const TitleComponent=subtitle?wonderBlocksTypography.LabelLarge:wonderBlocksTypography.HeadingSmall;return jsxRuntime.jsxs(wonderBlocksCore.View,{style:[sharedStyles.container,!title?sharedStyles.containerWithNoTitle:typeof title==="string"?sharedStyles.containerWithTextTitle:sharedStyles.containerWithNodeTitle,color==="dark"&&sharedStyles.dark,size==="small"&&sharedStyles.small],children:[jsxRuntime.jsx(wonderBlocksCore.View,{style:sharedStyles.leftColumn,children:leftContent}),title&&typeof title==="string"&&jsxRuntime.jsxs(wonderBlocksCore.View,{style:sharedStyles.titles,children:[jsxRuntime.jsx(TitleComponent,{id:"wb-toolbar-title",children:title}),subtitle&&jsxRuntime.jsx(wonderBlocksTypography.LabelSmall,{style:color==="light"&&sharedStyles.subtitle,children:subtitle})]}),title&&typeof title!=="string"&&jsxRuntime.jsx(wonderBlocksCore.View,{style:sharedStyles.titles,children:title}),!title&&jsxRuntime.jsx(wonderBlocksCore.View,{style:leftContent?sharedStyles.spacer:undefined}),jsxRuntime.jsx(wonderBlocksCore.View,{style:sharedStyles.rightColumn,children:rightContent})]})}const sharedStyles=aphrodite.StyleSheet.create({container:{background:wonderBlocksTokens.semanticColor.surface.primary,border:`1px solid ${wonderBlocksTokens.semanticColor.border.
|
|
10
|
+
function Toolbar({color="light",leftContent,rightContent,size="medium",subtitle,title}){const TitleComponent=subtitle?wonderBlocksTypography.LabelLarge:wonderBlocksTypography.HeadingSmall;return jsxRuntime.jsxs(wonderBlocksCore.View,{style:[sharedStyles.container,!title?sharedStyles.containerWithNoTitle:typeof title==="string"?sharedStyles.containerWithTextTitle:sharedStyles.containerWithNodeTitle,color==="dark"&&sharedStyles.dark,size==="small"&&sharedStyles.small],children:[jsxRuntime.jsx(wonderBlocksCore.View,{style:sharedStyles.leftColumn,children:leftContent}),title&&typeof title==="string"&&jsxRuntime.jsxs(wonderBlocksCore.View,{style:sharedStyles.titles,children:[jsxRuntime.jsx(TitleComponent,{id:"wb-toolbar-title",children:title}),subtitle&&jsxRuntime.jsx(wonderBlocksTypography.LabelSmall,{style:color==="light"&&sharedStyles.subtitle,children:subtitle})]}),title&&typeof title!=="string"&&jsxRuntime.jsx(wonderBlocksCore.View,{style:sharedStyles.titles,children:title}),!title&&jsxRuntime.jsx(wonderBlocksCore.View,{style:leftContent?sharedStyles.spacer:undefined}),jsxRuntime.jsx(wonderBlocksCore.View,{style:sharedStyles.rightColumn,children:rightContent})]})}const sharedStyles=aphrodite.StyleSheet.create({container:{background:wonderBlocksTokens.semanticColor.surface.primary,border:`1px solid ${wonderBlocksTokens.semanticColor.core.border.neutral.subtle}`,flex:1,display:"grid",alignItems:"center",minHeight:66,paddingInline:wonderBlocksTokens.spacing.medium_16,width:"100%"},containerWithTextTitle:{gridTemplateColumns:"1fr minmax(auto, 67%) 1fr"},containerWithNodeTitle:{gridTemplateColumns:"minmax(max-content, 1fr) auto minmax(max-content, 1fr)"},containerWithNoTitle:{gridTemplateColumns:"auto auto 1fr"},small:{minHeight:50},dark:{background:wonderBlocksTokens.semanticColor.surface.inverse,boxShadow:`0 1px 0 0 ${wonderBlocksTokens.color.white64}`,color:wonderBlocksTokens.semanticColor.text.inverse},leftColumn:{alignItems:"center",flexDirection:"row",justifyContent:"flex-start"},rightColumn:{alignItems:"center",flexDirection:"row",justifyContent:"flex-end",flexGrow:1},subtitle:{color:wonderBlocksTokens.semanticColor.text.secondary},titles:{padding:wonderBlocksTokens.spacing.small_12,textAlign:"center",justifySelf:"center",maxWidth:"100%"},spacer:{minWidth:wonderBlocksTokens.spacing.small_12}});
|
|
11
11
|
|
|
12
12
|
module.exports = Toolbar;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@khanacademy/wonder-blocks-toolbar",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.16",
|
|
4
4
|
"design": "v1",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -13,8 +13,8 @@
|
|
|
13
13
|
"license": "MIT",
|
|
14
14
|
"dependencies": {
|
|
15
15
|
"@khanacademy/wonder-blocks-core": "12.3.0",
|
|
16
|
-
"@khanacademy/wonder-blocks-
|
|
17
|
-
"@khanacademy/wonder-blocks-
|
|
16
|
+
"@khanacademy/wonder-blocks-tokens": "10.4.0",
|
|
17
|
+
"@khanacademy/wonder-blocks-typography": "4.1.0"
|
|
18
18
|
},
|
|
19
19
|
"peerDependencies": {
|
|
20
20
|
"aphrodite": "^1.2.5",
|