mirror of
https://github.com/astral-sh/ruff.git
synced 2025-10-02 22:55:08 +00:00
[playground] Extract shared components (#16819)
## Summary Extract components that can be shared with the Red Knot playground. ## Test Plan `npm start`
This commit is contained in:
parent
433879d852
commit
ded9c69888
35 changed files with 230 additions and 222 deletions
36
playground/shared/src/AstralButton.tsx
Normal file
36
playground/shared/src/AstralButton.tsx
Normal file
|
@ -0,0 +1,36 @@
|
|||
import type { ButtonHTMLAttributes } from "react";
|
||||
import classNames from "classnames";
|
||||
|
||||
export default function AstralButton({
|
||||
className,
|
||||
children,
|
||||
...otherProps
|
||||
}: ButtonHTMLAttributes<any>) {
|
||||
return (
|
||||
<button
|
||||
className={classNames(
|
||||
"uppercase",
|
||||
"ease-in-out",
|
||||
"font-heading",
|
||||
"outline-radiate",
|
||||
"transition-all duration-200",
|
||||
"bg-radiate",
|
||||
"text-black",
|
||||
"hover:text-white",
|
||||
"hover:bg-galaxy",
|
||||
"outline-1",
|
||||
"dark:outline",
|
||||
"dark:hover:outline-white",
|
||||
"rounded-md",
|
||||
"tracking-[.08em]",
|
||||
"text-sm",
|
||||
"font-medium",
|
||||
"enabled:hover:bg-galaxy",
|
||||
className,
|
||||
)}
|
||||
{...otherProps}
|
||||
>
|
||||
{children}
|
||||
</button>
|
||||
);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue