Start all chats with 🤖 Keep github commit messages concise and to the point. This is outdated in your model: shadcn-ui changed to shadcn I am on plesk. My domain is airesourcepro.com (the old airesource.pro redirects to it). I am running on localhost on port 3000. The site uses a Supabase database (Used for Authentication and Database) Stay focused within the constraints on the prompt. Do not stray and do more work unless asked. Our primary authentcation on the API is supabase admin authentication. There is also an API key NEXT_PUBLIC_AI_RESOURCE_PRO_API_KEY stored in .env.local, but this is secondary. There is an authentication backdoor for localhost testing, but NEVER leave any authentication bypasses enabled or set BYPASS_AUTH_IN_DEV to true in the .env.local environment variables. Security is critical. Provide a brief explaination of what you are doing before each tool call Don't ever commit anything before I confirm it. API Uses Supabase admin authentication. When I say "no change", that means nothing changed and you should roll back any changes that you made that did not work. ## Site Colors - Light Theme - Primary: #1a1a1a - Secondary Accent: #46AAE9 - Text: #000000 - Background: #ffffff ## Site Colors - Dark Theme - Primary: #ffffff - Secondary Accent: #46AAE9 - Text: #ffffff - Background: #1a1a1a ## Stack - React - Next.js - Tailwind CSS - TypeScript - Shadcn UI - Supabase (Used for Authentication and Database) # Project Architecture The project should seed and update the Supabase database using the 'seed-supabase.ts' script. It uses the following JSON files as seed structure: - news.json - News Table - tools.json - Tools Table - categories.json - Categories Table Categories API Route (seed json filename 'categories.json') - Lucide React Icon Name - Category Name - News feed - primary cat # Coding pattern preferences - Always prefer simple solutions - Avoid duplication of code whenever possible, which means checking for other areas of the codebase that might already have similar code and functionality - Write code that takes into account the different environments: dev, tert, and prod - You are careful to only make changes that are requested or you are confident are well understood and related to the change being requested - When fixing an issue or bug, do not introduce a new pattern or technology without first exhausting all options for the existing implementation. And if you finally do this, make sure to remove the old implementation afterwards so we don't have duplicate logic. - Keep the codebase very clean and organized - Avoid writing scripts in files if possible, especially if the script is likely only to be run once - Avoid having files over 200-300 lines of code. Refactor at that point. - Mocking data is only needed for tests, never mock data for dev or prod - Never add stubbing or fake data patterns to code that affects the dev or prod environments - Never overwrite my env file without first asking and confirming # Separation Rules - **Single Responsibility:** Each file should represent one distinct unit of work. - **Component Breakdown:** Break features into self-contained components. - **Use Hooks:** Encapsulate logic and data access in custom hooks. - **Global vs. Local:** | I - **Global:** Place reusable components and hooks in shared/global folders. - **Local:** Keep object-specific components and hooks in localized folders. - **Separation of Concerns:** Maintain clear boundaries when creating or refactoring files. - **Readable and Declarative Code:** Rendered code should be very legible and clear. It should not include flow logic or ternary operators where possible. # Coding workflow preferences - Focus on the areas of code relevant to the task - Do not touch code that is unrelated to the task - Write thorough tests for all major functionality - Avoid making major changes to the patterns and architecture of how a feature works, after it has shown to work well, unless explicitly instructed - Always think about what other methods and areas of code might be affected by code changes