From 01145a51f75ba9a66abfc4d44591dfaf247052c5 Mon Sep 17 00:00:00 2001 From: sajald77 Date: Thu, 17 Aug 2023 10:17:39 -0400 Subject: [PATCH 01/54] fix: add more pwa icons --- public/icons/120.png | Bin 0 -> 6028 bytes public/icons/128-padded.png | Bin 5821 -> 0 bytes public/icons/180-padded.png | Bin 0 -> 8347 bytes public/icons/180.png | Bin 9409 -> 0 bytes public/icons/64.png | Bin 0 -> 3027 bytes vite.config.ts | 11 ++++++++--- 6 files changed, 8 insertions(+), 3 deletions(-) create mode 100644 public/icons/120.png delete mode 100644 public/icons/128-padded.png create mode 100644 public/icons/180-padded.png delete mode 100644 public/icons/180.png create mode 100644 public/icons/64.png diff --git a/public/icons/120.png b/public/icons/120.png new file mode 100644 index 0000000000000000000000000000000000000000..55443be5503f888be66910dbe39f15e1919f055b GIT binary patch literal 6028 zcmV;77jx)|P)$A_H4>N4B^pJ*UDOywqkuBQHY@_uTP^SW&%Jl1 z8D|D&=&r6F`+VP>s;;i->b}1^=bn4+xwoR!Md?4N&gPB1qQ1c~$7%-E4Yr8(;oZ?( zcIGmS%K$FbTyQOmDgyDjpx&CeEaUPymk+tj;Wy?s);BCRCvrWb-aM{nuPYboG+>5k zF{OwG>($iN_2UD_^8SfjMsev)71@~JMvsxIE0p0}4%ct2VW_Y3?hN0j$GDzX;y6Gv ze3#+-ow-n_0OKMWtkb`)Zd?8~<9Yv7+7K%4G++M+qp=muZCm`jt*JBA?il>TUDsS8BT)Wk|o%z|G~zUz=t~9$8!TAbZ$WWbZhP?El=B?5%6b8Z>~cKE23FCb-wHdy0-rep8D4 z)oaOLzKXmBi^==wb8zQ+u`3v`U)QACOiP>X$R>30t>!;1;`-{d0Fm44=s}|>I(Bbz z=FX$+lcFz=}mR?PoDX zTLOR8*JKT@C3{G%1{=w(TAIzS<52wU6De`Y|B%(ck9fSzV1pF?9@fAba-Mya zGB-~XPd%*Nr|<)2lMDyR=B`cE4Hr`E=mW$|`YXRy<~nEr+6N{oHM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7GuLNitH7_e7ieMHxb3I$3PUXKdoxs?;I6`mA;^}DR~@%_A@!6+h!-GfqCBF z+@@SfAXj7OOtF?bM8{tS3K@)uUR}|P&>TKemV+o3j;C*|Of6JyRV^h9-|u41xX1In z$V9r+^GbO247@~yanXPJ1}@ro7yP zxN7(OKF7)4(vax+#&$5?bhO(2WG`oH|8{)Rz%~%%_w|`YTUy}*{HcfhD|RGL|Bj>2 z50OM>TBEP$_uI}FxYw0bwe&@H9s6w7xKGZjJ-%yPQaH96+Zk4*dY72EZ#h|t;0wc3D`*&A9^BJ11}$=dzVz;5T-NY!ec-}YXJuwWuA k+HtvZ48&0S|KuRJLvHL%lg*?5&C&pEbpy2zDvmM#2et|?4*&oF diff --git a/public/icons/180-padded.png b/public/icons/180-padded.png new file mode 100644 index 0000000000000000000000000000000000000000..79dea6121b760f4b8fc2bfa7cb63dac6d6228d8d GIT binary patch literal 8347 zcmbVSWmgn!s1e-NGVQ{;-xs3 z_x^)>KTL8?l9}Y3nK_x~Nusqi-{4^bu#u3E@Klr)bzl0X{{$2LrInsU7kufkJd};S zkdW|){uAUhE_`YvBnAx?MR`5{>_6sMpGg;*W%L(*3Q6ORb7Klw@}H;)_ba}Sey_GB z;#4rJ=)uf8ebZMaP!Ro9%gle6$4x6bMnGWLK^US#0$MX9MblB#$;Pvb{7~|*Pt@+2nA+B2|4Ow#}3 z5F;V1#@&Tqnc3dEsR^6&eJXB#W)tuf*PeNh-(`^h+eHbG2=?&|Co+N3F$wW`pnVG0 z%(PRlrrsUPe2G6>+*z6U@|*glo%?ZjbNrwNoI~?)%h^Rdj&%9@Fx|GGyB%wZ|NB2Y zg*U=qK$vk+-R1S{qCsyQMu@W*1Z>TJ+zoH8Ui$okTbvB6)^xd!tRk%!OqJNa!N-JW z?m5$MXS`oGIBWUTN&q!wSDtWpcRScwNzauI3NE;unpuzb~*C1b>4VSbR^zC?1aQyp$wul>}lJ9Ioyb}3G z0ArIRt9Hd2XNMn|1abRIr5B53pe#0m4~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)}4FkM7kG{2QEN zs{{wg5yRR4q0j;m3VrqseQE$nTaHF$oK~uOj>$noF{$*7-&5v~&vTa7`Ru}m0jGaa z*JAr9uGlF?C*4Z%*^?PqvWQ>cOmN5Bo6YHFY!fI4$Z8<}te#ZXzoDYoX_aXlwt_SXN%uCnXDS>lfY!t3fX_QO6=gcR!2 z;T)St^UQ^mp0kLxpjL)U)%b<^~{{z zXF6@o01&(`I~=6Kup^|BY1I;V_w=wNNa!l)FwAtQ>|kISOQ-d4bc|fvuW>ATTW+BYPX$|H&p{5m+az zSTa|%!UzeFQC#g|GI&mU(j0Q$`^f7Vme(*1#sCq5s>pg_9a*Z7Ay@#@`{2p028Z9h^4FaFMmsk zr)H9CC*}EECa`%R-_QPoYk&3w70aKH^?=F)S|fl=#DvFBPkWLwiSSGwilq8w~ILKwG}R0I<%keU#q*U(&jFA){Y!`9jne zyGv;zDsbY1x*y4rQ~$n*>!QHI{Z*CT^TM_F0%U;!*k*!V7Qs3S`2^|Ot|*7m21A^; zHt!;0=?c=k7opTUfN*xm1UW*8&=~$JaRp~dau$tXz}}6-NKI%17=R5$Q|Q8ZPZ*@IuEc(UP2GC-*h2D+ z@eARFX@zkMW8bX8;Czyr(C&1#4M<@GW>R~GR`GES$z3BIb;}G$VSClXe8!%kJ9*Ue z;7aB62BVHdYCF(z9(SpeYR?dkhq14Y&uycY4MrVB6BHK2=FuKjxor-=dfVo3Vh8rs z@hO;t(gd|}@_ZzhaqvS99xMN*{{bC` VLYue2->m=u002ovPDHLkV1n6awlV+! literal 0 HcmV?d00001 diff --git a/vite.config.ts b/vite.config.ts index b851d908d..06480c36d 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -33,12 +33,17 @@ const pwaOptions: Partial = { type: 'image/png', }, { - src: '/icons/128-padded.png', - sizes: '128x128', + src: '/icons/64.png', + sizes: '64x64', type: 'image/png', }, { - src: '/icons/180.png', + src: '/icons/120.png', + sizes: '120x120', + type: 'image/png', + }, + { + src: '/icons/180-padded.png', sizes: '180x180', type: 'image/png', }, From 5723eb27559d2152c22954a2579ba607b64e648e Mon Sep 17 00:00:00 2001 From: sajald77 Date: Fri, 18 Aug 2023 14:04:38 -0400 Subject: [PATCH 02/54] fix: add new script for upstream running, dev-stage --- .gitignore | 1 + package.json | 1 + vite.config.ts | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 66445bcf1..960661a7c 100644 --- a/.gitignore +++ b/.gitignore @@ -19,6 +19,7 @@ .env.development.local .env.test.local .env.production.local +.env.staging .env npm-debug.log* diff --git a/package.json b/package.json index ddc9da014..45bbfe03e 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,7 @@ "version": "0.5.0", "scripts": { "dev": "vite", + "dev:stage": "vite --mode staging", "build": "tsc && vite build", "preview": "vite preview --port 3000", "test:e2e": "yarn cypress run --e2e", diff --git a/vite.config.ts b/vite.config.ts index b851d908d..663fe1d16 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -116,7 +116,7 @@ export default defineConfig(({ command, mode }) => { pwaOptions.mode = env.APP_ENV === 'development' ? 'development' : 'production' const plugins: PluginOption[] = [VitePWA(pwaOptions), react()] - if (mode === 'development') { + if (mode !== 'production') { plugins.push(mkcert()) } From 5cff146ad061ef54cd2d70afdfd5a9e7152fbe9f Mon Sep 17 00:00:00 2001 From: sajald77 Date: Fri, 18 Aug 2023 14:04:54 -0400 Subject: [PATCH 03/54] fix: qr code flickering issue --- src/hooks/fundingFlow/useFundingFlow.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/hooks/fundingFlow/useFundingFlow.tsx b/src/hooks/fundingFlow/useFundingFlow.tsx index 0e5be1fa0..e33b3142d 100644 --- a/src/hooks/fundingFlow/useFundingFlow.tsx +++ b/src/hooks/fundingFlow/useFundingFlow.tsx @@ -281,6 +281,8 @@ export const useFundingFlow = (options?: IFundingFlowOptions) => { return { ...current, ...fundingActivity, + paymentRequest: + fundingActivity.paymentRequest || current.paymentRequest, uuid: fundingActivity.uuid || current.uuid, } } From aa3889c21a1e42ea0984087ea74d3b611c216972 Mon Sep 17 00:00:00 2001 From: sajald77 Date: Fri, 18 Aug 2023 14:08:33 -0400 Subject: [PATCH 04/54] fix: add loader till the success component is loaded --- .../screens/success/components/SuccessImageComponent.tsx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/pages/projectView/projectActivityPanel/screens/success/components/SuccessImageComponent.tsx b/src/pages/projectView/projectActivityPanel/screens/success/components/SuccessImageComponent.tsx index b5b846e26..80c293f7d 100644 --- a/src/pages/projectView/projectActivityPanel/screens/success/components/SuccessImageComponent.tsx +++ b/src/pages/projectView/projectActivityPanel/screens/success/components/SuccessImageComponent.tsx @@ -8,7 +8,7 @@ import { VStack, } from '@chakra-ui/react' import * as htmlToImage from 'html-to-image' -import { useState } from 'react' +import { useRef, useState } from 'react' import { useTranslation } from 'react-i18next' import { BiCopy } from 'react-icons/bi' import { HiOutlineCheck } from 'react-icons/hi' @@ -33,6 +33,8 @@ export const SuccessImageComponent = ({ const { project } = useProjectContext() + const successComponent = useRef(null) + if (!project) { return null } @@ -59,7 +61,7 @@ export const SuccessImageComponent = ({ } const getDataUrl = async () => { - const element = document.getElementById('successful-contribution-banner') + const element = successComponent.current if (element) { const dataUrl = await htmlToImage.toPng(element, { style: { backgroundColor: 'primary.400', borderStyle: 'double' }, @@ -79,6 +81,7 @@ export const SuccessImageComponent = ({ } onClick={handleCopy} + isLoading={successComponent.current === null} > Date: Fri, 18 Aug 2023 17:46:18 -0400 Subject: [PATCH 05/54] fix: reconnection for subscriptions --- src/config/apollo-client/apolloClient.ts | 51 ++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/src/config/apollo-client/apolloClient.ts b/src/config/apollo-client/apolloClient.ts index e8ce358dc..53916e075 100644 --- a/src/config/apollo-client/apolloClient.ts +++ b/src/config/apollo-client/apolloClient.ts @@ -39,9 +39,60 @@ const httpLink = createHttpLink({ const prefix = __development__ ? 'ws' : 'wss' +let restartRequestedBeforeConnected = false +let gracefullyRestart = () => { + restartRequestedBeforeConnected = true +} + +let activeSocket: WebSocket | null = null +let timedOut = 0 + +const closeSocket = (socket: WebSocket | null) => { + if (socket?.readyState === WebSocket?.OPEN) { + socket?.close(4408, 'Request Timeout') + } +} + const wsLink = new GraphQLWsLink( createClient({ url: `${prefix}://${API_SERVICE_ENDPOINT.split('//')[1]}/graphql`, + retryAttempts: Infinity, + shouldRetry: () => true, + keepAlive: 10000, + on: { + error() { + if (activeSocket) { + closeSocket(activeSocket) + } + }, + connected(socket: any) { + activeSocket = socket // save the active socket for later use + // restart by closing the socket which will trigger a silent reconnect + gracefullyRestart = () => { + closeSocket(socket) + } + + // if any restarts were missed during the connection + // phase, restart and reset the request + if (restartRequestedBeforeConnected) { + restartRequestedBeforeConnected = false + gracefullyRestart() + } + }, + ping(received) { + if (!received) { + // sent + timedOut = setTimeout(() => { + closeSocket(activeSocket) + }, 5000) + } // wait 5 seconds for the pong and then close the connection + }, + pong(received) { + if (received) { + clearTimeout(timedOut) + } // pong is received, clear connection close timeout + }, + }, }), ) From 4cfa6ea1c7c5de5ef921d26c4de6e6fc3d789b9c Mon Sep 17 00:00:00 2001 From: sajald77 Date: Tue, 22 Aug 2023 15:09:13 -0400 Subject: [PATCH 06/54] fix: add stuff to readme.md about dev:stage --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index d8136ed7e..aba18d1ac 100644 --- a/README.md +++ b/README.md @@ -51,6 +51,13 @@ APOLLO_KEY= [Contact us](email:admin@geyser.fund) if you don't have an `APOLLO_KEY` yet. +#### Option C: use both local server and staging API interchangably + +Many at times we prefer using staging API while sometimes we prefer the local server. In such cases we can setup to use them interchangably. + +1. Create the normal `.env` file, which contains the values for local server. This would be used when we command `yarn dev`. +2. Create a new file `.env.staging` this would have the values to use the staging API, and use the command `yarn dev:stage` to use the staging server env values. + ### Hosts Configuration In order for the requests to go through to the staging backend API, you will need to add the following line to your `/etc/hosts` file: From 664859cec824e0fd6135be776b7e7d5aca62ae18 Mon Sep 17 00:00:00 2001 From: sajald77 Date: Wed, 23 Aug 2023 11:13:28 -0400 Subject: [PATCH 07/54] fix: markdown table in WIP --- package.json | 3 + src/config/theme/popOverTheme.ts | 14 + src/config/theme/theme.ts | 2 + src/forms/components/TableExtension.tsx | 1 + src/forms/markdown/MarkdownField.tsx | 30 +- src/forms/markdown/MarkdownToolbar.tsx | 2 + src/forms/markdown/commands/ImageCommand.tsx | 2 + src/forms/markdown/commands/LinkCommand.tsx | 1 + src/forms/markdown/commands/TableCommand.tsx | 167 +++++ src/forms/markdown/commands/VideoCommand.tsx | 1 + .../markdown/commands/useToolbarCommand.ts | 2 +- src/forms/markdown/helpers/StyleProvider.tsx | 3 + src/forms/markdown/helpers/typeMaps.tsx | 18 + src/forms/markdown/toolbar/ToolbarTable.tsx | 34 + .../projectDashboard/ProjectDashboard.tsx | 8 +- yarn.lock | 648 +++++++++++++++++- 16 files changed, 926 insertions(+), 10 deletions(-) create mode 100644 src/config/theme/popOverTheme.ts create mode 100644 src/forms/components/TableExtension.tsx create mode 100644 src/forms/markdown/commands/TableCommand.tsx create mode 100644 src/forms/markdown/toolbar/ToolbarTable.tsx diff --git a/package.json b/package.json index 45bbfe03e..cb931d831 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,9 @@ "@hookform/resolvers": "^3.1.0", "@loadable/component": "^5.15.3", "@react-hookz/web": "^23.0.0", + "@remirror/extension-node-formatting": "^2.0.13", + "@remirror/extension-react-component": "^2.0.13", + "@remirror/extension-react-tables": "^2.2.18", "@remirror/pm": "^2.0.5", "@remirror/react": "^2.0.28", "@remirror/react-components": "^2.1.12", diff --git a/src/config/theme/popOverTheme.ts b/src/config/theme/popOverTheme.ts new file mode 100644 index 000000000..384782aa4 --- /dev/null +++ b/src/config/theme/popOverTheme.ts @@ -0,0 +1,14 @@ +import { popoverAnatomy } from '@chakra-ui/anatomy' +import { createMultiStyleConfigHelpers } from '@chakra-ui/react' + +const { definePartsStyle, defineMultiStyleConfig } = + createMultiStyleConfigHelpers(popoverAnatomy.keys) + +const baseStyle = definePartsStyle({ + body: { + bg: 'neutral.0', + borderRadius: '8px', + }, +}) + +export const popOverTheme = defineMultiStyleConfig({ baseStyle }) diff --git a/src/config/theme/theme.ts b/src/config/theme/theme.ts index ea0c72f58..8d105c9f6 100644 --- a/src/config/theme/theme.ts +++ b/src/config/theme/theme.ts @@ -5,6 +5,7 @@ import { alertTheme } from './alertTheme' import { drawerTheme } from './drawerTheme' import { menuTheme } from './menuTheme' import { modalTheme } from './modalTheme' +import { popOverTheme } from './popOverTheme' export const theme = { initialColorMode: 'system', @@ -247,6 +248,7 @@ export const theme = { Menu: menuTheme, Modal: modalTheme, Drawer: drawerTheme, + Popover: popOverTheme, Input: { defaultProps: { focusBorderColor: 'primary.400', diff --git a/src/forms/components/TableExtension.tsx b/src/forms/components/TableExtension.tsx new file mode 100644 index 000000000..403e5a1c4 --- /dev/null +++ b/src/forms/components/TableExtension.tsx @@ -0,0 +1 @@ +import { TableExtension } from '@remirror/extension-react-tables' diff --git a/src/forms/markdown/MarkdownField.tsx b/src/forms/markdown/MarkdownField.tsx index 7fb638939..348c1fdd9 100644 --- a/src/forms/markdown/MarkdownField.tsx +++ b/src/forms/markdown/MarkdownField.tsx @@ -1,10 +1,11 @@ import { Box, Button, HStack, Text } from '@chakra-ui/react' +// import { ReactComponentExtension } from '@remirror/extension-react-component' import { EditorComponent, Remirror, useRemirror } from '@remirror/react' import { ForwardedRef, useCallback } from 'react' import { Control } from 'react-hook-form' import { useTranslation } from 'react-i18next' import { BsGear } from 'react-icons/bs' -import { InvalidContentHandler } from 'remirror' +import { AnyExtension, InvalidContentHandler } from 'remirror' import { BlockquoteExtension, BoldExtension, @@ -17,6 +18,7 @@ import { ItalicExtension, LinkExtension, MarkdownExtension, + NodeFormattingExtension, OrderedListExtension, PlaceholderExtension, TableExtension, @@ -80,8 +82,8 @@ export const MarkdownField = ({ const { uploadFile } = useSignedUpload() - const extensions = useCallback( - () => [ + const extensions = useCallback<() => AnyExtension[]>(() => { + const exts = [ new PlaceholderExtension({ placeholder }), new LinkExtension({ autoLink: true, @@ -92,7 +94,11 @@ export const MarkdownField = ({ }), new MarkdownExtension({ copyAsMarkdown: true, - htmlToMarkdown: (html) => turndownService.turndown(html), + htmlToMarkdown(html) { + console.log('checking html', html) + return `${html}` + }, + // htmlToMarkdown: (html) => turndownService.turndown(html), }), new BoldExtension(), new UnderlineExtension(), @@ -107,6 +113,7 @@ export const MarkdownField = ({ new TrailingNodeExtension(), new BulletListExtension(), new TextExtension(), + new ImageExtension({ uploadHandler(files) { return files.map( @@ -119,9 +126,14 @@ export const MarkdownField = ({ }, enableResizing: false, }), - ], - [placeholder, uploadFile], - ) + ] as AnyExtension[] + + if (!preview) { + exts.push(new NodeFormattingExtension()) + } + + return exts + }, [placeholder, uploadFile]) const { manager } = useRemirror({ extensions, @@ -139,6 +151,9 @@ export const MarkdownField = ({ orderedList: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( ), + table: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( + + ), }, }, }) @@ -165,6 +180,7 @@ export const MarkdownField = ({ display="flex" justifyContent="space-between" alignItems="start" + mb={2} sx={ stickyToolbar !== undefined && stickyToolbar !== false ? { diff --git a/src/forms/markdown/MarkdownToolbar.tsx b/src/forms/markdown/MarkdownToolbar.tsx index 6028fc1d2..72694708d 100644 --- a/src/forms/markdown/MarkdownToolbar.tsx +++ b/src/forms/markdown/MarkdownToolbar.tsx @@ -4,6 +4,7 @@ import { ToolbarBlocks } from './toolbar/ToolbarBlocks' import { ToolbarCommon } from './toolbar/ToolbarCommon' import { ToolbarHeading } from './toolbar/ToolbarHeading' import { ToolbarMedia } from './toolbar/ToolbarMedia' +import { ToolbarTable } from './toolbar/ToolbarTable' export const MarkdownToolbar = ({ isDisabled }: { isDisabled?: boolean }) => { return ( @@ -12,6 +13,7 @@ export const MarkdownToolbar = ({ isDisabled }: { isDisabled?: boolean }) => { + ) } diff --git a/src/forms/markdown/commands/ImageCommand.tsx b/src/forms/markdown/commands/ImageCommand.tsx index d179b40ee..3183a7ee0 100644 --- a/src/forms/markdown/commands/ImageCommand.tsx +++ b/src/forms/markdown/commands/ImageCommand.tsx @@ -9,10 +9,12 @@ export const ImageCommand = ({ isDisabled }: { isDisabled?: boolean }) => { const commands = useCommands() const modal = useInsertLinkModal(({ url, label }: MarkdownImage) => { + if (!commands.insertImage) return commands.insertImage({ src: url, alt: label || 'image', }) + modal.onClose() }) diff --git a/src/forms/markdown/commands/LinkCommand.tsx b/src/forms/markdown/commands/LinkCommand.tsx index 0578ec1fa..e1779a8c8 100644 --- a/src/forms/markdown/commands/LinkCommand.tsx +++ b/src/forms/markdown/commands/LinkCommand.tsx @@ -12,6 +12,7 @@ export const LinkCommand = ({ isDisabled }: { isDisabled?: boolean }) => { const commands = useCommands() const modal = useInsertLinkModal(({ url, label }: MarkdownLink) => { + if (!commands.insertMarkdown) return commands.insertMarkdown(`[${label || url}](${url})`) modal.onClose() }) diff --git a/src/forms/markdown/commands/TableCommand.tsx b/src/forms/markdown/commands/TableCommand.tsx new file mode 100644 index 000000000..1dbe916b0 --- /dev/null +++ b/src/forms/markdown/commands/TableCommand.tsx @@ -0,0 +1,167 @@ +import { + Box, + Checkbox, + HStack, + Popover, + PopoverArrow, + PopoverBody, + PopoverCloseButton, + PopoverContent, + PopoverTrigger, + Text, + useDisclosure, + VStack, +} from '@chakra-ui/react' +import { useCommands } from '@remirror/react' +import { useState } from 'react' +import { useTranslation } from 'react-i18next' +import { BsTable } from 'react-icons/bs' +import { + RiDeleteColumn, + RiDeleteRow, + RiInsertColumnRight, + RiInsertRowBottom, +} from 'react-icons/ri' + +import { Body2, MonoBody2 } from '../../../components/typography' +import { useDebounce } from '../../../hooks' +import { ToolbarCommandButton } from './ToolbarCommandButton' + +interface TableCommandProps { + isDisabled?: boolean +} + +const tableBoxes = [ + [1, 2, 3, 4, 5, 6], + [1, 2, 3, 4, 5, 6], + [1, 2, 3, 4, 5, 6], + [1, 2, 3, 4, 5, 6], + [1, 2, 3, 4, 5, 6], +] + +export const TableCommand = ({ isDisabled }: TableCommandProps) => { + const { t } = useTranslation() + const { isOpen, onOpen, onClose } = useDisclosure() + const [hasHeader, setHasHeader] = useState(true) + + const commands = useCommands() + + const debouncedIsOpen = useDebounce(isOpen, 200) + + const [currentPosition, setCurrentPosition] = useState({ i: 0, j: 0 }) + + const handleTableCreate = ({ i, j }: { i: number; j: number }) => { + if (!commands.createTable) return + commands.createTable({ + rowsCount: i + 1, + columnsCount: j + 1, + }) + onClose() + } + + return ( + <> + + + + + + + + + + + + + + + + + + + + + + + + + + {tableBoxes.map((row, i) => ( + + {row.map((col, j) => ( + setCurrentPosition({ i, j })} + onClick={() => handleTableCreate({ i, j })} + > + + + ))} + + ))} + + + setHasHeader(e.target.checked)} + > + {t('headers')} + + {`${currentPosition.i + 1}X${ + currentPosition.j + 1 + }`} + + + + + + + ) +} diff --git a/src/forms/markdown/commands/VideoCommand.tsx b/src/forms/markdown/commands/VideoCommand.tsx index b4043ed56..74283e9d2 100644 --- a/src/forms/markdown/commands/VideoCommand.tsx +++ b/src/forms/markdown/commands/VideoCommand.tsx @@ -12,6 +12,7 @@ export const VideoCommand = ({ isDisabled }: { isDisabled?: boolean }) => { const commands = useCommands() const modal = useInsertVideoModal(({ url }: MarkdownVideo) => { + if (!commands.addYouTubeVideo) return commands.addYouTubeVideo({ video: url }) modal.onClose() }) diff --git a/src/forms/markdown/commands/useToolbarCommand.ts b/src/forms/markdown/commands/useToolbarCommand.ts index da8bf540b..cb13b0952 100644 --- a/src/forms/markdown/commands/useToolbarCommand.ts +++ b/src/forms/markdown/commands/useToolbarCommand.ts @@ -11,7 +11,7 @@ export const useToolbarCommand = (name: string, cmd: string) => { (attrs?: any) => { if (command) { command(attrs) - commands.focus() + commands.focus?.() } }, [command, commands], diff --git a/src/forms/markdown/helpers/StyleProvider.tsx b/src/forms/markdown/helpers/StyleProvider.tsx index e65cbea7d..d73f8c436 100644 --- a/src/forms/markdown/helpers/StyleProvider.tsx +++ b/src/forms/markdown/helpers/StyleProvider.tsx @@ -17,6 +17,9 @@ const Container = styled(Box, { '& a': { textDecoration: 'underline', }, + '& tr, & th, & td': { + height: '10px', + }, width: '100%', }, }) diff --git a/src/forms/markdown/helpers/typeMaps.tsx b/src/forms/markdown/helpers/typeMaps.tsx index cc6d199a6..5e37d942b 100644 --- a/src/forms/markdown/helpers/typeMaps.tsx +++ b/src/forms/markdown/helpers/typeMaps.tsx @@ -4,6 +4,12 @@ import { ListItem, ListProps, OrderedList, + Table, + Tbody, + Td, + Th, + Thead, + Tr, UnorderedList, } from '@chakra-ui/react' import { @@ -49,6 +55,12 @@ export const typeMap = { paragraph: 'p', orderedList: OrderedList, text: TextHandler, + table: Table, + tableHeader: Thead, + tableHeaderCell: Th, + tbody: Tbody, + tableRow: Tr, + tableCell: Td, } satisfies MarkMap export const markMap = { @@ -57,4 +69,10 @@ export const markMap = { code: 'code', link: createLinkHandler({ target: '_blank' }), underline: 'u', + table: 'table', + tableHeader: 'thead', + tableHeaderCell: 'th', + tbody: 'tbody', + tableRow: 'tr', + tableCell: 'td', } satisfies MarkMap diff --git a/src/forms/markdown/toolbar/ToolbarTable.tsx b/src/forms/markdown/toolbar/ToolbarTable.tsx new file mode 100644 index 000000000..2dc60ef0f --- /dev/null +++ b/src/forms/markdown/toolbar/ToolbarTable.tsx @@ -0,0 +1,34 @@ +import { ButtonGroup } from '@chakra-ui/react' +import { BiAlignLeft, BiAlignMiddle, BiAlignRight } from 'react-icons/bi' + +import { TableCommand } from '../commands/TableCommand' +import { ToolbarCommand } from '../commands/ToolbarCommand' + +export const ToolbarTable = ({ isDisabled }: { isDisabled?: boolean }) => { + return ( + + + + + + + ) +} diff --git a/src/pages/projectDashboard/ProjectDashboard.tsx b/src/pages/projectDashboard/ProjectDashboard.tsx index f27580e28..c9346210c 100644 --- a/src/pages/projectDashboard/ProjectDashboard.tsx +++ b/src/pages/projectDashboard/ProjectDashboard.tsx @@ -16,6 +16,7 @@ export type DashboardSection = { label: string path: keyof PathsMap fullWidth?: boolean + semiFullWidth?: boolean } export const creatorSections: Record = { @@ -43,6 +44,7 @@ export const projectSections: Record = { story: { label: 'Story', path: 'dashboardStory', + semiFullWidth: true, }, wallet: { label: 'Connect wallet', @@ -139,7 +141,11 @@ export const ProjectDashboard = () => { }} maxWidth={{ base: '100%', - lg: activeSection?.fullWidth ? '100%' : '2xl', + lg: activeSection?.fullWidth + ? '100%' + : activeSection?.semiFullWidth + ? '4xl' + : '2xl', }} justifyItems="center" > diff --git a/yarn.lock b/yarn.lock index 1346cab13..310946572 100644 --- a/yarn.lock +++ b/yarn.lock @@ -87,6 +87,14 @@ dependencies: "@babel/highlight" "^7.18.6" +"@babel/code-frame@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.22.10.tgz#1c20e612b768fefa75f6e90d6ecb86329247f0a3" + integrity sha512-/KKIMG4UEL35WmI9OlvMhurwtytjvXoFcGNrOvyG9zIzA8YmPjVtIZUf7b05+TPO7G7/GEmLHDaoCgACHl9hhA== + dependencies: + "@babel/highlight" "^7.22.10" + chalk "^2.4.2" + "@babel/code-frame@^7.22.5": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.22.5.tgz#234d98e1551960604f1246e6475891a570ad5658" @@ -172,6 +180,27 @@ json5 "^2.2.2" semver "^6.3.0" +"@babel/core@^7.22.9": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.22.10.tgz#aad442c7bcd1582252cb4576747ace35bc122f35" + integrity sha512-fTmqbbUBAwCcre6zPzNngvsI0aNrPZe77AeqvDxWM9Nm+04RrJ3CAmGHA9f7lJQY6ZMhRztNemy4uslDxTX4Qw== + dependencies: + "@ampproject/remapping" "^2.2.0" + "@babel/code-frame" "^7.22.10" + "@babel/generator" "^7.22.10" + "@babel/helper-compilation-targets" "^7.22.10" + "@babel/helper-module-transforms" "^7.22.9" + "@babel/helpers" "^7.22.10" + "@babel/parser" "^7.22.10" + "@babel/template" "^7.22.5" + "@babel/traverse" "^7.22.10" + "@babel/types" "^7.22.10" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.2" + json5 "^2.2.2" + semver "^6.3.1" + "@babel/generator@^7.14.0", "@babel/generator@^7.18.13", "@babel/generator@^7.21.3": version "7.21.3" resolved "https://registry.npmjs.org/@babel/generator/-/generator-7.21.3.tgz" @@ -192,6 +221,16 @@ "@jridgewell/trace-mapping" "^0.3.17" jsesc "^2.5.1" +"@babel/generator@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.22.10.tgz#c92254361f398e160645ac58831069707382b722" + integrity sha512-79KIf7YiWjjdZ81JnLujDRApWtl7BxTqWD88+FFdQEIOG8LJ0etDOM7CXuIgGJa55sGOwZVwuEsaLEm0PJ5/+A== + dependencies: + "@babel/types" "^7.22.10" + "@jridgewell/gen-mapping" "^0.3.2" + "@jridgewell/trace-mapping" "^0.3.17" + jsesc "^2.5.1" + "@babel/generator@^7.22.7", "@babel/generator@^7.22.9": version "7.22.9" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.22.9.tgz#572ecfa7a31002fa1de2a9d91621fd895da8493d" @@ -245,6 +284,17 @@ lru-cache "^5.1.1" semver "^6.3.0" +"@babel/helper-compilation-targets@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.10.tgz#01d648bbc25dd88f513d862ee0df27b7d4e67024" + integrity sha512-JMSwHD4J7SLod0idLq5PKgI+6g/hLD/iuWBq08ZX49xE14VpVEojJ5rHWptpirV2j020MvypRLAXAO50igCJ5Q== + dependencies: + "@babel/compat-data" "^7.22.9" + "@babel/helper-validator-option" "^7.22.5" + browserslist "^4.21.9" + lru-cache "^5.1.1" + semver "^6.3.1" + "@babel/helper-compilation-targets@^7.22.5", "@babel/helper-compilation-targets@^7.22.6", "@babel/helper-compilation-targets@^7.22.9": version "7.22.9" resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.9.tgz#f9d0a7aaaa7cd32a3f31c9316a69f5a9bcacb892" @@ -594,6 +644,15 @@ "@babel/traverse" "^7.21.5" "@babel/types" "^7.21.5" +"@babel/helpers@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.22.10.tgz#ae6005c539dfbcb5cd71fb51bfc8a52ba63bc37a" + integrity sha512-a41J4NW8HyZa1I1vAndrraTlPZ/eZoga2ZgS7fEr0tZJGVU4xqdE80CEm0CcNjha5EZ8fTBYLKHF0kqDUuAwQw== + dependencies: + "@babel/template" "^7.22.5" + "@babel/traverse" "^7.22.10" + "@babel/types" "^7.22.10" + "@babel/helpers@^7.22.6": version "7.22.6" resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.22.6.tgz#8e61d3395a4f0c5a8060f309fb008200969b5ecd" @@ -612,6 +671,15 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.22.10.tgz#02a3f6d8c1cb4521b2fd0ab0da8f4739936137d7" + integrity sha512-78aUtVcT7MUscr0K5mIEnkwxPE0MaxkR5RxRwuHaQ+JuU5AmTPhY+do2mdzVTnIJJpyBglql2pehuBIWHug+WQ== + dependencies: + "@babel/helper-validator-identifier" "^7.22.5" + chalk "^2.4.2" + js-tokens "^4.0.0" + "@babel/highlight@^7.22.5": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.22.5.tgz#aa6c05c5407a67ebce408162b7ede789b4d22031" @@ -631,6 +699,11 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.21.8.tgz#642af7d0333eab9c0ad70b14ac5e76dbde7bfdf8" integrity sha512-6zavDGdzG3gUqAdWvlLFfk+36RilI+Pwyuuh7HItyeScCWP3k6i8vKclAQ0bM/0y/Kz/xiwvxhMv9MgTJP5gmA== +"@babel/parser@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.22.10.tgz#e37634f9a12a1716136c44624ef54283cabd3f55" + integrity sha512-lNbdGsQb9ekfsnjFGhEiF4hfFqGgfOP3H3d27re3n+CGhNuTSUEQdfWk556sTLNTloczcdM5TYF2LhzmDQKyvQ== + "@babel/parser@^7.22.5", "@babel/parser@^7.22.7": version "7.22.7" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.22.7.tgz#df8cf085ce92ddbdbf668a7f186ce848c9036cae" @@ -1541,6 +1614,13 @@ dependencies: regenerator-runtime "^0.13.11" +"@babel/runtime@^7.21.5", "@babel/runtime@^7.22.3", "@babel/runtime@^7.22.6": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.10.tgz#ae3e9631fd947cb7e3610d3e9d8fef5f76696682" + integrity sha512-21t/fkKLMZI4pqP2wlmsQAWnYW1PDyKyyUV4vCi+B25ydmdaYTKXPwCj0BzSUnZf4seIiYvSA3jcZ3gdsMFkLQ== + dependencies: + regenerator-runtime "^0.14.0" + "@babel/template@^7.18.10", "@babel/template@^7.20.7": version "7.20.7" resolved "https://registry.npmjs.org/@babel/template/-/template-7.20.7.tgz" @@ -1591,6 +1671,22 @@ debug "^4.1.0" globals "^11.1.0" +"@babel/traverse@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.22.10.tgz#20252acb240e746d27c2e82b4484f199cf8141aa" + integrity sha512-Q/urqV4pRByiNNpb/f5OSv28ZlGJiFiiTh+GAHktbIrkPhPbl90+uW6SmpoLyZqutrg9AEaEf3Q/ZBRHBXgxig== + dependencies: + "@babel/code-frame" "^7.22.10" + "@babel/generator" "^7.22.10" + "@babel/helper-environment-visitor" "^7.22.5" + "@babel/helper-function-name" "^7.22.5" + "@babel/helper-hoist-variables" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + "@babel/parser" "^7.22.10" + "@babel/types" "^7.22.10" + debug "^4.1.0" + globals "^11.1.0" + "@babel/traverse@^7.22.6", "@babel/traverse@^7.22.8": version "7.22.8" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.22.8.tgz#4d4451d31bc34efeae01eac222b514a77aa4000e" @@ -1625,6 +1721,15 @@ "@babel/helper-validator-identifier" "^7.19.1" to-fast-properties "^2.0.0" +"@babel/types@^7.22.10": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.22.10.tgz#4a9e76446048f2c66982d1a989dd12b8a2d2dc03" + integrity sha512-obaoigiLrlDZ7TUQln/8m4mSqIW2QFeOrCQc9r+xsaHGNoplVNYlRVpsfE8Vj35GEm2ZH4ZhrNYogs/3fj85kg== + dependencies: + "@babel/helper-string-parser" "^7.22.5" + "@babel/helper-validator-identifier" "^7.22.5" + to-fast-properties "^2.0.0" + "@babel/types@^7.22.5", "@babel/types@^7.4.4": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.22.5.tgz#cd93eeaab025880a3a47ec881f4b096a5b786fbe" @@ -2742,6 +2847,17 @@ "@emotion/sheet" "^1.2.2" "@emotion/utils" "^1.2.1" +"@emotion/css@^11.11.0": + version "11.11.2" + resolved "https://registry.yarnpkg.com/@emotion/css/-/css-11.11.2.tgz#e5fa081d0c6e335352e1bc2b05953b61832dca5a" + integrity sha512-VJxe1ucoMYMS7DkiMdC2T7PWNbrEI0a39YRiyDvK2qq4lXwjRbVP/z4lpG+odCsRzadlR+1ywwrTzhdm5HNdew== + dependencies: + "@emotion/babel-plugin" "^11.11.0" + "@emotion/cache" "^11.11.0" + "@emotion/serialize" "^1.1.2" + "@emotion/sheet" "^1.2.2" + "@emotion/utils" "^1.2.1" + "@emotion/hash@0.8.0": version "0.8.0" resolved "https://registry.npmjs.org/@emotion/hash/-/hash-0.8.0.tgz" @@ -3124,6 +3240,13 @@ resolved "https://registry.npmjs.org/@floating-ui/core/-/core-1.2.4.tgz" integrity sha512-SQOeVbMwb1di+mVWWJLpsUTToKfqVNioXys011beCAhyOIFtS+GQoW4EQSneuxzmQKddExDwQ+X0hLl4lJJaSQ== +"@floating-ui/core@^1.4.1": + version "1.4.1" + resolved "https://registry.yarnpkg.com/@floating-ui/core/-/core-1.4.1.tgz#0d633f4b76052668afb932492ac452f7ebe97f17" + integrity sha512-jk3WqquEJRlcyu7997NtR5PibI+y5bi+LS3hPmguVClypenMsCY3CBa3LAQnozRCtCrYWSEtAdiskpamuJRFOQ== + dependencies: + "@floating-ui/utils" "^0.1.1" + "@floating-ui/dom@^1.0.1": version "1.2.5" resolved "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.2.5.tgz" @@ -3131,6 +3254,35 @@ dependencies: "@floating-ui/core" "^1.2.4" +"@floating-ui/dom@^1.3.0": + version "1.5.1" + resolved "https://registry.yarnpkg.com/@floating-ui/dom/-/dom-1.5.1.tgz#88b70defd002fe851f17b4a25efb2d3c04d7a8d7" + integrity sha512-KwvVcPSXg6mQygvA1TjbN/gh///36kKtllIF8SUm0qpFj8+rvYrpvlYdL1JoA71SHpDqgSSdGOSoQ0Mp3uY5aw== + dependencies: + "@floating-ui/core" "^1.4.1" + "@floating-ui/utils" "^0.1.1" + +"@floating-ui/react-dom@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@floating-ui/react-dom/-/react-dom-2.0.1.tgz#7972a4fc488a8c746cded3cfe603b6057c308a91" + integrity sha512-rZtAmSht4Lry6gdhAJDrCp/6rKN7++JnL1/Anbr/DdeyYXQPxvg/ivrbYvJulbRf4vL8b212suwMM2lxbv+RQA== + dependencies: + "@floating-ui/dom" "^1.3.0" + +"@floating-ui/react@^0.24.3": + version "0.24.8" + resolved "https://registry.yarnpkg.com/@floating-ui/react/-/react-0.24.8.tgz#e079e2836990be3fce9665ab509360a5447251a1" + integrity sha512-AuYeDoaR8jtUlUXtZ1IJ/6jtBkGnSpJXbGNzokBL87VDJ8opMq1Bgrc0szhK482ReQY6KZsMoZCVSb4xwalkBA== + dependencies: + "@floating-ui/react-dom" "^2.0.1" + aria-hidden "^1.2.3" + tabbable "^6.0.1" + +"@floating-ui/utils@^0.1.1": + version "0.1.1" + resolved "https://registry.yarnpkg.com/@floating-ui/utils/-/utils-0.1.1.tgz#1a5b1959a528e374e8037c4396c3e825d6cf4a83" + integrity sha512-m0G6wlnhm/AX0H12IOWtK8gASEMffnX08RtKkCgTdHb9JpHKGloI7icFfLg9ZmQeavcvR0PKmzxClyuFPSjKWw== + "@giphy/js-analytics@*": version "4.3.2" resolved "https://registry.yarnpkg.com/@giphy/js-analytics/-/js-analytics-4.3.2.tgz#9710c7eb6e401571d4219a870cb6b0d35df61cdc" @@ -3793,6 +3945,15 @@ "@jridgewell/resolve-uri" "3.1.0" "@jridgewell/sourcemap-codec" "1.4.14" +"@linaria/core@4.2.10": + version "4.2.10" + resolved "https://registry.yarnpkg.com/@linaria/core/-/core-4.2.10.tgz#3f8d45b20205c167d326d558ee9a926039483767" + integrity sha512-S1W01W7L4SQnGpWzp8awyCpPIYUOEJ+OLjjXqKpIXOU+ozPwBt86Mjjdas9aZccVhNBWDja74cMCUAVp8yUpDQ== + dependencies: + "@linaria/logger" "^4.0.0" + "@linaria/tags" "^4.3.5" + "@linaria/utils" "^4.3.4" + "@linaria/core@4.2.9": version "4.2.9" resolved "https://registry.yarnpkg.com/@linaria/core/-/core-4.2.9.tgz#4917bde18d064a29cff4fd86aa99621f953a2a2c" @@ -3810,6 +3971,14 @@ debug "^4.1.1" picocolors "^1.0.0" +"@linaria/logger@^4.5.0": + version "4.5.0" + resolved "https://registry.yarnpkg.com/@linaria/logger/-/logger-4.5.0.tgz#e5de815ffe7806822f47a559a512b98f66acea13" + integrity sha512-XdQLk242Cpcsc9a3Cz1ktOE5ysTo2TpxdeFQEPwMm8Z/+F/S6ZxBDdHYJL09srXWz3hkJr3oS2FPuMZNH1HIxw== + dependencies: + debug "^4.1.1" + picocolors "^1.0.0" + "@linaria/tags@^4.3.4": version "4.3.5" resolved "https://registry.yarnpkg.com/@linaria/tags/-/tags-4.3.5.tgz#bf2e070d11179addf2f27a66cd29d8192e71ca89" @@ -3819,6 +3988,15 @@ "@linaria/logger" "^4.0.0" "@linaria/utils" "^4.3.4" +"@linaria/tags@^4.3.5": + version "4.5.4" + resolved "https://registry.yarnpkg.com/@linaria/tags/-/tags-4.5.4.tgz#071ab024227433f783ea2d948904fc164731a912" + integrity sha512-HPxLB6HlJWLi6o8+8lTLegOmDnbMbuzEE+zzunaPZEGSoIIYx8HAv5VbY/sG/zNyxDElk6laiAwEVWN8h5/zxg== + dependencies: + "@babel/generator" "^7.22.9" + "@linaria/logger" "^4.5.0" + "@linaria/utils" "^4.5.3" + "@linaria/utils@^4.3.3", "@linaria/utils@^4.3.4": version "4.3.4" resolved "https://registry.yarnpkg.com/@linaria/utils/-/utils-4.3.4.tgz#860db9131e498b62510e49dc6fd4a8f0ed44bf4d" @@ -3833,6 +4011,24 @@ "@linaria/logger" "^4.0.0" babel-merge "^3.0.0" +"@linaria/utils@^4.5.3": + version "4.5.3" + resolved "https://registry.yarnpkg.com/@linaria/utils/-/utils-4.5.3.tgz#cf54f4096927ea347d01e814c1fb7aca7cf4063a" + integrity sha512-tSpxA3Zn0DKJ2n/YBnYAgiDY+MNvkmzAHrD8R9PKrpGaZ+wz1jQEmE1vGn1cqh8dJyWK0NzPAA8sf1cqa+RmAg== + dependencies: + "@babel/core" "^7.22.9" + "@babel/generator" "^7.22.9" + "@babel/plugin-proposal-export-namespace-from" "^7.18.9" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + "@babel/plugin-transform-modules-commonjs" "^7.22.5" + "@babel/template" "^7.22.5" + "@babel/traverse" "^7.22.8" + "@babel/types" "^7.22.5" + "@linaria/logger" "^4.5.0" + babel-merge "^3.0.0" + find-up "^5.0.0" + minimatch "^9.0.3" + "@lingui/core@^3.17.2": version "3.17.2" resolved "https://registry.yarnpkg.com/@lingui/core/-/core-3.17.2.tgz#275aa19520477910ddf41a838ef91a8204bea7eb" @@ -3842,11 +4038,32 @@ "@messageformat/parser" "^5.0.0" make-plural "^6.2.2" +"@lingui/core@^4.2.0": + version "4.4.0" + resolved "https://registry.yarnpkg.com/@lingui/core/-/core-4.4.0.tgz#d043c2770673d70bafa6b850cfeec3c859844085" + integrity sha512-0ngEP+g4bt6f3cNqEzkU5796VkEEamxNXF/JD/QV9Ftxp8QBw91WqAoHjNYs3aYZOctCsRBR7FlvRQ6o2fDWDg== + dependencies: + "@babel/runtime" "^7.20.13" + "@lingui/message-utils" "4.4.0" + unraw "^2.0.1" + "@lingui/detect-locale@^3.17.2": version "3.17.2" resolved "https://registry.yarnpkg.com/@lingui/detect-locale/-/detect-locale-3.17.2.tgz#9d7c2839f9ddd061261aaa479b908f06fe7e63f7" integrity sha512-rqyO16lj05WRfBuppo++mPzB1fQBFDhGqEFz5X97CbWXYp6AadOIkrm+pbn114Y2Yumy9QI7Cm4Ptbfk7CXO3Q== +"@lingui/detect-locale@^4.2.0": + version "4.4.0" + resolved "https://registry.yarnpkg.com/@lingui/detect-locale/-/detect-locale-4.4.0.tgz#6101a75833af9a4e27e9c9948238df351d1b324a" + integrity sha512-Mh4oLJ4KHSwcyWw7+bhQ8ErUCZjXDrZyILyHCcgq2S+HE2NG8M8OD/VBFajLW3dEUJPC9sRE8L2XTxYRNKlK6g== + +"@lingui/message-utils@4.4.0": + version "4.4.0" + resolved "https://registry.yarnpkg.com/@lingui/message-utils/-/message-utils-4.4.0.tgz#88a7ff9c0ca10fdce25374a92fc27b932a96778a" + integrity sha512-SScnNuemsyHx2vyLvLsHgmAaCBHwnaAxUg3LkKoulqXe2Po8CmLBh1/28oNQ20ZhjwadUmy0unGalp9qqEBOkw== + dependencies: + "@messageformat/parser" "^5.0.0" + "@loadable/component@^5.15.3": version "5.15.3" resolved "https://registry.npmjs.org/@loadable/component/-/component-5.15.3.tgz" @@ -3930,11 +4147,30 @@ prop-types "^15.8.1" react-is "^18.2.0" +"@mui/base@5.0.0-beta.11": + version "5.0.0-beta.11" + resolved "https://registry.yarnpkg.com/@mui/base/-/base-5.0.0-beta.11.tgz#0124d336f1931c6cd5f0008d015df5bd8fafd3a8" + integrity sha512-FdKZGPd8qmC3ZNke7CNhzcEgToc02M6WYZc9hcBsNQ17bgAd3s9F//1bDDYgMVBYxDM71V0sv/hBHlOY4I1ZVA== + dependencies: + "@babel/runtime" "^7.22.6" + "@emotion/is-prop-valid" "^1.2.1" + "@mui/types" "^7.2.4" + "@mui/utils" "^5.14.5" + "@popperjs/core" "^2.11.8" + clsx "^2.0.0" + prop-types "^15.8.1" + react-is "^18.2.0" + "@mui/core-downloads-tracker@^5.13.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/core-downloads-tracker/-/core-downloads-tracker-5.13.1.tgz#ccfc3fd659c48379cec14cc60fb00bb711777d8f" integrity sha512-qDHtNDO72NcBQMhaWBt9EZMvNiO+OXjPg5Sdk/6LgRDw6Zr3HdEZ5n2FJ/qtYsaT/okGyCuQavQkcZCOCEVf/g== +"@mui/core-downloads-tracker@^5.14.5": + version "5.14.5" + resolved "https://registry.yarnpkg.com/@mui/core-downloads-tracker/-/core-downloads-tracker-5.14.5.tgz#c5854b89d57520c77253a79b20b784d5c2903fb6" + integrity sha512-+wpGH1USwPcKMFPMvXqYPC6fEvhxM3FzxC8lyDiNK/imLyyJ6y2DPb1Oue7OGIKJWBmYBqrWWtfovrxd1aJHTA== + "@mui/material@^5.12.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/material/-/material-5.13.1.tgz#ecb0af2784ee8c552294475c285c8f2e644d8abc" @@ -3953,6 +4189,24 @@ react-is "^18.2.0" react-transition-group "^4.4.5" +"@mui/material@^5.13.2": + version "5.14.5" + resolved "https://registry.yarnpkg.com/@mui/material/-/material-5.14.5.tgz#4610b381fd159cd208c28e1d1f29c303ea24a518" + integrity sha512-4qa4GMfuZH0Ai3mttk5ccXP8a3sf7aPlAJwyMrUSz6h9hPri6BPou94zeu3rENhhmKLby9S/W1y+pmficy8JKA== + dependencies: + "@babel/runtime" "^7.22.6" + "@mui/base" "5.0.0-beta.11" + "@mui/core-downloads-tracker" "^5.14.5" + "@mui/system" "^5.14.5" + "@mui/types" "^7.2.4" + "@mui/utils" "^5.14.5" + "@types/react-transition-group" "^4.4.6" + clsx "^2.0.0" + csstype "^3.1.2" + prop-types "^15.8.1" + react-is "^18.2.0" + react-transition-group "^4.4.5" + "@mui/private-theming@^5.13.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/private-theming/-/private-theming-5.13.1.tgz#c3e9a0b44f9c5a51b92cfcfb660536060cb61ed7" @@ -3962,6 +4216,15 @@ "@mui/utils" "^5.13.1" prop-types "^15.8.1" +"@mui/private-theming@^5.14.5": + version "5.14.5" + resolved "https://registry.yarnpkg.com/@mui/private-theming/-/private-theming-5.14.5.tgz#834e1569c31e2644665f98d902def79014053017" + integrity sha512-cC4C5RrpXpDaaZyH9QwmPhRLgz+f2SYbOty3cPkk4qPSOSfif2ZEcDD9HTENKDDd9deB+xkPKzzZhi8cxIx8Ig== + dependencies: + "@babel/runtime" "^7.22.6" + "@mui/utils" "^5.14.5" + prop-types "^15.8.1" + "@mui/styled-engine@^5.12.3": version "5.12.3" resolved "https://registry.yarnpkg.com/@mui/styled-engine/-/styled-engine-5.12.3.tgz#3307643d52c81947a624cdd0437536cc8109c4f0" @@ -3972,6 +4235,16 @@ csstype "^3.1.2" prop-types "^15.8.1" +"@mui/styled-engine@^5.13.2": + version "5.13.2" + resolved "https://registry.yarnpkg.com/@mui/styled-engine/-/styled-engine-5.13.2.tgz#c87bd61c0ab8086d34828b6defe97c02bcd642ef" + integrity sha512-VCYCU6xVtXOrIN8lcbuPmoG+u7FYuOERG++fpY74hPpEWkyFQG97F+/XfTQVYzlR2m7nPjnwVUgATcTCMEaMvw== + dependencies: + "@babel/runtime" "^7.21.0" + "@emotion/cache" "^11.11.0" + csstype "^3.1.2" + prop-types "^15.8.1" + "@mui/system@^5.13.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/system/-/system-5.13.1.tgz#2296e3269dc6baa5914ea28d0cc9534f7b03a7b5" @@ -3986,6 +4259,20 @@ csstype "^3.1.2" prop-types "^15.8.1" +"@mui/system@^5.14.5": + version "5.14.5" + resolved "https://registry.yarnpkg.com/@mui/system/-/system-5.14.5.tgz#614394c4183d90df82c540e0e736ba72c1f95f8e" + integrity sha512-mextXZHDeGcR7E1kx43TRARrVXy+gI4wzpUgNv7MqZs1dvTVXQGVeAT6ydj9d6FUqHBPMNLGV/21vJOrpqsL+w== + dependencies: + "@babel/runtime" "^7.22.6" + "@mui/private-theming" "^5.14.5" + "@mui/styled-engine" "^5.13.2" + "@mui/types" "^7.2.4" + "@mui/utils" "^5.14.5" + clsx "^2.0.0" + csstype "^3.1.2" + prop-types "^15.8.1" + "@mui/types@^7.2.4": version "7.2.4" resolved "https://registry.yarnpkg.com/@mui/types/-/types-7.2.4.tgz#b6fade19323b754c5c6de679a38f068fd50b9328" @@ -4002,6 +4289,17 @@ prop-types "^15.8.1" react-is "^18.2.0" +"@mui/utils@^5.14.5": + version "5.14.5" + resolved "https://registry.yarnpkg.com/@mui/utils/-/utils-5.14.5.tgz#98fb6060610b793a8478e70ffe5e4ed5bd922dba" + integrity sha512-6Hzw63VR9C5xYv+CbjndoRLU6Gntal8rJ5W+GUzkyHrGWIyYPWZPa6AevnyGioySNETATe1H9oXS8f/7qgIHJA== + dependencies: + "@babel/runtime" "^7.22.6" + "@types/prop-types" "^15.7.5" + "@types/react-is" "^18.2.1" + prop-types "^15.8.1" + react-is "^18.2.0" + "@noble/curves@~0.8.3": version "0.8.3" resolved "https://registry.npmjs.org/@noble/curves/-/curves-0.8.3.tgz" @@ -4195,6 +4493,11 @@ resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.11.7.tgz#ccab5c8f7dc557a52ca3288c10075c9ccd37fff7" integrity sha512-Cr4OjIkipTtcXKjAsm8agyleBuDHvxzeBoa1v543lbv1YaIwQjESsVcmjiWiPEbC1FIeHOG/Op9kdCmAmiS3Kw== +"@popperjs/core@^2.11.8": + version "2.11.8" + resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.11.8.tgz#6b79032e760a0899cd4204710beede972a3a185f" + integrity sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A== + "@popperjs/core@^2.9.2", "@popperjs/core@^2.9.3": version "2.11.6" resolved "https://registry.npmjs.org/@popperjs/core/-/core-2.11.6.tgz" @@ -4219,6 +4522,11 @@ dependencies: "@babel/runtime" "^7.21.0" +"@remirror/core-constants@^2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@remirror/core-constants/-/core-constants-2.0.2.tgz#f05eccdc69e3a65e7d524b52548f567904a11a1a" + integrity sha512-dyHY+sMF0ihPus3O27ODd4+agdHMEmuRdyiZJ2CCWjPV5UFmn17ZbElvk6WOGVE4rdCJKZQCrPV2BcikOMLUGQ== + "@remirror/core-helpers@^2.0.2", "@remirror/core-helpers@^2.0.3": version "2.0.3" resolved "https://registry.yarnpkg.com/@remirror/core-helpers/-/core-helpers-2.0.3.tgz#fa4a0224a612016b9f16052ed0c5d817c69daa39" @@ -4240,6 +4548,25 @@ object.pick "^1.3.0" throttle-debounce "^3.0.1" +"@remirror/core-helpers@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@remirror/core-helpers/-/core-helpers-3.0.0.tgz#3a35c2346bc23ebc3cee585b7840b5567755c5f1" + integrity sha512-tusEgQJIqg4qKj6HSBUFcyRnWnziw3neh4T9wOmsPGHFC3w9kl5KSrDb9UAgE8uX6y32FnS7vJ955mWOl3n50A== + dependencies: + "@remirror/core-constants" "^2.0.2" + "@remirror/types" "^1.0.1" + "@types/object.omit" "^3.0.0" + "@types/object.pick" "^1.3.2" + "@types/throttle-debounce" "^2.1.0" + case-anything "^2.1.13" + dash-get "^1.0.2" + deepmerge "^4.3.1" + fast-deep-equal "^3.1.3" + make-error "^1.3.6" + object.omit "^3.0.0" + object.pick "^1.3.0" + throttle-debounce "^3.0.1" + "@remirror/core-types@^2.0.5": version "2.0.5" resolved "https://registry.yarnpkg.com/@remirror/core-types/-/core-types-2.0.5.tgz#f6a5c56a555b57a9b88b2e8c2b7edba8bcc1042a" @@ -4264,6 +4591,22 @@ min-document "^2.19.0" parenthesis "^3.1.8" +"@remirror/core-utils@^2.0.13": + version "2.0.13" + resolved "https://registry.yarnpkg.com/@remirror/core-utils/-/core-utils-2.0.13.tgz#a46bde5d18ea252664fa76f2428cb3cd9c20cd3d" + integrity sha512-5UggNc6Z2d7M8SVkstsVitID8DAHSKPrqet7Hfn4/dY+p4iMCOdwf9cLqcHMg3467k5/5/RvJPMTr9GQOEx7Hg== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core-constants" "^2.0.2" + "@remirror/core-helpers" "^3.0.0" + "@remirror/core-types" "^2.0.5" + "@remirror/messages" "^2.0.6" + "@types/min-document" "^2.19.0" + css-in-js-utils "^3.1.0" + get-dom-document "^0.1.3" + min-document "^2.19.0" + parenthesis "^3.1.8" + "@remirror/core@^2.0.13", "@remirror/core@^2.0.15", "@remirror/core@^2.0.16": version "2.0.16" resolved "https://registry.yarnpkg.com/@remirror/core/-/core-2.0.16.tgz#11a185f28e6b071c814728b662cd8330e90218b0" @@ -4281,6 +4624,23 @@ nanoevents "^5.1.13" tiny-warning "^1.0.3" +"@remirror/core@^2.0.17", "@remirror/core@^2.0.18", "@remirror/core@^2.0.19": + version "2.0.19" + resolved "https://registry.yarnpkg.com/@remirror/core/-/core-2.0.19.tgz#1ef089497e9404cd008ea6768b6a56223a0736fc" + integrity sha512-TGvDPUdKYqOiDQmt3+58GNBi4PX6QhBhII1qk9btZ/uFvG2/LLHEe+KN/BfBdvykGAu8CK9codLzg8NZd2fDEg== + dependencies: + "@babel/runtime" "^7.22.3" + "@linaria/core" "4.2.10" + "@remirror/core-constants" "^2.0.2" + "@remirror/core-helpers" "^3.0.0" + "@remirror/core-types" "^2.0.5" + "@remirror/core-utils" "^2.0.13" + "@remirror/i18n" "^2.0.5" + "@remirror/icons" "^2.0.3" + "@remirror/messages" "^2.0.6" + nanoevents "^5.1.13" + tiny-warning "^1.0.3" + "@remirror/dom@^2.0.16": version "2.0.16" resolved "https://registry.yarnpkg.com/@remirror/dom/-/dom-2.0.16.tgz#2823b4d92f057213d01cff927b7a0308fdeb2819" @@ -4340,6 +4700,16 @@ "@remirror/messages" "^2.0.3" "@remirror/theme" "^2.0.7" +"@remirror/extension-callout@^2.0.15": + version "2.0.15" + resolved "https://registry.yarnpkg.com/@remirror/extension-callout/-/extension-callout-2.0.15.tgz#1e5b882c66323e6429ac50b2f882bca5a24135a7" + integrity sha512-qn7o1JCy7k0rsybh57EtC8qRoZyEDkncxAtr4Rq1Z2PH/axuOJwwdIgeDadEGITpviRsqrh2L4ddogpDVWVImg== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.17" + "@remirror/messages" "^2.0.5" + "@remirror/theme" "^2.0.8" + "@remirror/extension-code-block@^2.0.14": version "2.0.14" resolved "https://registry.yarnpkg.com/@remirror/extension-code-block/-/extension-code-block-2.0.14.tgz#542ff6d6c76ef61fb7ca8f7aac70efd620523491" @@ -4352,6 +4722,18 @@ "@types/refractor" "^3.0.2" refractor "^3.6.0" +"@remirror/extension-code-block@^2.0.15": + version "2.0.18" + resolved "https://registry.yarnpkg.com/@remirror/extension-code-block/-/extension-code-block-2.0.18.tgz#62140479751018f41e863a937281a7672508ae17" + integrity sha512-Qu51glo0xQMUlSYiFR20HmYEnOJF1OcbZYLTcF32oa8Uq1JWStv1DacQaACUQEhZ6DKgxFZxFBWbPLonzZ1bmw== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.19" + "@remirror/messages" "^2.0.6" + "@remirror/theme" "^2.0.9" + "@types/refractor" "^3.0.2" + refractor "^3.6.0" + "@remirror/extension-code@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-code/-/extension-code-2.0.13.tgz#065cd7fdf02838bdcca1fe997e133ac4691537be" @@ -4388,6 +4770,15 @@ "@remirror/core" "^2.0.13" "@remirror/messages" "^2.0.3" +"@remirror/extension-columns@^2.0.14": + version "2.0.14" + resolved "https://registry.yarnpkg.com/@remirror/extension-columns/-/extension-columns-2.0.14.tgz#0d9da438d2b3dcf278216a49971daf59cd1b52b8" + integrity sha512-0WROpbsdCsuoHFTJB5daAIwjO4tGy9hVWx5kQk4P6bkLOW/qo5hSN6iQLi2mQsAG8pi7tn/NZtMNc1awWrRWhQ== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.17" + "@remirror/messages" "^2.0.5" + "@remirror/extension-diff@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-diff/-/extension-diff-2.0.13.tgz#8540cd935aefc2ba25d9d75702ffd80149962524" @@ -4471,6 +4862,15 @@ "@remirror/core" "^2.0.15" "@remirror/messages" "^2.0.4" +"@remirror/extension-events@^2.1.16": + version "2.1.16" + resolved "https://registry.yarnpkg.com/@remirror/extension-events/-/extension-events-2.1.16.tgz#3e74c35a24c75b69ed6e51be446c5ba4a4427c37" + integrity sha512-QHmYyLqKSaYnxsbZOVI3cx543lrTOzooHdH3FKjh5KBiZ84vmqBdngKvZIMWj6/2iPMIE6y+kp4VOXqm8qrLKA== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.19" + "@remirror/messages" "^2.0.6" + "@remirror/extension-find@^0.1.6": version "0.1.6" resolved "https://registry.yarnpkg.com/@remirror/extension-find/-/extension-find-0.1.6.tgz#efdb5b6ca28aa0e517b031c2f3817425bbdeb6af" @@ -4527,6 +4927,15 @@ "@remirror/core" "^2.0.13" "@remirror/messages" "^2.0.3" +"@remirror/extension-heading@^2.0.14": + version "2.0.14" + resolved "https://registry.yarnpkg.com/@remirror/extension-heading/-/extension-heading-2.0.14.tgz#b9ccca44d9cb2c4cc48f16e7352f6c71d5f65cc1" + integrity sha512-jBBQhLSbEvR/IbSyzBLPN6P69zGoYrW/lxclMPccBxiqr/Rzc1ynJqrbXPQOzj3P43bRLdjXBKiy2VJWzqqO8Q== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.17" + "@remirror/messages" "^2.0.5" + "@remirror/extension-history@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-history/-/extension-history-2.0.13.tgz#1bb1883b598fe5f7b9fd594795025afd76481435" @@ -4612,6 +5021,17 @@ "@remirror/messages" "^2.0.3" "@remirror/theme" "^2.0.7" +"@remirror/extension-mention-atom@^2.0.17": + version "2.0.17" + resolved "https://registry.yarnpkg.com/@remirror/extension-mention-atom/-/extension-mention-atom-2.0.17.tgz#2662c4f770b0ffa5ba0b9f88528004b7146bb471" + integrity sha512-RTHmhCrz8YVcMaifpKH8NB1aNxtgLRBG6ETyZgaPN2l9xcaRvtN5YHUb5myZsw0U4rUBXePI57/91j7QkxXw0Q== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.16" + "@remirror/extension-events" "^2.1.15" + "@remirror/messages" "^2.0.4" + "@remirror/theme" "^2.0.8" + "@remirror/extension-mention@^2.0.15": version "2.0.15" resolved "https://registry.yarnpkg.com/@remirror/extension-mention/-/extension-mention-2.0.15.tgz#1bfe713db515c1ce62720ced36b112875780bf67" @@ -4694,6 +5114,27 @@ "@remirror/theme" "^2.0.7" jsx-dom-cjs "^8.0.5" +"@remirror/extension-react-tables@^2.2.18": + version "2.2.18" + resolved "https://registry.yarnpkg.com/@remirror/extension-react-tables/-/extension-react-tables-2.2.18.tgz#914db5daac8059f3658e39bc9e29758baa5e09d5" + integrity sha512-hv4edyYEBzZ0VhAHbzcfFxbLGbHhw1jGb20jU+qx1zPrgpMakdAl5qESMdy+1yyB7kHPRPGOpzpH62pkvm9HgQ== + dependencies: + "@babel/runtime" "^7.22.3" + "@emotion/css" "^11.11.0" + "@linaria/core" "4.2.10" + "@remirror/core" "^2.0.19" + "@remirror/core-utils" "^2.0.13" + "@remirror/extension-positioner" "^2.1.8" + "@remirror/extension-tables" "^2.3.1" + "@remirror/icons" "^2.0.3" + "@remirror/messages" "^2.0.6" + "@remirror/preset-core" "^2.0.16" + "@remirror/react-components" "^2.1.17" + "@remirror/react-core" "^2.0.21" + "@remirror/react-hooks" "^2.0.25" + "@remirror/theme" "^2.0.9" + jsx-dom-cjs "^8.0.6" + "@remirror/extension-search@^2.0.14": version "2.0.14" resolved "https://registry.yarnpkg.com/@remirror/extension-search/-/extension-search-2.0.14.tgz#a8b5429411041a437e1f92b12cb21e220f15819c" @@ -4750,6 +5191,18 @@ "@remirror/messages" "^2.0.3" "@remirror/theme" "^2.0.7" +"@remirror/extension-tables@^2.3.1": + version "2.3.1" + resolved "https://registry.yarnpkg.com/@remirror/extension-tables/-/extension-tables-2.3.1.tgz#43cbec67366f2810f877c3eb9c69eacfd788b20e" + integrity sha512-SJ/vIrEql+dSC1K2vWr+g9fGONGYMId4D4AZWq0E/ttENZo8jZqEeUAV+Z6NIfPJyScVsXKxolZAVGWfZ4JK6g== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.19" + "@remirror/extension-events" "^2.1.16" + "@remirror/extension-positioner" "^2.1.8" + "@remirror/messages" "^2.0.6" + "@remirror/theme" "^2.0.9" + "@remirror/extension-text-case@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-text-case/-/extension-text-case-2.0.13.tgz#d3bd5923f48befe7fe9f5d275ed7301c3b88e7d3" @@ -4771,6 +5224,18 @@ "@remirror/theme" "^2.0.7" color2k "^2.0.2" +"@remirror/extension-text-color@^2.0.15": + version "2.0.15" + resolved "https://registry.yarnpkg.com/@remirror/extension-text-color/-/extension-text-color-2.0.15.tgz#9aab912e041fe71298313b5aa7389268f3c877b6" + integrity sha512-BCcJ2zyt+pu7WGru9D9SfnodtPz0zxRibVqZOsRvNGJQN29Bvxs89e5tV+xTlAoXUz9gwxJrM6cn03umu18mbA== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.17" + "@remirror/i18n" "^2.0.4" + "@remirror/messages" "^2.0.5" + "@remirror/theme" "^2.0.8" + color2k "^2.0.2" + "@remirror/extension-text-highlight@^2.0.14": version "2.0.14" resolved "https://registry.yarnpkg.com/@remirror/extension-text-highlight/-/extension-text-highlight-2.0.14.tgz#b3c36646fa9a200676a93078f31f57e48dc7dd7d" @@ -4842,6 +5307,17 @@ "@remirror/core-helpers" "^2.0.2" make-plural "^6.2.2" +"@remirror/i18n@^2.0.4", "@remirror/i18n@^2.0.5": + version "2.0.5" + resolved "https://registry.yarnpkg.com/@remirror/i18n/-/i18n-2.0.5.tgz#783e9118a875cd639576af26999d013f3e4523a6" + integrity sha512-oZ2umZav60iu+lBoVZxr7i11yUNRYpczVUXCsClNiHN55PDPMyYwNQ9CaEJdyQCvt0lb5WCmBNpnw1mbLaj7lQ== + dependencies: + "@babel/runtime" "^7.22.3" + "@lingui/core" "^4.2.0" + "@lingui/detect-locale" "^4.2.0" + "@remirror/core-helpers" "^3.0.0" + make-plural "^6.2.2" + "@remirror/icons@^2.0.2": version "2.0.2" resolved "https://registry.yarnpkg.com/@remirror/icons/-/icons-2.0.2.tgz#a1222dd6afbacfd2ac184859ba3590335b357b85" @@ -4850,6 +5326,14 @@ "@babel/runtime" "^7.21.0" "@remirror/core-helpers" "^2.0.2" +"@remirror/icons@^2.0.3": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@remirror/icons/-/icons-2.0.3.tgz#977e93b7f5cc1f0be03c77dc02005e1a70180c1e" + integrity sha512-ruOGU4FT6WJdXsdVwfNOurSaQvnk2Uo4AkMxxyLYkBPowxmR9Xe0lOn7d7UARai0wxmwFgX6IYaMSUVLIaaMCQ== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core-helpers" "^3.0.0" + "@remirror/messages@^2.0.3", "@remirror/messages@^2.0.4": version "2.0.4" resolved "https://registry.yarnpkg.com/@remirror/messages/-/messages-2.0.4.tgz#b577a6d7ff78c39e1e670e685aa13139364e34e0" @@ -4859,6 +5343,15 @@ "@lingui/core" "^3.17.2" "@remirror/core-helpers" "^2.0.2" +"@remirror/messages@^2.0.5", "@remirror/messages@^2.0.6": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@remirror/messages/-/messages-2.0.6.tgz#6b87a69001c691354cef3fa03f43e634edec69ce" + integrity sha512-JVnfuzuul4tcvnjiSM7Jj6iKDOP4hfaw79SciZ7t+cc2+iWyAcDYSrFMDV4Q50T+2IfWTYlWtKGpIhG6sfZaWw== + dependencies: + "@babel/runtime" "^7.22.3" + "@lingui/core" "^4.2.0" + "@remirror/core-helpers" "^3.0.0" + "@remirror/pm@^2.0.5": version "2.0.5" resolved "https://registry.yarnpkg.com/@remirror/pm/-/pm-2.0.5.tgz#021aca4726e41ef3540a3e18d1a689aea90a4c76" @@ -5009,6 +5502,54 @@ multishift "^2.0.8" react-color "^2.19.3" +"@remirror/react-components@^2.1.17": + version "2.1.17" + resolved "https://registry.yarnpkg.com/@remirror/react-components/-/react-components-2.1.17.tgz#e9f68e1302b58c90c2a6671001946054140aa779" + integrity sha512-25BIEfYJO10cxpChyA2fKdmQw5VSDD/Ltcjlxps9DuXTYtjPD1WQnwVdpUyW43W2r7UsvZ2OcVGtQLdJw+RBiw== + dependencies: + "@babel/runtime" "^7.22.3" + "@emotion/react" "^11.11.0" + "@emotion/styled" "^11.11.0" + "@floating-ui/react" "^0.24.3" + "@lingui/core" "^4.2.0" + "@mui/material" "^5.13.2" + "@remirror/core" "^2.0.17" + "@remirror/extension-blockquote" "^2.0.14" + "@remirror/extension-bold" "^2.0.13" + "@remirror/extension-callout" "^2.0.15" + "@remirror/extension-code" "^2.0.13" + "@remirror/extension-code-block" "^2.0.15" + "@remirror/extension-columns" "^2.0.14" + "@remirror/extension-find" "^0.1.6" + "@remirror/extension-font-size" "^2.0.13" + "@remirror/extension-heading" "^2.0.14" + "@remirror/extension-history" "^2.0.13" + "@remirror/extension-horizontal-rule" "^2.0.13" + "@remirror/extension-italic" "^2.0.13" + "@remirror/extension-list" "^2.0.16" + "@remirror/extension-node-formatting" "^2.0.13" + "@remirror/extension-positioner" "^2.1.8" + "@remirror/extension-strike" "^2.0.13" + "@remirror/extension-sub" "^2.0.13" + "@remirror/extension-sup" "^2.0.13" + "@remirror/extension-tables" "^2.2.10" + "@remirror/extension-text-color" "^2.0.15" + "@remirror/extension-underline" "^2.0.13" + "@remirror/extension-whitespace" "^2.0.13" + "@remirror/i18n" "^2.0.4" + "@remirror/icons" "^2.0.2" + "@remirror/messages" "^2.0.5" + "@remirror/react-core" "^2.0.20" + "@remirror/react-hooks" "^2.0.25" + "@remirror/react-utils" "^2.0.5" + "@remirror/theme" "^2.0.8" + "@seznam/compose-react-refs" "^1.0.6" + "@types/react-color" "^3.0.6" + create-context-state "^2.0.2" + match-sorter "^6.3.1" + multishift "^2.0.8" + react-color "^2.19.3" + "@remirror/react-core@^2.0.17": version "2.0.17" resolved "https://registry.yarnpkg.com/@remirror/react-core/-/react-core-2.0.17.tgz#5604f327e0335bdd3678dd67016e90cb24eed865" @@ -5030,6 +5571,27 @@ resize-observer-polyfill "^1.5.1" tiny-warning "^1.0.3" +"@remirror/react-core@^2.0.20", "@remirror/react-core@^2.0.21": + version "2.0.21" + resolved "https://registry.yarnpkg.com/@remirror/react-core/-/react-core-2.0.21.tgz#11ab05e476bf53849aa28680321957c1154b791f" + integrity sha512-8c7+e0Y0LmwErqR4nPdUs73WLFKGqVs/DuE9q0wxSfXWbArAFVAAZB4PWrpcbYMbb0jSvG7rKDgnFN8NM/1f5A== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.18" + "@remirror/extension-positioner" "^2.1.8" + "@remirror/extension-react-component" "^2.0.13" + "@remirror/i18n" "^2.0.4" + "@remirror/preset-core" "^2.0.16" + "@remirror/preset-react" "^2.0.14" + "@remirror/react-renderer" "^2.0.13" + "@remirror/react-utils" "^2.0.5" + "@remirror/theme" "^2.0.8" + "@seznam/compose-react-refs" "^1.0.6" + create-context-state "^2.0.2" + fast-deep-equal "^3.1.3" + resize-observer-polyfill "^1.5.1" + tiny-warning "^1.0.3" + "@remirror/react-editors@^1.0.33": version "1.0.33" resolved "https://registry.yarnpkg.com/@remirror/react-editors/-/react-editors-1.0.33.tgz#119717d958ef61125cf4440a5c952082de9abc56" @@ -5068,6 +5630,26 @@ use-isomorphic-layout-effect "^1.1.2" use-previous "^1.2.0" +"@remirror/react-hooks@^2.0.25": + version "2.0.25" + resolved "https://registry.yarnpkg.com/@remirror/react-hooks/-/react-hooks-2.0.25.tgz#ff459872ba4222ac248edb083e9ffa1fd6ed4a44" + integrity sha512-/qByk9+OSDVBFD5N3CalsXNvbHF0GEfOEhNstsBGvg0xxf0NsuvPj1rYcXnVHk+9mgx2TMh+EiOhfURRR2A9vg== + dependencies: + "@babel/runtime" "^7.22.3" + "@remirror/core" "^2.0.17" + "@remirror/extension-emoji" "^2.0.17" + "@remirror/extension-events" "^2.1.15" + "@remirror/extension-history" "^2.0.13" + "@remirror/extension-mention" "^2.0.15" + "@remirror/extension-mention-atom" "^2.0.17" + "@remirror/extension-positioner" "^2.1.8" + "@remirror/i18n" "^2.0.4" + "@remirror/react-core" "^2.0.20" + "@remirror/react-utils" "^2.0.5" + multishift "^2.0.8" + use-isomorphic-layout-effect "^1.1.2" + use-previous "^1.2.0" + "@remirror/react-renderer@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/react-renderer/-/react-renderer-2.0.13.tgz#2af76c30629c1c9782c7118984e103ae3a8baf2b" @@ -5122,6 +5704,17 @@ color2k "^2.0.2" csstype "^3.1.2" +"@remirror/theme@^2.0.9": + version "2.0.9" + resolved "https://registry.yarnpkg.com/@remirror/theme/-/theme-2.0.9.tgz#0ae990448e90cfead0a6ff7d36b414165a9c663d" + integrity sha512-MI6j7C9KImVyfSBh9GR/WQCuLQKXRKQkE0HsS8Sc/BC8a/0n4QTt7dAg5/a/+MbakyymNaGlibCdts8URgGStg== + dependencies: + "@babel/runtime" "^7.22.3" + "@linaria/core" "4.2.10" + "@remirror/core-types" "^2.0.5" + color2k "^2.0.2" + csstype "^3.1.2" + "@remirror/types@^1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@remirror/types/-/types-1.0.1.tgz#768502497a0fbbc23338a1586b893f729310cf70" @@ -5742,6 +6335,13 @@ dependencies: "@types/react" "*" +"@types/react-is@^18.2.1": + version "18.2.1" + resolved "https://registry.yarnpkg.com/@types/react-is/-/react-is-18.2.1.tgz#61d01c2a6fc089a53520c0b66996d458fdc46863" + integrity sha512-wyUkmaaSZEzFZivD8F2ftSyAfk6L+DfFliVj/mYdOXbVjRcS87fQJLTnhk6dRZPuJjI+9g6RZJO4PNCngUrmyw== + dependencies: + "@types/react" "*" + "@types/react-transition-group@^4.4.0": version "4.4.5" resolved "https://registry.npmjs.org/@types/react-transition-group/-/react-transition-group-4.4.5.tgz" @@ -6287,7 +6887,7 @@ argparse@^2.0.1: resolved "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== -aria-hidden@^1.2.2: +aria-hidden@^1.2.2, aria-hidden@^1.2.3: version "1.2.3" resolved "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.3.tgz" integrity sha512-xcLxITLe2HYa1cnYnwCjkOO1PqUHQpozB8x9AR0OgWN2woOBi5kSDVxKfd0b7sb1hw5qFeJhXm9H1nu3xSfLeQ== @@ -6848,6 +7448,11 @@ case-anything@^2.1.10: resolved "https://registry.yarnpkg.com/case-anything/-/case-anything-2.1.11.tgz#39a00ff733f26e48729f5c6c7f23763ac8fa0467" integrity sha512-uzKDXzdM/x914cepWPzElU3y50NRKYhjkO4ittOHLq+rF6M0AgRLF/+yPR1tvwLNAh8WHEPTfhuciZGPfX+oyg== +case-anything@^2.1.13: + version "2.1.13" + resolved "https://registry.yarnpkg.com/case-anything/-/case-anything-2.1.13.tgz#0cdc16278cb29a7fcdeb072400da3f342ba329e9" + integrity sha512-zlOQ80VrQ2Ue+ymH5OuM/DlDq64mEm+B9UTdHULv5osUMD6HalNTblf2b1u/m6QecjsnOkBpqVZ+XPwIVsy7Ng== + caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" @@ -7170,6 +7775,11 @@ clsx@^1.2.1: resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.2.1.tgz#0ddc4a20a549b59c93a4116bb26f5294ca17dc12" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== +clsx@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/clsx/-/clsx-2.0.0.tgz#12658f3fd98fafe62075595a5c30e43d18f3d00b" + integrity sha512-rQ1+kcj+ttHG0MKVGBUXwayCCF1oh39BF5COIpRzuCEv8Mwjv0XucrI2ExNTOn9IlLifGClWQcU9BrZORvtw6Q== + codemirror@^5.65.12: version "5.65.13" resolved "https://registry.yarnpkg.com/codemirror/-/codemirror-5.65.13.tgz#c098a6f409db8b5a7c5722788bd9fa3bb2367f2e" @@ -7584,6 +8194,13 @@ create-context-state@^2.0.1: dependencies: "@babel/runtime" "^7.21.0" +create-context-state@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/create-context-state/-/create-context-state-2.0.2.tgz#3a811c8e5bb082b35601747e501d1ec970ee4f7f" + integrity sha512-WIz5i5QYt0xvlpbpSnhl4RY7WfcPy8gWtqzE6xtr2hfhuR3WJTsa5V4Y7jgPt+Knp5r0yKbKK0myK59HW2+HHw== + dependencies: + "@babel/runtime" "^7.21.5" + create-emotion@^10.0.27: version "10.0.27" resolved "https://registry.npmjs.org/create-emotion/-/create-emotion-10.0.27.tgz" @@ -10518,6 +11135,13 @@ jsx-dom-cjs@^8.0.5: dependencies: csstype "^3.1.1" +jsx-dom-cjs@^8.0.6: + version "8.0.7" + resolved "https://registry.yarnpkg.com/jsx-dom-cjs/-/jsx-dom-cjs-8.0.7.tgz#098c54680ebf5bb6f6d12cdea5cde3799c172212" + integrity sha512-dQWnuQ+bTm7o72ZlJU4glzeMX8KLxx5U+ZwmEAzVP1+roL7BSM0MrkWdHjdsuNgmxobZCJ+qgiot9EgbJPOoEg== + dependencies: + csstype "^3.1.2" + keyv@^3.0.0: version "3.1.0" resolved "https://registry.npmjs.org/keyv/-/keyv-3.1.0.tgz" @@ -11042,6 +11666,13 @@ minimatch@^5.0.1: dependencies: brace-expansion "^2.0.1" +minimatch@^9.0.3: + version "9.0.3" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" + integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== + dependencies: + brace-expansion "^2.0.1" + minimist-options@4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/minimist-options/-/minimist-options-4.1.0.tgz" @@ -12637,6 +13268,11 @@ regenerator-runtime@^0.13.11, regenerator-runtime@^0.13.7: resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz" integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== +regenerator-runtime@^0.14.0: + version "0.14.0" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz#5e19d68eb12d486f797e15a3c6a918f7cec5eb45" + integrity sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA== + regenerator-transform@^0.15.1: version "0.15.1" resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.15.1.tgz#f6c4e99fc1b4591f780db2586328e4d9a9d8dc56" @@ -13668,6 +14304,11 @@ symbol-tree@^3.2.4: resolved "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz" integrity sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw== +tabbable@^6.0.1: + version "6.2.0" + resolved "https://registry.yarnpkg.com/tabbable/-/tabbable-6.2.0.tgz#732fb62bc0175cfcec257330be187dcfba1f3b97" + integrity sha512-Cat63mxsVJlzYvN51JmVXIgNoUokrIaT2zLclCXjRd8boZ0004U4KCs/sToJ75C6sdlByWxpYnb5Boif1VSFew== + temp-dir@^2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/temp-dir/-/temp-dir-2.0.0.tgz" @@ -14180,6 +14821,11 @@ unpipe@1.0.0, unpipe@~1.0.0: resolved "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz" integrity sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ== +unraw@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/unraw/-/unraw-2.0.1.tgz#7b51dcdfb1e43d59d5e52cdb44d349d029edbaba" + integrity sha512-tdOvLfRzHolwYcHS6HIX860MkK9LQ4+oLuNwFYL7bpgTEO64PZrcQxkisgwJYCfF8sKiWLwwu1c83DvMkbefIQ== + untildify@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/untildify/-/untildify-4.0.0.tgz#2bc947b953652487e4600949fb091e3ae8cd919b" From fbd1df95180b1270da114aa20d8ab373ce424f23 Mon Sep 17 00:00:00 2001 From: sajald77 Date: Wed, 23 Aug 2023 16:16:52 -0400 Subject: [PATCH 08/54] fix: in progress --- src/forms/markdown/MarkdownField.tsx | 21 ++++++++++--------- .../markdown/helpers/PreviewRenderer.tsx | 5 ++++- src/forms/markdown/helpers/StyleProvider.tsx | 10 ++++++--- 3 files changed, 22 insertions(+), 14 deletions(-) diff --git a/src/forms/markdown/MarkdownField.tsx b/src/forms/markdown/MarkdownField.tsx index 348c1fdd9..c6a12e48d 100644 --- a/src/forms/markdown/MarkdownField.tsx +++ b/src/forms/markdown/MarkdownField.tsx @@ -1,6 +1,11 @@ import { Box, Button, HStack, Text } from '@chakra-ui/react' // import { ReactComponentExtension } from '@remirror/extension-react-component' -import { EditorComponent, Remirror, useRemirror } from '@remirror/react' +import { + EditorComponent, + Remirror, + TableComponents, + useRemirror, +} from '@remirror/react' import { ForwardedRef, useCallback } from 'react' import { Control } from 'react-hook-form' import { useTranslation } from 'react-i18next' @@ -94,11 +99,6 @@ export const MarkdownField = ({ }), new MarkdownExtension({ copyAsMarkdown: true, - htmlToMarkdown(html) { - console.log('checking html', html) - return `${html}` - }, - // htmlToMarkdown: (html) => turndownService.turndown(html), }), new BoldExtension(), new UnderlineExtension(), @@ -142,9 +142,9 @@ export const MarkdownField = ({ react: { nodeViewComponents: { image: imageHandler, - paragraph: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( - - ), + // paragraph: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( + // + // ), bulletList: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( ), @@ -152,7 +152,7 @@ export const MarkdownField = ({ ), table: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( - + ), }, }, @@ -221,6 +221,7 @@ export const MarkdownField = ({ )} + diff --git a/src/forms/markdown/helpers/PreviewRenderer.tsx b/src/forms/markdown/helpers/PreviewRenderer.tsx index 7c63c17df..98d809517 100644 --- a/src/forms/markdown/helpers/PreviewRenderer.tsx +++ b/src/forms/markdown/helpers/PreviewRenderer.tsx @@ -10,13 +10,16 @@ export const PreviewRenderer = ({ manager: RemirrorManager content?: RemirrorContentType }) => { + const newContent = content?.toString().replaceAll(/\n/g, '\\n') + console.log('checking content', content) + console.log('checking newContent', newContent) return ( Date: Wed, 23 Aug 2023 22:46:09 -0400 Subject: [PATCH 09/54] fix: finalize table feature for story markdown editor and viewer --- package.json | 2 - .../components/TableCellMenuComponent.tsx | 69 ++ src/forms/components/TableExtension.tsx | 1 - src/forms/markdown/MarkdownField.tsx | 13 +- .../markdown/helpers/PreviewRenderer.tsx | 38 +- src/forms/markdown/helpers/StyleProvider.tsx | 7 + src/forms/markdown/helpers/typeMaps.tsx | 40 +- src/translations/English.json | 8 +- yarn.lock | 648 +----------------- 9 files changed, 161 insertions(+), 665 deletions(-) create mode 100644 src/forms/components/TableCellMenuComponent.tsx delete mode 100644 src/forms/components/TableExtension.tsx diff --git a/package.json b/package.json index cb931d831..49e29f55c 100644 --- a/package.json +++ b/package.json @@ -33,8 +33,6 @@ "@loadable/component": "^5.15.3", "@react-hookz/web": "^23.0.0", "@remirror/extension-node-formatting": "^2.0.13", - "@remirror/extension-react-component": "^2.0.13", - "@remirror/extension-react-tables": "^2.2.18", "@remirror/pm": "^2.0.5", "@remirror/react": "^2.0.28", "@remirror/react-components": "^2.1.12", diff --git a/src/forms/components/TableCellMenuComponent.tsx b/src/forms/components/TableCellMenuComponent.tsx new file mode 100644 index 000000000..47fcd767e --- /dev/null +++ b/src/forms/components/TableCellMenuComponent.tsx @@ -0,0 +1,69 @@ +import { ChevronDownIcon } from '@chakra-ui/icons' +import { + IconButton, + Menu, + MenuButton, + MenuItem, + MenuItemProps, + MenuList, + VStack, +} from '@chakra-ui/react' +import { useCommands } from '@remirror/react' +import { useTranslation } from 'react-i18next' + +export const TableCellMenuComponent = () => { + const { t } = useTranslation() + const commands = useCommands() + + const ModifiedMenuItem = (props: MenuItemProps) => { + return ( + + ) + } + + return ( +

+ } + border="1px solid" + borderRadius="4px" + borderColor="neutral.200" + _hover={{ color: 'primary.400', borderColor: 'primary.400' }} + /> + + commands.addTableRowBefore()}> + {t('Add row above')} + + commands.addTableRowAfter()}> + {t('Add row below')} + + commands.addTableColumnBefore()}> + {t('Add column left')} + + commands.addTableColumnAfter()}> + {t('Add column right')} + + commands.deleteTableColumn()}> + {t('Remove column')} + + commands.deleteTableRow()}> + {t('Remove row')} + + + + ) +} diff --git a/src/forms/components/TableExtension.tsx b/src/forms/components/TableExtension.tsx deleted file mode 100644 index 403e5a1c4..000000000 --- a/src/forms/components/TableExtension.tsx +++ /dev/null @@ -1 +0,0 @@ -import { TableExtension } from '@remirror/extension-react-tables' diff --git a/src/forms/markdown/MarkdownField.tsx b/src/forms/markdown/MarkdownField.tsx index c6a12e48d..67891b79a 100644 --- a/src/forms/markdown/MarkdownField.tsx +++ b/src/forms/markdown/MarkdownField.tsx @@ -1,5 +1,4 @@ import { Box, Button, HStack, Text } from '@chakra-ui/react' -// import { ReactComponentExtension } from '@remirror/extension-react-component' import { EditorComponent, Remirror, @@ -36,6 +35,7 @@ import TurndownService from 'turndown' import { useSignedUpload } from '../../hooks' import { useMobileMode } from '../../utils' import { ReactHookTextArea } from '../components/ReactHookTextArea' +import { TableCellMenuComponent } from '../components/TableCellMenuComponent' import { PreviewRenderer } from './helpers/PreviewRenderer' import { SaveModule } from './helpers/SaveModule' import { StyleProvider } from './helpers/StyleProvider' @@ -113,7 +113,6 @@ export const MarkdownField = ({ new TrailingNodeExtension(), new BulletListExtension(), new TextExtension(), - new ImageExtension({ uploadHandler(files) { return files.map( @@ -142,18 +141,12 @@ export const MarkdownField = ({ react: { nodeViewComponents: { image: imageHandler, - // paragraph: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( - // - // ), bulletList: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( ), orderedList: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( ), - table: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( - - ), }, }, }) @@ -221,7 +214,9 @@ export const MarkdownField = ({ )} - + diff --git a/src/forms/markdown/helpers/PreviewRenderer.tsx b/src/forms/markdown/helpers/PreviewRenderer.tsx index 98d809517..0d910915e 100644 --- a/src/forms/markdown/helpers/PreviewRenderer.tsx +++ b/src/forms/markdown/helpers/PreviewRenderer.tsx @@ -10,19 +10,49 @@ export const PreviewRenderer = ({ manager: RemirrorManager content?: RemirrorContentType }) => { - const newContent = content?.toString().replaceAll(/\n/g, '\\n') - console.log('checking content', content) - console.log('checking newContent', newContent) + // const newContent = formatString(content?.toString() || '') + return ( ) } + +// export const matchMarkDownSpecialKeysAtLineEnd = +// /\n(?!.*(\*|_|#|-|\||`|[0-9]+(\.|\))))/g + +// const formatString = (value: string): string => { +// const adjustForLineChange = value +// ? value.replaceAll(matchMarkDownSpecialKeysAtLineEnd, '\\\n') +// : '' + +// const adjustedForMultiParagrah = adjustForLineChange.replaceAll( +// /\n\n/g, +// '\n\\\n', +// ) + +// const finalValue = getRidOfEndSlash(adjustedForMultiParagrah) + +// console.log('before content', JSON.stringify(value)) +// console.log('medium content', JSON.stringify(adjustForLineChange)) +// console.log('after content', JSON.stringify(adjustedForMultiParagrah)) + +// return finalValue +// } + +// const getRidOfEndSlash = (value: string): string => { +// if (value[value.length - 2] === '\\') { +// const newValue = value.slice(0, value.length - 2) +// return getRidOfEndSlash(newValue) +// } + +// return value +// } diff --git a/src/forms/markdown/helpers/StyleProvider.tsx b/src/forms/markdown/helpers/StyleProvider.tsx index d15bda214..f6c4f1c10 100644 --- a/src/forms/markdown/helpers/StyleProvider.tsx +++ b/src/forms/markdown/helpers/StyleProvider.tsx @@ -5,12 +5,19 @@ import { useMemo } from 'react' import { RemirrorThemeType } from 'remirror' import { useCustomTheme } from '../../../utils' +import { tableCellStyles } from './typeMaps' const Container = styled(Box, { baseStyle: { '& p, & iframe, & h1, & h2, & h3, & h4, & h5': { mt: 4, }, + '& table': { + '& p': { + margin: '0px', + }, + ...tableCellStyles, + }, '& iframe': { minHeight: '28em', }, diff --git a/src/forms/markdown/helpers/typeMaps.tsx b/src/forms/markdown/helpers/typeMaps.tsx index 5e37d942b..a6efdda89 100644 --- a/src/forms/markdown/helpers/typeMaps.tsx +++ b/src/forms/markdown/helpers/typeMaps.tsx @@ -40,6 +40,44 @@ export const listItemHandler = ({ children }: ListProps) => { return {children} } +export const tableCellStyles = { + '& th, & td': { + padding: '3px 8px', + border: '1px solid', + borderColor: 'neutral.200', + }, +} + +export const tableHandler = (props: any) => { + const hasHeader = + props?.children[0]?.props?.json?.content[0]?.type === 'tableHeaderCell' + + return ( + + {hasHeader && {props.children[0]}} + + { + + {props.children.map((child: any, index: number) => { + if (hasHeader && index === 0) { + return null + } + + return child + })} + + } +
+ ) +} + export const typeMap = { blockquote: 'blockquote', bulletList: unorderedListHandler, @@ -55,7 +93,7 @@ export const typeMap = { paragraph: 'p', orderedList: OrderedList, text: TextHandler, - table: Table, + table: tableHandler, tableHeader: Thead, tableHeaderCell: Th, tbody: Tbody, diff --git a/src/translations/English.json b/src/translations/English.json index 1c62d1c2d..baedb431a 100644 --- a/src/translations/English.json +++ b/src/translations/English.json @@ -655,5 +655,11 @@ "There's a new version of Geyser!":"There's a new version of Geyser!", "Restart the app to load the new version":"Restart the app to load the new version", "Not now":"Not now", - "Restart app":"Restart app" + "Restart app":"Restart app", + "Add row above":"Add row above", + "Add row below":"Add row below", + "Add column left":"Add column left", + "Add column right":"Add column right", + "Remove column":"Remove column", + "Remove row":"Remove row" } diff --git a/yarn.lock b/yarn.lock index 310946572..1346cab13 100644 --- a/yarn.lock +++ b/yarn.lock @@ -87,14 +87,6 @@ dependencies: "@babel/highlight" "^7.18.6" -"@babel/code-frame@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.22.10.tgz#1c20e612b768fefa75f6e90d6ecb86329247f0a3" - integrity sha512-/KKIMG4UEL35WmI9OlvMhurwtytjvXoFcGNrOvyG9zIzA8YmPjVtIZUf7b05+TPO7G7/GEmLHDaoCgACHl9hhA== - dependencies: - "@babel/highlight" "^7.22.10" - chalk "^2.4.2" - "@babel/code-frame@^7.22.5": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.22.5.tgz#234d98e1551960604f1246e6475891a570ad5658" @@ -180,27 +172,6 @@ json5 "^2.2.2" semver "^6.3.0" -"@babel/core@^7.22.9": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.22.10.tgz#aad442c7bcd1582252cb4576747ace35bc122f35" - integrity sha512-fTmqbbUBAwCcre6zPzNngvsI0aNrPZe77AeqvDxWM9Nm+04RrJ3CAmGHA9f7lJQY6ZMhRztNemy4uslDxTX4Qw== - dependencies: - "@ampproject/remapping" "^2.2.0" - "@babel/code-frame" "^7.22.10" - "@babel/generator" "^7.22.10" - "@babel/helper-compilation-targets" "^7.22.10" - "@babel/helper-module-transforms" "^7.22.9" - "@babel/helpers" "^7.22.10" - "@babel/parser" "^7.22.10" - "@babel/template" "^7.22.5" - "@babel/traverse" "^7.22.10" - "@babel/types" "^7.22.10" - convert-source-map "^1.7.0" - debug "^4.1.0" - gensync "^1.0.0-beta.2" - json5 "^2.2.2" - semver "^6.3.1" - "@babel/generator@^7.14.0", "@babel/generator@^7.18.13", "@babel/generator@^7.21.3": version "7.21.3" resolved "https://registry.npmjs.org/@babel/generator/-/generator-7.21.3.tgz" @@ -221,16 +192,6 @@ "@jridgewell/trace-mapping" "^0.3.17" jsesc "^2.5.1" -"@babel/generator@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.22.10.tgz#c92254361f398e160645ac58831069707382b722" - integrity sha512-79KIf7YiWjjdZ81JnLujDRApWtl7BxTqWD88+FFdQEIOG8LJ0etDOM7CXuIgGJa55sGOwZVwuEsaLEm0PJ5/+A== - dependencies: - "@babel/types" "^7.22.10" - "@jridgewell/gen-mapping" "^0.3.2" - "@jridgewell/trace-mapping" "^0.3.17" - jsesc "^2.5.1" - "@babel/generator@^7.22.7", "@babel/generator@^7.22.9": version "7.22.9" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.22.9.tgz#572ecfa7a31002fa1de2a9d91621fd895da8493d" @@ -284,17 +245,6 @@ lru-cache "^5.1.1" semver "^6.3.0" -"@babel/helper-compilation-targets@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.10.tgz#01d648bbc25dd88f513d862ee0df27b7d4e67024" - integrity sha512-JMSwHD4J7SLod0idLq5PKgI+6g/hLD/iuWBq08ZX49xE14VpVEojJ5rHWptpirV2j020MvypRLAXAO50igCJ5Q== - dependencies: - "@babel/compat-data" "^7.22.9" - "@babel/helper-validator-option" "^7.22.5" - browserslist "^4.21.9" - lru-cache "^5.1.1" - semver "^6.3.1" - "@babel/helper-compilation-targets@^7.22.5", "@babel/helper-compilation-targets@^7.22.6", "@babel/helper-compilation-targets@^7.22.9": version "7.22.9" resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.9.tgz#f9d0a7aaaa7cd32a3f31c9316a69f5a9bcacb892" @@ -644,15 +594,6 @@ "@babel/traverse" "^7.21.5" "@babel/types" "^7.21.5" -"@babel/helpers@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.22.10.tgz#ae6005c539dfbcb5cd71fb51bfc8a52ba63bc37a" - integrity sha512-a41J4NW8HyZa1I1vAndrraTlPZ/eZoga2ZgS7fEr0tZJGVU4xqdE80CEm0CcNjha5EZ8fTBYLKHF0kqDUuAwQw== - dependencies: - "@babel/template" "^7.22.5" - "@babel/traverse" "^7.22.10" - "@babel/types" "^7.22.10" - "@babel/helpers@^7.22.6": version "7.22.6" resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.22.6.tgz#8e61d3395a4f0c5a8060f309fb008200969b5ecd" @@ -671,15 +612,6 @@ chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/highlight@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.22.10.tgz#02a3f6d8c1cb4521b2fd0ab0da8f4739936137d7" - integrity sha512-78aUtVcT7MUscr0K5mIEnkwxPE0MaxkR5RxRwuHaQ+JuU5AmTPhY+do2mdzVTnIJJpyBglql2pehuBIWHug+WQ== - dependencies: - "@babel/helper-validator-identifier" "^7.22.5" - chalk "^2.4.2" - js-tokens "^4.0.0" - "@babel/highlight@^7.22.5": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.22.5.tgz#aa6c05c5407a67ebce408162b7ede789b4d22031" @@ -699,11 +631,6 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.21.8.tgz#642af7d0333eab9c0ad70b14ac5e76dbde7bfdf8" integrity sha512-6zavDGdzG3gUqAdWvlLFfk+36RilI+Pwyuuh7HItyeScCWP3k6i8vKclAQ0bM/0y/Kz/xiwvxhMv9MgTJP5gmA== -"@babel/parser@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.22.10.tgz#e37634f9a12a1716136c44624ef54283cabd3f55" - integrity sha512-lNbdGsQb9ekfsnjFGhEiF4hfFqGgfOP3H3d27re3n+CGhNuTSUEQdfWk556sTLNTloczcdM5TYF2LhzmDQKyvQ== - "@babel/parser@^7.22.5", "@babel/parser@^7.22.7": version "7.22.7" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.22.7.tgz#df8cf085ce92ddbdbf668a7f186ce848c9036cae" @@ -1614,13 +1541,6 @@ dependencies: regenerator-runtime "^0.13.11" -"@babel/runtime@^7.21.5", "@babel/runtime@^7.22.3", "@babel/runtime@^7.22.6": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.10.tgz#ae3e9631fd947cb7e3610d3e9d8fef5f76696682" - integrity sha512-21t/fkKLMZI4pqP2wlmsQAWnYW1PDyKyyUV4vCi+B25ydmdaYTKXPwCj0BzSUnZf4seIiYvSA3jcZ3gdsMFkLQ== - dependencies: - regenerator-runtime "^0.14.0" - "@babel/template@^7.18.10", "@babel/template@^7.20.7": version "7.20.7" resolved "https://registry.npmjs.org/@babel/template/-/template-7.20.7.tgz" @@ -1671,22 +1591,6 @@ debug "^4.1.0" globals "^11.1.0" -"@babel/traverse@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.22.10.tgz#20252acb240e746d27c2e82b4484f199cf8141aa" - integrity sha512-Q/urqV4pRByiNNpb/f5OSv28ZlGJiFiiTh+GAHktbIrkPhPbl90+uW6SmpoLyZqutrg9AEaEf3Q/ZBRHBXgxig== - dependencies: - "@babel/code-frame" "^7.22.10" - "@babel/generator" "^7.22.10" - "@babel/helper-environment-visitor" "^7.22.5" - "@babel/helper-function-name" "^7.22.5" - "@babel/helper-hoist-variables" "^7.22.5" - "@babel/helper-split-export-declaration" "^7.22.6" - "@babel/parser" "^7.22.10" - "@babel/types" "^7.22.10" - debug "^4.1.0" - globals "^11.1.0" - "@babel/traverse@^7.22.6", "@babel/traverse@^7.22.8": version "7.22.8" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.22.8.tgz#4d4451d31bc34efeae01eac222b514a77aa4000e" @@ -1721,15 +1625,6 @@ "@babel/helper-validator-identifier" "^7.19.1" to-fast-properties "^2.0.0" -"@babel/types@^7.22.10": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.22.10.tgz#4a9e76446048f2c66982d1a989dd12b8a2d2dc03" - integrity sha512-obaoigiLrlDZ7TUQln/8m4mSqIW2QFeOrCQc9r+xsaHGNoplVNYlRVpsfE8Vj35GEm2ZH4ZhrNYogs/3fj85kg== - dependencies: - "@babel/helper-string-parser" "^7.22.5" - "@babel/helper-validator-identifier" "^7.22.5" - to-fast-properties "^2.0.0" - "@babel/types@^7.22.5", "@babel/types@^7.4.4": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.22.5.tgz#cd93eeaab025880a3a47ec881f4b096a5b786fbe" @@ -2847,17 +2742,6 @@ "@emotion/sheet" "^1.2.2" "@emotion/utils" "^1.2.1" -"@emotion/css@^11.11.0": - version "11.11.2" - resolved "https://registry.yarnpkg.com/@emotion/css/-/css-11.11.2.tgz#e5fa081d0c6e335352e1bc2b05953b61832dca5a" - integrity sha512-VJxe1ucoMYMS7DkiMdC2T7PWNbrEI0a39YRiyDvK2qq4lXwjRbVP/z4lpG+odCsRzadlR+1ywwrTzhdm5HNdew== - dependencies: - "@emotion/babel-plugin" "^11.11.0" - "@emotion/cache" "^11.11.0" - "@emotion/serialize" "^1.1.2" - "@emotion/sheet" "^1.2.2" - "@emotion/utils" "^1.2.1" - "@emotion/hash@0.8.0": version "0.8.0" resolved "https://registry.npmjs.org/@emotion/hash/-/hash-0.8.0.tgz" @@ -3240,13 +3124,6 @@ resolved "https://registry.npmjs.org/@floating-ui/core/-/core-1.2.4.tgz" integrity sha512-SQOeVbMwb1di+mVWWJLpsUTToKfqVNioXys011beCAhyOIFtS+GQoW4EQSneuxzmQKddExDwQ+X0hLl4lJJaSQ== -"@floating-ui/core@^1.4.1": - version "1.4.1" - resolved "https://registry.yarnpkg.com/@floating-ui/core/-/core-1.4.1.tgz#0d633f4b76052668afb932492ac452f7ebe97f17" - integrity sha512-jk3WqquEJRlcyu7997NtR5PibI+y5bi+LS3hPmguVClypenMsCY3CBa3LAQnozRCtCrYWSEtAdiskpamuJRFOQ== - dependencies: - "@floating-ui/utils" "^0.1.1" - "@floating-ui/dom@^1.0.1": version "1.2.5" resolved "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.2.5.tgz" @@ -3254,35 +3131,6 @@ dependencies: "@floating-ui/core" "^1.2.4" -"@floating-ui/dom@^1.3.0": - version "1.5.1" - resolved "https://registry.yarnpkg.com/@floating-ui/dom/-/dom-1.5.1.tgz#88b70defd002fe851f17b4a25efb2d3c04d7a8d7" - integrity sha512-KwvVcPSXg6mQygvA1TjbN/gh///36kKtllIF8SUm0qpFj8+rvYrpvlYdL1JoA71SHpDqgSSdGOSoQ0Mp3uY5aw== - dependencies: - "@floating-ui/core" "^1.4.1" - "@floating-ui/utils" "^0.1.1" - -"@floating-ui/react-dom@^2.0.1": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@floating-ui/react-dom/-/react-dom-2.0.1.tgz#7972a4fc488a8c746cded3cfe603b6057c308a91" - integrity sha512-rZtAmSht4Lry6gdhAJDrCp/6rKN7++JnL1/Anbr/DdeyYXQPxvg/ivrbYvJulbRf4vL8b212suwMM2lxbv+RQA== - dependencies: - "@floating-ui/dom" "^1.3.0" - -"@floating-ui/react@^0.24.3": - version "0.24.8" - resolved "https://registry.yarnpkg.com/@floating-ui/react/-/react-0.24.8.tgz#e079e2836990be3fce9665ab509360a5447251a1" - integrity sha512-AuYeDoaR8jtUlUXtZ1IJ/6jtBkGnSpJXbGNzokBL87VDJ8opMq1Bgrc0szhK482ReQY6KZsMoZCVSb4xwalkBA== - dependencies: - "@floating-ui/react-dom" "^2.0.1" - aria-hidden "^1.2.3" - tabbable "^6.0.1" - -"@floating-ui/utils@^0.1.1": - version "0.1.1" - resolved "https://registry.yarnpkg.com/@floating-ui/utils/-/utils-0.1.1.tgz#1a5b1959a528e374e8037c4396c3e825d6cf4a83" - integrity sha512-m0G6wlnhm/AX0H12IOWtK8gASEMffnX08RtKkCgTdHb9JpHKGloI7icFfLg9ZmQeavcvR0PKmzxClyuFPSjKWw== - "@giphy/js-analytics@*": version "4.3.2" resolved "https://registry.yarnpkg.com/@giphy/js-analytics/-/js-analytics-4.3.2.tgz#9710c7eb6e401571d4219a870cb6b0d35df61cdc" @@ -3945,15 +3793,6 @@ "@jridgewell/resolve-uri" "3.1.0" "@jridgewell/sourcemap-codec" "1.4.14" -"@linaria/core@4.2.10": - version "4.2.10" - resolved "https://registry.yarnpkg.com/@linaria/core/-/core-4.2.10.tgz#3f8d45b20205c167d326d558ee9a926039483767" - integrity sha512-S1W01W7L4SQnGpWzp8awyCpPIYUOEJ+OLjjXqKpIXOU+ozPwBt86Mjjdas9aZccVhNBWDja74cMCUAVp8yUpDQ== - dependencies: - "@linaria/logger" "^4.0.0" - "@linaria/tags" "^4.3.5" - "@linaria/utils" "^4.3.4" - "@linaria/core@4.2.9": version "4.2.9" resolved "https://registry.yarnpkg.com/@linaria/core/-/core-4.2.9.tgz#4917bde18d064a29cff4fd86aa99621f953a2a2c" @@ -3971,14 +3810,6 @@ debug "^4.1.1" picocolors "^1.0.0" -"@linaria/logger@^4.5.0": - version "4.5.0" - resolved "https://registry.yarnpkg.com/@linaria/logger/-/logger-4.5.0.tgz#e5de815ffe7806822f47a559a512b98f66acea13" - integrity sha512-XdQLk242Cpcsc9a3Cz1ktOE5ysTo2TpxdeFQEPwMm8Z/+F/S6ZxBDdHYJL09srXWz3hkJr3oS2FPuMZNH1HIxw== - dependencies: - debug "^4.1.1" - picocolors "^1.0.0" - "@linaria/tags@^4.3.4": version "4.3.5" resolved "https://registry.yarnpkg.com/@linaria/tags/-/tags-4.3.5.tgz#bf2e070d11179addf2f27a66cd29d8192e71ca89" @@ -3988,15 +3819,6 @@ "@linaria/logger" "^4.0.0" "@linaria/utils" "^4.3.4" -"@linaria/tags@^4.3.5": - version "4.5.4" - resolved "https://registry.yarnpkg.com/@linaria/tags/-/tags-4.5.4.tgz#071ab024227433f783ea2d948904fc164731a912" - integrity sha512-HPxLB6HlJWLi6o8+8lTLegOmDnbMbuzEE+zzunaPZEGSoIIYx8HAv5VbY/sG/zNyxDElk6laiAwEVWN8h5/zxg== - dependencies: - "@babel/generator" "^7.22.9" - "@linaria/logger" "^4.5.0" - "@linaria/utils" "^4.5.3" - "@linaria/utils@^4.3.3", "@linaria/utils@^4.3.4": version "4.3.4" resolved "https://registry.yarnpkg.com/@linaria/utils/-/utils-4.3.4.tgz#860db9131e498b62510e49dc6fd4a8f0ed44bf4d" @@ -4011,24 +3833,6 @@ "@linaria/logger" "^4.0.0" babel-merge "^3.0.0" -"@linaria/utils@^4.5.3": - version "4.5.3" - resolved "https://registry.yarnpkg.com/@linaria/utils/-/utils-4.5.3.tgz#cf54f4096927ea347d01e814c1fb7aca7cf4063a" - integrity sha512-tSpxA3Zn0DKJ2n/YBnYAgiDY+MNvkmzAHrD8R9PKrpGaZ+wz1jQEmE1vGn1cqh8dJyWK0NzPAA8sf1cqa+RmAg== - dependencies: - "@babel/core" "^7.22.9" - "@babel/generator" "^7.22.9" - "@babel/plugin-proposal-export-namespace-from" "^7.18.9" - "@babel/plugin-syntax-dynamic-import" "^7.8.3" - "@babel/plugin-transform-modules-commonjs" "^7.22.5" - "@babel/template" "^7.22.5" - "@babel/traverse" "^7.22.8" - "@babel/types" "^7.22.5" - "@linaria/logger" "^4.5.0" - babel-merge "^3.0.0" - find-up "^5.0.0" - minimatch "^9.0.3" - "@lingui/core@^3.17.2": version "3.17.2" resolved "https://registry.yarnpkg.com/@lingui/core/-/core-3.17.2.tgz#275aa19520477910ddf41a838ef91a8204bea7eb" @@ -4038,32 +3842,11 @@ "@messageformat/parser" "^5.0.0" make-plural "^6.2.2" -"@lingui/core@^4.2.0": - version "4.4.0" - resolved "https://registry.yarnpkg.com/@lingui/core/-/core-4.4.0.tgz#d043c2770673d70bafa6b850cfeec3c859844085" - integrity sha512-0ngEP+g4bt6f3cNqEzkU5796VkEEamxNXF/JD/QV9Ftxp8QBw91WqAoHjNYs3aYZOctCsRBR7FlvRQ6o2fDWDg== - dependencies: - "@babel/runtime" "^7.20.13" - "@lingui/message-utils" "4.4.0" - unraw "^2.0.1" - "@lingui/detect-locale@^3.17.2": version "3.17.2" resolved "https://registry.yarnpkg.com/@lingui/detect-locale/-/detect-locale-3.17.2.tgz#9d7c2839f9ddd061261aaa479b908f06fe7e63f7" integrity sha512-rqyO16lj05WRfBuppo++mPzB1fQBFDhGqEFz5X97CbWXYp6AadOIkrm+pbn114Y2Yumy9QI7Cm4Ptbfk7CXO3Q== -"@lingui/detect-locale@^4.2.0": - version "4.4.0" - resolved "https://registry.yarnpkg.com/@lingui/detect-locale/-/detect-locale-4.4.0.tgz#6101a75833af9a4e27e9c9948238df351d1b324a" - integrity sha512-Mh4oLJ4KHSwcyWw7+bhQ8ErUCZjXDrZyILyHCcgq2S+HE2NG8M8OD/VBFajLW3dEUJPC9sRE8L2XTxYRNKlK6g== - -"@lingui/message-utils@4.4.0": - version "4.4.0" - resolved "https://registry.yarnpkg.com/@lingui/message-utils/-/message-utils-4.4.0.tgz#88a7ff9c0ca10fdce25374a92fc27b932a96778a" - integrity sha512-SScnNuemsyHx2vyLvLsHgmAaCBHwnaAxUg3LkKoulqXe2Po8CmLBh1/28oNQ20ZhjwadUmy0unGalp9qqEBOkw== - dependencies: - "@messageformat/parser" "^5.0.0" - "@loadable/component@^5.15.3": version "5.15.3" resolved "https://registry.npmjs.org/@loadable/component/-/component-5.15.3.tgz" @@ -4147,30 +3930,11 @@ prop-types "^15.8.1" react-is "^18.2.0" -"@mui/base@5.0.0-beta.11": - version "5.0.0-beta.11" - resolved "https://registry.yarnpkg.com/@mui/base/-/base-5.0.0-beta.11.tgz#0124d336f1931c6cd5f0008d015df5bd8fafd3a8" - integrity sha512-FdKZGPd8qmC3ZNke7CNhzcEgToc02M6WYZc9hcBsNQ17bgAd3s9F//1bDDYgMVBYxDM71V0sv/hBHlOY4I1ZVA== - dependencies: - "@babel/runtime" "^7.22.6" - "@emotion/is-prop-valid" "^1.2.1" - "@mui/types" "^7.2.4" - "@mui/utils" "^5.14.5" - "@popperjs/core" "^2.11.8" - clsx "^2.0.0" - prop-types "^15.8.1" - react-is "^18.2.0" - "@mui/core-downloads-tracker@^5.13.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/core-downloads-tracker/-/core-downloads-tracker-5.13.1.tgz#ccfc3fd659c48379cec14cc60fb00bb711777d8f" integrity sha512-qDHtNDO72NcBQMhaWBt9EZMvNiO+OXjPg5Sdk/6LgRDw6Zr3HdEZ5n2FJ/qtYsaT/okGyCuQavQkcZCOCEVf/g== -"@mui/core-downloads-tracker@^5.14.5": - version "5.14.5" - resolved "https://registry.yarnpkg.com/@mui/core-downloads-tracker/-/core-downloads-tracker-5.14.5.tgz#c5854b89d57520c77253a79b20b784d5c2903fb6" - integrity sha512-+wpGH1USwPcKMFPMvXqYPC6fEvhxM3FzxC8lyDiNK/imLyyJ6y2DPb1Oue7OGIKJWBmYBqrWWtfovrxd1aJHTA== - "@mui/material@^5.12.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/material/-/material-5.13.1.tgz#ecb0af2784ee8c552294475c285c8f2e644d8abc" @@ -4189,24 +3953,6 @@ react-is "^18.2.0" react-transition-group "^4.4.5" -"@mui/material@^5.13.2": - version "5.14.5" - resolved "https://registry.yarnpkg.com/@mui/material/-/material-5.14.5.tgz#4610b381fd159cd208c28e1d1f29c303ea24a518" - integrity sha512-4qa4GMfuZH0Ai3mttk5ccXP8a3sf7aPlAJwyMrUSz6h9hPri6BPou94zeu3rENhhmKLby9S/W1y+pmficy8JKA== - dependencies: - "@babel/runtime" "^7.22.6" - "@mui/base" "5.0.0-beta.11" - "@mui/core-downloads-tracker" "^5.14.5" - "@mui/system" "^5.14.5" - "@mui/types" "^7.2.4" - "@mui/utils" "^5.14.5" - "@types/react-transition-group" "^4.4.6" - clsx "^2.0.0" - csstype "^3.1.2" - prop-types "^15.8.1" - react-is "^18.2.0" - react-transition-group "^4.4.5" - "@mui/private-theming@^5.13.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/private-theming/-/private-theming-5.13.1.tgz#c3e9a0b44f9c5a51b92cfcfb660536060cb61ed7" @@ -4216,15 +3962,6 @@ "@mui/utils" "^5.13.1" prop-types "^15.8.1" -"@mui/private-theming@^5.14.5": - version "5.14.5" - resolved "https://registry.yarnpkg.com/@mui/private-theming/-/private-theming-5.14.5.tgz#834e1569c31e2644665f98d902def79014053017" - integrity sha512-cC4C5RrpXpDaaZyH9QwmPhRLgz+f2SYbOty3cPkk4qPSOSfif2ZEcDD9HTENKDDd9deB+xkPKzzZhi8cxIx8Ig== - dependencies: - "@babel/runtime" "^7.22.6" - "@mui/utils" "^5.14.5" - prop-types "^15.8.1" - "@mui/styled-engine@^5.12.3": version "5.12.3" resolved "https://registry.yarnpkg.com/@mui/styled-engine/-/styled-engine-5.12.3.tgz#3307643d52c81947a624cdd0437536cc8109c4f0" @@ -4235,16 +3972,6 @@ csstype "^3.1.2" prop-types "^15.8.1" -"@mui/styled-engine@^5.13.2": - version "5.13.2" - resolved "https://registry.yarnpkg.com/@mui/styled-engine/-/styled-engine-5.13.2.tgz#c87bd61c0ab8086d34828b6defe97c02bcd642ef" - integrity sha512-VCYCU6xVtXOrIN8lcbuPmoG+u7FYuOERG++fpY74hPpEWkyFQG97F+/XfTQVYzlR2m7nPjnwVUgATcTCMEaMvw== - dependencies: - "@babel/runtime" "^7.21.0" - "@emotion/cache" "^11.11.0" - csstype "^3.1.2" - prop-types "^15.8.1" - "@mui/system@^5.13.1": version "5.13.1" resolved "https://registry.yarnpkg.com/@mui/system/-/system-5.13.1.tgz#2296e3269dc6baa5914ea28d0cc9534f7b03a7b5" @@ -4259,20 +3986,6 @@ csstype "^3.1.2" prop-types "^15.8.1" -"@mui/system@^5.14.5": - version "5.14.5" - resolved "https://registry.yarnpkg.com/@mui/system/-/system-5.14.5.tgz#614394c4183d90df82c540e0e736ba72c1f95f8e" - integrity sha512-mextXZHDeGcR7E1kx43TRARrVXy+gI4wzpUgNv7MqZs1dvTVXQGVeAT6ydj9d6FUqHBPMNLGV/21vJOrpqsL+w== - dependencies: - "@babel/runtime" "^7.22.6" - "@mui/private-theming" "^5.14.5" - "@mui/styled-engine" "^5.13.2" - "@mui/types" "^7.2.4" - "@mui/utils" "^5.14.5" - clsx "^2.0.0" - csstype "^3.1.2" - prop-types "^15.8.1" - "@mui/types@^7.2.4": version "7.2.4" resolved "https://registry.yarnpkg.com/@mui/types/-/types-7.2.4.tgz#b6fade19323b754c5c6de679a38f068fd50b9328" @@ -4289,17 +4002,6 @@ prop-types "^15.8.1" react-is "^18.2.0" -"@mui/utils@^5.14.5": - version "5.14.5" - resolved "https://registry.yarnpkg.com/@mui/utils/-/utils-5.14.5.tgz#98fb6060610b793a8478e70ffe5e4ed5bd922dba" - integrity sha512-6Hzw63VR9C5xYv+CbjndoRLU6Gntal8rJ5W+GUzkyHrGWIyYPWZPa6AevnyGioySNETATe1H9oXS8f/7qgIHJA== - dependencies: - "@babel/runtime" "^7.22.6" - "@types/prop-types" "^15.7.5" - "@types/react-is" "^18.2.1" - prop-types "^15.8.1" - react-is "^18.2.0" - "@noble/curves@~0.8.3": version "0.8.3" resolved "https://registry.npmjs.org/@noble/curves/-/curves-0.8.3.tgz" @@ -4493,11 +4195,6 @@ resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.11.7.tgz#ccab5c8f7dc557a52ca3288c10075c9ccd37fff7" integrity sha512-Cr4OjIkipTtcXKjAsm8agyleBuDHvxzeBoa1v543lbv1YaIwQjESsVcmjiWiPEbC1FIeHOG/Op9kdCmAmiS3Kw== -"@popperjs/core@^2.11.8": - version "2.11.8" - resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.11.8.tgz#6b79032e760a0899cd4204710beede972a3a185f" - integrity sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A== - "@popperjs/core@^2.9.2", "@popperjs/core@^2.9.3": version "2.11.6" resolved "https://registry.npmjs.org/@popperjs/core/-/core-2.11.6.tgz" @@ -4522,11 +4219,6 @@ dependencies: "@babel/runtime" "^7.21.0" -"@remirror/core-constants@^2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@remirror/core-constants/-/core-constants-2.0.2.tgz#f05eccdc69e3a65e7d524b52548f567904a11a1a" - integrity sha512-dyHY+sMF0ihPus3O27ODd4+agdHMEmuRdyiZJ2CCWjPV5UFmn17ZbElvk6WOGVE4rdCJKZQCrPV2BcikOMLUGQ== - "@remirror/core-helpers@^2.0.2", "@remirror/core-helpers@^2.0.3": version "2.0.3" resolved "https://registry.yarnpkg.com/@remirror/core-helpers/-/core-helpers-2.0.3.tgz#fa4a0224a612016b9f16052ed0c5d817c69daa39" @@ -4548,25 +4240,6 @@ object.pick "^1.3.0" throttle-debounce "^3.0.1" -"@remirror/core-helpers@^3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@remirror/core-helpers/-/core-helpers-3.0.0.tgz#3a35c2346bc23ebc3cee585b7840b5567755c5f1" - integrity sha512-tusEgQJIqg4qKj6HSBUFcyRnWnziw3neh4T9wOmsPGHFC3w9kl5KSrDb9UAgE8uX6y32FnS7vJ955mWOl3n50A== - dependencies: - "@remirror/core-constants" "^2.0.2" - "@remirror/types" "^1.0.1" - "@types/object.omit" "^3.0.0" - "@types/object.pick" "^1.3.2" - "@types/throttle-debounce" "^2.1.0" - case-anything "^2.1.13" - dash-get "^1.0.2" - deepmerge "^4.3.1" - fast-deep-equal "^3.1.3" - make-error "^1.3.6" - object.omit "^3.0.0" - object.pick "^1.3.0" - throttle-debounce "^3.0.1" - "@remirror/core-types@^2.0.5": version "2.0.5" resolved "https://registry.yarnpkg.com/@remirror/core-types/-/core-types-2.0.5.tgz#f6a5c56a555b57a9b88b2e8c2b7edba8bcc1042a" @@ -4591,22 +4264,6 @@ min-document "^2.19.0" parenthesis "^3.1.8" -"@remirror/core-utils@^2.0.13": - version "2.0.13" - resolved "https://registry.yarnpkg.com/@remirror/core-utils/-/core-utils-2.0.13.tgz#a46bde5d18ea252664fa76f2428cb3cd9c20cd3d" - integrity sha512-5UggNc6Z2d7M8SVkstsVitID8DAHSKPrqet7Hfn4/dY+p4iMCOdwf9cLqcHMg3467k5/5/RvJPMTr9GQOEx7Hg== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core-constants" "^2.0.2" - "@remirror/core-helpers" "^3.0.0" - "@remirror/core-types" "^2.0.5" - "@remirror/messages" "^2.0.6" - "@types/min-document" "^2.19.0" - css-in-js-utils "^3.1.0" - get-dom-document "^0.1.3" - min-document "^2.19.0" - parenthesis "^3.1.8" - "@remirror/core@^2.0.13", "@remirror/core@^2.0.15", "@remirror/core@^2.0.16": version "2.0.16" resolved "https://registry.yarnpkg.com/@remirror/core/-/core-2.0.16.tgz#11a185f28e6b071c814728b662cd8330e90218b0" @@ -4624,23 +4281,6 @@ nanoevents "^5.1.13" tiny-warning "^1.0.3" -"@remirror/core@^2.0.17", "@remirror/core@^2.0.18", "@remirror/core@^2.0.19": - version "2.0.19" - resolved "https://registry.yarnpkg.com/@remirror/core/-/core-2.0.19.tgz#1ef089497e9404cd008ea6768b6a56223a0736fc" - integrity sha512-TGvDPUdKYqOiDQmt3+58GNBi4PX6QhBhII1qk9btZ/uFvG2/LLHEe+KN/BfBdvykGAu8CK9codLzg8NZd2fDEg== - dependencies: - "@babel/runtime" "^7.22.3" - "@linaria/core" "4.2.10" - "@remirror/core-constants" "^2.0.2" - "@remirror/core-helpers" "^3.0.0" - "@remirror/core-types" "^2.0.5" - "@remirror/core-utils" "^2.0.13" - "@remirror/i18n" "^2.0.5" - "@remirror/icons" "^2.0.3" - "@remirror/messages" "^2.0.6" - nanoevents "^5.1.13" - tiny-warning "^1.0.3" - "@remirror/dom@^2.0.16": version "2.0.16" resolved "https://registry.yarnpkg.com/@remirror/dom/-/dom-2.0.16.tgz#2823b4d92f057213d01cff927b7a0308fdeb2819" @@ -4700,16 +4340,6 @@ "@remirror/messages" "^2.0.3" "@remirror/theme" "^2.0.7" -"@remirror/extension-callout@^2.0.15": - version "2.0.15" - resolved "https://registry.yarnpkg.com/@remirror/extension-callout/-/extension-callout-2.0.15.tgz#1e5b882c66323e6429ac50b2f882bca5a24135a7" - integrity sha512-qn7o1JCy7k0rsybh57EtC8qRoZyEDkncxAtr4Rq1Z2PH/axuOJwwdIgeDadEGITpviRsqrh2L4ddogpDVWVImg== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.17" - "@remirror/messages" "^2.0.5" - "@remirror/theme" "^2.0.8" - "@remirror/extension-code-block@^2.0.14": version "2.0.14" resolved "https://registry.yarnpkg.com/@remirror/extension-code-block/-/extension-code-block-2.0.14.tgz#542ff6d6c76ef61fb7ca8f7aac70efd620523491" @@ -4722,18 +4352,6 @@ "@types/refractor" "^3.0.2" refractor "^3.6.0" -"@remirror/extension-code-block@^2.0.15": - version "2.0.18" - resolved "https://registry.yarnpkg.com/@remirror/extension-code-block/-/extension-code-block-2.0.18.tgz#62140479751018f41e863a937281a7672508ae17" - integrity sha512-Qu51glo0xQMUlSYiFR20HmYEnOJF1OcbZYLTcF32oa8Uq1JWStv1DacQaACUQEhZ6DKgxFZxFBWbPLonzZ1bmw== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.19" - "@remirror/messages" "^2.0.6" - "@remirror/theme" "^2.0.9" - "@types/refractor" "^3.0.2" - refractor "^3.6.0" - "@remirror/extension-code@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-code/-/extension-code-2.0.13.tgz#065cd7fdf02838bdcca1fe997e133ac4691537be" @@ -4770,15 +4388,6 @@ "@remirror/core" "^2.0.13" "@remirror/messages" "^2.0.3" -"@remirror/extension-columns@^2.0.14": - version "2.0.14" - resolved "https://registry.yarnpkg.com/@remirror/extension-columns/-/extension-columns-2.0.14.tgz#0d9da438d2b3dcf278216a49971daf59cd1b52b8" - integrity sha512-0WROpbsdCsuoHFTJB5daAIwjO4tGy9hVWx5kQk4P6bkLOW/qo5hSN6iQLi2mQsAG8pi7tn/NZtMNc1awWrRWhQ== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.17" - "@remirror/messages" "^2.0.5" - "@remirror/extension-diff@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-diff/-/extension-diff-2.0.13.tgz#8540cd935aefc2ba25d9d75702ffd80149962524" @@ -4862,15 +4471,6 @@ "@remirror/core" "^2.0.15" "@remirror/messages" "^2.0.4" -"@remirror/extension-events@^2.1.16": - version "2.1.16" - resolved "https://registry.yarnpkg.com/@remirror/extension-events/-/extension-events-2.1.16.tgz#3e74c35a24c75b69ed6e51be446c5ba4a4427c37" - integrity sha512-QHmYyLqKSaYnxsbZOVI3cx543lrTOzooHdH3FKjh5KBiZ84vmqBdngKvZIMWj6/2iPMIE6y+kp4VOXqm8qrLKA== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.19" - "@remirror/messages" "^2.0.6" - "@remirror/extension-find@^0.1.6": version "0.1.6" resolved "https://registry.yarnpkg.com/@remirror/extension-find/-/extension-find-0.1.6.tgz#efdb5b6ca28aa0e517b031c2f3817425bbdeb6af" @@ -4927,15 +4527,6 @@ "@remirror/core" "^2.0.13" "@remirror/messages" "^2.0.3" -"@remirror/extension-heading@^2.0.14": - version "2.0.14" - resolved "https://registry.yarnpkg.com/@remirror/extension-heading/-/extension-heading-2.0.14.tgz#b9ccca44d9cb2c4cc48f16e7352f6c71d5f65cc1" - integrity sha512-jBBQhLSbEvR/IbSyzBLPN6P69zGoYrW/lxclMPccBxiqr/Rzc1ynJqrbXPQOzj3P43bRLdjXBKiy2VJWzqqO8Q== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.17" - "@remirror/messages" "^2.0.5" - "@remirror/extension-history@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-history/-/extension-history-2.0.13.tgz#1bb1883b598fe5f7b9fd594795025afd76481435" @@ -5021,17 +4612,6 @@ "@remirror/messages" "^2.0.3" "@remirror/theme" "^2.0.7" -"@remirror/extension-mention-atom@^2.0.17": - version "2.0.17" - resolved "https://registry.yarnpkg.com/@remirror/extension-mention-atom/-/extension-mention-atom-2.0.17.tgz#2662c4f770b0ffa5ba0b9f88528004b7146bb471" - integrity sha512-RTHmhCrz8YVcMaifpKH8NB1aNxtgLRBG6ETyZgaPN2l9xcaRvtN5YHUb5myZsw0U4rUBXePI57/91j7QkxXw0Q== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.16" - "@remirror/extension-events" "^2.1.15" - "@remirror/messages" "^2.0.4" - "@remirror/theme" "^2.0.8" - "@remirror/extension-mention@^2.0.15": version "2.0.15" resolved "https://registry.yarnpkg.com/@remirror/extension-mention/-/extension-mention-2.0.15.tgz#1bfe713db515c1ce62720ced36b112875780bf67" @@ -5114,27 +4694,6 @@ "@remirror/theme" "^2.0.7" jsx-dom-cjs "^8.0.5" -"@remirror/extension-react-tables@^2.2.18": - version "2.2.18" - resolved "https://registry.yarnpkg.com/@remirror/extension-react-tables/-/extension-react-tables-2.2.18.tgz#914db5daac8059f3658e39bc9e29758baa5e09d5" - integrity sha512-hv4edyYEBzZ0VhAHbzcfFxbLGbHhw1jGb20jU+qx1zPrgpMakdAl5qESMdy+1yyB7kHPRPGOpzpH62pkvm9HgQ== - dependencies: - "@babel/runtime" "^7.22.3" - "@emotion/css" "^11.11.0" - "@linaria/core" "4.2.10" - "@remirror/core" "^2.0.19" - "@remirror/core-utils" "^2.0.13" - "@remirror/extension-positioner" "^2.1.8" - "@remirror/extension-tables" "^2.3.1" - "@remirror/icons" "^2.0.3" - "@remirror/messages" "^2.0.6" - "@remirror/preset-core" "^2.0.16" - "@remirror/react-components" "^2.1.17" - "@remirror/react-core" "^2.0.21" - "@remirror/react-hooks" "^2.0.25" - "@remirror/theme" "^2.0.9" - jsx-dom-cjs "^8.0.6" - "@remirror/extension-search@^2.0.14": version "2.0.14" resolved "https://registry.yarnpkg.com/@remirror/extension-search/-/extension-search-2.0.14.tgz#a8b5429411041a437e1f92b12cb21e220f15819c" @@ -5191,18 +4750,6 @@ "@remirror/messages" "^2.0.3" "@remirror/theme" "^2.0.7" -"@remirror/extension-tables@^2.3.1": - version "2.3.1" - resolved "https://registry.yarnpkg.com/@remirror/extension-tables/-/extension-tables-2.3.1.tgz#43cbec67366f2810f877c3eb9c69eacfd788b20e" - integrity sha512-SJ/vIrEql+dSC1K2vWr+g9fGONGYMId4D4AZWq0E/ttENZo8jZqEeUAV+Z6NIfPJyScVsXKxolZAVGWfZ4JK6g== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.19" - "@remirror/extension-events" "^2.1.16" - "@remirror/extension-positioner" "^2.1.8" - "@remirror/messages" "^2.0.6" - "@remirror/theme" "^2.0.9" - "@remirror/extension-text-case@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/extension-text-case/-/extension-text-case-2.0.13.tgz#d3bd5923f48befe7fe9f5d275ed7301c3b88e7d3" @@ -5224,18 +4771,6 @@ "@remirror/theme" "^2.0.7" color2k "^2.0.2" -"@remirror/extension-text-color@^2.0.15": - version "2.0.15" - resolved "https://registry.yarnpkg.com/@remirror/extension-text-color/-/extension-text-color-2.0.15.tgz#9aab912e041fe71298313b5aa7389268f3c877b6" - integrity sha512-BCcJ2zyt+pu7WGru9D9SfnodtPz0zxRibVqZOsRvNGJQN29Bvxs89e5tV+xTlAoXUz9gwxJrM6cn03umu18mbA== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.17" - "@remirror/i18n" "^2.0.4" - "@remirror/messages" "^2.0.5" - "@remirror/theme" "^2.0.8" - color2k "^2.0.2" - "@remirror/extension-text-highlight@^2.0.14": version "2.0.14" resolved "https://registry.yarnpkg.com/@remirror/extension-text-highlight/-/extension-text-highlight-2.0.14.tgz#b3c36646fa9a200676a93078f31f57e48dc7dd7d" @@ -5307,17 +4842,6 @@ "@remirror/core-helpers" "^2.0.2" make-plural "^6.2.2" -"@remirror/i18n@^2.0.4", "@remirror/i18n@^2.0.5": - version "2.0.5" - resolved "https://registry.yarnpkg.com/@remirror/i18n/-/i18n-2.0.5.tgz#783e9118a875cd639576af26999d013f3e4523a6" - integrity sha512-oZ2umZav60iu+lBoVZxr7i11yUNRYpczVUXCsClNiHN55PDPMyYwNQ9CaEJdyQCvt0lb5WCmBNpnw1mbLaj7lQ== - dependencies: - "@babel/runtime" "^7.22.3" - "@lingui/core" "^4.2.0" - "@lingui/detect-locale" "^4.2.0" - "@remirror/core-helpers" "^3.0.0" - make-plural "^6.2.2" - "@remirror/icons@^2.0.2": version "2.0.2" resolved "https://registry.yarnpkg.com/@remirror/icons/-/icons-2.0.2.tgz#a1222dd6afbacfd2ac184859ba3590335b357b85" @@ -5326,14 +4850,6 @@ "@babel/runtime" "^7.21.0" "@remirror/core-helpers" "^2.0.2" -"@remirror/icons@^2.0.3": - version "2.0.3" - resolved "https://registry.yarnpkg.com/@remirror/icons/-/icons-2.0.3.tgz#977e93b7f5cc1f0be03c77dc02005e1a70180c1e" - integrity sha512-ruOGU4FT6WJdXsdVwfNOurSaQvnk2Uo4AkMxxyLYkBPowxmR9Xe0lOn7d7UARai0wxmwFgX6IYaMSUVLIaaMCQ== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core-helpers" "^3.0.0" - "@remirror/messages@^2.0.3", "@remirror/messages@^2.0.4": version "2.0.4" resolved "https://registry.yarnpkg.com/@remirror/messages/-/messages-2.0.4.tgz#b577a6d7ff78c39e1e670e685aa13139364e34e0" @@ -5343,15 +4859,6 @@ "@lingui/core" "^3.17.2" "@remirror/core-helpers" "^2.0.2" -"@remirror/messages@^2.0.5", "@remirror/messages@^2.0.6": - version "2.0.6" - resolved "https://registry.yarnpkg.com/@remirror/messages/-/messages-2.0.6.tgz#6b87a69001c691354cef3fa03f43e634edec69ce" - integrity sha512-JVnfuzuul4tcvnjiSM7Jj6iKDOP4hfaw79SciZ7t+cc2+iWyAcDYSrFMDV4Q50T+2IfWTYlWtKGpIhG6sfZaWw== - dependencies: - "@babel/runtime" "^7.22.3" - "@lingui/core" "^4.2.0" - "@remirror/core-helpers" "^3.0.0" - "@remirror/pm@^2.0.5": version "2.0.5" resolved "https://registry.yarnpkg.com/@remirror/pm/-/pm-2.0.5.tgz#021aca4726e41ef3540a3e18d1a689aea90a4c76" @@ -5502,54 +5009,6 @@ multishift "^2.0.8" react-color "^2.19.3" -"@remirror/react-components@^2.1.17": - version "2.1.17" - resolved "https://registry.yarnpkg.com/@remirror/react-components/-/react-components-2.1.17.tgz#e9f68e1302b58c90c2a6671001946054140aa779" - integrity sha512-25BIEfYJO10cxpChyA2fKdmQw5VSDD/Ltcjlxps9DuXTYtjPD1WQnwVdpUyW43W2r7UsvZ2OcVGtQLdJw+RBiw== - dependencies: - "@babel/runtime" "^7.22.3" - "@emotion/react" "^11.11.0" - "@emotion/styled" "^11.11.0" - "@floating-ui/react" "^0.24.3" - "@lingui/core" "^4.2.0" - "@mui/material" "^5.13.2" - "@remirror/core" "^2.0.17" - "@remirror/extension-blockquote" "^2.0.14" - "@remirror/extension-bold" "^2.0.13" - "@remirror/extension-callout" "^2.0.15" - "@remirror/extension-code" "^2.0.13" - "@remirror/extension-code-block" "^2.0.15" - "@remirror/extension-columns" "^2.0.14" - "@remirror/extension-find" "^0.1.6" - "@remirror/extension-font-size" "^2.0.13" - "@remirror/extension-heading" "^2.0.14" - "@remirror/extension-history" "^2.0.13" - "@remirror/extension-horizontal-rule" "^2.0.13" - "@remirror/extension-italic" "^2.0.13" - "@remirror/extension-list" "^2.0.16" - "@remirror/extension-node-formatting" "^2.0.13" - "@remirror/extension-positioner" "^2.1.8" - "@remirror/extension-strike" "^2.0.13" - "@remirror/extension-sub" "^2.0.13" - "@remirror/extension-sup" "^2.0.13" - "@remirror/extension-tables" "^2.2.10" - "@remirror/extension-text-color" "^2.0.15" - "@remirror/extension-underline" "^2.0.13" - "@remirror/extension-whitespace" "^2.0.13" - "@remirror/i18n" "^2.0.4" - "@remirror/icons" "^2.0.2" - "@remirror/messages" "^2.0.5" - "@remirror/react-core" "^2.0.20" - "@remirror/react-hooks" "^2.0.25" - "@remirror/react-utils" "^2.0.5" - "@remirror/theme" "^2.0.8" - "@seznam/compose-react-refs" "^1.0.6" - "@types/react-color" "^3.0.6" - create-context-state "^2.0.2" - match-sorter "^6.3.1" - multishift "^2.0.8" - react-color "^2.19.3" - "@remirror/react-core@^2.0.17": version "2.0.17" resolved "https://registry.yarnpkg.com/@remirror/react-core/-/react-core-2.0.17.tgz#5604f327e0335bdd3678dd67016e90cb24eed865" @@ -5571,27 +5030,6 @@ resize-observer-polyfill "^1.5.1" tiny-warning "^1.0.3" -"@remirror/react-core@^2.0.20", "@remirror/react-core@^2.0.21": - version "2.0.21" - resolved "https://registry.yarnpkg.com/@remirror/react-core/-/react-core-2.0.21.tgz#11ab05e476bf53849aa28680321957c1154b791f" - integrity sha512-8c7+e0Y0LmwErqR4nPdUs73WLFKGqVs/DuE9q0wxSfXWbArAFVAAZB4PWrpcbYMbb0jSvG7rKDgnFN8NM/1f5A== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.18" - "@remirror/extension-positioner" "^2.1.8" - "@remirror/extension-react-component" "^2.0.13" - "@remirror/i18n" "^2.0.4" - "@remirror/preset-core" "^2.0.16" - "@remirror/preset-react" "^2.0.14" - "@remirror/react-renderer" "^2.0.13" - "@remirror/react-utils" "^2.0.5" - "@remirror/theme" "^2.0.8" - "@seznam/compose-react-refs" "^1.0.6" - create-context-state "^2.0.2" - fast-deep-equal "^3.1.3" - resize-observer-polyfill "^1.5.1" - tiny-warning "^1.0.3" - "@remirror/react-editors@^1.0.33": version "1.0.33" resolved "https://registry.yarnpkg.com/@remirror/react-editors/-/react-editors-1.0.33.tgz#119717d958ef61125cf4440a5c952082de9abc56" @@ -5630,26 +5068,6 @@ use-isomorphic-layout-effect "^1.1.2" use-previous "^1.2.0" -"@remirror/react-hooks@^2.0.25": - version "2.0.25" - resolved "https://registry.yarnpkg.com/@remirror/react-hooks/-/react-hooks-2.0.25.tgz#ff459872ba4222ac248edb083e9ffa1fd6ed4a44" - integrity sha512-/qByk9+OSDVBFD5N3CalsXNvbHF0GEfOEhNstsBGvg0xxf0NsuvPj1rYcXnVHk+9mgx2TMh+EiOhfURRR2A9vg== - dependencies: - "@babel/runtime" "^7.22.3" - "@remirror/core" "^2.0.17" - "@remirror/extension-emoji" "^2.0.17" - "@remirror/extension-events" "^2.1.15" - "@remirror/extension-history" "^2.0.13" - "@remirror/extension-mention" "^2.0.15" - "@remirror/extension-mention-atom" "^2.0.17" - "@remirror/extension-positioner" "^2.1.8" - "@remirror/i18n" "^2.0.4" - "@remirror/react-core" "^2.0.20" - "@remirror/react-utils" "^2.0.5" - multishift "^2.0.8" - use-isomorphic-layout-effect "^1.1.2" - use-previous "^1.2.0" - "@remirror/react-renderer@^2.0.13": version "2.0.13" resolved "https://registry.yarnpkg.com/@remirror/react-renderer/-/react-renderer-2.0.13.tgz#2af76c30629c1c9782c7118984e103ae3a8baf2b" @@ -5704,17 +5122,6 @@ color2k "^2.0.2" csstype "^3.1.2" -"@remirror/theme@^2.0.9": - version "2.0.9" - resolved "https://registry.yarnpkg.com/@remirror/theme/-/theme-2.0.9.tgz#0ae990448e90cfead0a6ff7d36b414165a9c663d" - integrity sha512-MI6j7C9KImVyfSBh9GR/WQCuLQKXRKQkE0HsS8Sc/BC8a/0n4QTt7dAg5/a/+MbakyymNaGlibCdts8URgGStg== - dependencies: - "@babel/runtime" "^7.22.3" - "@linaria/core" "4.2.10" - "@remirror/core-types" "^2.0.5" - color2k "^2.0.2" - csstype "^3.1.2" - "@remirror/types@^1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@remirror/types/-/types-1.0.1.tgz#768502497a0fbbc23338a1586b893f729310cf70" @@ -6335,13 +5742,6 @@ dependencies: "@types/react" "*" -"@types/react-is@^18.2.1": - version "18.2.1" - resolved "https://registry.yarnpkg.com/@types/react-is/-/react-is-18.2.1.tgz#61d01c2a6fc089a53520c0b66996d458fdc46863" - integrity sha512-wyUkmaaSZEzFZivD8F2ftSyAfk6L+DfFliVj/mYdOXbVjRcS87fQJLTnhk6dRZPuJjI+9g6RZJO4PNCngUrmyw== - dependencies: - "@types/react" "*" - "@types/react-transition-group@^4.4.0": version "4.4.5" resolved "https://registry.npmjs.org/@types/react-transition-group/-/react-transition-group-4.4.5.tgz" @@ -6887,7 +6287,7 @@ argparse@^2.0.1: resolved "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== -aria-hidden@^1.2.2, aria-hidden@^1.2.3: +aria-hidden@^1.2.2: version "1.2.3" resolved "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.3.tgz" integrity sha512-xcLxITLe2HYa1cnYnwCjkOO1PqUHQpozB8x9AR0OgWN2woOBi5kSDVxKfd0b7sb1hw5qFeJhXm9H1nu3xSfLeQ== @@ -7448,11 +6848,6 @@ case-anything@^2.1.10: resolved "https://registry.yarnpkg.com/case-anything/-/case-anything-2.1.11.tgz#39a00ff733f26e48729f5c6c7f23763ac8fa0467" integrity sha512-uzKDXzdM/x914cepWPzElU3y50NRKYhjkO4ittOHLq+rF6M0AgRLF/+yPR1tvwLNAh8WHEPTfhuciZGPfX+oyg== -case-anything@^2.1.13: - version "2.1.13" - resolved "https://registry.yarnpkg.com/case-anything/-/case-anything-2.1.13.tgz#0cdc16278cb29a7fcdeb072400da3f342ba329e9" - integrity sha512-zlOQ80VrQ2Ue+ymH5OuM/DlDq64mEm+B9UTdHULv5osUMD6HalNTblf2b1u/m6QecjsnOkBpqVZ+XPwIVsy7Ng== - caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" @@ -7775,11 +7170,6 @@ clsx@^1.2.1: resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.2.1.tgz#0ddc4a20a549b59c93a4116bb26f5294ca17dc12" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== -clsx@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/clsx/-/clsx-2.0.0.tgz#12658f3fd98fafe62075595a5c30e43d18f3d00b" - integrity sha512-rQ1+kcj+ttHG0MKVGBUXwayCCF1oh39BF5COIpRzuCEv8Mwjv0XucrI2ExNTOn9IlLifGClWQcU9BrZORvtw6Q== - codemirror@^5.65.12: version "5.65.13" resolved "https://registry.yarnpkg.com/codemirror/-/codemirror-5.65.13.tgz#c098a6f409db8b5a7c5722788bd9fa3bb2367f2e" @@ -8194,13 +7584,6 @@ create-context-state@^2.0.1: dependencies: "@babel/runtime" "^7.21.0" -create-context-state@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/create-context-state/-/create-context-state-2.0.2.tgz#3a811c8e5bb082b35601747e501d1ec970ee4f7f" - integrity sha512-WIz5i5QYt0xvlpbpSnhl4RY7WfcPy8gWtqzE6xtr2hfhuR3WJTsa5V4Y7jgPt+Knp5r0yKbKK0myK59HW2+HHw== - dependencies: - "@babel/runtime" "^7.21.5" - create-emotion@^10.0.27: version "10.0.27" resolved "https://registry.npmjs.org/create-emotion/-/create-emotion-10.0.27.tgz" @@ -11135,13 +10518,6 @@ jsx-dom-cjs@^8.0.5: dependencies: csstype "^3.1.1" -jsx-dom-cjs@^8.0.6: - version "8.0.7" - resolved "https://registry.yarnpkg.com/jsx-dom-cjs/-/jsx-dom-cjs-8.0.7.tgz#098c54680ebf5bb6f6d12cdea5cde3799c172212" - integrity sha512-dQWnuQ+bTm7o72ZlJU4glzeMX8KLxx5U+ZwmEAzVP1+roL7BSM0MrkWdHjdsuNgmxobZCJ+qgiot9EgbJPOoEg== - dependencies: - csstype "^3.1.2" - keyv@^3.0.0: version "3.1.0" resolved "https://registry.npmjs.org/keyv/-/keyv-3.1.0.tgz" @@ -11666,13 +11042,6 @@ minimatch@^5.0.1: dependencies: brace-expansion "^2.0.1" -minimatch@^9.0.3: - version "9.0.3" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" - integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== - dependencies: - brace-expansion "^2.0.1" - minimist-options@4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/minimist-options/-/minimist-options-4.1.0.tgz" @@ -13268,11 +12637,6 @@ regenerator-runtime@^0.13.11, regenerator-runtime@^0.13.7: resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz" integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== -regenerator-runtime@^0.14.0: - version "0.14.0" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz#5e19d68eb12d486f797e15a3c6a918f7cec5eb45" - integrity sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA== - regenerator-transform@^0.15.1: version "0.15.1" resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.15.1.tgz#f6c4e99fc1b4591f780db2586328e4d9a9d8dc56" @@ -14304,11 +13668,6 @@ symbol-tree@^3.2.4: resolved "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz" integrity sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw== -tabbable@^6.0.1: - version "6.2.0" - resolved "https://registry.yarnpkg.com/tabbable/-/tabbable-6.2.0.tgz#732fb62bc0175cfcec257330be187dcfba1f3b97" - integrity sha512-Cat63mxsVJlzYvN51JmVXIgNoUokrIaT2zLclCXjRd8boZ0004U4KCs/sToJ75C6sdlByWxpYnb5Boif1VSFew== - temp-dir@^2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/temp-dir/-/temp-dir-2.0.0.tgz" @@ -14821,11 +14180,6 @@ unpipe@1.0.0, unpipe@~1.0.0: resolved "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz" integrity sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ== -unraw@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/unraw/-/unraw-2.0.1.tgz#7b51dcdfb1e43d59d5e52cdb44d349d029edbaba" - integrity sha512-tdOvLfRzHolwYcHS6HIX860MkK9LQ4+oLuNwFYL7bpgTEO64PZrcQxkisgwJYCfF8sKiWLwwu1c83DvMkbefIQ== - untildify@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/untildify/-/untildify-4.0.0.tgz#2bc947b953652487e4600949fb091e3ae8cd919b" From 3b02573f534cc2882479f774c2f667d48056498a Mon Sep 17 00:00:00 2001 From: sajald77 Date: Thu, 24 Aug 2023 12:16:42 -0400 Subject: [PATCH 10/54] fix: insert hardbreak after images and videos --- src/forms/markdown/commands/ImageCommand.tsx | 2 + src/forms/markdown/commands/TableCommand.tsx | 75 +++----------------- src/forms/markdown/commands/VideoCommand.tsx | 1 + 3 files changed, 13 insertions(+), 65 deletions(-) diff --git a/src/forms/markdown/commands/ImageCommand.tsx b/src/forms/markdown/commands/ImageCommand.tsx index 3183a7ee0..8aec9cdde 100644 --- a/src/forms/markdown/commands/ImageCommand.tsx +++ b/src/forms/markdown/commands/ImageCommand.tsx @@ -15,6 +15,8 @@ export const ImageCommand = ({ isDisabled }: { isDisabled?: boolean }) => { alt: label || 'image', }) + commands.insertHardBreak() + modal.onClose() }) diff --git a/src/forms/markdown/commands/TableCommand.tsx b/src/forms/markdown/commands/TableCommand.tsx index 1dbe916b0..d151ad458 100644 --- a/src/forms/markdown/commands/TableCommand.tsx +++ b/src/forms/markdown/commands/TableCommand.tsx @@ -1,29 +1,19 @@ import { Box, - Checkbox, HStack, Popover, PopoverArrow, PopoverBody, - PopoverCloseButton, PopoverContent, PopoverTrigger, - Text, useDisclosure, VStack, } from '@chakra-ui/react' import { useCommands } from '@remirror/react' import { useState } from 'react' -import { useTranslation } from 'react-i18next' import { BsTable } from 'react-icons/bs' -import { - RiDeleteColumn, - RiDeleteRow, - RiInsertColumnRight, - RiInsertRowBottom, -} from 'react-icons/ri' -import { Body2, MonoBody2 } from '../../../components/typography' +import { MonoBody2 } from '../../../components/typography' import { useDebounce } from '../../../hooks' import { ToolbarCommandButton } from './ToolbarCommandButton' @@ -32,17 +22,15 @@ interface TableCommandProps { } const tableBoxes = [ - [1, 2, 3, 4, 5, 6], - [1, 2, 3, 4, 5, 6], - [1, 2, 3, 4, 5, 6], - [1, 2, 3, 4, 5, 6], - [1, 2, 3, 4, 5, 6], + [1, 2, 3, 4, 5], + [1, 2, 3, 4, 5], + [1, 2, 3, 4, 5], + [1, 2, 3, 4, 5], + [1, 2, 3, 4, 5], ] export const TableCommand = ({ isDisabled }: TableCommandProps) => { - const { t } = useTranslation() const { isOpen, onOpen, onClose } = useDisclosure() - const [hasHeader, setHasHeader] = useState(true) const commands = useCommands() @@ -79,47 +67,13 @@ export const TableCommand = ({ isDisabled }: TableCommandProps) => { - - - - - - - - - - - - - - {tableBoxes.map((row, i) => ( @@ -146,18 +100,9 @@ export const TableCommand = ({ isDisabled }: TableCommandProps) => { ))} - - setHasHeader(e.target.checked)} - > - {t('headers')} - - {`${currentPosition.i + 1}X${ - currentPosition.j + 1 - }`} - + {`${currentPosition.i + 1}X${ + currentPosition.j + 1 + }`} diff --git a/src/forms/markdown/commands/VideoCommand.tsx b/src/forms/markdown/commands/VideoCommand.tsx index 74283e9d2..dc3b40571 100644 --- a/src/forms/markdown/commands/VideoCommand.tsx +++ b/src/forms/markdown/commands/VideoCommand.tsx @@ -14,6 +14,7 @@ export const VideoCommand = ({ isDisabled }: { isDisabled?: boolean }) => { const modal = useInsertVideoModal(({ url }: MarkdownVideo) => { if (!commands.addYouTubeVideo) return commands.addYouTubeVideo({ video: url }) + commands.insertHardBreak() modal.onClose() }) From e46b51bcff6fc908d263cd2f43f15214ef784603 Mon Sep 17 00:00:00 2001 From: sajald77 Date: Thu, 24 Aug 2023 17:02:43 -0400 Subject: [PATCH 11/54] fix: issues with markdown and add multi line feature --- package.json | 2 + src/forms/markdown/MarkdownField.tsx | 11 +- .../markdown/helpers/PreviewRenderer.tsx | 42 +-- src/forms/markdown/helpers/SaveModule.tsx | 11 +- src/forms/markdown/helpers/htmlToMarkdown.tsx | 277 ++++++++++++++++++ src/forms/markdown/helpers/index.ts | 5 + yarn.lock | 14 +- 7 files changed, 323 insertions(+), 39 deletions(-) create mode 100644 src/forms/markdown/helpers/htmlToMarkdown.tsx create mode 100644 src/forms/markdown/helpers/index.ts diff --git a/package.json b/package.json index 49e29f55c..7157f093e 100644 --- a/package.json +++ b/package.json @@ -42,6 +42,7 @@ "bech32": "^2.0.0", "buffer": "^6.0.3", "classnames": "^2.3.2", + "dompurify": "^3.0.5", "dotenv": "^16.0.3", "express": "^4.18.2", "framer-motion": "^8.5.2", @@ -98,6 +99,7 @@ "@testing-library/react": "^13.4.0", "@testing-library/react-hooks": "^8.0.1", "@testing-library/user-event": "^14.4.3", + "@types/dompurify": "^3.0.2", "@types/loadable__component": "^5.13.4", "@types/luxon": "^3.2.0", "@types/node": "^18.11.18", diff --git a/src/forms/markdown/MarkdownField.tsx b/src/forms/markdown/MarkdownField.tsx index 67891b79a..8f9603827 100644 --- a/src/forms/markdown/MarkdownField.tsx +++ b/src/forms/markdown/MarkdownField.tsx @@ -36,10 +36,12 @@ import { useSignedUpload } from '../../hooks' import { useMobileMode } from '../../utils' import { ReactHookTextArea } from '../components/ReactHookTextArea' import { TableCellMenuComponent } from '../components/TableCellMenuComponent' -import { PreviewRenderer } from './helpers/PreviewRenderer' -import { SaveModule } from './helpers/SaveModule' -import { StyleProvider } from './helpers/StyleProvider' -import { imageHandler } from './helpers/typeMaps' +import { + imageHandler, + PreviewRenderer, + SaveModule, + StyleProvider, +} from './helpers' import { MarkdownToolbar } from './MarkdownToolbar' const turndownService = new TurndownService() @@ -76,7 +78,6 @@ export const MarkdownField = ({ }: Props) => { const { t } = useTranslation() const isMobile = useMobileMode() - const onError: InvalidContentHandler = useCallback( ({ json, invalidContent, transformers }) => { // Automatically remove all invalid nodes and marks. diff --git a/src/forms/markdown/helpers/PreviewRenderer.tsx b/src/forms/markdown/helpers/PreviewRenderer.tsx index 0d910915e..72c63f255 100644 --- a/src/forms/markdown/helpers/PreviewRenderer.tsx +++ b/src/forms/markdown/helpers/PreviewRenderer.tsx @@ -1,4 +1,5 @@ import { RemirrorRenderer } from '@remirror/react' +import DOMPurify from 'dompurify' import { getRemirrorJSON, RemirrorContentType, RemirrorManager } from 'remirror' import { markMap, typeMap } from './typeMaps' @@ -10,7 +11,9 @@ export const PreviewRenderer = ({ manager: RemirrorManager content?: RemirrorContentType }) => { - // const newContent = formatString(content?.toString() || '') + const newContent = FormatWhiteSpaceForMarkDownString( + content?.toString() || '', + ) return ( { -// const adjustForLineChange = value -// ? value.replaceAll(matchMarkDownSpecialKeysAtLineEnd, '\\\n') -// : '' - -// const adjustedForMultiParagrah = adjustForLineChange.replaceAll( -// /\n\n/g, -// '\n\\\n', -// ) - -// const finalValue = getRidOfEndSlash(adjustedForMultiParagrah) +export const matchMarkDownSpecialKeysAtLineEnd = /\n(?!.*(\||#|\[|>))/g -// console.log('before content', JSON.stringify(value)) -// console.log('medium content', JSON.stringify(adjustForLineChange)) -// console.log('after content', JSON.stringify(adjustedForMultiParagrah)) +export const FormatWhiteSpaceForMarkDownString = (value: string): string => { + const adjustForLineChange = value + ? value.replaceAll(matchMarkDownSpecialKeysAtLineEnd, '
') + : '' -// return finalValue -// } - -// const getRidOfEndSlash = (value: string): string => { -// if (value[value.length - 2] === '\\') { -// const newValue = value.slice(0, value.length - 2) -// return getRidOfEndSlash(newValue) -// } - -// return value -// } + return DOMPurify.sanitize(adjustForLineChange) +} diff --git a/src/forms/markdown/helpers/SaveModule.tsx b/src/forms/markdown/helpers/SaveModule.tsx index 56832388b..265dea021 100644 --- a/src/forms/markdown/helpers/SaveModule.tsx +++ b/src/forms/markdown/helpers/SaveModule.tsx @@ -2,6 +2,8 @@ import { useDebouncedCallback } from '@react-hookz/web' import { useHelpers, useRemirrorContext } from '@remirror/react' import { Control, useController, useFormContext } from 'react-hook-form' +import { htmlToMarkdown } from './htmlToMarkdown' + export function SaveModule(props: { control?: Control; name?: string }) { const { field: { onChange }, @@ -11,11 +13,14 @@ export function SaveModule(props: { control?: Control; name?: string }) { }) const { trigger } = useFormContext() - const { getMarkdown } = useHelpers() + const { getHTML } = useHelpers() const changeCallback = useDebouncedCallback( - (ctx) => { - onChange(getMarkdown(ctx.state)) + async (ctx) => { + const html = getHTML(ctx.state) + const newHTML = html.replaceAll('

', '
') + const newMarkdown = htmlToMarkdown(newHTML) + onChange(newMarkdown) trigger(props.name ?? 'content') }, [], diff --git a/src/forms/markdown/helpers/htmlToMarkdown.tsx b/src/forms/markdown/helpers/htmlToMarkdown.tsx new file mode 100644 index 000000000..3c5b47528 --- /dev/null +++ b/src/forms/markdown/helpers/htmlToMarkdown.tsx @@ -0,0 +1,277 @@ +/** + * @module + * + * Use `turndown` to provide a github flavoured markdown converter and the + * default common mark converter. + */ +import { + defaultImport, + ErrorConstant, + invariant, + isElementDomNode, +} from '@remirror/core' +import _TurndownService from 'turndown' + +const TurndownService = defaultImport(_TurndownService) + +/** + * Converts the provide HTML to markdown. + */ +export function htmlToMarkdown(html: string): string { + return turndownService.turndown(html) +} + +/** + * A tableRow is a heading row if: + * - the parent is a THEAD + * - or if its the first child of the TABLE or the first TBODY (possibly + * following a blank THEAD) + * - and every cell is a TH + */ +function isHeadingRow(tableRow: Node): tableRow is HTMLTableRowElement { + const { parentNode } = tableRow + + if (!isElementDomNode(parentNode)) { + return false + } + + if (parentNode.nodeName === 'THEAD') { + return true + } + + if (parentNode.nodeName !== 'TABLE' && !isFirstTbody(parentNode)) { + return false + } + + const childNodes = [...tableRow.childNodes] + return ( + childNodes.every((n) => n.nodeName === 'TH') && + childNodes.some((n) => Boolean(n.textContent)) + ) +} + +/** + * Controller cells are generated by the React Tables extension, and provide Node Views for adding/removing columns and rows + * + * However they should not be included in markdown output. + */ +function isControllerHeadingCell(cell: unknown): cell is HTMLTableCellElement { + return isElementDomNode(cell) && cell.matches('th[data-controller-cell]') +} + +/** + * A tableRow is a controller heading row if: + * - the parent is a THEAD + * - or if its the first child of the TABLE or the first TBODY (possibly + * following a blank THEAD) + * - and every cell is a controller cell + */ +function isControllerHeadingRow( + tableRow: Node, +): tableRow is HTMLTableRowElement { + const { parentNode } = tableRow + + if (!isElementDomNode(parentNode)) { + return false + } + + if (parentNode.nodeName !== 'TABLE' && !isFirstTbody(parentNode)) { + return false + } + + const childNodes = [...tableRow.childNodes] + return childNodes.every((n) => isControllerHeadingCell(n)) +} + +/** + * Check whether this is the first `tbody` in the table. + */ +function isFirstTbody(element: Node): element is HTMLTableSectionElement { + if (element.nodeName !== 'TBODY') { + return false + } + + const { previousSibling } = element + + if (!previousSibling) { + return true + } + + return ( + isElementDomNode(previousSibling) && + previousSibling.nodeName === 'THEAD' && + !previousSibling.textContent?.trim() + ) +} + +/** + * Markdown does not support nested tables, check if current table has a table ancestor node + */ +function isNestedTable(element: HTMLElement): boolean { + const currentTable = element.closest('table') + + if (!currentTable) { + return false + } + + const { parentNode } = currentTable + + if (!parentNode) { + return true + } + + return Boolean((parentNode as HTMLElement).closest('table')) +} + +/** + * Create a cell from the table. + */ +function cell(content: string, node: Node) { + const childNodes = [] + + for (const n of node.parentNode?.childNodes ?? []) { + if (isControllerHeadingCell(n)) { + continue + } + + childNodes.push(n) + } + + const index = childNodes.indexOf(node as ChildNode) + const prefix = index === 0 ? '| ' : ' ' + + return `${prefix + content.trim()} |` +} + +/** + * Create the turndown service which will be used to convert html to markdown. + * + * This supports html by default. + */ +const turndownService = new TurndownService({ + codeBlockStyle: 'fenced', + headingStyle: 'atx', +}) + .addRule('taskListItems', { + filter: (node) => + node.nodeName === 'LI' && node.hasAttribute('data-task-list-item'), + replacement(content, node) { + const isChecked = (node as HTMLElement).hasAttribute('data-checked') + return `- ${isChecked ? '[x]' : '[ ]'} ${content.trimStart()}` + }, + }) + .addRule('tableCell', { + filter: ['th', 'td'], + replacement(content, node) { + if (isControllerHeadingCell(node)) { + return '' + } + + return cell(content, node as ChildNode) + }, + }) + .addRule('tableRow', { + filter: 'tr', + replacement(content, node) { + let borderCells = '' + const alignMap = { left: ':--', right: '--:', center: ':-:' } + + // Get child nodes ignoring controller cells + const childNodes = [...node.childNodes].filter( + (n) => !isControllerHeadingCell(n), + ) + + if (isHeadingRow(node)) { + for (const childNode of childNodes) { + if (!isElementDomNode(childNode)) { + // This should never happen. + continue + } + + let border = '---' + const align = ( + childNode.getAttribute('align') ?? '' + ).toLowerCase() as keyof typeof alignMap + + if (align) { + border = alignMap[align] || border + } + + borderCells += cell(border, childNode) + } + } + + return `\n${content}${borderCells ? `\n${borderCells}` : ''}` + }, + }) + .addRule('table', { + // Only convert tables with a heading row. Tables with no heading row are kept + // using `keep` (see below). + filter(node) { + if (node.nodeName !== 'TABLE') { + return false + } + + if (isNestedTable(node)) { + return false + } + + const rows = [...(node as HTMLTableElement).rows].filter( + (r) => + // Remove controller rows + !isControllerHeadingRow(r), + ) + if (rows[0]) return isHeadingRow(rows[0]) + return false + }, + + replacement(content) { + // Ensure there are no blank lines + content = content.replace('\n\n', '\n') + return `\n\n${content}\n\n` + }, + }) + .addRule('tableSection', { + filter: ['thead', 'tbody', 'tfoot'], + replacement(content) { + return content + }, + }) + .keep( + (node) => + node.nodeName === 'TABLE' && + !isHeadingRow((node as HTMLTableElement).rows[0] as any), + ) + .keep((node) => node.nodeName === 'TABLE' && isNestedTable(node)) + .addRule('strikethrough', { + filter: ['del', 's', 'strike' as 'del'], + replacement(content) { + return `~${content}~` + }, + }) + + // Add improved code block support from html. + .addRule('fencedCodeBlock', { + filter: (node, options) => + Boolean( + options.codeBlockStyle === 'fenced' && + node.nodeName === 'PRE' && + node.firstChild && + node.firstChild.nodeName === 'CODE', + ), + + replacement(_, node, options) { + invariant(isElementDomNode(node.firstChild), { + code: ErrorConstant.EXTENSION, + message: `Invalid node \`${node.firstChild?.nodeName}\` encountered for codeblock when converting html to markdown.`, + }) + + const className = node.firstChild.getAttribute('class') ?? '' + const language = + className.match(/(?:lang|language)-(\S+)/)?.[1] ?? + node.firstChild.getAttribute('data-code-block-language') ?? + '' + + return `\n\n${options.fence}${language}\n${node.firstChild.textContent}\n${options.fence}\n\n` + }, + }) diff --git a/src/forms/markdown/helpers/index.ts b/src/forms/markdown/helpers/index.ts new file mode 100644 index 000000000..1b42a768f --- /dev/null +++ b/src/forms/markdown/helpers/index.ts @@ -0,0 +1,5 @@ +export * from './htmlToMarkdown' +export * from './PreviewRenderer' +export * from './SaveModule' +export * from './StyleProvider' +export * from './typeMaps' diff --git a/yarn.lock b/yarn.lock index 1346cab13..d6b628548 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5521,6 +5521,13 @@ resolved "https://registry.yarnpkg.com/@types/direction/-/direction-1.0.0.tgz#6a0962feade8502f9e986e87abe1130b611b13be" integrity sha512-et1wmqXm/5smJ8lTJfBnwD12/2Y7eVJLKbuaRT0h2xaKAoo1h8Dz2Io22GObDLFwxY1ddXRTLH3Gq5v44Fl/2w== +"@types/dompurify@^3.0.2": + version "3.0.2" + resolved "https://registry.yarnpkg.com/@types/dompurify/-/dompurify-3.0.2.tgz#c1cd33a475bc49c43c2a7900e41028e2136a4553" + integrity sha512-YBL4ziFebbbfQfH5mlC+QTJsvh0oJUrWbmxKMyEdL7emlHJqGR2Qb34TEFKj+VCayBvjKy3xczMFNhugThUsfQ== + dependencies: + "@types/trusted-types" "*" + "@types/estree@*": version "1.0.1" resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.1.tgz#aa22750962f3bf0e79d753d3cc067f010c95f194" @@ -5835,7 +5842,7 @@ resolved "https://registry.yarnpkg.com/@types/throttle-debounce/-/throttle-debounce-2.1.0.tgz#1c3df624bfc4b62f992d3012b84c56d41eab3776" integrity sha512-5eQEtSCoESnh2FsiLTxE121IiE60hnMqcb435fShf4bpLRjEu1Eoekht23y6zXS9Ts3l+Szu3TARnTsA0GkOkQ== -"@types/trusted-types@^2.0.2": +"@types/trusted-types@*", "@types/trusted-types@^2.0.2": version "2.0.3" resolved "https://registry.yarnpkg.com/@types/trusted-types/-/trusted-types-2.0.3.tgz#a136f83b0758698df454e328759dbd3d44555311" integrity sha512-NfQ4gyz38SL8sDNrSixxU2Os1a5xcdFxipAFxYEuLUlvU2uDwS4NUpsImcf1//SlWItCVMMLiylsxbmNMToV/g== @@ -8032,6 +8039,11 @@ dompurify@^2.2.2: resolved "https://registry.npmjs.org/dompurify/-/dompurify-2.4.5.tgz" integrity sha512-jggCCd+8Iqp4Tsz0nIvpcb22InKEBrGz5dw3EQJMs8HPJDsKbFIO3STYtAvCfDx26Muevn1MHVI0XxjgFfmiSA== +dompurify@^3.0.5: + version "3.0.5" + resolved "https://registry.yarnpkg.com/dompurify/-/dompurify-3.0.5.tgz#eb3d9cfa10037b6e73f32c586682c4b2ab01fbed" + integrity sha512-F9e6wPGtY+8KNMRAVfxeCOHU0/NPWMSENNq4pQctuXRqqdEPW7q3CrLbR5Nse044WwacyjHGOMlvNsBe1y6z9A== + dot-case@^3.0.4: version "3.0.4" resolved "https://registry.npmjs.org/dot-case/-/dot-case-3.0.4.tgz" From bc25d9b7976e13c5b7e35164e3e4c796e868d846 Mon Sep 17 00:00:00 2001 From: sajald77 Date: Fri, 25 Aug 2023 11:25:34 -0400 Subject: [PATCH 12/54] fix: finalize video fixes and sanitize html --- src/forms/markdown/commands/ImageCommand.tsx | 1 + src/forms/markdown/commands/VideoCommand.tsx | 1 + src/forms/markdown/helpers/PreviewRenderer.tsx | 7 ++++--- src/forms/markdown/helpers/htmlToMarkdown.tsx | 1 + 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/forms/markdown/commands/ImageCommand.tsx b/src/forms/markdown/commands/ImageCommand.tsx index 8aec9cdde..0c5e5314e 100644 --- a/src/forms/markdown/commands/ImageCommand.tsx +++ b/src/forms/markdown/commands/ImageCommand.tsx @@ -10,6 +10,7 @@ export const ImageCommand = ({ isDisabled }: { isDisabled?: boolean }) => { const modal = useInsertLinkModal(({ url, label }: MarkdownImage) => { if (!commands.insertImage) return + commands.insertHardBreak() commands.insertImage({ src: url, alt: label || 'image', diff --git a/src/forms/markdown/commands/VideoCommand.tsx b/src/forms/markdown/commands/VideoCommand.tsx index dc3b40571..c2ab9d47e 100644 --- a/src/forms/markdown/commands/VideoCommand.tsx +++ b/src/forms/markdown/commands/VideoCommand.tsx @@ -13,6 +13,7 @@ export const VideoCommand = ({ isDisabled }: { isDisabled?: boolean }) => { const modal = useInsertVideoModal(({ url }: MarkdownVideo) => { if (!commands.addYouTubeVideo) return + commands.insertHardBreak() commands.addYouTubeVideo({ video: url }) commands.insertHardBreak() modal.onClose() diff --git a/src/forms/markdown/helpers/PreviewRenderer.tsx b/src/forms/markdown/helpers/PreviewRenderer.tsx index 72c63f255..a72be2b38 100644 --- a/src/forms/markdown/helpers/PreviewRenderer.tsx +++ b/src/forms/markdown/helpers/PreviewRenderer.tsx @@ -29,12 +29,13 @@ export const PreviewRenderer = ({ ) } -export const matchMarkDownSpecialKeysAtLineEnd = /\n(?!.*(\||#|\[|>))/g +export const matchMarkDownSpecialKeysAtLineEnd = + /(?))\n(?!.*(\n\||\||#|\[|>))/g export const FormatWhiteSpaceForMarkDownString = (value: string): string => { const adjustForLineChange = value - ? value.replaceAll(matchMarkDownSpecialKeysAtLineEnd, '
') + ? value.replaceAll(matchMarkDownSpecialKeysAtLineEnd, '
') : '' - return DOMPurify.sanitize(adjustForLineChange) + return DOMPurify.sanitize(adjustForLineChange, { ADD_TAGS: ['iframe'] }) } diff --git a/src/forms/markdown/helpers/htmlToMarkdown.tsx b/src/forms/markdown/helpers/htmlToMarkdown.tsx index 3c5b47528..f740ee340 100644 --- a/src/forms/markdown/helpers/htmlToMarkdown.tsx +++ b/src/forms/markdown/helpers/htmlToMarkdown.tsx @@ -152,6 +152,7 @@ const turndownService = new TurndownService({ codeBlockStyle: 'fenced', headingStyle: 'atx', }) + .keep(['iframe']) .addRule('taskListItems', { filter: (node) => node.nodeName === 'LI' && node.hasAttribute('data-task-list-item'), From d4628d5e1452613f5f7039935a78a1aa81e1eb19 Mon Sep 17 00:00:00 2001 From: sajald77 Date: Fri, 25 Aug 2023 20:46:11 -0400 Subject: [PATCH 13/54] fix: add twitter embed inside markdown --- index.html | 16 ++++ src/constants/components/id.ts | 5 ++ src/forms/markdown/MarkdownField.tsx | 15 +++- src/forms/markdown/commands/TweetCommand.tsx | 74 +++++++++++++++++++ .../markdown/helpers/PreviewRenderer.tsx | 4 +- src/forms/markdown/helpers/StyleProvider.tsx | 15 +++- src/forms/markdown/helpers/typeMaps.tsx | 60 ++++++++++++++- .../markdown/modals/InsertTwitterModal.tsx | 64 ++++++++++++++++ .../markdown/modals/InsertVideoModal.tsx | 7 +- src/forms/markdown/toolbar/ToolbarMedia.tsx | 2 + src/forms/validations/twitter.ts | 12 +++ src/translations/English.json | 7 +- src/types/types.ts | 2 + 13 files changed, 274 insertions(+), 9 deletions(-) create mode 100644 src/forms/markdown/commands/TweetCommand.tsx create mode 100644 src/forms/markdown/modals/InsertTwitterModal.tsx create mode 100644 src/forms/validations/twitter.ts diff --git a/index.html b/index.html index a266caab3..d224a7670 100644 --- a/index.html +++ b/index.html @@ -42,6 +42,22 @@ a.appendChild(r); })(window,document,'https://static.hotjar.com/c/hotjar-','.js?sv='); +
diff --git a/src/constants/components/id.ts b/src/constants/components/id.ts index cd9fc495c..ed3be575c 100644 --- a/src/constants/components/id.ts +++ b/src/constants/components/id.ts @@ -22,6 +22,11 @@ export const ID = { contribution: 'project-activity-list-container', leaderboard: 'project-leaderboard-list-container', }, + story: { + markdown: { + container: 'project-story-markdown-container', + }, + }, }, profile: { tabs: 'user-profile-tab-container', diff --git a/src/forms/markdown/MarkdownField.tsx b/src/forms/markdown/MarkdownField.tsx index 8f9603827..ee60045e1 100644 --- a/src/forms/markdown/MarkdownField.tsx +++ b/src/forms/markdown/MarkdownField.tsx @@ -37,6 +37,7 @@ import { useMobileMode } from '../../utils' import { ReactHookTextArea } from '../components/ReactHookTextArea' import { TableCellMenuComponent } from '../components/TableCellMenuComponent' import { + FrameHandler, imageHandler, PreviewRenderer, SaveModule, @@ -108,7 +109,18 @@ export const MarkdownField = ({ new BlockquoteExtension(), new OrderedListExtension(), new CodeExtension(), - new IframeExtension(), + new IframeExtension({ + enableResizing: false, + extraAttributes: { + width: '100%', + scolling: 'no', + style: { + default: JSON.stringify({ width: '100%', height: '400px' }), + parseDOM: (domNode) => domNode.getAttribute('style'), + toDOM: (attrs) => ['style', (attrs.style as string) || ''], + }, + }, + }), new HardBreakExtension(), new TableExtension(), new TrailingNodeExtension(), @@ -148,6 +160,7 @@ export const MarkdownField = ({ orderedList: ({ forwardRef }: { forwardRef: ForwardedRef }) => ( ), + iframe: (props: any) => FrameHandler(props), }, }, }) diff --git a/src/forms/markdown/commands/TweetCommand.tsx b/src/forms/markdown/commands/TweetCommand.tsx new file mode 100644 index 000000000..f60dd9913 --- /dev/null +++ b/src/forms/markdown/commands/TweetCommand.tsx @@ -0,0 +1,74 @@ +import { Box } from '@chakra-ui/react' +import { useCommands } from '@remirror/react' +import { BsTwitter } from 'react-icons/bs' + +import { useDarkMode } from '../../../utils' +import { + InsertTwitterModal, + MarkdownTwitter, + useInsertTwitterModal, +} from '../modals/InsertTwitterModal' +import { ToolbarCommandButton } from './ToolbarCommandButton' + +export const TweetCommand = ({ isDisabled }: { isDisabled?: boolean }) => { + const commands = useCommands() + const isDarkMode = useDarkMode() + + const modal = useInsertTwitterModal(async ({ url }: MarkdownTwitter) => { + if (!commands.addYouTubeVideo) return + commands.insertHardBreak() + + const UrlSplit = url.split('/').filter((val) => val && val !== '/') + + const tweetId = UrlSplit[UrlSplit.length - 1] + + if (!tweetId) return + + const value = await twttr.widgets.createTweet( + tweetId, + document.getElementById('tweet-container'), + { + width: '350px', + theme: isDarkMode ? 'dark' : 'light', + }, + ) + + console.log('inner html', value.innerHTML) + + commands.insertHtml(value.innerHTML, {}) + commands.insertHardBreak() + + const element = document.getElementById('tweet-container') + if (element) { + element.innerHTML = '' + } + + modal.onClose() + }) + + return ( + <> + modal.onOpen()} + isDisabled={isDisabled} + > + + + {modal.isOpen ? : null} + + + ) +} diff --git a/src/forms/markdown/helpers/PreviewRenderer.tsx b/src/forms/markdown/helpers/PreviewRenderer.tsx index a72be2b38..faf689bfd 100644 --- a/src/forms/markdown/helpers/PreviewRenderer.tsx +++ b/src/forms/markdown/helpers/PreviewRenderer.tsx @@ -30,11 +30,11 @@ export const PreviewRenderer = ({ } export const matchMarkDownSpecialKeysAtLineEnd = - /(?))\n(?!.*(\n\||\||#|\[|>))/g + /(?))\n(?!.*(\*|_|#|-|\[|>|\n\||\||`|[0-9]+(\.|\))))/g export const FormatWhiteSpaceForMarkDownString = (value: string): string => { const adjustForLineChange = value - ? value.replaceAll(matchMarkDownSpecialKeysAtLineEnd, '
') + ? value.replaceAll(matchMarkDownSpecialKeysAtLineEnd, '
') : '' return DOMPurify.sanitize(adjustForLineChange, { ADD_TAGS: ['iframe'] }) diff --git a/src/forms/markdown/helpers/StyleProvider.tsx b/src/forms/markdown/helpers/StyleProvider.tsx index f6c4f1c10..a7522d968 100644 --- a/src/forms/markdown/helpers/StyleProvider.tsx +++ b/src/forms/markdown/helpers/StyleProvider.tsx @@ -1,9 +1,10 @@ import { Box, BoxProps, styled } from '@chakra-ui/react' import { ThemeProvider } from '@remirror/react-components' import { AllStyledComponent } from '@remirror/styles/emotion' -import { useMemo } from 'react' +import { useEffect, useMemo } from 'react' import { RemirrorThemeType } from 'remirror' +import { ID } from '../../../constants' import { useCustomTheme } from '../../../utils' import { tableCellStyles } from './typeMaps' @@ -21,6 +22,11 @@ const Container = styled(Box, { '& iframe': { minHeight: '28em', }, + '& div.remirror-iframe-custom': { + width: '100% !important', + height: 'auto !important', + marginBottom: '20px', + }, '& a': { textDecoration: 'underline', }, @@ -57,8 +63,15 @@ export const StyleProvider = ({ [colors], ) + useEffect(() => { + twttr.widgets.load( + document.getElementById(ID.project.story.markdown.container), + ) + }, []) + return ( { ) } +export const FrameHandler = (props: any) => { + const colorMode = localStorage.getItem('chakra-ui-color-mode') + + const newSrc = `${props.node.attrs.src}`.replace( + /theme=dark|theme=light/, + `theme=${colorMode || 'light'}`, + ) + + const splitValues = + `${props.node.attrs.style}` + .replaceAll(/"|\{|\}/g, '') + .replaceAll(',', ';') + .split(';') || [] + + const newStyle = {} as { [key: string]: string | number } + + splitValues.map((acc: any) => { + const [key, value] = acc.split(':') + if (key && value) { + newStyle[key.trim()] = value.trim() + } + }) + + const isTwitter = newSrc.toLowerCase().includes('twitter') + + return ( + + +