diff --git a/web/next-example/package.json b/web/next-example/package.json index 286073ead..be6592503 100644 --- a/web/next-example/package.json +++ b/web/next-example/package.json @@ -23,24 +23,24 @@ "@types/js-beautify": "^1.14.3", "@uiw/codemirror-theme-vscode": "^4.21.24", "@uiw/react-codemirror": "^4.21.25", - "@yoopta/accordion": "^4.6.4-rc.1", - "@yoopta/action-menu-list": "^4.6.4-rc.1", - "@yoopta/blockquote": "^4.6.4-rc.1", - "@yoopta/callout": "^4.6.4-rc.1", - "@yoopta/code": "^4.6.4-rc.1", - "@yoopta/editor": "^4.6.4-rc.1", - "@yoopta/embed": "^4.6.4-rc.1", - "@yoopta/exports": "^4.6.4-rc.1", - "@yoopta/file": "^4.6.4-rc.1", - "@yoopta/headings": "^4.6.4-rc.1", - "@yoopta/image": "^4.6.4-rc.1", - "@yoopta/link": "^4.6.4-rc.1", - "@yoopta/link-tool": "^4.6.4-rc.1", - "@yoopta/lists": "^4.6.4-rc.1", - "@yoopta/marks": "^4.6.4-rc.1", - "@yoopta/paragraph": "^4.6.4-rc.1", - "@yoopta/toolbar": "^4.6.4-rc.1", - "@yoopta/video": "^4.6.4-rc.1", + "@yoopta/accordion": "^4.6.4-rc.2", + "@yoopta/action-menu-list": "^4.6.4-rc.2", + "@yoopta/blockquote": "^4.6.4-rc.2", + "@yoopta/callout": "^4.6.4-rc.2", + "@yoopta/code": "^4.6.4-rc.2", + "@yoopta/editor": "^4.6.4-rc.2", + "@yoopta/embed": "^4.6.4-rc.2", + "@yoopta/exports": "^4.6.4-rc.2", + "@yoopta/file": "^4.6.4-rc.2", + "@yoopta/headings": "^4.6.4-rc.2", + "@yoopta/image": "^4.6.4-rc.2", + "@yoopta/link": "^4.6.4-rc.2", + "@yoopta/link-tool": "^4.6.4-rc.2", + "@yoopta/lists": "^4.6.4-rc.2", + "@yoopta/marks": "^4.6.4-rc.2", + "@yoopta/paragraph": "^4.6.4-rc.2", + "@yoopta/toolbar": "^4.6.4-rc.2", + "@yoopta/video": "^4.6.4-rc.2", "class-variance-authority": "^0.7.0", "classnames": "^2.5.1", "clsx": "^2.1.0", diff --git a/web/next-example/src/components/examples/withBaseFullSetup/index.tsx b/web/next-example/src/components/examples/withBaseFullSetup/index.tsx index e9a52f794..0aab54d9b 100644 --- a/web/next-example/src/components/examples/withBaseFullSetup/index.tsx +++ b/web/next-example/src/components/examples/withBaseFullSetup/index.tsx @@ -18,7 +18,7 @@ import Toolbar, { DefaultToolbarRender } from '@yoopta/toolbar'; import LinkTool, { DefaultLinkToolRender } from '@yoopta/link-tool'; import { uploadToCloudinary } from '@/utils/cloudinary'; -import { useEffect, useMemo, useRef } from 'react'; +import { useMemo, useRef } from 'react'; import { WITH_BASIC_INIT_VALUE } from './initValue'; const plugins = [ diff --git a/web/next-example/src/components/examples/withBaseFullSetup/initValue.ts b/web/next-example/src/components/examples/withBaseFullSetup/initValue.ts index f1f8b89e0..7dfe84e79 100644 --- a/web/next-example/src/components/examples/withBaseFullSetup/initValue.ts +++ b/web/next-example/src/components/examples/withBaseFullSetup/initValue.ts @@ -604,7 +604,7 @@ export const WITH_BASIC_INIT_VALUE = { type: 'BulletedList', meta: { order: 23, - depth: 0, + depth: 1, }, }, '3d61674a-8d55-4b6f-9ff3-eb1518ec22b0': { @@ -792,6 +792,7 @@ export const WITH_BASIC_INIT_VALUE = { meta: { order: 3, depth: 0, + align: 'center', }, value: [ { @@ -1262,6 +1263,7 @@ export const WITH_BASIC_INIT_VALUE = { meta: { order: 5, depth: 0, + align: 'center', }, }, '62bcd227-f42c-426d-8b3a-9bff70b5308d': { @@ -1280,19 +1282,7 @@ export const WITH_BASIC_INIT_VALUE = { type: 'accordion-list-item-heading', children: [ { - text: 'Can I relax with Yoopta-Editor?', - }, - ], - props: { - nodeType: 'block', - }, - }, - { - id: 'a203259d-f075-44a3-a557-7d89f15a3501', - type: 'accordion-list-item-content', - children: [ - { - text: 'Definitely, yes. We are aiming to ensure that you never worry about developing rich-text editors, but just focus on business logic when writing your super applications.', + text: 'Is Yoopta-Editor free?', }, ], props: { @@ -1307,7 +1297,7 @@ export const WITH_BASIC_INIT_VALUE = { }, children: [ { - text: 'Just install the needed packages, make the necessary configuration and relax', + text: "Yes! Just install and relax, it's under MIT license", underline: true, }, ], @@ -1386,6 +1376,90 @@ export const WITH_BASIC_INIT_VALUE = { isExpanded: true, }, }, + { + id: '79655082-d9b0-4ade-aecb-cb0599b0643f', + type: 'accordion-list-item', + children: [ + { + id: '4ead075d-ed01-4e97-9ead-cd40e9b38f80', + type: 'accordion-list-item-heading', + children: [ + { + text: 'We need collaborative! Any news?', + }, + ], + props: { + nodeType: 'block', + }, + }, + { + id: '05d9e7d5-b827-4248-80a2-c53f0bbf89b9', + type: 'accordion-list-item-content', + children: [ + { + text: 'Already in progress 😎', + }, + ], + props: { + nodeType: 'block', + }, + }, + ], + props: { + nodeType: 'block', + isExpanded: true, + }, + }, + { + id: '5114a98e-7a17-44ff-b9b1-f95b8f03efdf', + type: 'accordion-list-item', + children: [ + { + id: '9e367393-3c7c-4928-b62f-aa254ece444c', + type: 'accordion-list-item-heading', + children: [ + { + text: 'How I can support project?', + }, + ], + props: { + nodeType: 'block', + }, + }, + { + id: 'ac810605-4e80-47d0-b70f-6ea7ce630ef9', + type: 'accordion-list-item-content', + children: [ + { + text: 'Support us using ', + }, + { + type: 'link', + children: [ + { + text: 'Github sponsor link', + }, + ], + props: { + url: 'https://github.com/sponsors/Darginec05', + target: '_self', + rel: 'noopener noreferrer', + }, + }, + { + text: ' ❤️', + }, + ], + props: { + nodeType: 'block', + }, + }, + ], + props: { + nodeType: 'block', + isExpanded: true, + }, + }, { id: 'ec4816dd-c646-43c8-90cf-30fe02b2a93f', type: 'accordion-list-item', @@ -1437,6 +1511,7 @@ export const WITH_BASIC_INIT_VALUE = { meta: { order: 4, depth: 0, + align: 'center', }, }, '39f639c6-219f-4cb7-a817-cb9f4d6ea07c': { @@ -1459,6 +1534,7 @@ export const WITH_BASIC_INIT_VALUE = { meta: { order: 2, depth: 0, + align: 'center', }, }, }; diff --git a/web/next-example/src/components/examples/withCustomRenders/index.tsx b/web/next-example/src/components/examples/withCustomRenders/index.tsx index 34e6df0ec..4d8d333db 100644 --- a/web/next-example/src/components/examples/withCustomRenders/index.tsx +++ b/web/next-example/src/components/examples/withCustomRenders/index.tsx @@ -24,7 +24,7 @@ import NextImage, { ImageProps } from 'next/image'; import NextLink from 'next/link'; import Typography from '@mui/material/Typography'; -const plugins = [ +const getPlugins = () => [ Paragraph, HeadingOne, HeadingTwo.extend({ @@ -193,7 +193,7 @@ function WithCustomRenders() { >