Skip to content

Commit 3e0047f

Browse files
lwinmoepaingclaude
andcommitted
♻️ refactor: migrate framer-motion to motion and reduce MMSWE glow layers
Replace framer-motion with motion package (import from "motion/react") across all 29 files. Also reduce GPU-heavy blur layers in MmsweTypoSection by limiting ambient glow to only M, S, E letters for better performance. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent dfc8cbe commit 3e0047f

31 files changed

Lines changed: 55 additions & 48 deletions

bun.lockb

480 Bytes
Binary file not shown.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,11 @@
5252
"date-fns": "^2.30.0",
5353
"fast-shuffle": "^6.0.1",
5454
"firebase": "^12.10.0",
55-
"framer-motion": "^12.36.0",
5655
"husky": "^8.0.3",
5756
"lexical": "^0.41.0",
5857
"lint-staged": "^15.0.2",
5958
"lucide-react": "^0.577.0",
59+
"motion": "^12.37.0",
6060
"next": "16.1.6",
6161
"next-contentlayer2": "^0.5.8",
6262
"next-intl": "^4.8.3",

src/app/blog/BlogPageClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {
88
useMotionValue,
99
useSpring,
1010
useTransform,
11-
} from "framer-motion";
11+
} from "motion/react";
1212
import { useRef, useCallback } from "react";
1313
import Link from "next/link";
1414
import {

src/app/blog/edit/BlogEditClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import { useState, useCallback, Suspense } from "react";
44
import { useSearchParams } from "next/navigation";
55
import { cn } from "@/utils";
6-
import { motion } from "framer-motion";
6+
import { motion } from "motion/react";
77
import { PenLine, Save, Tag, X, Image as ImageIcon, CheckCircle } from "lucide-react";
88
import AuthGuard from "@/components/Auth/AuthGuard";
99
import UnauthorizedMessage from "@/components/Auth/UnauthorizedMessage";

src/app/blog/my-posts/MyPostsClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import { useState, useEffect, useCallback } from "react";
44
import { cn } from "@/utils";
5-
import { motion } from "framer-motion";
5+
import { motion } from "motion/react";
66
import {
77
FileText,
88
PenLine,

src/app/blog/post/BlogPostClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import { useState, useEffect, Suspense } from "react";
44
import { useSearchParams } from "next/navigation";
55
import { cn } from "@/utils";
6-
import { motion } from "framer-motion";
6+
import { motion } from "motion/react";
77
import {
88
Calendar,
99
ArrowLeft,

src/app/blog/write/BlogWriteClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import { useState, useCallback } from "react";
44
import { useRouter } from "next/navigation";
55
import { cn } from "@/utils";
6-
import { motion } from "framer-motion";
6+
import { motion } from "motion/react";
77
import { PenLine, Save, Tag, X, Image as ImageIcon } from "lucide-react";
88
import AuthGuard from "@/components/Auth/AuthGuard";
99
import { ContentEditor } from "@/components/ContentEditor";

src/app/contact-us/ContactPageClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {
88
useMotionValue,
99
useSpring,
1010
useTransform,
11-
} from "framer-motion";
11+
} from "motion/react";
1212
import { useRef, useCallback } from "react";
1313
import {
1414
Users,

src/app/how-to/HowToPageClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import { cn } from "@/utils";
44
import MseLink from "@/components/Ui/MseLink/MseLink";
5-
import { motion, useInView, AnimatePresence } from "framer-motion";
5+
import { motion, useInView, AnimatePresence } from "motion/react";
66
import { useRef, useState } from "react";
77
import {
88
BookOpen,

src/app/profile/editor/ProfileEditorClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import Container from "@/components/Common/Container/Container";
55
import EditorPane from "@/components/ProfileEditor/EditorPane";
66
import PreviewPane from "@/components/ProfileEditor/PreviewPane";
77
import { useProfileEditor } from "@/hooks/profile/useProfileEditor";
8-
import { motion, useInView } from "framer-motion";
8+
import { motion, useInView } from "motion/react";
99
import { useRef } from "react";
1010
import {
1111
PenTool,

0 commit comments

Comments
 (0)