diff --git a/apps/www/app/(blog)/blog/[...slug]/page.tsx b/apps/www/app/(blog)/blog/[...slug]/page.tsx index 59dc89466..5fff4ca24 100644 --- a/apps/www/app/(blog)/blog/[...slug]/page.tsx +++ b/apps/www/app/(blog)/blog/[...slug]/page.tsx @@ -4,14 +4,15 @@ import Link from "next/link" import { notFound } from "next/navigation" import { mdxComponents } from "@/mdx-components" import { ArrowLeftIcon } from "lucide-react" -import { Badge } from "@/components/ui/badge" import type { BlogPosting, BreadcrumbList, WithContext } from "schema-dts" + import { siteConfig } from "@/config/site" import { blogSource } from "@/lib/source" import { absoluteUrl, calculateReadingTime, formatDate } from "@/lib/utils" +import { Badge } from "@/components/ui/badge" import { buttonVariants } from "@/components/ui/button" -import { BlogTableOfContents } from "@/components/blog/table-of-contents" import { MobileTOC } from "@/components/blog/mobile-toc" +import { BlogTableOfContents } from "@/components/blog/table-of-contents" import { SidebarCTA } from "@/components/sidebar-cta" export const revalidate = false @@ -188,7 +189,7 @@ export default async function BlogPage({ params }: PageProps) { {doc.title}
@@ -219,14 +220,16 @@ export default async function BlogPage({ params }: PageProps) { return ( tags.length > 0 && ( -
+
{tags.map((tag) => ( - + {tag} diff --git a/apps/www/app/(blog)/blog/page.tsx b/apps/www/app/(blog)/blog/page.tsx index 658c8c601..6f3164f3c 100644 --- a/apps/www/app/(blog)/blog/page.tsx +++ b/apps/www/app/(blog)/blog/page.tsx @@ -127,7 +127,7 @@ export default async function Page({ __html: serializedBreadcrumbStructuredData, }} /> -
+

Blog

@@ -202,20 +202,20 @@ export default async function Page({ > {post.data?.image && ( -
+
{post.data?.title
)}
-

+

{post.data?.title ?? post.url}

{post.data?.description && ( @@ -239,15 +239,17 @@ export default async function Page({ {normalizeTag(post.data?.tags).length > 0 && (
- {normalizeTag(post.data.tags).slice(0, 3).map((tag) => ( - - {tag} - - ))} + {normalizeTag(post.data.tags) + .slice(0, 3) + .map((tag) => ( + + {tag} + + ))}
)}
diff --git a/apps/www/components/blog/table-of-contents.tsx b/apps/www/components/blog/table-of-contents.tsx index 557b1e62d..6a65bca64 100644 --- a/apps/www/components/blog/table-of-contents.tsx +++ b/apps/www/components/blog/table-of-contents.tsx @@ -16,10 +16,10 @@ const generateHeadingId = (text: string) => { .trim() } -export function BlogTableOfContents({ +export function BlogTableOfContents({ className, onLinkClick, -}: { +}: { className?: string onLinkClick?: () => void }) { diff --git a/apps/www/content/blog/typescript-vs-javascript-differences.mdx b/apps/www/content/blog/typescript-vs-javascript-differences.mdx index 04ecda5d5..86d260d31 100644 --- a/apps/www/content/blog/typescript-vs-javascript-differences.mdx +++ b/apps/www/content/blog/typescript-vs-javascript-differences.mdx @@ -39,7 +39,7 @@ This comparison isn't about crowning a winner. It’s about helping you make the
- + - + @@ -73,7 +73,7 @@ This comparison isn't about crowning a winner. It’s about helping you make the maintainability. - + @@ -84,7 +84,7 @@ This comparison isn't about crowning a winner. It’s about helping you make the Catches type-related errors during compilation, before code is run. - + diff --git a/apps/www/content/docs/components/smooth-cursor.mdx b/apps/www/content/docs/components/smooth-cursor.mdx index daf1d396a..ab0c38787 100644 --- a/apps/www/content/docs/components/smooth-cursor.mdx +++ b/apps/www/content/docs/components/smooth-cursor.mdx @@ -34,6 +34,10 @@ npx shadcn@latest add @magicui/smooth-cursor +```bash +npx add smooth-cursor framer-motion +``` + Copy and paste the following code into your project. @@ -102,10 +106,10 @@ select { ## Props -| Prop | Type | Default | Description | -| -------------- | ----------------- | ---------------------- | ------------------------------------------------------ | -| `cursor` | `React.ReactNode` | `` | Custom cursor component to replace the default cursor | -| `springConfig` | `SpringConfig` | See below | Configuration object for the spring animation behavior | +| Prop | Type | Default | Description | +| -------------- | -------------- | ---------------------- | ------------------------------------------------------ | +| `cursor` | `JSX.Element`. | `` | Custom cursor component to replace the default cursor | +| `springConfig` | `SpringConfig` | See below | Configuration object for the spring animation behavior | ### SpringConfig Type diff --git a/apps/www/mdx-components.tsx b/apps/www/mdx-components.tsx index 35f658e7c..94ef6cf06 100644 --- a/apps/www/mdx-components.tsx +++ b/apps/www/mdx-components.tsx @@ -100,10 +100,7 @@ export const mdxComponents = { /> ), p: ({ className, ...props }: React.ComponentProps<"p">) => ( -

+

), strong: ({ className, ...props }: React.HTMLAttributes) => ( @@ -119,7 +116,10 @@ export const mdxComponents = { ), blockquote: ({ className, ...props }: React.ComponentProps<"blockquote">) => (

), @@ -128,40 +128,30 @@ export const mdxComponents = { {alt} ), iframe: ({ className, ...props }: React.ComponentProps<"iframe">) => ( -
Project Scope
Error Detection
Developer Experience