mirror of
https://github.com/lowdefy/lowdefy.git
synced 2025-02-23 14:39:32 +08:00
Merge pull request #110 from lowdefy/blocks-basic
Add @lowdefy/blocks-basic
This commit is contained in:
commit
c4ebd94261
BIN
.yarn/cache/@npmcli-move-file-npm-1.0.1-90209166f0-ed2cb75eef.zip
vendored
Normal file
BIN
.yarn/cache/@npmcli-move-file-npm-1.0.1-90209166f0-ed2cb75eef.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@types-hast-npm-2.3.1-65e0b0f4b1-8aff367be4.zip
vendored
Normal file
BIN
.yarn/cache/@types-hast-npm-2.3.1-65e0b0f4b1-8aff367be4.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/aggregate-error-npm-3.1.0-415a406f4e-704d2001a3.zip
vendored
Normal file
BIN
.yarn/cache/aggregate-error-npm-3.1.0-415a406f4e-704d2001a3.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/cacache-npm-15.0.5-5c6c90d2e8-8e371cbf3c.zip
vendored
Normal file
BIN
.yarn/cache/cacache-npm-15.0.5-5c6c90d2e8-8e371cbf3c.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/clean-stack-npm-2.2.0-a8ce435a5c-e291ce2b8c.zip
vendored
Normal file
BIN
.yarn/cache/clean-stack-npm-2.2.0-a8ce435a5c-e291ce2b8c.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/clipboard-npm-2.0.6-3d616039e3-25e2e6b595.zip
vendored
Normal file
BIN
.yarn/cache/clipboard-npm-2.0.6-3d616039e3-25e2e6b595.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/collapse-white-space-npm-1.0.6-6fdbf5906f-beca17619b.zip
vendored
Normal file
BIN
.yarn/cache/collapse-white-space-npm-1.0.6-6fdbf5906f-beca17619b.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/comma-separated-tokens-npm-1.0.8-00dbbf3418-31a5a2fa6e.zip
vendored
Normal file
BIN
.yarn/cache/comma-separated-tokens-npm-1.0.8-00dbbf3418-31a5a2fa6e.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/copy-webpack-plugin-npm-6.2.1-297e10f806-99ef83b423.zip
vendored
Normal file
BIN
.yarn/cache/copy-webpack-plugin-npm-6.2.1-297e10f806-99ef83b423.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/delegate-npm-3.2.0-d3f849ea99-ccbbf29eb4.zip
vendored
Normal file
BIN
.yarn/cache/delegate-npm-3.2.0-d3f849ea99-ccbbf29eb4.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/fault-npm-1.0.4-2788bc13e3-6b8ef4f743.zip
vendored
Normal file
BIN
.yarn/cache/fault-npm-1.0.4-2788bc13e3-6b8ef4f743.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/find-cache-dir-npm-3.3.1-66916b4b23-b1e23226ee.zip
vendored
Normal file
BIN
.yarn/cache/find-cache-dir-npm-3.3.1-66916b4b23-b1e23226ee.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/format-npm-0.2.2-679f3acc64-0740f52121.zip
vendored
Normal file
BIN
.yarn/cache/format-npm-0.2.2-679f3acc64-0740f52121.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/good-listener-npm-1.2.2-e7865da849-640a1627e5.zip
vendored
Normal file
BIN
.yarn/cache/good-listener-npm-1.2.2-e7865da849-640a1627e5.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/hast-util-parse-selector-npm-2.2.4-de83623cf7-affd2e8d83.zip
vendored
Normal file
BIN
.yarn/cache/hast-util-parse-selector-npm-2.2.4-de83623cf7-affd2e8d83.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/hastscript-npm-6.0.0-380b27a9f0-c801a85913.zip
vendored
Normal file
BIN
.yarn/cache/hastscript-npm-6.0.0-380b27a9f0-c801a85913.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/highlight.js-npm-10.3.2-f197b5807b-8dab959070.zip
vendored
Normal file
BIN
.yarn/cache/highlight.js-npm-10.3.2-f197b5807b-8dab959070.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/is-whitespace-character-npm-1.0.4-02d39af907-fd6dbced04.zip
vendored
Normal file
BIN
.yarn/cache/is-whitespace-character-npm-1.0.4-02d39af907-fd6dbced04.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/is-word-character-npm-1.0.4-eeb59c97bc-84da3b0a2c.zip
vendored
Normal file
BIN
.yarn/cache/is-word-character-npm-1.0.4-eeb59c97bc-84da3b0a2c.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/jest-npm-26.5.2-802df785c1-8c31ca019c.zip
vendored
Normal file
BIN
.yarn/cache/jest-npm-26.5.2-802df785c1-8c31ca019c.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/lowlight-npm-1.16.0-15996b17f7-98970f15c9.zip
vendored
Normal file
BIN
.yarn/cache/lowlight-npm-1.16.0-15996b17f7-98970f15c9.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/lru-cache-npm-6.0.0-b4c8668fe1-b8b78353d2.zip
vendored
Normal file
BIN
.yarn/cache/lru-cache-npm-6.0.0-b4c8668fe1-b8b78353d2.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/markdown-escapes-npm-1.0.4-6f56c61420-eea95364ec.zip
vendored
Normal file
BIN
.yarn/cache/markdown-escapes-npm-1.0.4-6f56c61420-eea95364ec.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/minipass-collect-npm-1.0.2-3b4676eab5-529ef62123.zip
vendored
Normal file
BIN
.yarn/cache/minipass-collect-npm-1.0.2-3b4676eab5-529ef62123.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/minipass-flush-npm-1.0.5-efe79d9826-d354ca0da8.zip
vendored
Normal file
BIN
.yarn/cache/minipass-flush-npm-1.0.5-efe79d9826-d354ca0da8.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/minipass-pipeline-npm-1.2.4-5924cb077f-001d5a4a0c.zip
vendored
Normal file
BIN
.yarn/cache/minipass-pipeline-npm-1.2.4-5924cb077f-001d5a4a0c.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/p-map-npm-4.0.0-4677ae07c7-d51e630d72.zip
vendored
Normal file
BIN
.yarn/cache/p-map-npm-4.0.0-4677ae07c7-d51e630d72.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/parse-entities-npm-1.2.2-6be249f6ff-66fb7cb7c8.zip
vendored
Normal file
BIN
.yarn/cache/parse-entities-npm-1.2.2-6be249f6ff-66fb7cb7c8.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/prismjs-npm-1.22.0-5aa7ce32e1-c9370f1f6a.zip
vendored
Normal file
BIN
.yarn/cache/prismjs-npm-1.22.0-5aa7ce32e1-c9370f1f6a.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/property-information-npm-5.6.0-1322d29e0f-d069696456.zip
vendored
Normal file
BIN
.yarn/cache/property-information-npm-5.6.0-1322d29e0f-d069696456.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/react-markdown-npm-4.3.1-9120cab586-89111d726b.zip
vendored
Normal file
BIN
.yarn/cache/react-markdown-npm-4.3.1-9120cab586-89111d726b.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/react-syntax-highlighter-npm-15.2.1-102a3321c0-22b880f0ec.zip
vendored
Normal file
BIN
.yarn/cache/react-syntax-highlighter-npm-15.2.1-102a3321c0-22b880f0ec.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/refractor-npm-3.2.0-38c54ef1c5-4b5e485bf8.zip
vendored
Normal file
BIN
.yarn/cache/refractor-npm-3.2.0-38c54ef1c5-4b5e485bf8.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/remark-parse-npm-5.0.0-12afcecf81-e5295c40ef.zip
vendored
Normal file
BIN
.yarn/cache/remark-parse-npm-5.0.0-12afcecf81-e5295c40ef.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/select-npm-1.1.2-13cd366fa2-66be63b7cf.zip
vendored
Normal file
BIN
.yarn/cache/select-npm-1.1.2-13cd366fa2-66be63b7cf.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/space-separated-tokens-npm-1.1.5-2352c83473-2b143776c3.zip
vendored
Normal file
BIN
.yarn/cache/space-separated-tokens-npm-1.1.5-2352c83473-2b143776c3.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/ssri-npm-8.0.0-276fb838a8-97964745a8.zip
vendored
Normal file
BIN
.yarn/cache/ssri-npm-8.0.0-276fb838a8-97964745a8.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/state-toggle-npm-1.0.3-dd096f8bd0-8c013394b3.zip
vendored
Normal file
BIN
.yarn/cache/state-toggle-npm-1.0.3-dd096f8bd0-8c013394b3.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/tiny-emitter-npm-2.1.0-2a4d94f487-0055509c72.zip
vendored
Normal file
BIN
.yarn/cache/tiny-emitter-npm-2.1.0-2a4d94f487-0055509c72.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/trim-npm-0.0.1-d138075543-ecf8478384.zip
vendored
Normal file
BIN
.yarn/cache/trim-npm-0.0.1-d138075543-ecf8478384.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/trim-trailing-lines-npm-1.1.4-4bf3b2c576-d3fd2a2804.zip
vendored
Normal file
BIN
.yarn/cache/trim-trailing-lines-npm-1.1.4-4bf3b2c576-d3fd2a2804.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/unherit-npm-1.1.3-14f0bf5f12-387415adc7.zip
vendored
Normal file
BIN
.yarn/cache/unherit-npm-1.1.3-14f0bf5f12-387415adc7.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/unified-npm-6.2.0-824644bed4-f524c6320c.zip
vendored
Normal file
BIN
.yarn/cache/unified-npm-6.2.0-824644bed4-f524c6320c.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/unist-util-is-npm-3.0.0-1816040586-c001cb8366.zip
vendored
Normal file
BIN
.yarn/cache/unist-util-is-npm-3.0.0-1816040586-c001cb8366.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/unist-util-remove-position-npm-1.1.4-ddac633e26-be5b8e2d35.zip
vendored
Normal file
BIN
.yarn/cache/unist-util-remove-position-npm-1.1.4-ddac633e26-be5b8e2d35.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/unist-util-stringify-position-npm-1.1.2-df033816cc-fa314c7d14.zip
vendored
Normal file
BIN
.yarn/cache/unist-util-stringify-position-npm-1.1.2-df033816cc-fa314c7d14.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/unist-util-visit-npm-1.4.1-fdb79796c9-6c62b50495.zip
vendored
Normal file
BIN
.yarn/cache/unist-util-visit-npm-1.4.1-fdb79796c9-6c62b50495.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/unist-util-visit-parents-npm-2.1.2-154aede9d7-26807f1d21.zip
vendored
Normal file
BIN
.yarn/cache/unist-util-visit-parents-npm-2.1.2-154aede9d7-26807f1d21.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/vfile-location-npm-2.0.6-a098041eed-b050677560.zip
vendored
Normal file
BIN
.yarn/cache/vfile-location-npm-2.0.6-a098041eed-b050677560.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/vfile-message-npm-1.1.1-6458d7e753-d6c086d7c1.zip
vendored
Normal file
BIN
.yarn/cache/vfile-message-npm-1.1.1-6458d7e753-d6c086d7c1.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/vfile-npm-2.3.0-0781febdcc-b59f2a73a6.zip
vendored
Normal file
BIN
.yarn/cache/vfile-npm-2.3.0-0781febdcc-b59f2a73a6.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/webpack-merge-npm-5.2.0-dfa3a85026-edc100b9c7.zip
vendored
Normal file
BIN
.yarn/cache/webpack-merge-npm-5.2.0-dfa3a85026-edc100b9c7.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/webpack-sources-npm-1.4.3-2b3a9b1de0-2a753b36ad.zip
vendored
Normal file
BIN
.yarn/cache/webpack-sources-npm-1.4.3-2b3a9b1de0-2a753b36ad.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/x-is-string-npm-0.1.0-a254bc0c3e-a0e9f54303.zip
vendored
Normal file
BIN
.yarn/cache/x-is-string-npm-0.1.0-a254bc0c3e-a0e9f54303.zip
vendored
Normal file
Binary file not shown.
1
.yarn/versions/aaab972e.yml
vendored
1
.yarn/versions/aaab972e.yml
vendored
@ -1,5 +1,6 @@
|
||||
releases:
|
||||
"@lowdefy/block-tools": patch
|
||||
"@lowdefy/blocks-basic": patch
|
||||
"@lowdefy/build": patch
|
||||
"@lowdefy/cli": patch
|
||||
"@lowdefy/color": patch
|
||||
|
@ -10,14 +10,5 @@
|
||||
}
|
||||
],
|
||||
"@babel/preset-react"
|
||||
],
|
||||
"plugins": [
|
||||
[
|
||||
"import",
|
||||
{
|
||||
"libraryName": "antd",
|
||||
"style": "css"
|
||||
}
|
||||
]
|
||||
]
|
||||
}
|
||||
|
@ -55,8 +55,6 @@
|
||||
"@wojtekmaj/enzyme-adapter-react-17": "0.2.0",
|
||||
"babel-jest": "26.6.1",
|
||||
"babel-loader": "8.1.0",
|
||||
"babel-plugin-import": "1.13.1",
|
||||
"buffer": "5.7.0",
|
||||
"clean-webpack-plugin": "3.0.0",
|
||||
"css-loader": "5.0.0",
|
||||
"enzyme": "3.11.0",
|
||||
@ -66,8 +64,6 @@
|
||||
"js-yaml": "3.14.0",
|
||||
"path-browserify": "1.0.1",
|
||||
"process": "0.11.10",
|
||||
"react": "17.0.1",
|
||||
"react-dom": "17.0.1",
|
||||
"react-syntax-highlight": "15.3.1",
|
||||
"react-test-renderer": "17.0.1",
|
||||
"style-loader": "2.0.0",
|
||||
|
14
packages/blocksBasic/.babelrc
Normal file
14
packages/blocksBasic/.babelrc
Normal file
@ -0,0 +1,14 @@
|
||||
{
|
||||
"presets": [
|
||||
[
|
||||
"@babel/preset-env",
|
||||
{
|
||||
"targets": {
|
||||
"node": "12",
|
||||
"esmodules": true
|
||||
}
|
||||
}
|
||||
],
|
||||
"@babel/preset-react"
|
||||
]
|
||||
}
|
3
packages/blocksBasic/README.md
Normal file
3
packages/blocksBasic/README.md
Normal file
@ -0,0 +1,3 @@
|
||||
# Lowdefy Blocks Basic
|
||||
|
||||
Basic Lowdefy blocks.
|
71
packages/blocksBasic/demo/Examples.js
Normal file
71
packages/blocksBasic/demo/Examples.js
Normal file
@ -0,0 +1,71 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React, { useState } from 'react';
|
||||
import YAML from 'js-yaml';
|
||||
import { stubBlockProps, blockDefaultProps, BlockSchemaErrors } from '@lowdefy/block-tools';
|
||||
import yaml from 'react-syntax-highlighter/dist/esm/languages/hljs/yaml';
|
||||
import { Light as SyntaxHighlighter } from 'react-syntax-highlighter';
|
||||
import vs2015 from 'react-syntax-highlighter/dist/esm/styles/hljs/vs2015';
|
||||
|
||||
SyntaxHighlighter.registerLanguage('yaml', yaml);
|
||||
const logger = console.log;
|
||||
|
||||
const Examples = ({ type, Component }) => {
|
||||
const [showYaml, toggelYaml] = useState(true);
|
||||
// duplicate imported yaml to be mutabile
|
||||
const examples = JSON.parse(JSON.stringify(require(`./examples/${type}.yaml`)));
|
||||
const meta = require(`../src/blocks/${type}/${type}.json`);
|
||||
Component.defaultProps = blockDefaultProps;
|
||||
return (
|
||||
<div>
|
||||
<h1>{type}</h1>
|
||||
<div>
|
||||
Render YAML:{' '}
|
||||
<input type="checkbox" checked={showYaml} onChange={() => toggelYaml(!showYaml)} />
|
||||
</div>
|
||||
{(examples || []).map((block) => {
|
||||
const exYaml = YAML.safeDump(block, {
|
||||
// sortKeys: true,
|
||||
noRefs: true,
|
||||
});
|
||||
const props = stubBlockProps({ block, meta, logger });
|
||||
return (
|
||||
<div key={block.id}>
|
||||
<h4 style={{ borderTop: '1px solid #b1b1b1', padding: 10, margin: 10 }}>
|
||||
{type} {block.id}
|
||||
</h4>
|
||||
<div style={{ display: 'flex' }}>
|
||||
{showYaml && (
|
||||
<div style={{ minWidth: '30%' }}>
|
||||
<SyntaxHighlighter language="yaml" style={vs2015} showLineNumbers={true}>
|
||||
{exYaml}
|
||||
</SyntaxHighlighter>
|
||||
<BlockSchemaErrors schemaErrors={props.schemaErrors} />
|
||||
</div>
|
||||
)}
|
||||
<div style={{ ...{ padding: 20, width: '100%' }, ...block.style }}>
|
||||
<Component {...props} />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export default Examples;
|
4
packages/blocksBasic/demo/app.css
Normal file
4
packages/blocksBasic/demo/app.css
Normal file
@ -0,0 +1,4 @@
|
||||
html {
|
||||
box-sizing: border-box;
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue';
|
||||
}
|
33
packages/blocksBasic/demo/bootstrap.js
vendored
Normal file
33
packages/blocksBasic/demo/bootstrap.js
vendored
Normal file
@ -0,0 +1,33 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { render } from 'react-dom';
|
||||
import Blocks from '../src';
|
||||
import Examples from './Examples';
|
||||
import './app.css';
|
||||
|
||||
const Demo = () => (
|
||||
<div id="page">
|
||||
{Object.keys(Blocks).map((key) => (
|
||||
<Examples key={key} type={key} Component={Blocks[key]} />
|
||||
))}
|
||||
</div>
|
||||
);
|
||||
|
||||
export default Demo;
|
||||
|
||||
render(<Demo />, document.querySelector('#root'));
|
29
packages/blocksBasic/demo/examples/Box.yaml
Normal file
29
packages/blocksBasic/demo/examples/Box.yaml
Normal file
@ -0,0 +1,29 @@
|
||||
- id: default
|
||||
type: Box
|
||||
- id: properties.content
|
||||
type: Box
|
||||
properties:
|
||||
content: Foo
|
||||
- id: properties.style
|
||||
type: Box
|
||||
properties:
|
||||
style:
|
||||
border: '1px solid blue'
|
||||
- id: areas.content
|
||||
type: Box
|
||||
areas:
|
||||
content:
|
||||
blocks:
|
||||
- id: testArea
|
||||
type: Test
|
||||
- id: actions.onClick
|
||||
type: Box
|
||||
areas:
|
||||
content:
|
||||
blocks:
|
||||
- id: testArea
|
||||
type: Test
|
||||
actions:
|
||||
onClick:
|
||||
- id: testAction
|
||||
type: Text
|
29
packages/blocksBasic/demo/examples/Context.yaml
Normal file
29
packages/blocksBasic/demo/examples/Context.yaml
Normal file
@ -0,0 +1,29 @@
|
||||
- id: default
|
||||
type: Context
|
||||
- id: properties.content
|
||||
type: Context
|
||||
properties:
|
||||
content: Foo
|
||||
- id: properties.style
|
||||
type: Context
|
||||
properties:
|
||||
style:
|
||||
border: '1px solid blue'
|
||||
- id: areas.content
|
||||
type: Context
|
||||
areas:
|
||||
content:
|
||||
blocks:
|
||||
- id: testArea
|
||||
type: Test
|
||||
- id: actions.onClick
|
||||
type: Context
|
||||
areas:
|
||||
content:
|
||||
blocks:
|
||||
- id: testArea
|
||||
type: Test
|
||||
actions:
|
||||
onClick:
|
||||
- id: testAction
|
||||
type: Text
|
23
packages/blocksBasic/demo/examples/Html.yaml
Normal file
23
packages/blocksBasic/demo/examples/Html.yaml
Normal file
@ -0,0 +1,23 @@
|
||||
- id: default
|
||||
type: Html
|
||||
- id: properties.html
|
||||
type: Html
|
||||
properties:
|
||||
html: |
|
||||
<div style="background: green; padding: 10px;">Content green background</div>
|
||||
- id: properties.style
|
||||
type: Html
|
||||
properties:
|
||||
style:
|
||||
background: yellow
|
||||
padding: 10
|
||||
html: |
|
||||
<div>properties.style yellow background</div>
|
||||
- id: properties.html-styled
|
||||
type: Html
|
||||
properties:
|
||||
style:
|
||||
background: yellow
|
||||
padding: 10
|
||||
html: |
|
||||
<div style="background: green; padding: 10px;">Content green background and properties.style yellow background</div>
|
25
packages/blocksBasic/demo/examples/List.yaml
Normal file
25
packages/blocksBasic/demo/examples/List.yaml
Normal file
@ -0,0 +1,25 @@
|
||||
- id: default
|
||||
type: List
|
||||
- id: default-two-items
|
||||
type: List
|
||||
blocks:
|
||||
- id: one
|
||||
type: Test
|
||||
- id: two
|
||||
type: Test
|
||||
- id: properties.style
|
||||
type: List
|
||||
properties:
|
||||
style:
|
||||
border: 1px solid blue
|
||||
- id: properties.style-two-items
|
||||
type: List
|
||||
properties:
|
||||
style:
|
||||
border: 1px solid blue
|
||||
blocks:
|
||||
- id: one
|
||||
type: Test
|
||||
- id: two
|
||||
type: Test
|
||||
|
29
packages/blocksBasic/demo/examples/Span.yaml
Normal file
29
packages/blocksBasic/demo/examples/Span.yaml
Normal file
@ -0,0 +1,29 @@
|
||||
- id: default
|
||||
type: Span
|
||||
- id: properties.content
|
||||
type: Span
|
||||
properties:
|
||||
content: Foo
|
||||
- id: properties.style
|
||||
type: Span
|
||||
properties:
|
||||
style:
|
||||
border: '1px solid blue'
|
||||
- id: areas.content
|
||||
type: Span
|
||||
areas:
|
||||
content:
|
||||
blocks:
|
||||
- id: testArea
|
||||
type: Test
|
||||
- id: actions.onClick
|
||||
type: Span
|
||||
areas:
|
||||
content:
|
||||
blocks:
|
||||
- id: testArea
|
||||
type: Test
|
||||
actions:
|
||||
onClick:
|
||||
- id: testAction
|
||||
type: Text
|
17
packages/blocksBasic/demo/index.js
Normal file
17
packages/blocksBasic/demo/index.js
Normal file
@ -0,0 +1,17 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import('./bootstrap');
|
19
packages/blocksBasic/jest.config.js
Normal file
19
packages/blocksBasic/jest.config.js
Normal file
@ -0,0 +1,19 @@
|
||||
module.exports = {
|
||||
clearMocks: true,
|
||||
collectCoverage: true,
|
||||
collectCoverageFrom: ['src/**/*.js'],
|
||||
coverageDirectory: 'coverage',
|
||||
coveragePathIgnorePatterns: ['<rootDir>/dist/', '<rootDir>/src/test'],
|
||||
coverageReporters: [['lcov', { projectRoot: '../..' }], 'text', 'clover'],
|
||||
errorOnDeprecated: true,
|
||||
testPathIgnorePatterns: ['<rootDir>/dist/', '<rootDir>/src/test'],
|
||||
moduleNameMapper: {
|
||||
'\\.(css|less)$': '<rootDir>/tests/__mocks__/styleMock.js',
|
||||
},
|
||||
coveragePathIgnorePatterns: ['/tests/', '/demo/'],
|
||||
transform: {
|
||||
'\\.yaml$': 'yaml-jest',
|
||||
'\\.js?$': 'babel-jest',
|
||||
},
|
||||
moduleFileExtensions: ['js', 'json', 'jsx', 'ts', 'tsx', 'node', 'yaml', 'css'],
|
||||
};
|
75
packages/blocksBasic/package.json
Normal file
75
packages/blocksBasic/package.json
Normal file
@ -0,0 +1,75 @@
|
||||
{
|
||||
"name": "@lowdefy/blocks-basic",
|
||||
"version": "1.0.6",
|
||||
"license": "Apache-2.0",
|
||||
"description": "Basic html Lowdefy blocks.",
|
||||
"homepage": "https://lowdefy.com",
|
||||
"bugs": {
|
||||
"url": "https://github.com/lowdefy/lowdefy/issues"
|
||||
},
|
||||
"contributors": [
|
||||
{
|
||||
"name": "Sam Tolmay",
|
||||
"url": "https://github.com/SamTolmay"
|
||||
},
|
||||
{
|
||||
"name": "Gerrie van Wyk",
|
||||
"url": "https://github.com/Gervwyk"
|
||||
}
|
||||
],
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/lowdefy/blocks-basic.git"
|
||||
},
|
||||
"browser": "dist/remoteEntry.js",
|
||||
"files": [
|
||||
"dist/*"
|
||||
],
|
||||
"scripts": {
|
||||
"build": "webpack --config webpack.prod.js",
|
||||
"clean": "rm -rf dist",
|
||||
"npm-publish": "npm publish --access public",
|
||||
"prepare": "yarn build",
|
||||
"prepublishOnly": "yarn build",
|
||||
"serve": "serve dist -p 3002",
|
||||
"start": "webpack serve --config webpack.dev.js",
|
||||
"test": "jest --coverage --config jest.config.js --no-cache",
|
||||
"version:prerelease": "yarn version prerelease",
|
||||
"version:patch": "yarn version patch -d",
|
||||
"version:minor": "yarn version minor -d",
|
||||
"version:major": "yarn version major -d"
|
||||
},
|
||||
"dependencies": {
|
||||
"@lowdefy/block-tools": "1.0.1-alpha.13",
|
||||
"react": "17.0.1",
|
||||
"react-dom": "17.0.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/cli": "7.12.1",
|
||||
"@babel/core": "7.12.3",
|
||||
"@babel/preset-env": "7.12.1",
|
||||
"@babel/preset-react": "7.12.1",
|
||||
"@wojtekmaj/enzyme-adapter-react-17": "0.2.0",
|
||||
"babel-jest": "26.6.1",
|
||||
"babel-loader": "8.1.0",
|
||||
"buffer": "5.7.0",
|
||||
"clean-webpack-plugin": "3.0.0",
|
||||
"copy-webpack-plugin": "6.2.1",
|
||||
"css-loader": "5.0.0",
|
||||
"enzyme": "3.11.0",
|
||||
"html-webpack-plugin": "4.5.0",
|
||||
"identity-obj-proxy": "3.0.0",
|
||||
"jest": "26.5.2",
|
||||
"js-yaml": "3.14.0",
|
||||
"react-markdown": "4.3.1",
|
||||
"react-syntax-highlighter": "15.2.1",
|
||||
"serve": "11.3.2",
|
||||
"style-loader": "2.0.0",
|
||||
"webpack": "5.3.2",
|
||||
"webpack-cli": "4.1.0",
|
||||
"webpack-dev-server": "3.11.0",
|
||||
"webpack-merge": "5.2.0",
|
||||
"yaml-jest": "1.0.5",
|
||||
"yaml-loader": "0.6.0"
|
||||
}
|
||||
}
|
7
packages/blocksBasic/public/index.html
Normal file
7
packages/blocksBasic/public/index.html
Normal file
@ -0,0 +1,7 @@
|
||||
<html>
|
||||
<head>
|
||||
</head>
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
</body>
|
||||
</html>
|
36
packages/blocksBasic/src/blocks/Box/Box.js
Normal file
36
packages/blocksBasic/src/blocks/Box/Box.js
Normal file
@ -0,0 +1,36 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { blockDefaultProps } from '@lowdefy/block-tools';
|
||||
|
||||
const Box = ({ blockId, content, properties, methods, actions }) => (
|
||||
<div
|
||||
id={blockId}
|
||||
data-testid={blockId}
|
||||
onClick={() => methods.callAction({ action: 'onClick' })}
|
||||
className={methods.makeCssClass([
|
||||
{ outline: 'none', cursor: actions.onClick && 'pointer' },
|
||||
properties.style,
|
||||
])}
|
||||
>
|
||||
{properties.content || (content.content && content.content())}
|
||||
</div>
|
||||
);
|
||||
|
||||
Box.defaultProps = blockDefaultProps;
|
||||
|
||||
export default Box;
|
29
packages/blocksBasic/src/blocks/Box/Box.json
Normal file
29
packages/blocksBasic/src/blocks/Box/Box.json
Normal file
@ -0,0 +1,29 @@
|
||||
{
|
||||
"category": "container",
|
||||
"loading": false,
|
||||
"schema": {
|
||||
"properties": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"content": {
|
||||
"type": "string",
|
||||
"description": "Box content string, alternatively provide and list of blocks as Box content."
|
||||
},
|
||||
"style": {
|
||||
"type": "object",
|
||||
"description": "Style to apply to Box div."
|
||||
}
|
||||
}
|
||||
},
|
||||
"actions": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"onClick": {
|
||||
"type": "array"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
36
packages/blocksBasic/src/blocks/Context/Context.js
Normal file
36
packages/blocksBasic/src/blocks/Context/Context.js
Normal file
@ -0,0 +1,36 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { blockDefaultProps } from '@lowdefy/block-tools';
|
||||
|
||||
const Context = ({ blockId, content, properties, methods, actions }) => (
|
||||
<div
|
||||
id={blockId}
|
||||
data-testid={blockId}
|
||||
onClick={() => methods.callAction({ action: 'onClick' })}
|
||||
className={methods.makeCssClass([
|
||||
{ outline: 'none', cursor: actions.onClick && 'pointer' },
|
||||
properties.style,
|
||||
])}
|
||||
>
|
||||
{properties.content || (content.content && content.content())}
|
||||
</div>
|
||||
);
|
||||
|
||||
Context.defaultProps = blockDefaultProps;
|
||||
|
||||
export default Context;
|
29
packages/blocksBasic/src/blocks/Context/Context.json
Normal file
29
packages/blocksBasic/src/blocks/Context/Context.json
Normal file
@ -0,0 +1,29 @@
|
||||
{
|
||||
"category": "context",
|
||||
"loading": false,
|
||||
"schema": {
|
||||
"properties": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"content": {
|
||||
"type": "string",
|
||||
"description": "Context content string, alternatively provide and list of blocks as Context content."
|
||||
},
|
||||
"style": {
|
||||
"type": "object",
|
||||
"description": "Style to apply to Context div."
|
||||
}
|
||||
}
|
||||
},
|
||||
"actions": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"onClick": {
|
||||
"type": "array"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
51
packages/blocksBasic/src/blocks/Html/Html.js
Normal file
51
packages/blocksBasic/src/blocks/Html/Html.js
Normal file
@ -0,0 +1,51 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { blockDefaultProps } from '@lowdefy/block-tools';
|
||||
|
||||
class HtmlBlock extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.div = null;
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.div.innerHTML = this.props.properties.html;
|
||||
}
|
||||
|
||||
componentDidUpdate() {
|
||||
this.div.innerHTML = this.props.properties.html;
|
||||
}
|
||||
|
||||
render() {
|
||||
const { blockId, properties, methods } = this.props;
|
||||
return (
|
||||
<div
|
||||
id={blockId}
|
||||
data-testid={blockId}
|
||||
ref={(el) => {
|
||||
this.div = el;
|
||||
}}
|
||||
className={methods.makeCssClass(properties.style)}
|
||||
/>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
HtmlBlock.defaultProps = blockDefaultProps;
|
||||
|
||||
export default HtmlBlock;
|
20
packages/blocksBasic/src/blocks/Html/Html.json
Normal file
20
packages/blocksBasic/src/blocks/Html/Html.json
Normal file
@ -0,0 +1,20 @@
|
||||
{
|
||||
"category": "display",
|
||||
"loading": false,
|
||||
"schema": {
|
||||
"properties": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"html": {
|
||||
"type": "string",
|
||||
"description": "Content to be rendered as Html."
|
||||
},
|
||||
"style": {
|
||||
"type": "object",
|
||||
"description": "Style to apply to Html div."
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
44
packages/blocksBasic/src/blocks/List/List.js
Normal file
44
packages/blocksBasic/src/blocks/List/List.js
Normal file
@ -0,0 +1,44 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React, { useEffect } from 'react';
|
||||
import { blockDefaultProps } from '@lowdefy/block-tools';
|
||||
import Box from '../Box/Box';
|
||||
|
||||
const List = ({ actions, blockId, methods, properties, list }) => {
|
||||
useEffect(() => {
|
||||
methods.registerMethod('pushItem', methods.pushItem);
|
||||
methods.registerMethod('unshiftItem', methods.unshiftItem);
|
||||
methods.registerMethod('removeItem', methods.removeItem);
|
||||
methods.registerMethod('moveItemDown', methods.moveItemDown);
|
||||
methods.registerMethod('moveItemUp', methods.moveItemUp);
|
||||
}, []);
|
||||
return (
|
||||
<Box
|
||||
actions={actions}
|
||||
blockId={blockId}
|
||||
properties={{ style: properties.style }}
|
||||
methods={methods}
|
||||
content={{
|
||||
content: () => list.map((item) => item.content()),
|
||||
}}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
List.defaultProps = blockDefaultProps;
|
||||
|
||||
export default List;
|
27
packages/blocksBasic/src/blocks/List/List.json
Normal file
27
packages/blocksBasic/src/blocks/List/List.json
Normal file
@ -0,0 +1,27 @@
|
||||
{
|
||||
"category": "list",
|
||||
"valueType": "array",
|
||||
"loading": false,
|
||||
"schema": {
|
||||
"properties": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"style": {
|
||||
"type": "object",
|
||||
"description": "Style to apply to Box div."
|
||||
}
|
||||
}
|
||||
},
|
||||
"actions": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"onClick": {
|
||||
"type": "array"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
36
packages/blocksBasic/src/blocks/Span/Span.js
Normal file
36
packages/blocksBasic/src/blocks/Span/Span.js
Normal file
@ -0,0 +1,36 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { blockDefaultProps } from '@lowdefy/block-tools';
|
||||
|
||||
const Span = ({ actions, blockId, properties, content, methods }) => (
|
||||
<span
|
||||
id={blockId}
|
||||
data-testid={blockId}
|
||||
onClick={() => methods.callAction({ action: 'onClick' })}
|
||||
className={methods.makeCssClass([
|
||||
{ outline: 'none', cursor: actions.onClick && 'pointer' },
|
||||
properties.style,
|
||||
])}
|
||||
>
|
||||
{properties.content || (content.content && content.content())}
|
||||
</span>
|
||||
);
|
||||
|
||||
Span.defaultProps = blockDefaultProps;
|
||||
|
||||
export default Span;
|
29
packages/blocksBasic/src/blocks/Span/Span.json
Normal file
29
packages/blocksBasic/src/blocks/Span/Span.json
Normal file
@ -0,0 +1,29 @@
|
||||
{
|
||||
"category": "container",
|
||||
"loading": false,
|
||||
"schema": {
|
||||
"properties": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"content": {
|
||||
"type": "string",
|
||||
"description": "Span content string, alternatively provide and list of blocks as Span content."
|
||||
},
|
||||
"style": {
|
||||
"type": "object",
|
||||
"description": "Style to apply to Span div."
|
||||
}
|
||||
}
|
||||
},
|
||||
"actions": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"onClick": {
|
||||
"type": "array"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
24
packages/blocksBasic/src/index.js
Normal file
24
packages/blocksBasic/src/index.js
Normal file
@ -0,0 +1,24 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import Box from './blocks/Box/Box';
|
||||
import Context from './blocks/Context/Context';
|
||||
import Html from './blocks/Html/Html';
|
||||
import List from './blocks/List/List';
|
||||
import Span from './blocks/Span/Span';
|
||||
|
||||
export { Box, Context, Html, Span, List };
|
||||
export default { Box, Context, Html, Span, List };
|
42
packages/blocksBasic/tests/Box.test.js
Normal file
42
packages/blocksBasic/tests/Box.test.js
Normal file
@ -0,0 +1,42 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { mockBlock, runBlockSchemaTests, runRenderTests } from '@lowdefy/block-tools';
|
||||
import { configure, mount } from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
configure({ adapter: new Adapter() });
|
||||
|
||||
import { Box } from '../src';
|
||||
import examples from '../demo/examples/Box.yaml';
|
||||
import meta from '../src/blocks/Box/Box.json';
|
||||
|
||||
runRenderTests({ examples, Block: Box, meta });
|
||||
runBlockSchemaTests({ examples, meta });
|
||||
|
||||
const { before, methods, getProps } = mockBlock({ meta });
|
||||
beforeEach(before);
|
||||
|
||||
test('callAction onClick', () => {
|
||||
const block = {
|
||||
id: 'one',
|
||||
type: 'Box',
|
||||
};
|
||||
const Shell = () => <Box {...getProps(block)} methods={methods} />;
|
||||
const wrapper = mount(<Shell />);
|
||||
wrapper.find('[data-testid="one"]').simulate('click');
|
||||
expect(methods.callAction).toHaveBeenCalledWith({ action: 'onClick' });
|
||||
});
|
42
packages/blocksBasic/tests/Context.test.js
Normal file
42
packages/blocksBasic/tests/Context.test.js
Normal file
@ -0,0 +1,42 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { mockBlock, runBlockSchemaTests, runRenderTests } from '@lowdefy/block-tools';
|
||||
import { configure, mount } from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
configure({ adapter: new Adapter() });
|
||||
|
||||
import { Context } from '../src';
|
||||
import examples from '../demo/examples/Context.yaml';
|
||||
import meta from '../src/blocks/Context/Context.json';
|
||||
|
||||
runRenderTests({ examples, Block: Context, meta });
|
||||
runBlockSchemaTests({ examples, meta });
|
||||
|
||||
const { before, methods, getProps } = mockBlock({ meta });
|
||||
beforeEach(before);
|
||||
|
||||
test('callAction onClick', () => {
|
||||
const block = {
|
||||
id: 'one',
|
||||
type: 'Context',
|
||||
};
|
||||
const Shell = () => <Context {...getProps(block)} methods={methods} />;
|
||||
const wrapper = mount(<Shell />);
|
||||
wrapper.find('[data-testid="one"]').simulate('click');
|
||||
expect(methods.callAction).toHaveBeenCalledWith({ action: 'onClick' });
|
||||
});
|
53
packages/blocksBasic/tests/Html.test.js
Normal file
53
packages/blocksBasic/tests/Html.test.js
Normal file
@ -0,0 +1,53 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { mockBlock, runBlockSchemaTests, runRenderTests } from '@lowdefy/block-tools';
|
||||
import { configure, mount } from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
configure({ adapter: new Adapter() });
|
||||
|
||||
import { Html } from '../src';
|
||||
import examples from '../demo/examples/Html.yaml';
|
||||
import meta from '../src/blocks/Html/Html.json';
|
||||
|
||||
runRenderTests({ examples, Block: Html, meta });
|
||||
runBlockSchemaTests({ examples, meta });
|
||||
|
||||
const { before, methods, getProps } = mockBlock({ meta });
|
||||
beforeEach(before);
|
||||
|
||||
test('update on properties.html change', () => {
|
||||
const config = {
|
||||
id: 'update',
|
||||
type: 'Html',
|
||||
properties: {
|
||||
html: '<div>one</div>',
|
||||
},
|
||||
};
|
||||
const Shell = ({ properties }) => (
|
||||
<Html {...getProps(config)} methods={methods} properties={properties} />
|
||||
);
|
||||
const wrapper = mount(<Shell properties={config.properties} />);
|
||||
expect(wrapper.html()).toMatchInlineSnapshot(
|
||||
`"<div id=\\"update\\" data-testid=\\"update\\" class=\\"{}\\"><div>one</div></div>"`
|
||||
);
|
||||
wrapper.setProps({ properties: { html: '<div>two</div>' } });
|
||||
wrapper.update();
|
||||
expect(wrapper.html()).toMatchInlineSnapshot(
|
||||
`"<div id=\\"update\\" data-testid=\\"update\\" class=\\"{}\\"><div>two</div></div>"`
|
||||
);
|
||||
});
|
116
packages/blocksBasic/tests/List.test.js
Normal file
116
packages/blocksBasic/tests/List.test.js
Normal file
@ -0,0 +1,116 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { mockBlock, runBlockSchemaTests, runRenderTests } from '@lowdefy/block-tools';
|
||||
import { configure, mount } from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
configure({ adapter: new Adapter() });
|
||||
|
||||
import { List } from '../src';
|
||||
import examples from '../demo/examples/List.yaml';
|
||||
import meta from '../src/blocks/List/List.json';
|
||||
|
||||
runRenderTests({ examples, Block: List, meta });
|
||||
runBlockSchemaTests({ examples, meta });
|
||||
|
||||
const { before, methods, getProps } = mockBlock({ meta });
|
||||
beforeEach(before);
|
||||
|
||||
test('callAction onClick', () => {
|
||||
const block = {
|
||||
id: 'one',
|
||||
type: 'List',
|
||||
};
|
||||
const Shell = () => <List {...getProps(block)} methods={methods} />;
|
||||
const wrapper = mount(<Shell />);
|
||||
wrapper.find('[data-testid="one"]').simulate('click');
|
||||
expect(methods.callAction).toHaveBeenCalledWith({ action: 'onClick' });
|
||||
});
|
||||
|
||||
test('register list methods on mount', () => {
|
||||
const block = {
|
||||
id: 'update',
|
||||
type: 'List',
|
||||
properties: {
|
||||
style: { test: 1 },
|
||||
},
|
||||
blocks: [
|
||||
{
|
||||
id: 'one',
|
||||
type: 'Test',
|
||||
},
|
||||
],
|
||||
};
|
||||
const Shell = ({ properties }) => (
|
||||
<List {...getProps(block)} methods={methods} properties={properties} />
|
||||
);
|
||||
const wrapper = mount(<Shell properties={block.properties} />);
|
||||
|
||||
expect(methods.registerMethod).toMatchInlineSnapshot(`
|
||||
[MockFunction] {
|
||||
"calls": Array [
|
||||
Array [
|
||||
"pushItem",
|
||||
[MockFunction],
|
||||
],
|
||||
Array [
|
||||
"unshiftItem",
|
||||
[MockFunction],
|
||||
],
|
||||
Array [
|
||||
"removeItem",
|
||||
[MockFunction],
|
||||
],
|
||||
Array [
|
||||
"moveItemDown",
|
||||
[MockFunction],
|
||||
],
|
||||
Array [
|
||||
"moveItemUp",
|
||||
[MockFunction],
|
||||
],
|
||||
],
|
||||
"results": Array [
|
||||
Object {
|
||||
"type": "return",
|
||||
"value": undefined,
|
||||
},
|
||||
Object {
|
||||
"type": "return",
|
||||
"value": undefined,
|
||||
},
|
||||
Object {
|
||||
"type": "return",
|
||||
"value": undefined,
|
||||
},
|
||||
Object {
|
||||
"type": "return",
|
||||
"value": undefined,
|
||||
},
|
||||
Object {
|
||||
"type": "return",
|
||||
"value": undefined,
|
||||
},
|
||||
],
|
||||
}
|
||||
`);
|
||||
expect(methods.registerMethod).toHaveBeenCalledTimes(5);
|
||||
// only on mount
|
||||
wrapper.setProps({ properties: { test: 2 } });
|
||||
wrapper.update();
|
||||
expect(methods.registerMethod).toHaveBeenCalledTimes(5);
|
||||
});
|
42
packages/blocksBasic/tests/Span.test.js
Normal file
42
packages/blocksBasic/tests/Span.test.js
Normal file
@ -0,0 +1,42 @@
|
||||
/*
|
||||
Copyright 2020 Lowdefy, Inc
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { mockBlock, runBlockSchemaTests, runRenderTests } from '@lowdefy/block-tools';
|
||||
import { configure, mount } from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
configure({ adapter: new Adapter() });
|
||||
|
||||
import { Span } from '../src';
|
||||
import examples from '../demo/examples/Span.yaml';
|
||||
import meta from '../src/blocks/Span/Span.json';
|
||||
|
||||
runRenderTests({ examples, Block: Span, meta });
|
||||
runBlockSchemaTests({ examples, meta });
|
||||
|
||||
const { before, methods, getProps } = mockBlock({ meta });
|
||||
beforeEach(before);
|
||||
|
||||
test('callAction onClick', () => {
|
||||
const block = {
|
||||
id: 'one',
|
||||
type: 'Span',
|
||||
};
|
||||
const Shell = () => <Span {...getProps(block)} methods={methods} />;
|
||||
const wrapper = mount(<Shell />);
|
||||
wrapper.find('[data-testid="one"]').simulate('click');
|
||||
expect(methods.callAction).toHaveBeenCalledWith({ action: 'onClick' });
|
||||
});
|
1
packages/blocksBasic/tests/__mocks__/styleMock.js
Normal file
1
packages/blocksBasic/tests/__mocks__/styleMock.js
Normal file
@ -0,0 +1 @@
|
||||
module.exports = {};
|
112
packages/blocksBasic/tests/__snapshots__/Box.test.js.snap
Normal file
112
packages/blocksBasic/tests/__snapshots__/Box.test.js.snap
Normal file
@ -0,0 +1,112 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`Render actions.onClick 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\",\\"cursor\\":\\"pointer\\"},null]}"
|
||||
data-testid="actions.onClick"
|
||||
id="actions.onClick"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render areas.content 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="areas.content"
|
||||
id="areas.content"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render default 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="default"
|
||||
id="default"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render properties.content 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="properties.content"
|
||||
id="properties.content"
|
||||
onClick={[Function]}
|
||||
>
|
||||
Foo
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render properties.style 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},{\\"border\\":\\"1px solid blue\\"}]}"
|
||||
data-testid="properties.style"
|
||||
id="properties.style"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Test Schema actions.onClick 1`] = `true`;
|
||||
|
||||
exports[`Test Schema actions.onClick 2`] = `null`;
|
||||
|
||||
exports[`Test Schema areas.content 1`] = `true`;
|
||||
|
||||
exports[`Test Schema areas.content 2`] = `null`;
|
||||
|
||||
exports[`Test Schema default 1`] = `true`;
|
||||
|
||||
exports[`Test Schema default 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.content 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.content 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.style 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.style 2`] = `null`;
|
112
packages/blocksBasic/tests/__snapshots__/Context.test.js.snap
Normal file
112
packages/blocksBasic/tests/__snapshots__/Context.test.js.snap
Normal file
@ -0,0 +1,112 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`Render actions.onClick 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\",\\"cursor\\":\\"pointer\\"},null]}"
|
||||
data-testid="actions.onClick"
|
||||
id="actions.onClick"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render areas.content 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="areas.content"
|
||||
id="areas.content"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render default 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="default"
|
||||
id="default"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render properties.content 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="properties.content"
|
||||
id="properties.content"
|
||||
onClick={[Function]}
|
||||
>
|
||||
Foo
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render properties.style 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},{\\"border\\":\\"1px solid blue\\"}]}"
|
||||
data-testid="properties.style"
|
||||
id="properties.style"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Test Schema actions.onClick 1`] = `true`;
|
||||
|
||||
exports[`Test Schema actions.onClick 2`] = `null`;
|
||||
|
||||
exports[`Test Schema areas.content 1`] = `true`;
|
||||
|
||||
exports[`Test Schema areas.content 2`] = `null`;
|
||||
|
||||
exports[`Test Schema default 1`] = `true`;
|
||||
|
||||
exports[`Test Schema default 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.content 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.content 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.style 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.style 2`] = `null`;
|
49
packages/blocksBasic/tests/__snapshots__/Html.test.js.snap
Normal file
49
packages/blocksBasic/tests/__snapshots__/Html.test.js.snap
Normal file
@ -0,0 +1,49 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`Render default 1`] = `
|
||||
<div
|
||||
className="{}"
|
||||
data-testid="default"
|
||||
id="default"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`Render properties.html 1`] = `
|
||||
<div
|
||||
className="{}"
|
||||
data-testid="properties.html"
|
||||
id="properties.html"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`Render properties.html-styled 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":{\\"background\\":\\"yellow\\",\\"padding\\":10}}"
|
||||
data-testid="properties.html-styled"
|
||||
id="properties.html-styled"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`Render properties.style 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":{\\"background\\":\\"yellow\\",\\"padding\\":10}}"
|
||||
data-testid="properties.style"
|
||||
id="properties.style"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`Test Schema default 1`] = `true`;
|
||||
|
||||
exports[`Test Schema default 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.html 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.html 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.html-styled 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.html-styled 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.style 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.style 2`] = `null`;
|
95
packages/blocksBasic/tests/__snapshots__/List.test.js.snap
Normal file
95
packages/blocksBasic/tests/__snapshots__/List.test.js.snap
Normal file
@ -0,0 +1,95 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`Render default 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="default"
|
||||
id="default"
|
||||
onClick={[Function]}
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`Render default-two-items 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="default-two-items"
|
||||
id="default-two-items"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
one
|
||||
</div>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
two
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Render properties.style 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},{\\"border\\":\\"1px solid blue\\"}]}"
|
||||
data-testid="properties.style"
|
||||
id="properties.style"
|
||||
onClick={[Function]}
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`Render properties.style-two-items 1`] = `
|
||||
<div
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},{\\"border\\":\\"1px solid blue\\"}]}"
|
||||
data-testid="properties.style-two-items"
|
||||
id="properties.style-two-items"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
one
|
||||
</div>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
two
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`Test Schema default 1`] = `true`;
|
||||
|
||||
exports[`Test Schema default 2`] = `null`;
|
||||
|
||||
exports[`Test Schema default-two-items 1`] = `true`;
|
||||
|
||||
exports[`Test Schema default-two-items 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.style 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.style 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.style-two-items 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.style-two-items 2`] = `null`;
|
112
packages/blocksBasic/tests/__snapshots__/Span.test.js.snap
Normal file
112
packages/blocksBasic/tests/__snapshots__/Span.test.js.snap
Normal file
@ -0,0 +1,112 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`Render actions.onClick 1`] = `
|
||||
<span
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\",\\"cursor\\":\\"pointer\\"},null]}"
|
||||
data-testid="actions.onClick"
|
||||
id="actions.onClick"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</span>
|
||||
`;
|
||||
|
||||
exports[`Render areas.content 1`] = `
|
||||
<span
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="areas.content"
|
||||
id="areas.content"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</span>
|
||||
`;
|
||||
|
||||
exports[`Render default 1`] = `
|
||||
<span
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="default"
|
||||
id="default"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</span>
|
||||
`;
|
||||
|
||||
exports[`Render properties.content 1`] = `
|
||||
<span
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},null]}"
|
||||
data-testid="properties.content"
|
||||
id="properties.content"
|
||||
onClick={[Function]}
|
||||
>
|
||||
Foo
|
||||
</span>
|
||||
`;
|
||||
|
||||
exports[`Render properties.style 1`] = `
|
||||
<span
|
||||
className="{\\"style\\":[{\\"outline\\":\\"none\\"},{\\"border\\":\\"1px solid blue\\"}]}"
|
||||
data-testid="properties.style"
|
||||
id="properties.style"
|
||||
onClick={[Function]}
|
||||
>
|
||||
<div
|
||||
style={
|
||||
Object {
|
||||
"border": "1px solid red",
|
||||
"padding": 10,
|
||||
}
|
||||
}
|
||||
>
|
||||
content
|
||||
</div>
|
||||
</span>
|
||||
`;
|
||||
|
||||
exports[`Test Schema actions.onClick 1`] = `true`;
|
||||
|
||||
exports[`Test Schema actions.onClick 2`] = `null`;
|
||||
|
||||
exports[`Test Schema areas.content 1`] = `true`;
|
||||
|
||||
exports[`Test Schema areas.content 2`] = `null`;
|
||||
|
||||
exports[`Test Schema default 1`] = `true`;
|
||||
|
||||
exports[`Test Schema default 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.content 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.content 2`] = `null`;
|
||||
|
||||
exports[`Test Schema properties.style 1`] = `true`;
|
||||
|
||||
exports[`Test Schema properties.style 2`] = `null`;
|
95
packages/blocksBasic/webpack.common.js
Normal file
95
packages/blocksBasic/webpack.common.js
Normal file
@ -0,0 +1,95 @@
|
||||
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||
const { ModuleFederationPlugin } = require('webpack').container;
|
||||
const path = require('path');
|
||||
const fs = require('fs');
|
||||
|
||||
const package = require('./package.json');
|
||||
|
||||
const sanitizeName = (name) => {
|
||||
return name
|
||||
.replace('@', '_at_')
|
||||
.replace('/', '_slash_')
|
||||
.replace('-', '_dash_')
|
||||
.replace(/^[a-zA-Z0-9_]/g, '_');
|
||||
};
|
||||
|
||||
// Get all directories in ./src/blocks folder and create module definition for ModuleFederation
|
||||
const getDirectories = (srcPath) =>
|
||||
fs.readdirSync(srcPath).filter((file) => fs.statSync(path.join(srcPath, file)).isDirectory());
|
||||
const blockModules = () => {
|
||||
const blocks = getDirectories('./src/blocks');
|
||||
const modules = {};
|
||||
blocks.forEach((block) => {
|
||||
modules[`./${block}`] = `./src/blocks/${block}/${block}.js`;
|
||||
// modules[`./${block}/meta`] = `./src/blocks/${block}/${block}.json`;
|
||||
});
|
||||
return modules;
|
||||
};
|
||||
|
||||
module.exports = {
|
||||
output: {
|
||||
path: path.resolve(__dirname, 'dist'),
|
||||
},
|
||||
resolve: { fallback: { buffer: require.resolve('buffer/') } },
|
||||
module: {
|
||||
rules: [
|
||||
// TODO: FIXME: do NOT webpack 5 support with this
|
||||
// x-ref: https://github.com/webpack/webpack/issues/11467
|
||||
// waiting for babel fix: https://github.com/vercel/next.js/pull/17095#issuecomment-692435147
|
||||
{
|
||||
test: /\.m?js/,
|
||||
resolve: {
|
||||
fullySpecified: false,
|
||||
},
|
||||
},
|
||||
{
|
||||
test: /\.jsx?$/,
|
||||
loader: 'babel-loader',
|
||||
exclude: /node_modules/,
|
||||
options: {
|
||||
presets: ['@babel/preset-react'],
|
||||
},
|
||||
},
|
||||
{
|
||||
test: /\.ya?ml$/,
|
||||
type: 'json',
|
||||
use: 'yaml-loader',
|
||||
},
|
||||
{
|
||||
test: /\.css$/,
|
||||
use: [
|
||||
{
|
||||
loader: 'style-loader',
|
||||
},
|
||||
{
|
||||
loader: 'css-loader', // translates CSS into CommonJS
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
plugins: [
|
||||
new ModuleFederationPlugin({
|
||||
name: sanitizeName(package.name),
|
||||
library: { type: 'var', name: sanitizeName(package.name) },
|
||||
filename: 'remoteEntry.js',
|
||||
exposes: blockModules(),
|
||||
shared: {
|
||||
...package.dependencies,
|
||||
react: {
|
||||
singleton: true, // only a single version of the shared module is allowed
|
||||
requiredVersion: '~17.0.0',
|
||||
version: package.dependencies.react,
|
||||
},
|
||||
'react-dom': {
|
||||
singleton: true, // only a single version of the shared module is allowed
|
||||
requiredVersion: '~17.0.0',
|
||||
version: package.dependencies['react-dom'],
|
||||
},
|
||||
},
|
||||
}),
|
||||
new HtmlWebpackPlugin({
|
||||
template: './public/index.html',
|
||||
}),
|
||||
],
|
||||
};
|
49
packages/blocksBasic/webpack.dev.js
Normal file
49
packages/blocksBasic/webpack.dev.js
Normal file
@ -0,0 +1,49 @@
|
||||
const CopyPlugin = require('copy-webpack-plugin');
|
||||
const path = require('path');
|
||||
const { merge } = require('webpack-merge');
|
||||
|
||||
const common = require('./webpack.common.js');
|
||||
const package = require('./package.json');
|
||||
|
||||
const sanitizeName = (name) => {
|
||||
return name
|
||||
.replace('@', '_at_')
|
||||
.replace('/', '_slash_')
|
||||
.replace('-', '_dash_')
|
||||
.replace(/^[a-zA-Z0-9_]/g, '_');
|
||||
};
|
||||
|
||||
const addRemoteEntryUrl = (content, absoluteFrom) => {
|
||||
const scope = sanitizeName(package.name);
|
||||
const meta = JSON.parse(content);
|
||||
meta.moduleFederation = {
|
||||
module: path.basename(absoluteFrom, '.json'),
|
||||
scope,
|
||||
version: package.version,
|
||||
remoteEntryUrl: 'http://localhost:3002/remoteEntry.js',
|
||||
};
|
||||
return JSON.stringify(meta);
|
||||
};
|
||||
|
||||
module.exports = merge(common, {
|
||||
entry: './demo/index',
|
||||
mode: 'development',
|
||||
devtool: 'eval-source-map',
|
||||
devServer: {
|
||||
contentBase: path.join(__dirname, 'dist'),
|
||||
port: 3002,
|
||||
},
|
||||
plugins: [
|
||||
new CopyPlugin({
|
||||
patterns: [
|
||||
{
|
||||
from: 'src/blocks/**/*.json',
|
||||
transformPath: (targetPath) => {
|
||||
return path.join('meta', path.basename(targetPath));
|
||||
},
|
||||
transform: addRemoteEntryUrl,
|
||||
},
|
||||
],
|
||||
}),
|
||||
],
|
||||
});
|
47
packages/blocksBasic/webpack.prod.js
Normal file
47
packages/blocksBasic/webpack.prod.js
Normal file
@ -0,0 +1,47 @@
|
||||
const CopyPlugin = require('copy-webpack-plugin');
|
||||
const path = require('path');
|
||||
const { merge } = require('webpack-merge');
|
||||
|
||||
const common = require('./webpack.common.js');
|
||||
const package = require('./package.json');
|
||||
|
||||
const sanitizeName = (name) => {
|
||||
return name
|
||||
.replace('@', '_at_')
|
||||
.replace('/', '_slash_')
|
||||
.replace('-', '_dash_')
|
||||
.replace(/^[a-zA-Z0-9_]/g, '_');
|
||||
};
|
||||
|
||||
const addRemoteEntryUrl = (content, absoluteFrom) => {
|
||||
const scope = sanitizeName(package.name);
|
||||
const meta = JSON.parse(content);
|
||||
// if no moduleFederation info is provided, default to unpkg
|
||||
if (!meta.moduleFederation) {
|
||||
meta.moduleFederation = {
|
||||
module: path.basename(absoluteFrom, '.json'),
|
||||
scope,
|
||||
version: package.version,
|
||||
remoteEntryUrl: `https://unpkg.com/${package.name}@${package.version}/dist/remoteEntry.js`,
|
||||
};
|
||||
}
|
||||
return JSON.stringify(meta);
|
||||
};
|
||||
|
||||
module.exports = merge(common, {
|
||||
entry: './src/index',
|
||||
mode: 'production',
|
||||
plugins: [
|
||||
new CopyPlugin({
|
||||
patterns: [
|
||||
{
|
||||
from: 'src/blocks/**/*.json',
|
||||
transformPath: (targetPath) => {
|
||||
return path.join('meta', path.basename(targetPath));
|
||||
},
|
||||
transform: addRemoteEntryUrl,
|
||||
},
|
||||
],
|
||||
}),
|
||||
],
|
||||
});
|
600
yarn.lock
600
yarn.lock
@ -1526,7 +1526,7 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@babel/runtime@npm:^7.0.0, @babel/runtime@npm:^7.1.2, @babel/runtime@npm:^7.10.1, @babel/runtime@npm:^7.10.2, @babel/runtime@npm:^7.10.4, @babel/runtime@npm:^7.11.1, @babel/runtime@npm:^7.11.2, @babel/runtime@npm:^7.12.1, @babel/runtime@npm:^7.8.4":
|
||||
"@babel/runtime@npm:^7.0.0, @babel/runtime@npm:^7.1.2, @babel/runtime@npm:^7.10.1, @babel/runtime@npm:^7.10.2, @babel/runtime@npm:^7.10.4, @babel/runtime@npm:^7.11.1, @babel/runtime@npm:^7.11.2, @babel/runtime@npm:^7.12.1, @babel/runtime@npm:^7.3.1, @babel/runtime@npm:^7.8.4":
|
||||
version: 7.12.1
|
||||
resolution: "@babel/runtime@npm:7.12.1"
|
||||
dependencies:
|
||||
@ -1810,7 +1810,7 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@jest/core@npm:^26.5.3, @jest/core@npm:^26.6.1":
|
||||
"@jest/core@npm:^26.5.2, @jest/core@npm:^26.5.3, @jest/core@npm:^26.6.1":
|
||||
version: 26.6.1
|
||||
resolution: "@jest/core@npm:26.6.1"
|
||||
dependencies:
|
||||
@ -2808,8 +2808,6 @@ __metadata:
|
||||
ajv-errors: 1.0.1
|
||||
babel-jest: 26.6.1
|
||||
babel-loader: 8.1.0
|
||||
babel-plugin-import: 1.13.1
|
||||
buffer: 5.7.0
|
||||
clean-webpack-plugin: 3.0.0
|
||||
create-emotion: 10.0.27
|
||||
css-loader: 5.0.0
|
||||
@ -2833,6 +2831,42 @@ __metadata:
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@lowdefy/blocks-basic@workspace:packages/blocksBasic":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@lowdefy/blocks-basic@workspace:packages/blocksBasic"
|
||||
dependencies:
|
||||
"@babel/cli": 7.12.1
|
||||
"@babel/core": 7.12.3
|
||||
"@babel/preset-env": 7.12.1
|
||||
"@babel/preset-react": 7.12.1
|
||||
"@lowdefy/block-tools": 1.0.1-alpha.13
|
||||
"@wojtekmaj/enzyme-adapter-react-17": 0.2.0
|
||||
babel-jest: 26.6.1
|
||||
babel-loader: 8.1.0
|
||||
buffer: 5.7.0
|
||||
clean-webpack-plugin: 3.0.0
|
||||
copy-webpack-plugin: 6.2.1
|
||||
css-loader: 5.0.0
|
||||
enzyme: 3.11.0
|
||||
html-webpack-plugin: 4.5.0
|
||||
identity-obj-proxy: 3.0.0
|
||||
jest: 26.5.2
|
||||
js-yaml: 3.14.0
|
||||
react: 17.0.1
|
||||
react-dom: 17.0.1
|
||||
react-markdown: 4.3.1
|
||||
react-syntax-highlighter: 15.2.1
|
||||
serve: 11.3.2
|
||||
style-loader: 2.0.0
|
||||
webpack: 5.3.2
|
||||
webpack-cli: 4.1.0
|
||||
webpack-dev-server: 3.11.0
|
||||
webpack-merge: 5.2.0
|
||||
yaml-jest: 1.0.5
|
||||
yaml-loader: 0.6.0
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
"@lowdefy/build@workspace:packages/build":
|
||||
version: 0.0.0-use.local
|
||||
resolution: "@lowdefy/build@workspace:packages/build"
|
||||
@ -3219,6 +3253,15 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@npmcli/move-file@npm:^1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "@npmcli/move-file@npm:1.0.1"
|
||||
dependencies:
|
||||
mkdirp: ^1.0.4
|
||||
checksum: ed2cb75eefe218113794416fae43b5307f7c30476506942ed6c6c51f702713323842f81102ae1327f9134130bec0360312e6f858ddef143c21d9e269e90737ac
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@octokit/auth-token@npm:^2.4.0":
|
||||
version: 2.4.2
|
||||
resolution: "@octokit/auth-token@npm:2.4.2"
|
||||
@ -3717,6 +3760,15 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@types/hast@npm:^2.0.0":
|
||||
version: 2.3.1
|
||||
resolution: "@types/hast@npm:2.3.1"
|
||||
dependencies:
|
||||
"@types/unist": "*"
|
||||
checksum: 8aff367be477854d6cd3e5cf03d7154cd163a67bc3266777c2f4b1c32d07a335420ba58a8a799965dbc3190f1ed9989880008afb1392043290acc384a155a7a3
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@types/html-minifier-terser@npm:^5.0.0":
|
||||
version: 5.1.1
|
||||
resolution: "@types/html-minifier-terser@npm:5.1.1"
|
||||
@ -4654,6 +4706,16 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"aggregate-error@npm:^3.0.0":
|
||||
version: 3.1.0
|
||||
resolution: "aggregate-error@npm:3.1.0"
|
||||
dependencies:
|
||||
clean-stack: ^2.0.0
|
||||
indent-string: ^4.0.0
|
||||
checksum: 704d2001a303c185e9b836d211f7eef2f4557195a11c3271143b4dcda5f6f263abe746d9b8a06b5871d07870686c7db9c0b2c38e2d3cbc593784eaaee8a29043
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"airbnb-prop-types@npm:^2.16.0":
|
||||
version: 2.16.0
|
||||
resolution: "airbnb-prop-types@npm:2.16.0"
|
||||
@ -6206,6 +6268,31 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"cacache@npm:^15.0.5":
|
||||
version: 15.0.5
|
||||
resolution: "cacache@npm:15.0.5"
|
||||
dependencies:
|
||||
"@npmcli/move-file": ^1.0.1
|
||||
chownr: ^2.0.0
|
||||
fs-minipass: ^2.0.0
|
||||
glob: ^7.1.4
|
||||
infer-owner: ^1.0.4
|
||||
lru-cache: ^6.0.0
|
||||
minipass: ^3.1.1
|
||||
minipass-collect: ^1.0.2
|
||||
minipass-flush: ^1.0.5
|
||||
minipass-pipeline: ^1.2.2
|
||||
mkdirp: ^1.0.3
|
||||
p-map: ^4.0.0
|
||||
promise-inflight: ^1.0.1
|
||||
rimraf: ^3.0.2
|
||||
ssri: ^8.0.0
|
||||
tar: ^6.0.2
|
||||
unique-filename: ^1.1.1
|
||||
checksum: 8e371cbf3c5051585127e63a84c9f1e430032590e5c4ada17d57b7953e21f6d5722e7f29f80cfef26520175ea2d1705a0670897ed7fe64377c7bd2ee650be287
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"cache-base@npm:^1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "cache-base@npm:1.0.1"
|
||||
@ -6607,6 +6694,13 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"clean-stack@npm:^2.0.0":
|
||||
version: 2.2.0
|
||||
resolution: "clean-stack@npm:2.2.0"
|
||||
checksum: e291ce2b8c8c59e6449ac9a7a726090264bea6696e5343b21385e16d279c808ca09d73a1abea8fd23a9b7699e6ef5ce582df203511f71c8c27666bf3b2e300c5
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"clean-webpack-plugin@npm:3.0.0":
|
||||
version: 3.0.0
|
||||
resolution: "clean-webpack-plugin@npm:3.0.0"
|
||||
@ -6695,6 +6789,17 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"clipboard@npm:^2.0.0":
|
||||
version: 2.0.6
|
||||
resolution: "clipboard@npm:2.0.6"
|
||||
dependencies:
|
||||
good-listener: ^1.2.2
|
||||
select: ^1.1.2
|
||||
tiny-emitter: ^2.0.0
|
||||
checksum: 25e2e6b595f764ebb541dfda5c77051200567b5dd2de42ac6ab9681febe1256a977be450ab1d6f0d41554799106cc92e79e167797c8e8b8e88edcb0aec5b5dcb
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"clipboardy@npm:1.2.3":
|
||||
version: 1.2.3
|
||||
resolution: "clipboardy@npm:1.2.3"
|
||||
@ -6800,6 +6905,13 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"collapse-white-space@npm:^1.0.2":
|
||||
version: 1.0.6
|
||||
resolution: "collapse-white-space@npm:1.0.6"
|
||||
checksum: beca17619bd6f8a09bf1a08667d4951af39eeddb59c2a225d3f40a5b758bd0c42ebf8885488b73372c9330085b0971efa1b95503fca833d75e84d8cd1992914f
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"collect-v8-coverage@npm:^1.0.0":
|
||||
version: 1.0.1
|
||||
resolution: "collect-v8-coverage@npm:1.0.1"
|
||||
@ -6889,6 +7001,13 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"comma-separated-tokens@npm:^1.0.0":
|
||||
version: 1.0.8
|
||||
resolution: "comma-separated-tokens@npm:1.0.8"
|
||||
checksum: 31a5a2fa6e0f02764b0634e0aa31913c9be0ef568f4e58b5c1ec85d0a6e4a6c367905eacf2c7e59b57d3d05f40cff166ea3c9b6ee8338625cad060ce43ede9fd
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"command-line-usage@npm:^6.1.0":
|
||||
version: 6.1.0
|
||||
resolution: "command-line-usage@npm:6.1.0"
|
||||
@ -7273,6 +7392,27 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"copy-webpack-plugin@npm:6.2.1":
|
||||
version: 6.2.1
|
||||
resolution: "copy-webpack-plugin@npm:6.2.1"
|
||||
dependencies:
|
||||
cacache: ^15.0.5
|
||||
fast-glob: ^3.2.4
|
||||
find-cache-dir: ^3.3.1
|
||||
glob-parent: ^5.1.1
|
||||
globby: ^11.0.1
|
||||
loader-utils: ^2.0.0
|
||||
normalize-path: ^3.0.0
|
||||
p-limit: ^3.0.2
|
||||
schema-utils: ^3.0.0
|
||||
serialize-javascript: ^5.0.1
|
||||
webpack-sources: ^1.4.3
|
||||
peerDependencies:
|
||||
webpack: ^4.37.0 || ^5.0.0
|
||||
checksum: 99ef83b4237b51e95618365ad2e62775b640fe1cae0d39d3ab03bcb09c9026a00ab0fb1c03f72d164c1457482114ddf959e7a03ab409704f34686e0a64ee4a31
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"core-js-compat@npm:^3.6.2":
|
||||
version: 3.6.5
|
||||
resolution: "core-js-compat@npm:3.6.5"
|
||||
@ -7860,6 +8000,13 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"delegate@npm:^3.1.2":
|
||||
version: 3.2.0
|
||||
resolution: "delegate@npm:3.2.0"
|
||||
checksum: ccbbf29eb436719e4ffef06a1df2635a150f229f8ae549f4b6e118e940b17917e063c939541c6e23f38675d30acf424ecca9a8d1cca2a874d63fa0c257b0811f
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"delegates@npm:^1.0.0":
|
||||
version: 1.0.0
|
||||
resolution: "delegates@npm:1.0.0"
|
||||
@ -9221,7 +9368,7 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"fast-glob@npm:^3.1.1, fast-glob@npm:^3.2.2":
|
||||
"fast-glob@npm:^3.1.1, fast-glob@npm:^3.2.2, fast-glob@npm:^3.2.4":
|
||||
version: 3.2.4
|
||||
resolution: "fast-glob@npm:3.2.4"
|
||||
dependencies:
|
||||
@ -9267,6 +9414,15 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"fault@npm:^1.0.0":
|
||||
version: 1.0.4
|
||||
resolution: "fault@npm:1.0.4"
|
||||
dependencies:
|
||||
format: ^0.2.0
|
||||
checksum: 6b8ef4f7439b21a3c319e45ff68b31e1ca5de4e27f2aa5fd2138909b77e18e8fabaa131953aeb0be7038951c7d5a9f5394f81b06c5a1e41ea8a442e867b69bbb
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"faye-websocket@npm:^0.10.0":
|
||||
version: 0.10.0
|
||||
resolution: "faye-websocket@npm:0.10.0"
|
||||
@ -9421,6 +9577,17 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"find-cache-dir@npm:^3.3.1":
|
||||
version: 3.3.1
|
||||
resolution: "find-cache-dir@npm:3.3.1"
|
||||
dependencies:
|
||||
commondir: ^1.0.1
|
||||
make-dir: ^3.0.2
|
||||
pkg-dir: ^4.1.0
|
||||
checksum: b1e23226ee89fba89646aa5f72d084c6d04bb64f6d523c9cb2d57a1b5280fcac39e92fd5be572e2fae8a83aa70bc5b797ce33a826b9a4b92373cc38e66d4aa64
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"find-up@npm:^1.0.0":
|
||||
version: 1.1.2
|
||||
resolution: "find-up@npm:1.1.2"
|
||||
@ -9567,6 +9734,13 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"format@npm:^0.2.0":
|
||||
version: 0.2.2
|
||||
resolution: "format@npm:0.2.2"
|
||||
checksum: 0740f5212144e63dad4b3b2156d84a875c0649f4976ecfa91f21b086ad007e9af575e88cf782b202c5f5783fb6d4ee3cebcd357b79aa82d556f8401dc1762f55
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"forwarded@npm:~0.1.2":
|
||||
version: 0.1.2
|
||||
resolution: "forwarded@npm:0.1.2"
|
||||
@ -9964,7 +10138,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"glob-parent@npm:^5.0.0, glob-parent@npm:^5.1.0, glob-parent@npm:~5.1.0":
|
||||
"glob-parent@npm:^5.0.0, glob-parent@npm:^5.1.0, glob-parent@npm:^5.1.1, glob-parent@npm:~5.1.0":
|
||||
version: 5.1.1
|
||||
resolution: "glob-parent@npm:5.1.1"
|
||||
dependencies:
|
||||
@ -10128,6 +10302,15 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"good-listener@npm:^1.2.2":
|
||||
version: 1.2.2
|
||||
resolution: "good-listener@npm:1.2.2"
|
||||
dependencies:
|
||||
delegate: ^3.1.2
|
||||
checksum: 640a1627e528ceb3337595a8020f44d09455f284c18c765eaf9ce5dcdf1799810e7b11ca2b61582a5a4db20aad0b7e6b820235864822d84df541d74383bcd01c
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"got@npm:^10.7.0":
|
||||
version: 10.7.0
|
||||
resolution: "got@npm:10.7.0"
|
||||
@ -10475,6 +10658,26 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"hast-util-parse-selector@npm:^2.0.0":
|
||||
version: 2.2.4
|
||||
resolution: "hast-util-parse-selector@npm:2.2.4"
|
||||
checksum: affd2e8d834305c3fe495b499d063fb84c697d467b22e225d7598c24e1b987af5e44957f9af43f6f80074b8e8d34728836f3e348049575016735a8d623c4f947
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"hastscript@npm:^6.0.0":
|
||||
version: 6.0.0
|
||||
resolution: "hastscript@npm:6.0.0"
|
||||
dependencies:
|
||||
"@types/hast": ^2.0.0
|
||||
comma-separated-tokens: ^1.0.0
|
||||
hast-util-parse-selector: ^2.0.0
|
||||
property-information: ^5.0.0
|
||||
space-separated-tokens: ^1.0.0
|
||||
checksum: c801a859137b7b0092235e50b5c9927c8e0ddbfc4739f4da5bf20170821be6bd883744a11ed2a3909d00d24964632892118913b3b13b02601018035da8b00b52
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"he@npm:^1.2.0":
|
||||
version: 1.2.0
|
||||
resolution: "he@npm:1.2.0"
|
||||
@ -10484,6 +10687,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"highlight.js@npm:^10.1.1, highlight.js@npm:~10.3.0":
|
||||
version: 10.3.2
|
||||
resolution: "highlight.js@npm:10.3.2"
|
||||
checksum: 8dab959070ff2e20190cbe7ea9bc03ce0163f0a6a09d88cfec8f7e21ca12111c0553515b4c5b273748da531fb26de8f34a361f6f0f03c1348175d2424e265599
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"highlight.js@npm:^9.12.0":
|
||||
version: 9.18.3
|
||||
resolution: "highlight.js@npm:9.18.3"
|
||||
@ -10990,7 +11200,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"inherits@npm:2, inherits@npm:2.0.4, inherits@npm:^2.0.1, inherits@npm:^2.0.3, inherits@npm:^2.0.4, inherits@npm:~2.0.3":
|
||||
"inherits@npm:2, inherits@npm:2.0.4, inherits@npm:^2.0.0, inherits@npm:^2.0.1, inherits@npm:^2.0.3, inherits@npm:^2.0.4, inherits@npm:~2.0.3":
|
||||
version: 2.0.4
|
||||
resolution: "inherits@npm:2.0.4"
|
||||
checksum: 98426da247ddfc3dcd7d7daedd90c3ca32d5b08deca08949726f12d49232aef94772a07b36cf4ff833e105ae2ef931777f6de4a6dd8245a216b9299ad4a50bea
|
||||
@ -11213,7 +11423,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"is-buffer@npm:^1.1.5":
|
||||
"is-buffer@npm:^1.1.4, is-buffer@npm:^1.1.5":
|
||||
version: 1.1.6
|
||||
resolution: "is-buffer@npm:1.1.6"
|
||||
checksum: 336ec78f00e88efe6ff6f1aa08d06aadb942a6cd320e5f538ac00648378fb964743b3737c88ce7ce8741c067e4a3b78f596b83ee1a3c72dc2885ea0b03dc84f2
|
||||
@ -11654,6 +11864,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"is-whitespace-character@npm:^1.0.0":
|
||||
version: 1.0.4
|
||||
resolution: "is-whitespace-character@npm:1.0.4"
|
||||
checksum: fd6dbced044036b5c46213399b6f8825ca664a42278cfbeede1970ab3511a1b5ed64ee63b5a7b25afa094762fe778223b530e956dd28f894ceb4c10516fc7b27
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"is-windows@npm:^1.0.0, is-windows@npm:^1.0.1, is-windows@npm:^1.0.2":
|
||||
version: 1.0.2
|
||||
resolution: "is-windows@npm:1.0.2"
|
||||
@ -11661,6 +11878,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"is-word-character@npm:^1.0.0":
|
||||
version: 1.0.4
|
||||
resolution: "is-word-character@npm:1.0.4"
|
||||
checksum: 84da3b0a2c0a15623fbfa40a1a81d3ffa37879745b83eb4079edc9d4d3be0bd97de3c04defaf822c16a3d991688d18285dec30f233ac57aa5a2e31a2e22f95d0
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"is-wsl@npm:^1.1.0":
|
||||
version: 1.1.0
|
||||
resolution: "is-wsl@npm:1.1.0"
|
||||
@ -11836,7 +12060,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"jest-cli@npm:^26.5.3, jest-cli@npm:^26.6.1":
|
||||
"jest-cli@npm:^26.5.2, jest-cli@npm:^26.5.3, jest-cli@npm:^26.6.1":
|
||||
version: 26.6.1
|
||||
resolution: "jest-cli@npm:26.6.1"
|
||||
dependencies:
|
||||
@ -12258,6 +12482,19 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"jest@npm:26.5.2":
|
||||
version: 26.5.2
|
||||
resolution: "jest@npm:26.5.2"
|
||||
dependencies:
|
||||
"@jest/core": ^26.5.2
|
||||
import-local: ^3.0.2
|
||||
jest-cli: ^26.5.2
|
||||
bin:
|
||||
jest: bin/jest.js
|
||||
checksum: 8c31ca019ce4241f9de95bff9c389eb73db060278c7d19111c67554b2caebacd33b3ddc4eb9662f6d29e509aa012451a47c8021e58bbddf1d7439288de1d2eb1
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"jest@npm:26.5.3":
|
||||
version: 26.5.3
|
||||
resolution: "jest@npm:26.5.3"
|
||||
@ -13070,6 +13307,16 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"lowlight@npm:^1.14.0":
|
||||
version: 1.16.0
|
||||
resolution: "lowlight@npm:1.16.0"
|
||||
dependencies:
|
||||
fault: ^1.0.0
|
||||
highlight.js: ~10.3.0
|
||||
checksum: 98970f15c98487359ece6465c181f31991c4d964d7c703b94054a29a634a2b5fe3bee1ccf46784aecfa4ee33ae5219bad0f6f3f9ecf7eef07cc7670cb2bff7f4
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"lru-cache@npm:^4.0.1":
|
||||
version: 4.1.5
|
||||
resolution: "lru-cache@npm:4.1.5"
|
||||
@ -13089,6 +13336,15 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"lru-cache@npm:^6.0.0":
|
||||
version: 6.0.0
|
||||
resolution: "lru-cache@npm:6.0.0"
|
||||
dependencies:
|
||||
yallist: ^4.0.0
|
||||
checksum: b8b78353d2391c0f135cdc245c4744ad41c2efb1a6d98f31bc57a2cf48ebf02de96e4876657c3026673576bf1f1f61fc3fdd77ab00ad1ead737537bf17d8019d
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"lru-queue@npm:0.1":
|
||||
version: 0.1.0
|
||||
resolution: "lru-queue@npm:0.1.0"
|
||||
@ -13124,7 +13380,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"make-dir@npm:^3.0.0":
|
||||
"make-dir@npm:^3.0.0, make-dir@npm:^3.0.2":
|
||||
version: 3.1.0
|
||||
resolution: "make-dir@npm:3.1.0"
|
||||
dependencies:
|
||||
@ -13198,6 +13454,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"markdown-escapes@npm:^1.0.0":
|
||||
version: 1.0.4
|
||||
resolution: "markdown-escapes@npm:1.0.4"
|
||||
checksum: eea95364eccadf6fa656f2fd3f8e0837aee3a86b582a80d9c301c794512caaf0dba021614fcc5b93bfdb6110f2d8b9902da9bc915b33362fc335dca285d6d902
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"mdast-add-list-metadata@npm:1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "mdast-add-list-metadata@npm:1.0.1"
|
||||
@ -13600,6 +13863,33 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"minipass-collect@npm:^1.0.2":
|
||||
version: 1.0.2
|
||||
resolution: "minipass-collect@npm:1.0.2"
|
||||
dependencies:
|
||||
minipass: ^3.0.0
|
||||
checksum: 529ef6212333e6b9afc6aa4487a246df6fd28a28e42060533491ebf58fddb349f9b044f017725bddf3e13cae3986c58c24ee2531832f62e6d97379846e04e0a8
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"minipass-flush@npm:^1.0.5":
|
||||
version: 1.0.5
|
||||
resolution: "minipass-flush@npm:1.0.5"
|
||||
dependencies:
|
||||
minipass: ^3.0.0
|
||||
checksum: d354ca0da834e3e79a1f0372d1cb86ba043a96b495624ed6360f7cd1f549e5685d9b292d4193a963497efcf4a4db8563e188cda565b119b8acc00852259e286c
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"minipass-pipeline@npm:^1.2.2":
|
||||
version: 1.2.4
|
||||
resolution: "minipass-pipeline@npm:1.2.4"
|
||||
dependencies:
|
||||
minipass: ^3.0.0
|
||||
checksum: 001d5a4a0c14816230984e684e8458d972b92dae52255f17fbc2dae74965f544c3c64f93146c218413004e72acec7f57d0f6ee10a49377ad715cf7d389af710c
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"minipass@npm:^2.3.5, minipass@npm:^2.6.0, minipass@npm:^2.8.6, minipass@npm:^2.9.0":
|
||||
version: 2.9.0
|
||||
resolution: "minipass@npm:2.9.0"
|
||||
@ -13610,7 +13900,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"minipass@npm:^3.0.0":
|
||||
"minipass@npm:^3.0.0, minipass@npm:^3.1.1":
|
||||
version: 3.1.3
|
||||
resolution: "minipass@npm:3.1.3"
|
||||
dependencies:
|
||||
@ -14728,6 +15018,15 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"p-map@npm:^4.0.0":
|
||||
version: 4.0.0
|
||||
resolution: "p-map@npm:4.0.0"
|
||||
dependencies:
|
||||
aggregate-error: ^3.0.0
|
||||
checksum: d51e630d72b7c38bc9e396710e7a068f0b813fe4db6f4a2d1ce2972e7fa11142c763c3aa39bcfd77c0133688c1ebfdd9b38fa3ac4c6ada20b62df26239c5c0e4
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"p-pipe@npm:^1.2.0":
|
||||
version: 1.2.0
|
||||
resolution: "p-pipe@npm:1.2.0"
|
||||
@ -14843,6 +15142,20 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"parse-entities@npm:^1.1.0":
|
||||
version: 1.2.2
|
||||
resolution: "parse-entities@npm:1.2.2"
|
||||
dependencies:
|
||||
character-entities: ^1.0.0
|
||||
character-entities-legacy: ^1.0.0
|
||||
character-reference-invalid: ^1.0.0
|
||||
is-alphanumerical: ^1.0.0
|
||||
is-decimal: ^1.0.0
|
||||
is-hexadecimal: ^1.0.0
|
||||
checksum: 66fb7cb7c81284aa35408ef0aaae3c704a7005f9b2e99fb86f4c5b454d465b7520e81dbdd35c79a65da98a567a4f03bd74b4097dc965f72ef947a1e09d6bf838
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"parse-entities@npm:^2.0.0":
|
||||
version: 2.0.0
|
||||
resolution: "parse-entities@npm:2.0.0"
|
||||
@ -15180,7 +15493,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"pkg-dir@npm:^4.2.0":
|
||||
"pkg-dir@npm:^4.1.0, pkg-dir@npm:^4.2.0":
|
||||
version: 4.2.0
|
||||
resolution: "pkg-dir@npm:4.2.0"
|
||||
dependencies:
|
||||
@ -15364,6 +15677,18 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"prismjs@npm:^1.21.0, prismjs@npm:~1.22.0":
|
||||
version: 1.22.0
|
||||
resolution: "prismjs@npm:1.22.0"
|
||||
dependencies:
|
||||
clipboard: ^2.0.0
|
||||
dependenciesMeta:
|
||||
clipboard:
|
||||
optional: true
|
||||
checksum: c9370f1f6a8c419cf7d712527dede91de33080ecdd9265cf6a7f0938cfe75e954dae4a02915ac8b9df4485f0c9fbab94a7babfedb7076a83ed57b9b132255e34
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"private@npm:^0.1.8":
|
||||
version: 0.1.8
|
||||
resolution: "private@npm:0.1.8"
|
||||
@ -15478,6 +15803,15 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"property-information@npm:^5.0.0":
|
||||
version: 5.6.0
|
||||
resolution: "property-information@npm:5.6.0"
|
||||
dependencies:
|
||||
xtend: ^4.0.0
|
||||
checksum: d06969645665a2d1b4d701b90970ec3bbab123d55581ab5612e33cb4b5cd134522ed21fe1eb339440561249269f47f3896fb345d9c9c67e24ba69a764b14aaf7
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"proto-list@npm:~1.2.1":
|
||||
version: 1.2.4
|
||||
resolution: "proto-list@npm:1.2.4"
|
||||
@ -16316,6 +16650,24 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"react-markdown@npm:4.3.1":
|
||||
version: 4.3.1
|
||||
resolution: "react-markdown@npm:4.3.1"
|
||||
dependencies:
|
||||
html-to-react: ^1.3.4
|
||||
mdast-add-list-metadata: 1.0.1
|
||||
prop-types: ^15.7.2
|
||||
react-is: ^16.8.6
|
||||
remark-parse: ^5.0.0
|
||||
unified: ^6.1.5
|
||||
unist-util-visit: ^1.3.0
|
||||
xtend: ^4.0.1
|
||||
peerDependencies:
|
||||
react: ^15.0.0 || ^16.0.0
|
||||
checksum: 89111d726b03e47a0282557041aca3f918c9e4a9b2cdb4988061f162ad348fec576fcf91b1ab37d34f32475b620c72ea21a8bb61a8e1702d3fb8f5e7fc7f09b3
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"react-markdown@npm:5.0.2":
|
||||
version: 5.0.2
|
||||
resolution: "react-markdown@npm:5.0.2"
|
||||
@ -16408,6 +16760,21 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"react-syntax-highlighter@npm:15.2.1":
|
||||
version: 15.2.1
|
||||
resolution: "react-syntax-highlighter@npm:15.2.1"
|
||||
dependencies:
|
||||
"@babel/runtime": ^7.3.1
|
||||
highlight.js: ^10.1.1
|
||||
lowlight: ^1.14.0
|
||||
prismjs: ^1.21.0
|
||||
refractor: ^3.1.0
|
||||
peerDependencies:
|
||||
react: ">= 0.14.0"
|
||||
checksum: 22b880f0ece6c3dcef0796e18028931cf1580ecccae69c1e38b6cd1da3b84d4aa9c6aff4f87c6acce4b9256b28d05d571ded9e6d92c5c93b59df5dba825712c8
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"react-test-renderer@npm:17.0.1, react-test-renderer@npm:^17.0.0-0":
|
||||
version: 17.0.1
|
||||
resolution: "react-test-renderer@npm:17.0.1"
|
||||
@ -16711,6 +17078,17 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"refractor@npm:^3.1.0":
|
||||
version: 3.2.0
|
||||
resolution: "refractor@npm:3.2.0"
|
||||
dependencies:
|
||||
hastscript: ^6.0.0
|
||||
parse-entities: ^2.0.0
|
||||
prismjs: ~1.22.0
|
||||
checksum: 4b5e485bf8b3f25cfb269a141e14d09e8f86b35f9033b47531b9a17d7d18176db3d01b20d6f1721b83273678a7ece622f473b45c2f178483962ed18a4e3d4cd4
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"regenerate-unicode-properties@npm:^8.2.0":
|
||||
version: 8.2.0
|
||||
resolution: "regenerate-unicode-properties@npm:8.2.0"
|
||||
@ -16865,6 +17243,29 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"remark-parse@npm:^5.0.0":
|
||||
version: 5.0.0
|
||||
resolution: "remark-parse@npm:5.0.0"
|
||||
dependencies:
|
||||
collapse-white-space: ^1.0.2
|
||||
is-alphabetical: ^1.0.0
|
||||
is-decimal: ^1.0.0
|
||||
is-whitespace-character: ^1.0.0
|
||||
is-word-character: ^1.0.0
|
||||
markdown-escapes: ^1.0.0
|
||||
parse-entities: ^1.1.0
|
||||
repeat-string: ^1.5.4
|
||||
state-toggle: ^1.0.0
|
||||
trim: 0.0.1
|
||||
trim-trailing-lines: ^1.0.0
|
||||
unherit: ^1.0.4
|
||||
unist-util-remove-position: ^1.0.0
|
||||
vfile-location: ^2.0.0
|
||||
xtend: ^4.0.1
|
||||
checksum: e5295c40efaf32b93fe1217c35c85be2c84e97ae4c1f1c25b9f8595f2338a3f22c91d4c5ec8ee7be5540935ea5f21649a5297b73eb368cf1de6f7ecbc250871e
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"remark-parse@npm:^9.0.0":
|
||||
version: 9.0.0
|
||||
resolution: "remark-parse@npm:9.0.0"
|
||||
@ -16901,7 +17302,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"repeat-string@npm:^1.6.1":
|
||||
"repeat-string@npm:^1.5.4, repeat-string@npm:^1.6.1":
|
||||
version: 1.6.1
|
||||
resolution: "repeat-string@npm:1.6.1"
|
||||
checksum: 99c431ba7bef7a5d39819d562ebca89206368b45f73213677a3b562e25b5dd272d9e6a2ca8105001df14b6fc8cc71f0b10258c86e16cf8a256318fac1ddc8a77
|
||||
@ -17378,6 +17779,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"select@npm:^1.1.2":
|
||||
version: 1.1.2
|
||||
resolution: "select@npm:1.1.2"
|
||||
checksum: 66be63b7cf0973af48cebcca47909d0ba703bb7f01373f9ebf19880dc8fe9c97f41e2ebdefee144f60bbf416cafbf77dfb98cd1776e62d7afc336b843f1009b1
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"selfsigned@npm:^1.10.7":
|
||||
version: 1.10.8
|
||||
resolution: "selfsigned@npm:1.10.8"
|
||||
@ -17806,7 +18214,7 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"source-list-map@npm:^2.0.1":
|
||||
"source-list-map@npm:^2.0.0, source-list-map@npm:^2.0.1":
|
||||
version: 2.0.1
|
||||
resolution: "source-list-map@npm:2.0.1"
|
||||
checksum: d8d45f29987d00d995ccda308dcc78b710031a9958fdb5d26674d32220c952eb7a8562062638d91896628ae4eef30e1cd112a6a547563dfda0b013024c2a9bf7
|
||||
@ -17864,6 +18272,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"space-separated-tokens@npm:^1.0.0":
|
||||
version: 1.1.5
|
||||
resolution: "space-separated-tokens@npm:1.1.5"
|
||||
checksum: 2b143776c39176e7faa020d9c96d41ecc33862139b8bc92d5551561e9ae7adbe537b3a51d381da563a953dbda82ea117cefaa7dec9075fb869596cb02d582abe
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"spdx-correct@npm:^3.0.0":
|
||||
version: 3.1.1
|
||||
resolution: "spdx-correct@npm:3.1.1"
|
||||
@ -17996,6 +18411,15 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"ssri@npm:^8.0.0":
|
||||
version: 8.0.0
|
||||
resolution: "ssri@npm:8.0.0"
|
||||
dependencies:
|
||||
minipass: ^3.1.1
|
||||
checksum: 97964745a80846b4a50d4506b10b08d35384c3cec482d687cae5f4b7c842afe239c8c368d620f5d7d92642ab75379b409aa809072c2b8e94ec15d9c70d843da5
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"stack-utils@npm:^2.0.2":
|
||||
version: 2.0.2
|
||||
resolution: "stack-utils@npm:2.0.2"
|
||||
@ -18005,6 +18429,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"state-toggle@npm:^1.0.0":
|
||||
version: 1.0.3
|
||||
resolution: "state-toggle@npm:1.0.3"
|
||||
checksum: 8c013394b3a345e89ceeaf9a57c670c48e324cff733c2e8e0add75695fea23e7f478f479ccd399d75305d02f90a3ce651d47dfcc77b057334412f543909add14
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"static-extend@npm:^0.1.1":
|
||||
version: 0.1.2
|
||||
resolution: "static-extend@npm:0.1.2"
|
||||
@ -18767,6 +19198,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"tiny-emitter@npm:^2.0.0":
|
||||
version: 2.1.0
|
||||
resolution: "tiny-emitter@npm:2.1.0"
|
||||
checksum: 0055509c72e5fe35d6ab66fa6339342e0f29129e77ed2086e475fdf80be43a8651f2517be76513b46a042c8356396f4da5a35e2e23457252176808d5a892036a
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"tiny-invariant@npm:^1.0.2":
|
||||
version: 1.1.0
|
||||
resolution: "tiny-invariant@npm:1.1.0"
|
||||
@ -18971,6 +19409,20 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"trim-trailing-lines@npm:^1.0.0":
|
||||
version: 1.1.4
|
||||
resolution: "trim-trailing-lines@npm:1.1.4"
|
||||
checksum: d3fd2a2804baaffc9859b439524c0736fbecdc2114816fd7138c2289291c73f8b25d7e4497b4dccab8e74ddf357072c79b4041bd32c6583847e2453ed6f77df0
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"trim@npm:0.0.1":
|
||||
version: 0.0.1
|
||||
resolution: "trim@npm:0.0.1"
|
||||
checksum: ecf84783845ebf947081fa6cded3f5ebba7482caebc915995bef9b4bece86d1e11d57c16c8007529312dff2c0c3808a2fe21b200b22d2ca7a6a6cf94c6873b65
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"trough@npm:^1.0.0":
|
||||
version: 1.0.5
|
||||
resolution: "trough@npm:1.0.5"
|
||||
@ -19192,6 +19644,16 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unherit@npm:^1.0.4":
|
||||
version: 1.1.3
|
||||
resolution: "unherit@npm:1.1.3"
|
||||
dependencies:
|
||||
inherits: ^2.0.0
|
||||
xtend: ^4.0.0
|
||||
checksum: 387415adc7d392cf2e20ac406560444ae2b814f1a696469bbaea1a5b5e2dc0b4c9342704510050e9469efab6ce7580054084b9810392cf715b25e396f86ecd87
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unicode-canonical-property-names-ecmascript@npm:^1.0.4":
|
||||
version: 1.0.4
|
||||
resolution: "unicode-canonical-property-names-ecmascript@npm:1.0.4"
|
||||
@ -19223,6 +19685,20 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unified@npm:^6.1.5":
|
||||
version: 6.2.0
|
||||
resolution: "unified@npm:6.2.0"
|
||||
dependencies:
|
||||
bail: ^1.0.0
|
||||
extend: ^3.0.0
|
||||
is-plain-obj: ^1.1.0
|
||||
trough: ^1.0.0
|
||||
vfile: ^2.0.0
|
||||
x-is-string: ^0.1.0
|
||||
checksum: f524c6320cc6f8eeb08a096a31c6b667e57c7163a893b8ff40e4c643d77215a5056fcdca1170369b94777ea2060b4cc0a0e6d5327294029ffe3bdcf0402d87e9
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unified@npm:^9.0.0":
|
||||
version: 9.2.0
|
||||
resolution: "unified@npm:9.2.0"
|
||||
@ -19283,6 +19759,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-is@npm:^3.0.0":
|
||||
version: 3.0.0
|
||||
resolution: "unist-util-is@npm:3.0.0"
|
||||
checksum: c001cb83663fe70af5ad595020a836d2efef40ce1ba1f03e574cbb9b0976ccd342a991f23417cb407a629ba882ca5e7e955e544dcee9c49b24177b869dd3fd6d
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-is@npm:^4.0.0":
|
||||
version: 4.0.3
|
||||
resolution: "unist-util-is@npm:4.0.3"
|
||||
@ -19290,6 +19773,22 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-remove-position@npm:^1.0.0":
|
||||
version: 1.1.4
|
||||
resolution: "unist-util-remove-position@npm:1.1.4"
|
||||
dependencies:
|
||||
unist-util-visit: ^1.1.0
|
||||
checksum: be5b8e2d3535799bc100017b33eda17e2d920690299006edd07e92c517a71e5a97f8c2743a0d67e996671c9fceb841257b9484468a222519f1bc15b6aec26ffd
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-stringify-position@npm:^1.0.0, unist-util-stringify-position@npm:^1.1.1":
|
||||
version: 1.1.2
|
||||
resolution: "unist-util-stringify-position@npm:1.1.2"
|
||||
checksum: fa314c7d147d84cc57df8f765b1ca869f27a6a4f093f29da9fc7e909effe80ca65bbe89d5c6a99dc64c0554604bfda4fdcec9184e808858b209c2adc30cb9dd1
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-stringify-position@npm:^2.0.0":
|
||||
version: 2.0.3
|
||||
resolution: "unist-util-stringify-position@npm:2.0.3"
|
||||
@ -19306,6 +19805,15 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-visit-parents@npm:^2.0.0":
|
||||
version: 2.1.2
|
||||
resolution: "unist-util-visit-parents@npm:2.1.2"
|
||||
dependencies:
|
||||
unist-util-is: ^3.0.0
|
||||
checksum: 26807f1d21131d84cb47a5e55443383a57825456d88dc7a96003e457809d3c3b817bcb2c32b1f59d9a8e94b6124234cb9532ec8b2b2992ae0e38d1fa5d1f41ae
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-visit-parents@npm:^3.0.0":
|
||||
version: 3.1.1
|
||||
resolution: "unist-util-visit-parents@npm:3.1.1"
|
||||
@ -19316,6 +19824,15 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-visit@npm:^1.1.0, unist-util-visit@npm:^1.3.0":
|
||||
version: 1.4.1
|
||||
resolution: "unist-util-visit@npm:1.4.1"
|
||||
dependencies:
|
||||
unist-util-visit-parents: ^2.0.0
|
||||
checksum: 6c62b50495b03528ee38a88c52de7d8488f0e3b34f505201cb6ad099c520d9756787d2999ef46a4c9c761c0e19347ded28d139b68efb69c5dcb8b26d5382dc7a
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"unist-util-visit@npm:^2.0.0":
|
||||
version: 2.0.3
|
||||
resolution: "unist-util-visit@npm:2.0.3"
|
||||
@ -19600,6 +20117,22 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"vfile-location@npm:^2.0.0":
|
||||
version: 2.0.6
|
||||
resolution: "vfile-location@npm:2.0.6"
|
||||
checksum: b0506775609852b50849771398417236d7772b8debdfc9dc0b1ae59e139cbed381fa1ed6247109e18a15dd415db6355f5c92397cb4c795ec497d02d89d88b318
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"vfile-message@npm:^1.0.0":
|
||||
version: 1.1.1
|
||||
resolution: "vfile-message@npm:1.1.1"
|
||||
dependencies:
|
||||
unist-util-stringify-position: ^1.1.1
|
||||
checksum: d6c086d7c1d3c1e54351ab1f027655a0289e2e600f3fa86ea670ff230b65c79b8417ff7b515010ccab3973b6726576aed0d61f8814bceeb1296ea39862869dcd
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"vfile-message@npm:^2.0.0":
|
||||
version: 2.0.4
|
||||
resolution: "vfile-message@npm:2.0.4"
|
||||
@ -19610,6 +20143,18 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"vfile@npm:^2.0.0":
|
||||
version: 2.3.0
|
||||
resolution: "vfile@npm:2.3.0"
|
||||
dependencies:
|
||||
is-buffer: ^1.1.4
|
||||
replace-ext: 1.0.0
|
||||
unist-util-stringify-position: ^1.0.0
|
||||
vfile-message: ^1.0.0
|
||||
checksum: b59f2a73a61f96f83d6fb2aa05d5bf767ae0a6bf29f02677b35a7aad448058da41f272cc75f1e43d7e76cbd09e07ae2a99b1d39e75cab7d6dd13a27776ded775
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"vfile@npm:^4.0.0":
|
||||
version: 4.2.0
|
||||
resolution: "vfile@npm:4.2.0"
|
||||
@ -19881,6 +20426,16 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"webpack-merge@npm:5.2.0":
|
||||
version: 5.2.0
|
||||
resolution: "webpack-merge@npm:5.2.0"
|
||||
dependencies:
|
||||
clone-deep: ^4.0.1
|
||||
wildcard: ^2.0.0
|
||||
checksum: edc100b9c7cfc675d1e1857afd6a194daa1756d140eda9da452e4f73933307a9af7a485a94b68ef29dfa3047f69e34d6ca724e5858109ed287f32b79c0c0d11b
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"webpack-merge@npm:5.3.0":
|
||||
version: 5.3.0
|
||||
resolution: "webpack-merge@npm:5.3.0"
|
||||
@ -19900,6 +20455,16 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"webpack-sources@npm:^1.4.3":
|
||||
version: 1.4.3
|
||||
resolution: "webpack-sources@npm:1.4.3"
|
||||
dependencies:
|
||||
source-list-map: ^2.0.0
|
||||
source-map: ~0.6.1
|
||||
checksum: 2a753b36adf0ddd4dadf6ff375824108a918d180c4ea5383b377526f543e6db0c1ecd40b4154bae8e94c4b209b7814d764879691a468fe230ef9eb32b27fdde4
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"webpack-sources@npm:^2.1.1":
|
||||
version: 2.2.0
|
||||
resolution: "webpack-sources@npm:2.2.0"
|
||||
@ -20240,6 +20805,13 @@ fsevents@^1.2.7:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"x-is-string@npm:^0.1.0":
|
||||
version: 0.1.0
|
||||
resolution: "x-is-string@npm:0.1.0"
|
||||
checksum: a0e9f5430373c7c3683bb5c6c4cdb3d050027c3c806cf0fd090ad5f0e961ce169bfec970c69eae3fdc5967b80287c1959fb8220a6f945b548c15d1ef9f0bcddd
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"xdg-basedir@npm:^4.0.0":
|
||||
version: 4.0.0
|
||||
resolution: "xdg-basedir@npm:4.0.0"
|
||||
|
Loading…
Reference in New Issue
Block a user