refactor: rename pastel app to color and update all references

This commit is contained in:
2026-02-26 12:19:22 +01:00
parent 061ea1d806
commit 484423f299
23 changed files with 55 additions and 64 deletions

View File

@@ -4,16 +4,7 @@
@source "../components/color/*.{js,ts,jsx,tsx}";
@source "../components/layout/*.{js,ts,jsx,tsx}";
@source "../components/providers/*.{js,ts,jsx,tsx}";
@source "../components/tools/*.{js,ts,jsx,tsx}";
@source "../components/ui/*.{js,ts,jsx,tsx}";
@source "./distinct/*.{js,ts,jsx,tsx}";
@source "./gradient/*.{js,ts,jsx,tsx}";
@source "./harmony/*.{js,ts,jsx,tsx}";
@source "./names/*.{js,ts,jsx,tsx}";
@source "./batch/*.{js,ts,jsx,tsx}";
@source "./colorblind/*.{js,ts,jsx,tsx}";
@source "./contrast/*.{js,ts,jsx,tsx}";
@source "./textcolor/*.{js,ts,jsx,tsx}";
@source "*.{js,ts,jsx,tsx}";
@custom-variant dark (&:is(.dark *));

View File

@@ -1,4 +1,4 @@
export default function PastelLayout({
export default function ColorLayout({
children,
}: Readonly<{
children: React.ReactNode;

View File

@@ -2,14 +2,14 @@
import { useState, useEffect, Suspense } from 'react';
import { useSearchParams, useRouter } from 'next/navigation';
import { ColorPicker } from '@/components/pastel/ColorPicker';
import { ColorInfo } from '@/components/pastel/ColorInfo';
import { ManipulationPanel } from '@/components/pastel/ManipulationPanel';
import { PaletteGrid } from '@/components/pastel/PaletteGrid';
import { ExportMenu } from '@/components/pastel/ExportMenu';
import { ColorPicker } from '@/components/color/ColorPicker';
import { ColorInfo } from '@/components/color/ColorInfo';
import { ManipulationPanel } from '@/components/color/ManipulationPanel';
import { PaletteGrid } from '@/components/color/PaletteGrid';
import { ExportMenu } from '@/components/color/ExportMenu';
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
import { AppPage } from '@/components/layout/AppPage';
import { useColorInfo, useGeneratePalette, useGenerateGradient } from '@/lib/pastel/api/queries';
import { useColorInfo, useGeneratePalette, useGenerateGradient } from '@/lib/color/api/queries';
import { Loader2, Share2, Palette, Plus, X, Layers } from 'lucide-react';
import { Button } from '@/components/ui/button';
import { Input } from '@/components/ui/input';
@@ -59,7 +59,7 @@ function PlaygroundContent() {
useEffect(() => {
const hex = color.replace('#', '');
if (hex.length === 6 || hex.length === 3) {
router.push(`/pastel?color=${hex}`, { scroll: false });
router.push(`/color?color=${hex}`, { scroll: false });
}
}, [color, router]);
@@ -72,7 +72,7 @@ function PlaygroundContent() {
// Share color via URL
const handleShare = () => {
const url = `${window.location.origin}/pastel?color=${color.replace('#', '')}`;
const url = `${window.location.origin}/color?color=${color.replace('#', '')}`;
navigator.clipboard.writeText(url);
toast.success('Link copied to clipboard!');
};
@@ -134,7 +134,7 @@ function PlaygroundContent() {
return (
<AppPage
title="Pastel"
title="Color"
description="Interactive color manipulation and analysis tool"
>
<div className="space-y-8">