@workday/canvas-kit-docs 14.0.0-alpha.1234-next.0 → 14.0.0-alpha.1237-next.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.
|
@@ -18,7 +18,7 @@ import eslintrc from '!!raw-loader!./stackblitzFiles/.eslintrc.cjs.txt';
|
|
|
18
18
|
import tsconfigNodeFile from '!!raw-loader!./stackblitzFiles/tsconfig.node.json';
|
|
19
19
|
import appFile from '!!raw-loader!./stackblitzFiles/App.tsx';
|
|
20
20
|
import viteEnvFile from '!!raw-loader!./stackblitzFiles/vite-env.d.ts';
|
|
21
|
-
import { CanvasProvider,
|
|
21
|
+
import { CanvasProvider, defaultBranding } from '@workday/canvas-kit-react/common';
|
|
22
22
|
const cardStencil = createStencil({
|
|
23
23
|
base: {
|
|
24
24
|
'[data-part="example-block"]': {
|
|
@@ -110,7 +110,7 @@ export const ExampleCodeBlock = ({ code }) => {
|
|
|
110
110
|
openFile: 'src/Demo.tsx',
|
|
111
111
|
});
|
|
112
112
|
};
|
|
113
|
-
return (_jsxs("div", { ...cardStencil({ opened: isCodeDisplayed }), children: [_jsx(Card, { "data-part": "example-block", className: "sb-unstyled", children: _jsx(Card.Body, { children: _jsxs(CanvasProvider, {
|
|
113
|
+
return (_jsxs("div", { ...cardStencil({ opened: isCodeDisplayed }), children: [_jsx(Card, { "data-part": "example-block", className: "sb-unstyled", children: _jsx(Card.Body, { children: _jsxs(CanvasProvider, { className: defaultBranding, children: [React.createElement(code), code && (_jsxs("div", { "data-part": "code-toggle-stackblitz-btn-container", children: [_jsx(TertiaryButton, { size: "extraSmall", onClick: () => openProjectInStackblitz(), children: "\u26A1\uFE0F Edit in Stackblitz" }), _jsx(TertiaryButton, { size: "extraSmall", onClick: () => setCodeDisplayed(!isCodeDisplayed), children: !isCodeDisplayed ? 'Show Code' : 'Hide Code' })] }))] }) }) }), _jsx(Card, { "data-part": "code-block", padding: 0, children: _jsx(Card.Body, { cs: { position: 'relative' }, children: _jsxs(CanvasProvider, { className: defaultBranding, children: [code && (_jsx("div", { ref: textInput, children: _jsx(SyntaxHighlighter, { className: "sb-unstyled", language: "jsx", style: vscDarkPlus, customStyle: {
|
|
114
114
|
fontSize: cssVar(system.fontSize.subtext.large),
|
|
115
115
|
lineHeight: cssVar(system.lineHeight.subtext.large),
|
|
116
116
|
margin: '0',
|
package/dist/es6/lib/docs.js
CHANGED
|
@@ -192704,6 +192704,22 @@ export const docs = (typeof window !== 'undefined' && window.__docs) ||
|
|
|
192704
192704
|
"name": "CanvasProvider"
|
|
192705
192705
|
}
|
|
192706
192706
|
},
|
|
192707
|
+
{
|
|
192708
|
+
"name": "defaultBranding",
|
|
192709
|
+
"fileName": "/home/runner/work/canvas-kit/canvas-kit/modules/react/common/lib/CanvasProvider.tsx",
|
|
192710
|
+
"description": "If you wish to reset the theme to the default, apply this class on the CanvasProvider.",
|
|
192711
|
+
"declarations": [
|
|
192712
|
+
{
|
|
192713
|
+
"name": "defaultBranding",
|
|
192714
|
+
"filePath": "/home/runner/work/canvas-kit/canvas-kit/modules/react/common/lib/CanvasProvider.tsx"
|
|
192715
|
+
}
|
|
192716
|
+
],
|
|
192717
|
+
"tags": {},
|
|
192718
|
+
"type": {
|
|
192719
|
+
"kind": "primitive",
|
|
192720
|
+
"value": "string"
|
|
192721
|
+
}
|
|
192722
|
+
},
|
|
192707
192723
|
{
|
|
192708
192724
|
"name": "useCanvasThemeToCssVars",
|
|
192709
192725
|
"fileName": "/home/runner/work/canvas-kit/canvas-kit/modules/react/common/lib/CanvasProvider.tsx",
|
|
@@ -18,11 +18,11 @@ export const packageJSONFile = `{
|
|
|
18
18
|
"@emotion/react": "11.11.4",
|
|
19
19
|
"@types/react": "18.2.60",
|
|
20
20
|
"@types/react-dom": "18.2.19",
|
|
21
|
-
"@workday/canvas-kit-labs-react": "13.2.
|
|
22
|
-
"@workday/canvas-kit-preview-react": "13.2.
|
|
23
|
-
"@workday/canvas-kit-react": "13.2.
|
|
24
|
-
"@workday/canvas-kit-react-fonts": "^13.2.
|
|
25
|
-
"@workday/canvas-kit-styling": "13.2.
|
|
21
|
+
"@workday/canvas-kit-labs-react": "13.2.25",
|
|
22
|
+
"@workday/canvas-kit-preview-react": "13.2.25",
|
|
23
|
+
"@workday/canvas-kit-react": "13.2.25",
|
|
24
|
+
"@workday/canvas-kit-react-fonts": "^13.2.25",
|
|
25
|
+
"@workday/canvas-kit-styling": "13.2.25",
|
|
26
26
|
"@workday/canvas-system-icons-web": "3.0.22",
|
|
27
27
|
"@workday/canvas-tokens-web": "2.0.0"
|
|
28
28
|
},
|
|
@@ -18,11 +18,11 @@ export const packageJSONFile = `{
|
|
|
18
18
|
"@emotion/react": "11.11.4",
|
|
19
19
|
"@types/react": "18.2.60",
|
|
20
20
|
"@types/react-dom": "18.2.19",
|
|
21
|
-
"@workday/canvas-kit-labs-react": "13.2.
|
|
22
|
-
"@workday/canvas-kit-preview-react": "13.2.
|
|
23
|
-
"@workday/canvas-kit-react": "13.2.
|
|
24
|
-
"@workday/canvas-kit-react-fonts": "^13.2.
|
|
25
|
-
"@workday/canvas-kit-styling": "13.2.
|
|
21
|
+
"@workday/canvas-kit-labs-react": "13.2.25",
|
|
22
|
+
"@workday/canvas-kit-preview-react": "13.2.25",
|
|
23
|
+
"@workday/canvas-kit-react": "13.2.25",
|
|
24
|
+
"@workday/canvas-kit-react-fonts": "^13.2.25",
|
|
25
|
+
"@workday/canvas-kit-styling": "13.2.25",
|
|
26
26
|
"@workday/canvas-system-icons-web": "3.0.22",
|
|
27
27
|
"@workday/canvas-tokens-web": "2.0.0"
|
|
28
28
|
},
|
package/lib/ExampleCodeBlock.tsx
CHANGED
|
@@ -18,7 +18,7 @@ import eslintrc from '!!raw-loader!./stackblitzFiles/.eslintrc.cjs.txt';
|
|
|
18
18
|
import tsconfigNodeFile from '!!raw-loader!./stackblitzFiles/tsconfig.node.json';
|
|
19
19
|
import appFile from '!!raw-loader!./stackblitzFiles/App.tsx';
|
|
20
20
|
import viteEnvFile from '!!raw-loader!./stackblitzFiles/vite-env.d.ts';
|
|
21
|
-
import {CanvasProvider,
|
|
21
|
+
import {CanvasProvider, defaultBranding} from '@workday/canvas-kit-react/common';
|
|
22
22
|
|
|
23
23
|
const cardStencil = createStencil({
|
|
24
24
|
base: {
|
|
@@ -124,7 +124,7 @@ export const ExampleCodeBlock = ({code}: any) => {
|
|
|
124
124
|
<div {...cardStencil({opened: isCodeDisplayed})}>
|
|
125
125
|
<Card data-part="example-block" className="sb-unstyled">
|
|
126
126
|
<Card.Body>
|
|
127
|
-
<CanvasProvider
|
|
127
|
+
<CanvasProvider className={defaultBranding}>
|
|
128
128
|
{React.createElement(code)}
|
|
129
129
|
{code && (
|
|
130
130
|
<div data-part="code-toggle-stackblitz-btn-container">
|
|
@@ -144,7 +144,7 @@ export const ExampleCodeBlock = ({code}: any) => {
|
|
|
144
144
|
</Card>
|
|
145
145
|
<Card data-part="code-block" padding={0}>
|
|
146
146
|
<Card.Body cs={{position: 'relative'}}>
|
|
147
|
-
<CanvasProvider
|
|
147
|
+
<CanvasProvider className={defaultBranding}>
|
|
148
148
|
{code && (
|
|
149
149
|
<div ref={textInput}>
|
|
150
150
|
<SyntaxHighlighter
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@workday/canvas-kit-docs",
|
|
3
|
-
"version": "14.0.0-alpha.
|
|
3
|
+
"version": "14.0.0-alpha.1237-next.0",
|
|
4
4
|
"description": "Documentation components of Canvas Kit components",
|
|
5
5
|
"author": "Workday, Inc. (https://www.workday.com)",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -45,10 +45,10 @@
|
|
|
45
45
|
"@emotion/styled": "^11.6.0",
|
|
46
46
|
"@stackblitz/sdk": "^1.11.0",
|
|
47
47
|
"@storybook/csf": "0.0.1",
|
|
48
|
-
"@workday/canvas-kit-labs-react": "^14.0.0-alpha.
|
|
49
|
-
"@workday/canvas-kit-preview-react": "^14.0.0-alpha.
|
|
50
|
-
"@workday/canvas-kit-react": "^14.0.0-alpha.
|
|
51
|
-
"@workday/canvas-kit-styling": "^14.0.0-alpha.
|
|
48
|
+
"@workday/canvas-kit-labs-react": "^14.0.0-alpha.1237-next.0",
|
|
49
|
+
"@workday/canvas-kit-preview-react": "^14.0.0-alpha.1237-next.0",
|
|
50
|
+
"@workday/canvas-kit-react": "^14.0.0-alpha.1237-next.0",
|
|
51
|
+
"@workday/canvas-kit-styling": "^14.0.0-alpha.1237-next.0",
|
|
52
52
|
"@workday/canvas-system-icons-web": "^3.0.35",
|
|
53
53
|
"@workday/canvas-tokens-web": "3.0.0-alpha.12",
|
|
54
54
|
"markdown-to-jsx": "^7.2.0",
|
|
@@ -61,5 +61,5 @@
|
|
|
61
61
|
"mkdirp": "^1.0.3",
|
|
62
62
|
"typescript": "5.0"
|
|
63
63
|
},
|
|
64
|
-
"gitHead": "
|
|
64
|
+
"gitHead": "8a03bc6fdf11ecb2672ad937247aaf18b7cee0ec"
|
|
65
65
|
}
|