Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

editor: fix `framer-motion` deprecation warning

Abdullah Attadc15bf75c6a6
diff --git a/packages/editor/src/components/action-sheet/index.tsx b/packages/editor/src/components/action-sheet/index.tsx
index ddf6d7a14..eb67dfa0d 100644
--- a/packages/editor/src/components/action-sheet/index.tsx
+++ b/packages/editor/src/components/action-sheet/index.tsx
@@ -38,7 +38,7 @@ import {
import { useTheme } from "@emotion/react";
import { EmotionThemeProvider, Theme } from "@notesnook/theme";
-const AnimatedFlex = motion(Flex);
+const AnimatedFlex = motion.create(Flex);
type ActionSheetHistoryItem = {
title?: string;
diff --git a/packages/editor/src/extensions/image/component.tsx b/packages/editor/src/extensions/image/component.tsx
index 92fa4bcc1..9841c8299 100644
--- a/packages/editor/src/extensions/image/component.tsx
+++ b/packages/editor/src/extensions/image/component.tsx
@@ -43,7 +43,7 @@ import { useObserver } from "../../hooks/use-observer.js";
import { Attachment, ImageAlignmentOptions } from "../attachment/index.js";
import { DataURL } from "@notesnook/common";
-export const AnimatedImage = motion(Image);
+export const AnimatedImage = motion.create(Image);
export function ImageComponent(
props: ReactNodeViewProps<Partial<ImageAttributes>>