v0.1.0 — Moon Base initial scaffold: auth, garden plant registry + log

This commit is contained in:
Bonna Moon
2026-06-15 16:14:48 -05:00
commit 99918fffbc
47 changed files with 2764 additions and 0 deletions

22
src/lib/utils.ts Normal file
View File

@@ -0,0 +1,22 @@
import { type ClassValue, clsx } from "clsx";
import { twMerge } from "tailwind-merge";
export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs));
}
export function initials(name: string): string {
return name
.split(/\s+/)
.map((p) => p[0])
.filter(Boolean)
.slice(0, 2)
.join("")
.toUpperCase();
}
export function formatDate(date: Date | string | null | undefined): string {
if (!date) return "—";
const d = typeof date === "string" ? new Date(date) : date;
return d.toLocaleDateString("en-US", { month: "short", day: "numeric", year: "numeric" });
}