diff --git a/example/package.json b/example/package.json index 626b155a..185ee7ce 100644 --- a/example/package.json +++ b/example/package.json @@ -14,6 +14,11 @@ "author": "", "license": "ISC", "devDependencies": { + "@wordpress/block-editor": "^12.19.9", + "@wordpress/blocks": "^12.28.6", + "@wordpress/components": "^26.0.6", + "@wordpress/core-data": "^6.28.9", + "@wordpress/data": "^9.21.1", "@wordpress/env": "^9.9.0", "@wordpress/eslint-plugin": "^18.0.0", "@wordpress/scripts": "^27.8.0" diff --git a/example/src/blocks/color-settings-example/block.json b/example/src/blocks/color-settings-example/block.json index 9c31f138..e3cdb6e0 100644 --- a/example/src/blocks/color-settings-example/block.json +++ b/example/src/blocks/color-settings-example/block.json @@ -1,4 +1,5 @@ { + "apiVersion": 3, "name": "example/color-settings-example", "title": "Color Settings Component Example", "description": "Example Block to show the Color settings component", @@ -14,5 +15,5 @@ } }, "variations": [], - "editorScript": "file:./index.js" + "editorScript": "file:./index.ts" } \ No newline at end of file diff --git a/example/src/blocks/color-settings-example/edit.js b/example/src/blocks/color-settings-example/edit.js deleted file mode 100644 index ed97a414..00000000 --- a/example/src/blocks/color-settings-example/edit.js +++ /dev/null @@ -1,40 +0,0 @@ -import { __ } from '@wordpress/i18n'; -import { InspectorControls } from '@wordpress/block-editor'; -import { PanelBody } from '@wordpress/components'; - -import { ColorSetting } from '@10up/block-components'; - -export const BlockEdit = (props) => { - const { - attributes: { color }, - setAttributes - } = props; - - const colors = [ - { name: 'red', color: '#f00' }, - { name: 'white', color: '#fff' }, - { name: 'blue', color: '#00f' }, - ]; - return ( - <> - - - setAttributes( { color: val } ) } - /> - - - setAttributes( { color: val } ) } - /> - > - ) -} \ No newline at end of file diff --git a/example/src/blocks/color-settings-example/edit.tsx b/example/src/blocks/color-settings-example/edit.tsx new file mode 100644 index 00000000..15962f11 --- /dev/null +++ b/example/src/blocks/color-settings-example/edit.tsx @@ -0,0 +1,45 @@ +import React from 'react'; +import { __ } from '@wordpress/i18n'; +import { InspectorControls, useBlockProps } from '@wordpress/block-editor'; +import { PanelBody } from '@wordpress/components'; + +import { ColorSetting } from '@10up/block-components'; + +export const BlockEdit = (props) => { + const { + attributes: { color }, + setAttributes + } = props; + + const blockProps = useBlockProps(); + + const colors = [ + { name: 'red', color: '#f00' }, + { name: 'white', color: '#fff' }, + { name: 'blue', color: '#00f' }, + ]; + return ( + <> + + + setAttributes({ color: val })} + /> + + + + setAttributes({ color: val })} + /> + + > + ) +} \ No newline at end of file diff --git a/example/src/blocks/color-settings-example/index.js b/example/src/blocks/color-settings-example/index.ts similarity index 100% rename from example/src/blocks/color-settings-example/index.js rename to example/src/blocks/color-settings-example/index.ts diff --git a/example/src/blocks/content-item/block.json b/example/src/blocks/content-item/block.json index 7553e3be..494141f8 100644 --- a/example/src/blocks/content-item/block.json +++ b/example/src/blocks/content-item/block.json @@ -1,5 +1,5 @@ { - "apiVersion": 2, + "apiVersion": 3, "name": "example/content-item", "title": "Content Item", "icon": "smiley", @@ -12,5 +12,5 @@ "variations": [], "usesContext": ["postId", "postType", "queryId"], "ancestor": ["core/post-template"], - "editorScript": "file:./index.js" + "editorScript": "file:./index.ts" } \ No newline at end of file diff --git a/example/src/blocks/content-item/edit.js b/example/src/blocks/content-item/edit.tsx similarity index 98% rename from example/src/blocks/content-item/edit.js rename to example/src/blocks/content-item/edit.tsx index 3281e268..4c11fd2b 100644 --- a/example/src/blocks/content-item/edit.js +++ b/example/src/blocks/content-item/edit.tsx @@ -1,3 +1,4 @@ +import React from 'react'; import { useBlockProps } from '@wordpress/block-editor'; import { __ } from '@wordpress/i18n'; diff --git a/example/src/blocks/content-item/index.js b/example/src/blocks/content-item/index.ts similarity index 100% rename from example/src/blocks/content-item/index.js rename to example/src/blocks/content-item/index.ts diff --git a/example/src/blocks/content-picker-example/block.json b/example/src/blocks/content-picker-example/block.json index fce65ab9..fc99aa11 100644 --- a/example/src/blocks/content-picker-example/block.json +++ b/example/src/blocks/content-picker-example/block.json @@ -1,5 +1,5 @@ { - "apiVersion": 2, + "apiVersion": 3, "name": "example/content-picker", "title": "Content Picker", "description": "Example Block to show the Content Picker in usage", @@ -15,5 +15,5 @@ } }, "variations": [], - "editorScript": "file:./index.js" + "editorScript": "file:./index.ts" } \ No newline at end of file diff --git a/example/src/blocks/content-picker-example/edit.js b/example/src/blocks/content-picker-example/edit.tsx similarity index 98% rename from example/src/blocks/content-picker-example/edit.js rename to example/src/blocks/content-picker-example/edit.tsx index b91cafba..80e05a8e 100644 --- a/example/src/blocks/content-picker-example/edit.js +++ b/example/src/blocks/content-picker-example/edit.tsx @@ -1,3 +1,4 @@ +import React from 'react'; import { __ } from '@wordpress/i18n'; import { InspectorControls, useBlockProps } from '@wordpress/block-editor'; import { PanelBody, Placeholder } from '@wordpress/components'; diff --git a/example/src/blocks/content-picker-example/index.js b/example/src/blocks/content-picker-example/index.ts similarity index 100% rename from example/src/blocks/content-picker-example/index.js rename to example/src/blocks/content-picker-example/index.ts diff --git a/example/src/blocks/content-search-example/block.json b/example/src/blocks/content-search-example/block.json index 6fd476e8..5fa75b8e 100644 --- a/example/src/blocks/content-search-example/block.json +++ b/example/src/blocks/content-search-example/block.json @@ -1,5 +1,5 @@ { - "apiVersion": 2, + "apiVersion": 3, "name": "example/content-search", "title": "Post Searcher", "description": "Example Block to show the Content Search in usage", @@ -15,5 +15,5 @@ } }, "variations": [], - "editorScript": "file:./index.js" + "editorScript": "file:./index.ts" } \ No newline at end of file diff --git a/example/src/blocks/content-search-example/edit.js b/example/src/blocks/content-search-example/edit.tsx similarity index 97% rename from example/src/blocks/content-search-example/edit.js rename to example/src/blocks/content-search-example/edit.tsx index 34d4f83a..2f9366f8 100644 --- a/example/src/blocks/content-search-example/edit.js +++ b/example/src/blocks/content-search-example/edit.tsx @@ -1,3 +1,4 @@ +import React from 'react'; import { __ } from '@wordpress/i18n'; import { InspectorControls, useBlockProps } from '@wordpress/block-editor'; import { PanelBody, Placeholder } from '@wordpress/components'; diff --git a/example/src/blocks/content-search-example/index.js b/example/src/blocks/content-search-example/index.ts similarity index 100% rename from example/src/blocks/content-search-example/index.js rename to example/src/blocks/content-search-example/index.ts diff --git a/example/src/blocks/counter-example/block.json b/example/src/blocks/counter-example/block.json index 9f9cbf0a..9744574b 100644 --- a/example/src/blocks/counter-example/block.json +++ b/example/src/blocks/counter-example/block.json @@ -1,5 +1,5 @@ { - "apiVersion": 2, + "apiVersion": 3, "name": "example/counter", "title": "Counter Example", "description": "Example Block to show the Counter in usage", @@ -10,5 +10,5 @@ "html": false }, "variations": [], - "editorScript": "file:./index.js" + "editorScript": "file:./index.ts" } \ No newline at end of file diff --git a/example/src/blocks/counter-example/edit.js b/example/src/blocks/counter-example/edit.tsx similarity index 97% rename from example/src/blocks/counter-example/edit.js rename to example/src/blocks/counter-example/edit.tsx index 098e9b98..510332ef 100644 --- a/example/src/blocks/counter-example/edit.js +++ b/example/src/blocks/counter-example/edit.tsx @@ -1,3 +1,4 @@ +import React from 'react'; import { __ } from '@wordpress/i18n'; import { InspectorControls, useBlockProps } from '@wordpress/block-editor'; import { PanelBody, Placeholder, TextControl } from '@wordpress/components'; diff --git a/example/src/blocks/counter-example/index.js b/example/src/blocks/counter-example/index.ts similarity index 100% rename from example/src/blocks/counter-example/index.js rename to example/src/blocks/counter-example/index.ts diff --git a/example/src/blocks/hello-world/block.json b/example/src/blocks/hello-world/block.json index 7501603c..602fea7e 100644 --- a/example/src/blocks/hello-world/block.json +++ b/example/src/blocks/hello-world/block.json @@ -1,4 +1,5 @@ { + "apiVersion": 3, "name": "example/hello-world", "title": "Hello World", "description": "Example Block to show the Post Picker in usage", @@ -14,5 +15,5 @@ } }, "variations": [], - "editorScript": "file:./index.js" + "editorScript": "file:./index.ts" } \ No newline at end of file diff --git a/example/src/blocks/hello-world/edit.js b/example/src/blocks/hello-world/edit.tsx similarity index 87% rename from example/src/blocks/hello-world/edit.js rename to example/src/blocks/hello-world/edit.tsx index dcf40370..a6edf835 100644 --- a/example/src/blocks/hello-world/edit.js +++ b/example/src/blocks/hello-world/edit.tsx @@ -1,12 +1,12 @@ +import React from 'react'; import { __ } from '@wordpress/i18n'; -import { InspectorControls } from '@wordpress/block-editor'; +import { InspectorControls, useBlockProps } from '@wordpress/block-editor'; import { PanelBody, Placeholder } from '@wordpress/components'; import {ContentPicker} from '@10up/block-components'; export const BlockEdit = (props) => { const { - className, attributes: { selectedPost }, setAttributes } = props; @@ -15,6 +15,8 @@ export const BlockEdit = (props) => { setAttributes( { selectedPost: post } ) } + const blockProps = useBlockProps(); + return ( <> @@ -28,7 +30,7 @@ export const BlockEdit = (props) => { /> - + - - - - - ); - } - return ( - <> - - - - { - (item, index, setItem, removeItem) => ( - - - setItem({pageName: val})} /> - - - setItem({visibility: val})} /> - - - - - - ) - } - - - > - ) + + + + { + (item, index, setItem, removeItem) => ( + + + setItem({ pageName: val })} /> + + + setItem({ visibility: val })} /> + + + + + + ) + } + + + > + ) } \ No newline at end of file diff --git a/example/src/blocks/repeater-component-example/index.js b/example/src/blocks/repeater-component-example/index.ts similarity index 100% rename from example/src/blocks/repeater-component-example/index.js rename to example/src/blocks/repeater-component-example/index.ts diff --git a/example/src/blocks/rich-text-character-limit/block.json b/example/src/blocks/rich-text-character-limit/block.json index 937ee5e5..d154bbc6 100644 --- a/example/src/blocks/rich-text-character-limit/block.json +++ b/example/src/blocks/rich-text-character-limit/block.json @@ -1,6 +1,6 @@ { "name": "example/rich-text-character-limit", - "apiVersion": 2, + "apiVersion": 3, "title": "Rich Text Character Limit", "description": "Example Block to show the Rich Text Character Limit in usage", "icon": "smiley", @@ -15,5 +15,5 @@ "default": "" } }, - "editorScript": "file:./index.js" + "editorScript": "file:./index.ts" } \ No newline at end of file diff --git a/example/src/blocks/rich-text-character-limit/edit.js b/example/src/blocks/rich-text-character-limit/edit.tsx similarity index 95% rename from example/src/blocks/rich-text-character-limit/edit.js rename to example/src/blocks/rich-text-character-limit/edit.tsx index fb23d78e..58c43658 100644 --- a/example/src/blocks/rich-text-character-limit/edit.js +++ b/example/src/blocks/rich-text-character-limit/edit.tsx @@ -1,3 +1,4 @@ +import React from 'react'; import { __ } from '@wordpress/i18n'; import { useBlockProps } from '@wordpress/block-editor'; import { RichTextCharacterLimit } from '@10up/block-components'; diff --git a/example/src/blocks/rich-text-character-limit/index.js b/example/src/blocks/rich-text-character-limit/index.ts similarity index 100% rename from example/src/blocks/rich-text-character-limit/index.js rename to example/src/blocks/rich-text-character-limit/index.ts diff --git a/example/src/extensions/background-pattern/edit.js b/example/src/extensions/background-pattern/edit.tsx similarity index 66% rename from example/src/extensions/background-pattern/edit.js rename to example/src/extensions/background-pattern/edit.tsx index 2665e7f5..58929f6e 100644 --- a/example/src/extensions/background-pattern/edit.js +++ b/example/src/extensions/background-pattern/edit.tsx @@ -1,38 +1,51 @@ +import React from 'react'; import { InspectorControls } from '@wordpress/block-editor'; import { PanelBody, SelectControl, ToggleControl, ColorPalette, BaseControl } from '@wordpress/components'; +const COLOR_OPTIONS = [ + { + name: 'Green', + slug: 'green', + color: 'hsl(110, 100%, 50%)' + } as const, + { + name: 'Blue', + slug: 'blue', + color: 'hsl(230, 100%, 50%)' + } as const, + { + name: 'Red', + slug: 'red', + color: 'hsl(5, 100%, 50%)' + } as const +]; + +// get the slugs of the available color options +type AvailableColors = typeof COLOR_OPTIONS[number]['slug']; + +type BlockEditProps = { + attributes: { + hasBackgroundPattern: boolean; + backgroundPatternShape: string; + backgroundPatternColor: AvailableColors; + }; + setAttributes: (newAttributes: { hasBackgroundPattern?: boolean; backgroundPatternShape?: string; backgroundPatternColor?: AvailableColors }) => void; +}; + /** * BlockEdit * * a react component that will get mounted in the Editor when the block is - * selected. It is reccomended to use Slots like `BlockControls` or `InspectorControls` + * selected. It is recommended to use Slots like `BlockControls` or `InspectorControls` * in here to put settings into the blocks toolbar or sidebar. * * @param {object} props block props * @returns {JSX} */ -export function BlockEdit(props) { +export function BlockEdit(props: BlockEditProps) { const { attributes, setAttributes } = props; const { hasBackgroundPattern, backgroundPatternShape, backgroundPatternColor } = attributes; - const COLOR_OPTIONS = [ - { - name: 'Green', - slug: 'green', - color: 'hsl(110, 100%, 50%)' - }, - { - name: 'Blue', - slug: 'blue', - color: 'hsl(230, 100%, 50%)' - }, - { - name: 'Red', - slug: 'red', - color: 'hsl(5, 100%, 50%)' - } - ]; - return ( @@ -48,7 +61,7 @@ export function BlockEdit(props) { value={backgroundPatternShape} options={[ { value: 'dots', label: "Dots" }, - { value: 'squares', label: "Suares" }, + { value: 'squares', label: "Squares" }, ]} onChange={value => setAttributes({backgroundPatternShape: value})} /> @@ -56,9 +69,9 @@ export function BlockEdit(props) { item.slug === backgroundPatternColor ).color} - onChange={value => { - const colorName = COLOR_OPTIONS.find( item => item.color === value ).slug + value={COLOR_OPTIONS.find( item => item.slug === backgroundPatternColor )?.color} + onChange={(value) => { + const colorName = COLOR_OPTIONS.find( item => item.slug === value )?.slug setAttributes({ backgroundPatternColor: colorName }) diff --git a/example/src/extensions/background-pattern/index.js b/example/src/extensions/background-pattern/index.ts similarity index 100% rename from example/src/extensions/background-pattern/index.js rename to example/src/extensions/background-pattern/index.ts diff --git a/package-lock.json b/package-lock.json index f8eeb52b..bd2d33e4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -50,6 +50,11 @@ "@wordpress/icons": "^9.48.0" }, "devDependencies": { + "@wordpress/block-editor": "^12.19.9", + "@wordpress/blocks": "^12.28.6", + "@wordpress/components": "^26.0.6", + "@wordpress/core-data": "^6.28.9", + "@wordpress/data": "^9.21.1", "@wordpress/env": "^9.9.0", "@wordpress/eslint-plugin": "^18.0.0", "@wordpress/scripts": "^27.8.0" @@ -59,6 +64,267 @@ "resolved": "dist/index.js", "link": true }, + "example/node_modules/@wordpress/block-editor": { + "version": "12.19.9", + "resolved": "https://registry.npmjs.org/@wordpress/block-editor/-/block-editor-12.19.9.tgz", + "integrity": "sha512-ECodQVF5C/KwSjPqnvGweJavi4YCVi5ym2X2Fztqzu3wDHQ6Z9UVbrVJPHoQ3Sy9mZ+9aZKgvcYyyB4YHhxyLA==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0", + "@emotion/react": "^11.7.1", + "@emotion/styled": "^11.6.0", + "@react-spring/web": "^9.4.5", + "@wordpress/a11y": "^3.51.1", + "@wordpress/api-fetch": "^6.48.1", + "@wordpress/blob": "^3.51.1", + "@wordpress/blocks": "^12.28.6", + "@wordpress/commands": "^0.22.6", + "@wordpress/components": "^26.0.6", + "@wordpress/compose": "^6.28.1", + "@wordpress/data": "^9.21.1", + "@wordpress/date": "^4.51.1", + "@wordpress/deprecated": "^3.51.1", + "@wordpress/dom": "^3.51.1", + "@wordpress/element": "^5.28.1", + "@wordpress/escape-html": "^2.51.1", + "@wordpress/hooks": "^3.51.1", + "@wordpress/html-entities": "^3.51.1", + "@wordpress/i18n": "^4.51.1", + "@wordpress/icons": "^9.42.4", + "@wordpress/is-shallow-equal": "^4.51.1", + "@wordpress/keyboard-shortcuts": "^4.28.1", + "@wordpress/keycodes": "^3.51.1", + "@wordpress/notices": "^4.19.1", + "@wordpress/preferences": "^3.28.6", + "@wordpress/private-apis": "^0.33.1", + "@wordpress/rich-text": "^6.28.4", + "@wordpress/style-engine": "^1.34.1", + "@wordpress/token-list": "^2.51.1", + "@wordpress/url": "^3.52.1", + "@wordpress/warning": "^2.51.1", + "@wordpress/wordcount": "^3.51.1", + "change-case": "^4.1.2", + "classnames": "^2.3.1", + "colord": "^2.7.0", + "deepmerge": "^4.3.0", + "diff": "^4.0.2", + "dom-scroll-into-view": "^1.2.1", + "fast-deep-equal": "^3.1.3", + "memize": "^2.1.0", + "postcss": "^8.4.21", + "postcss-prefixwrap": "^1.41.0", + "postcss-urlrebase": "^1.0.0", + "react-autosize-textarea": "^7.1.0", + "react-easy-crop": "^4.5.1", + "rememo": "^4.0.2", + "remove-accents": "^0.5.0" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "react": "^18.0.0", + "react-dom": "^18.0.0" + } + }, + "example/node_modules/@wordpress/blocks": { + "version": "12.28.6", + "resolved": "https://registry.npmjs.org/@wordpress/blocks/-/blocks-12.28.6.tgz", + "integrity": "sha512-dTMY/ZRaszsGpbmc4N3/lzvu7kp2zPOPkNy8Eznwy952OFqKYkq6ajJrw8CKH1FRkgXACAH+BDA/6OBHTcuvfQ==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0", + "@wordpress/autop": "^3.51.1", + "@wordpress/blob": "^3.51.1", + "@wordpress/block-serialization-default-parser": "^4.51.1", + "@wordpress/compose": "^6.28.1", + "@wordpress/data": "^9.21.1", + "@wordpress/deprecated": "^3.51.1", + "@wordpress/dom": "^3.51.1", + "@wordpress/element": "^5.28.1", + "@wordpress/hooks": "^3.51.1", + "@wordpress/html-entities": "^3.51.1", + "@wordpress/i18n": "^4.51.1", + "@wordpress/is-shallow-equal": "^4.51.1", + "@wordpress/private-apis": "^0.33.1", + "@wordpress/rich-text": "^6.28.4", + "@wordpress/shortcode": "^3.51.1", + "change-case": "^4.1.2", + "colord": "^2.7.0", + "fast-deep-equal": "^3.1.3", + "hpq": "^1.3.0", + "is-plain-object": "^5.0.0", + "memize": "^2.1.0", + "react-is": "^18.2.0", + "rememo": "^4.0.2", + "remove-accents": "^0.5.0", + "showdown": "^1.9.1", + "simple-html-tokenizer": "^0.5.7", + "uuid": "^9.0.1" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "react": "^18.0.0" + } + }, + "example/node_modules/@wordpress/commands": { + "version": "0.22.6", + "resolved": "https://registry.npmjs.org/@wordpress/commands/-/commands-0.22.6.tgz", + "integrity": "sha512-T4uqI3FQhJtkNGgcmbofuKTOyJdcaYfZAKrCxhrO4WgiBEvmSQ3yYaFTAfeaWdueodlZsNGVP58cl3WpKzPbaA==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0", + "@wordpress/components": "^26.0.6", + "@wordpress/data": "^9.21.1", + "@wordpress/element": "^5.28.1", + "@wordpress/i18n": "^4.51.1", + "@wordpress/icons": "^9.42.4", + "@wordpress/keyboard-shortcuts": "^4.28.1", + "@wordpress/private-apis": "^0.33.1", + "classnames": "^2.3.1", + "cmdk": "^0.2.0", + "rememo": "^4.0.2" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "react": "^18.0.0", + "react-dom": "^18.0.0" + } + }, + "example/node_modules/@wordpress/components": { + "version": "26.0.6", + "resolved": "https://registry.npmjs.org/@wordpress/components/-/components-26.0.6.tgz", + "integrity": "sha512-1e3UY7OCrShVlC3VkX3oolADmQyrybIXNWYki1B0yQk/mBhJXiQTscYmR7UNW2MlOxMM+uOPIvtSfacur7TdWA==", + "dev": true, + "dependencies": { + "@ariakit/react": "^0.3.12", + "@babel/runtime": "^7.16.0", + "@emotion/cache": "^11.7.1", + "@emotion/css": "^11.7.1", + "@emotion/react": "^11.7.1", + "@emotion/serialize": "^1.0.2", + "@emotion/styled": "^11.6.0", + "@emotion/utils": "^1.0.0", + "@floating-ui/react-dom": "^2.0.8", + "@types/gradient-parser": "0.1.3", + "@types/highlight-words-core": "1.2.1", + "@use-gesture/react": "^10.2.24", + "@wordpress/a11y": "^3.51.1", + "@wordpress/compose": "^6.28.1", + "@wordpress/date": "^4.51.1", + "@wordpress/deprecated": "^3.51.1", + "@wordpress/dom": "^3.51.1", + "@wordpress/element": "^5.28.1", + "@wordpress/escape-html": "^2.51.1", + "@wordpress/hooks": "^3.51.1", + "@wordpress/html-entities": "^3.51.1", + "@wordpress/i18n": "^4.51.1", + "@wordpress/icons": "^9.42.4", + "@wordpress/is-shallow-equal": "^4.51.1", + "@wordpress/keycodes": "^3.51.1", + "@wordpress/primitives": "^3.49.1", + "@wordpress/private-apis": "^0.33.1", + "@wordpress/rich-text": "^6.28.4", + "@wordpress/warning": "^2.51.1", + "change-case": "^4.1.2", + "classnames": "^2.3.1", + "colord": "^2.7.0", + "date-fns": "^2.28.0", + "deepmerge": "^4.3.0", + "dom-scroll-into-view": "^1.2.1", + "downshift": "^6.0.15", + "fast-deep-equal": "^3.1.3", + "framer-motion": "^10.13.0", + "gradient-parser": "^0.1.5", + "highlight-words-core": "^1.2.2", + "is-plain-object": "^5.0.0", + "memize": "^2.1.0", + "path-to-regexp": "^6.2.1", + "re-resizable": "^6.4.0", + "react-colorful": "^5.3.1", + "remove-accents": "^0.5.0", + "use-lilius": "^2.0.1", + "uuid": "^9.0.1", + "valtio": "1.7.0" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "react": "^18.0.0", + "react-dom": "^18.0.0" + } + }, + "example/node_modules/@wordpress/core-data": { + "version": "6.28.9", + "resolved": "https://registry.npmjs.org/@wordpress/core-data/-/core-data-6.28.9.tgz", + "integrity": "sha512-1qpRUYkWEQkIxdideQw52WElhD1asJf5Ph55qfFOboXpMkF18N95bC+VMVaYlp7quKCtORYfTkbrL3XFNnx/IQ==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0", + "@wordpress/api-fetch": "^6.48.1", + "@wordpress/block-editor": "^12.19.9", + "@wordpress/blocks": "^12.28.6", + "@wordpress/compose": "^6.28.1", + "@wordpress/data": "^9.21.1", + "@wordpress/deprecated": "^3.51.1", + "@wordpress/element": "^5.28.1", + "@wordpress/html-entities": "^3.51.1", + "@wordpress/i18n": "^4.51.1", + "@wordpress/is-shallow-equal": "^4.51.1", + "@wordpress/private-apis": "^0.33.1", + "@wordpress/rich-text": "^6.28.4", + "@wordpress/sync": "^0.13.1", + "@wordpress/undo-manager": "^0.11.1", + "@wordpress/url": "^3.52.1", + "change-case": "^4.1.2", + "equivalent-key-map": "^0.2.2", + "fast-deep-equal": "^3.1.3", + "memize": "^2.1.0", + "rememo": "^4.0.2", + "uuid": "^9.0.1" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "react": "^18.0.0", + "react-dom": "^18.0.0" + } + }, + "example/node_modules/@wordpress/data": { + "version": "9.21.1", + "resolved": "https://registry.npmjs.org/@wordpress/data/-/data-9.21.1.tgz", + "integrity": "sha512-7B9ABDvs0V0fb/GvrL5T14KauZNI133u/v5IBAuq89YvZPBUOAFiO/h8DxdkdV1Rr/q79knxAfDxxarjbFzBiw==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0", + "@wordpress/compose": "^6.28.1", + "@wordpress/deprecated": "^3.51.1", + "@wordpress/element": "^5.28.1", + "@wordpress/is-shallow-equal": "^4.51.1", + "@wordpress/priority-queue": "^2.51.1", + "@wordpress/private-apis": "^0.33.1", + "@wordpress/redux-routine": "^4.51.1", + "deepmerge": "^4.3.0", + "equivalent-key-map": "^0.2.2", + "is-plain-object": "^5.0.0", + "is-promise": "^4.0.0", + "redux": "^4.1.2", + "rememo": "^4.0.2", + "use-memo-one": "^1.1.1" + }, + "engines": { + "node": ">=12" + }, + "peerDependencies": { + "react": "^18.0.0" + } + }, "example/node_modules/@wordpress/eslint-plugin": { "version": "18.0.0", "resolved": "https://registry.npmjs.org/@wordpress/eslint-plugin/-/eslint-plugin-18.0.0.tgz", @@ -102,6 +368,68 @@ } } }, + "example/node_modules/@wordpress/private-apis": { + "version": "0.33.1", + "resolved": "https://registry.npmjs.org/@wordpress/private-apis/-/private-apis-0.33.1.tgz", + "integrity": "sha512-I7nxWUtZJ243vBC7cRRTId7FK0+c82RlIUZ1DVzutojJlg5a66RfFlMygWg/jVBWEmQqfcGSB4zPiGhi7JVBAg==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0" + }, + "engines": { + "node": ">=12" + } + }, + "example/node_modules/@wordpress/sync": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/@wordpress/sync/-/sync-0.13.1.tgz", + "integrity": "sha512-MHyXM+qALZvTI/eLyGmfImDU9mXZaeU2tkDSg5+l2fsg7iN2tGzy4PfRvOgUAHa47PBF1oar+yg2EbOq7K3uYg==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0", + "@types/simple-peer": "^9.11.5", + "@wordpress/url": "^3.52.1", + "import-locals": "^2.0.0", + "lib0": "^0.2.42", + "simple-peer": "^9.11.0", + "y-indexeddb": "~9.0.11", + "y-protocols": "^1.0.5", + "y-webrtc": "~10.2.5", + "yjs": "~13.6.6" + }, + "engines": { + "node": ">=12" + } + }, + "example/node_modules/@wordpress/undo-manager": { + "version": "0.11.1", + "resolved": "https://registry.npmjs.org/@wordpress/undo-manager/-/undo-manager-0.11.1.tgz", + "integrity": "sha512-ukBF8sRDXmnLa0AEpoLSsZ7G8lUl/X41ZF+Cq7EiTC7ZQWVMd+e5THJUvSEuQO6d8Tttgm44J1eDd4Kydod5ZA==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.16.0", + "@wordpress/is-shallow-equal": "^4.51.1" + }, + "engines": { + "node": ">=12" + } + }, + "example/node_modules/date-fns": { + "version": "2.30.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.30.0.tgz", + "integrity": "sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==", + "dev": true, + "dependencies": { + "@babel/runtime": "^7.21.0" + }, + "engines": { + "node": ">=0.11" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/date-fns" + } + }, "example/node_modules/eslint-config-prettier": { "version": "8.10.0", "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.10.0.tgz", @@ -137,6 +465,26 @@ "eslint": "^7.0.0 || ^8.0.0 || ^9.0.0" } }, + "example/node_modules/react-easy-crop": { + "version": "4.7.5", + "resolved": "https://registry.npmjs.org/react-easy-crop/-/react-easy-crop-4.7.5.tgz", + "integrity": "sha512-qKfI4PuhaH1jOLC3DQfQB0cE0z+3N7bfyPkPejQmylXNb8nstfPMH+oHj3gKgpBHLFUiQp/C1rY7sVCVgtjn3Q==", + "dev": true, + "dependencies": { + "normalize-wheel": "^1.0.1", + "tslib": "2.0.1" + }, + "peerDependencies": { + "react": ">=16.4.0", + "react-dom": ">=16.4.0" + } + }, + "example/node_modules/tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==", + "dev": true + }, "node_modules/@10up/babel-preset-default": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/@10up/babel-preset-default/-/babel-preset-default-2.1.1.tgz", @@ -12416,6 +12764,12 @@ "utila": "~0.4" } }, + "node_modules/dom-scroll-into-view": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/dom-scroll-into-view/-/dom-scroll-into-view-1.2.1.tgz", + "integrity": "sha512-LwNVg3GJOprWDO+QhLL1Z9MMgWe/KAFLxVWKzjRTxNSPn8/LLDIfmuG71YHznXCqaqTjvHJDYO1MEAgX6XCNbQ==", + "dev": true + }, "node_modules/dom-serializer": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", @@ -23395,6 +23749,12 @@ "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==", "dev": true }, + "node_modules/proxy-compare": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/proxy-compare/-/proxy-compare-2.3.0.tgz", + "integrity": "sha512-c3L2CcAi7f7pvlD0D7xsF+2CQIW8C3HaYx2Pfgq8eA4HAl3GAH6/dVYsyBbYF/0XJs2ziGLrzmz5fmzPm6A0pQ==", + "dev": true + }, "node_modules/proxy-from-env": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.0.0.tgz", @@ -27960,6 +28320,56 @@ "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, + "node_modules/valtio": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/valtio/-/valtio-1.7.0.tgz", + "integrity": "sha512-3Tnix66EERwMcrl1rfB3ylcewOcL5L/GiPmC3FlVNreQzqf2jufEeqlNmgnLgSGchkEmH3WYVtS+x6Qw4r+yzQ==", + "dev": true, + "dependencies": { + "proxy-compare": "2.3.0", + "use-sync-external-store": "1.2.0" + }, + "engines": { + "node": ">=12.7.0" + }, + "peerDependencies": { + "@babel/helper-module-imports": ">=7.12", + "@babel/types": ">=7.13", + "aslemammad-vite-plugin-macro": ">=1.0.0-alpha.1", + "babel-plugin-macros": ">=3.0", + "react": ">=16.8", + "vite": ">=2.8.6" + }, + "peerDependenciesMeta": { + "@babel/helper-module-imports": { + "optional": true + }, + "@babel/types": { + "optional": true + }, + "aslemammad-vite-plugin-macro": { + "optional": true + }, + "babel-plugin-macros": { + "optional": true + }, + "react": { + "optional": true + }, + "vite": { + "optional": true + } + } + }, + "node_modules/valtio/node_modules/use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "dev": true, + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, "node_modules/vary": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz",