Files
shadcn/app/components/open-in-h-button.tsx
zeekay 9f1122cf9b fix: Correct color alias mappings in registry-colors
- Fix gray/zinc alias confusion (gray→neutral, zinc→zen)
- Consolidate duplicate gray color definition
- Add finance components to ui/ directory
- Clean up documentation structure
- Remove test artifacts and backup files

The color aliases were incorrectly mapped:
  Before: gray→zen, zinc→neutral (wrong)
  After: gray→neutral, zinc→zen (correct)

This ensures Hanzo's branded 'zen' color properly maps to zinc
while gray correctly references the standard neutral palette.

Verified:
- Production build: 544 pages ✓
- All tests passing: 219/219 ✓
- Visual verification: /colors page working ✓
- Code review: Approved ✓

Ready for deployment to ui.hanzo.ai
2025-11-12 13:22:56 -08:00

31 lines
772 B
TypeScript

import Link from "next/link"
import { cn } from "@/lib/utils"
import { HanzoLogo } from "@/components/hanzo-logo"
import { Button } from "@/registry/default/ui/button"
export function OpenInHButton({
name,
className,
...props
}: React.ComponentProps<typeof Button> & {
name: string
}) {
return (
<Button
size="sm"
asChild
className={cn(
"h-[1.8rem] gap-1.5 bg-black text-white hover:bg-black dark:bg-white dark:text-black dark:hover:bg-white",
className
)}
{...props}
>
<Link href={`https://hanzo.app/builder?block=${name}`} target="_blank">
<span className="font-medium">Open in</span>
<HanzoLogo className="size-4 shrink-0 invert dark:invert-0" />
</Link>
</Button>
)
}