From 7e6ef23bd25ebc0b55394cf3430a1d440cbd404e Mon Sep 17 00:00:00 2001 From: Untone Date: Fri, 11 Oct 2024 04:55:29 +0300 Subject: [PATCH] lint --- src/components/Editor/Editor.tsx | 9 +-------- src/components/Editor/Toolbar/FullBubbleMenu.tsx | 9 ++++++--- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/src/components/Editor/Editor.tsx b/src/components/Editor/Editor.tsx index e095a622..67395443 100644 --- a/src/components/Editor/Editor.tsx +++ b/src/components/Editor/Editor.tsx @@ -303,7 +303,6 @@ export const EditorComponent = (props: EditorComponentProps) => { user: { name: profile.name, color: uniqolor(profile.slug).color } }) ) - } catch (error) { console.error('Error initializing collaboration:', error) showSnackbar({ body: t('Failed to initialize collaboration') }) @@ -334,13 +333,7 @@ export const EditorComponent = (props: EditorComponentProps) => { }) // collab mode on/off - createEffect( - on( - isCollabMode, - (x) => !x && initializeCollaboration(), - { defer: true } - ) - ) + createEffect(on(isCollabMode, (x) => !x && initializeCollaboration(), { defer: true })) onCleanup(() => { editorElRef()?.removeEventListener('focus', handleFocus) diff --git a/src/components/Editor/Toolbar/FullBubbleMenu.tsx b/src/components/Editor/Toolbar/FullBubbleMenu.tsx index ad0b01fa..a304b597 100644 --- a/src/components/Editor/Toolbar/FullBubbleMenu.tsx +++ b/src/components/Editor/Toolbar/FullBubbleMenu.tsx @@ -9,8 +9,8 @@ import { MicroBubbleMenu } from './MicroBubbleMenu' import { ToolbarControl } from './ToolbarControl' import { Popover } from '~/components/_shared/Popover/Popover' -import styles from './FullBubbleMenu.module.scss' import { useEditorContext } from '~/context/editor' +import styles from './FullBubbleMenu.module.scss' type FullBubbleMenuProps = { editor: () => Editor | undefined @@ -265,8 +265,11 @@ export const FullBubbleMenu = (props: FullBubbleMenuProps) => {
{(triggerRef: (el: HTMLButtonElement) => void) => ( -