UI Library for Design Engineers. Animated components and effects you can copy and paste into your apps. Free. Open Source.
🐛 fix: fixes
Dillion Verma50eebbda7915
diff --git a/app/components/page.tsx b/app/components/page.tsxindex 35a2e1d5..0e67f9b8 100644--- a/app/components/page.tsx+++ b/app/components/page.tsx@@ -40,51 +40,34 @@ export default async function ComponentPage() {<FadeIn key={post._id} delay={index * 0.1}><articlekey={post._id}- className="group relative space-y-2 flex grow flex-col overflow-hidden rounded-xl border hover:border-gray-300 dark:border-gray-800 dark:hover:border-gray-700 transition-all duration-300"+ className="group relative flex grow flex-col overflow-hidden rounded-xl border hover:border-gray-300 dark:border-gray-800 dark:hover:border-gray-700 transition-all duration-300">- {post.image && (- <video- src="https://media.graphassets.com/v4QIVBhuTUCT4uOrH6LO"- autoPlay- loop- muted- playsInline- className="aspect-video overflow-hidden"- />- // <Image- // src={post.image}- // alt={post.title}- // width={804}- // height={452}- // className="rounded-md border bg-muted transition-colors"- // priority={index <= 1}- // />+ {post.video && (+ <div className="overflow-hidden">+ <video+ src={post.video}+ autoPlay+ loop+ muted+ playsInline+ className="relative -bottom-1 aspect-video" // needed because random black line at bottom of video+ />+ </div>)}- <div className="flex grow flex-col px-3 pb-2 pt-3">+ <div className="flex grow flex-col p-3"><h2>{post.title}</h2>{/* {post.date && (- <p className="text-sm text-gray-500">- {formatDate(post.date)}- </p>- )} */}+ <p className="text-sm text-gray-500">+ {formatDate(post.date)}+ </p>+ )} */}{post.summary && (<p className="mb-2 text-sm text-muted-foreground">{post.summary}</p>)}- {/* <p className="mb-2 text-sm text-gray-500">- A gradient that follows your cursor to paint a border.- </p> */}</div>- {/* <h2 className="text-2xl font-extrabold">{post.title}</h2>- {post.summary && (- <p className="text-muted-foreground">{post.summary}</p>- )}- {post.date && (- <p className="text-sm text-muted-foreground">- {formatDate(post.date)}- </p>- )} */}+<Link href={post.url} className="absolute inset-0"><span className="sr-only">View Article</span></Link>diff --git a/app/globals.css b/app/globals.cssindex 10be7bb8..332588b6 100644--- a/app/globals.css+++ b/app/globals.css@@ -32,7 +32,7 @@--destructive: 0 84.2% 60.2%;--destructive-foreground: 0 0% 98%;- --ring: 240 5% 64.9%;+ --ring: 220 9% 46%;--radius: 0.5rem;}@@ -42,7 +42,8 @@--foreground: 0 0% 98%;--muted: 216 34% 17%;- --muted-foreground: 240 5% 64.9%;++ --muted-foreground: 220 9% 46%;--popover: var(--background);--popover-foreground: 0 0% 98%;diff --git a/content/components/magic-border.mdx b/content/components/magic-border.mdxindex f7b1a3c3..d3c73582 100644--- a/content/components/magic-border.mdx+++ b/content/components/magic-border.mdx@@ -1,8 +1,9 @@---title: Magic Borderdate: 2023-06-25-summary: Animated border on hover+summary: A spotlight effect that highlights borders where you move your cursorauthor: dillionverma+video: https://cdn.magicuikit.com/magic-border.webm---<Steps>diff --git a/contentlayer.config.ts b/contentlayer.config.tsindex 79922177..756c008b 100644--- a/contentlayer.config.ts+++ b/contentlayer.config.ts@@ -8,17 +8,6 @@ import { BlogPosting, WithContext } from "schema-dts";import { visit } from "unist-util-visit";import { env } from "./env.mjs";-// const computedFields = {-// slug: {-// type: "string",-// resolve: (doc) => `/${doc._raw.flattenedPath}`,-// },-// slugAsParams: {-// type: "string",-// resolve: (doc) => doc._raw.flattenedPath.split("/").slice(1).join("/"),-// },-// }-export const Component = defineDocumentType(() => ({name: "Component",filePathPattern: `components/**/*.mdx`,@@ -26,7 +15,7 @@ export const Component = defineDocumentType(() => ({fields: {title: { type: "string", required: true },date: { type: "date", required: true },- // image: { type: "string", required: false },+ video: { type: "string", required: false },summary: { type: "string", required: true },author: { type: "string", required: true },published: { type: "boolean", required: false, default: true },diff --git a/next.config.js b/next.config.jsindex 031932f5..f9ed45e4 100644--- a/next.config.js+++ b/next.config.js@@ -1,6 +1,12 @@const { withContentlayer } = require("next-contentlayer");/** @type {import('next').NextConfig} */-const nextConfig = { reactStrictMode: true, swcMinify: true };+const nextConfig = {+ reactStrictMode: true,+ swcMinify: true,+ images: {+ domains: ["localhost", "cdn.magicuikit.com"],+ },+};module.exports = withContentlayer(nextConfig);diff --git a/tailwind.config.js b/tailwind.config.jsindex 2e64a699..ed1dce46 100644--- a/tailwind.config.js+++ b/tailwind.config.js@@ -53,9 +53,6 @@ module.exports = {md: `calc(var(--radius) - 2px)`,sm: "calc(var(--radius) - 4px)",},- // fontFamily: {- // sans: ["var(--font-sans)", ...fontFamily.sans],- // },keyframes: {"accordion-down": {from: { height: 0 },