-
Notifications
You must be signed in to change notification settings - Fork 381
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: added script copy button #342
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor fixes
Also, you should run pnpm format:write
and pnpm lint:fix
locally to clean the code before pushing up
{ | ||
name: "script-copy-btn", | ||
type: "registry:ui", | ||
files: ["magicui/script-copy-btn.tsx"], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should list the dependencies here that are being imported by the component
registry/default/magicui/dock.tsx
Outdated
distance: distance, | ||
}); | ||
} | ||
return child; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this dock fix should be in a separate PR ideally just so we know this is not related to the new component
import { Check, Copy } from "lucide-react"; | ||
import { codeToHtml } from "shiki"; | ||
import { motion } from "framer-motion"; | ||
import { useTheme } from "next-themes"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what should be done for non next.js users?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It will work for non-next.js users too.
Script copy Button added with theme support.