@@ -925,176 +315,48 @@ The router includes automatic scroll-to-top functionality and a 404 NotFound pag
```
-### Empty States and No Content Found
-
-When no content is found (empty search results, no data available, etc.), display a minimalist empty state with helpful messaging. The application uses NIP-65 relay management, so users can manage their relays through the settings or relay management interface.
+For empty results, show a minimalist empty state in a `border-dashed` card:
```tsx
-import { Card, CardContent } from '@/components/ui/card';
-
-// Empty state example
-
-
-
-
-
- No results found. Try checking your relay connections or wait a moment for content to load.
-
-
-
-
-
+
+
+
+ No results found. Try checking your relay connections or wait a moment for content to load.
+
+
+
```
-## CRITICAL Design Standards
+## Design Standards
-- Create breathtaking, immersive designs that feel like bespoke masterpieces, rivaling the polish of Apple, Stripe, or luxury brands
-- Designs must be production-ready, fully featured, with no placeholders unless explicitly requested, ensuring every element serves a functional and aesthetic purpose
-- Avoid generic or templated aesthetics at all costs; every design must have a unique, brand-specific visual signature that feels custom-crafted
-- Headers must be dynamic, immersive, and storytelling-driven, using layered visuals, motion, and symbolic elements to reflect the brand’s identity—never use simple “icon and text” combos
-- Incorporate purposeful, lightweight animations for scroll reveals, micro-interactions (e.g., hover, click, transitions), and section transitions to create a sense of delight and fluidity
+Designs should be polished and production-ready. Concrete rules:
-### Design Principles
+- **Responsive** down to ~360px; test mobile, tablet, desktop.
+- **WCAG 2.1 AA**: ≥ 4.5:1 contrast for body text, ≥ 3:1 for large text and UI elements. Full keyboard nav, ARIA labels, visible `focus-visible` rings.
+- **8px grid** for spacing (Tailwind's 4-based scale). Don't sprinkle `p-[13px]`-style one-offs.
+- **Typography hierarchy**: ≥ 18px body, ≥ 40px primary headlines. Prefer a modern sans (e.g. Inter) for UI and pair a display/serif for headings when personality is needed.
+- **Depth**: soft shadows, gentle gradients, rounded corners (`rounded-lg` / `rounded-xl`). Avoid heavy drop shadows.
+- **Motion**: lightweight, purposeful (hover, scroll reveals, transitions). Respect `prefers-reduced-motion` with Tailwind's `motion-safe:` / `motion-reduce:` variants.
+- **Reusable components**: consistent variants and feedback states (`hover`, `focus-visible`, `active`, `disabled`, `aria-invalid`). Use `cn()` for conditional classes and `class-variance-authority` for variants (copy an existing `ui/` component as a template).
+- **Custom over generic**: avoid template-looking headers — combine layered visuals, subtle motion, and brand colors. Generate custom images with available tools before reaching for stock.
-- Achieve Apple-level refinement with meticulous attention to detail, ensuring designs evoke strong emotions (e.g., wonder, inspiration, energy) through color, motion, and composition
-- Deliver fully functional interactive components with intuitive feedback states, ensuring every element has a clear purpose and enhances user engagement
-- **Generate custom images liberally** when image generation tools are available - this is ALWAYS preferred over stock photography for creating unique, brand-specific visuals that perfectly match the design intent
-- Ensure designs feel alive and modern with dynamic elements like gradients, glows, or parallax effects, avoiding static or flat aesthetics
-- Before finalizing, ask: "Would this design make Apple or Stripe designers pause and take notice?" If not, iterate until it does
+For font installation, color-scheme changes, light/dark theming, or the `isolate` + negative-z-index gotcha, load the **`theming`** skill.
-### Avoid Generic Design
+## Writing Tests vs. Running Tests
-- No basic layouts (e.g., text-on-left, image-on-right) without significant custom polish, such as dynamic backgrounds, layered visuals, or interactive elements
-- No simplistic headers; they must be immersive, animated, and reflective of the brand’s core identity and mission
-- No designs that could be mistaken for free templates or overused patterns; every element must feel intentional and tailored
+**Writing (creating new test files) — don't, unless asked.** Only create new tests when:
-### Interaction Patterns
+1. The user explicitly asks for tests.
+2. The user describes a specific bug and asks for tests to diagnose it.
+3. The user says a problem persists after you tried to fix it.
-- Use progressive disclosure for complex forms or content to guide users intuitively and reduce cognitive load
-- Incorporate contextual menus, smart tooltips, and visual cues to enhance navigation and usability
-- Implement drag-and-drop, hover effects, and transitions with clear, dynamic visual feedback to elevate the user experience
-- Support power users with keyboard shortcuts, ARIA labels, and focus states for accessibility and efficiency
-- Add subtle parallax effects or scroll-triggered animations to create depth and engagement without overwhelming the user
+Never write tests because tool results show failures, because you think tests would be helpful, or because you added a new feature.
-### Technical Requirements
-
-- Curated color FRpalette (3-5 evocative colors + neutrals) that aligns with the brand’s emotional tone and creates a memorable impact
-- Ensure a minimum 4.5:1 contrast ratio for all text and interactive elements to meet accessibility standards
-- Use expressive, readable fonts (18px+ for body text, 40px+ for headlines) with a clear hierarchy; pair a modern sans-serif (e.g., Inter) with an elegant serif (e.g., Playfair Display) for personality
-- Design for full responsiveness, ensuring flawless performance and aesthetics across all screen sizes (mobile, tablet, desktop)
-- Adhere to WCAG 2.1 AA guidelines, including keyboard navigation, screen reader support, and reduced motion options
-- Follow an 8px grid system for consistent spacing, padding, and alignment to ensure visual harmony
-- Add depth with subtle shadows, gradients, glows, and rounded corners (e.g., 16px radius) to create a polished, modern aesthetic
-- Optimize animations and interactions to be lightweight and performant, ensuring smooth experiences across devices
-
-### Components
-
-- Design reusable, modular components with consistent styling, behavior, and feedback states (e.g., hover, active, focus, error)
-- Include purposeful animations (e.g., scale-up on hover, fade-in on scroll) to guide attention and enhance interactivity without distraction
-- Ensure full accessibility support with keyboard navigation, ARIA labels, and visible focus states (e.g., a glowing outline in an accent color)
-- Use custom icons or illustrations for components to reinforce the brand’s visual identity
-
-### Adding Fonts
-
-To add custom fonts, follow these steps:
-
-1. **Install a font package** using npm:
-
- **Any Google Font can be installed** using the @fontsource packages. Examples:
- - For Inter Variable: `@fontsource-variable/inter`
- - For Roboto: `@fontsource/roboto`
- - For Outfit Variable: `@fontsource-variable/outfit`
- - For Poppins: `@fontsource/poppins`
- - For Open Sans: `@fontsource/open-sans`
-
- **Format**: `@fontsource/[font-name]` or `@fontsource-variable/[font-name]` (for variable fonts)
-
-2. **Import the font** in `src/main.tsx`:
- ```typescript
- import '@fontsource-variable/
';
- ```
-
-3. **Update Tailwind configuration** in `tailwind.config.ts`:
- ```typescript
- export default {
- theme: {
- extend: {
- fontFamily: {
- sans: ['Inter Variable', 'Inter', 'system-ui', 'sans-serif'],
- },
- },
- },
- }
- ```
-
-### Recommended Font Choices by Use Case
-
-- **Modern/Clean**: Inter Variable, Outfit Variable, or Manrope
-- **Professional/Corporate**: Roboto, Open Sans, or Source Sans Pro
-- **Creative/Artistic**: Poppins, Nunito, or Comfortaa
-- **Technical/Code**: JetBrains Mono, Fira Code, or Source Code Pro (for monospace)
-
-### Theme System
-
-The project includes a complete light/dark theme system using CSS custom properties. The theme can be controlled via:
-
-- `useTheme` hook for programmatic theme switching
-- CSS custom properties defined in `src/index.css`
-- Automatic dark mode support with `.dark` class
-
-### Color Scheme Implementation
-
-When users specify color schemes:
-- Update CSS custom properties in `src/index.css` (both `:root` and `.dark` selectors)
-- Use Tailwind's color palette or define custom colors
-- Ensure proper contrast ratios for accessibility
-- Apply colors consistently across components (buttons, links, accents)
-- Test both light and dark mode variants
-
-### Component Styling Patterns
-
-- Use `cn()` utility for conditional class merging
-- Follow shadcn/ui patterns for component variants
-- Implement responsive design with Tailwind breakpoints
-- Add hover and focus states for interactive elements
-- When using negative z-index (e.g., `-z-10`) for background images or decorative elements, **always add `isolate` to the parent container** to create a local stacking context. Without `isolate`, negative z-index pushes elements behind the page's background color, making them invisible.
-
-## Writing Tests vs Running Tests
-
-There is an important distinction between **writing new tests** and **running existing tests**:
-
-### Writing Tests (Creating New Test Files)
-
-**Do not write tests** unless the user explicitly requests them in plain language. Writing unnecessary tests wastes significant time and money. Only create tests when:
-
-1. **The user explicitly asks for tests** to be written in their message
-2. **The user describes a specific bug in plain language** and requests tests to help diagnose it
-3. **The user says they are still experiencing a problem** that you have already attempted to solve (tests can help verify the fix)
-
-**Never write tests because:**
-- Tool results show test failures (these are not user requests)
-- You think tests would be helpful
-- New features or components are created
-- Existing functionality needs verification
-
-### Running Tests (Executing the Test Suite)
-
-**ALWAYS run the test script** after making any code changes. This is mandatory regardless of whether you wrote new tests or not.
-
-- **You must run the test script** to validate your changes
-- **Your task is not complete** until the test script passes without errors
-- **This applies to all changes** - bug fixes, new features, refactoring, or any code modifications
-- **The test script includes** TypeScript compilation, ESLint checks, and existing test validation
+**Running the existing test script — always do it.** After any code change, run the project's test/validation script. **Your task is not complete until it passes.** The script typically covers TypeScript compilation, ESLint, and existing tests.
### Test Setup
-The project uses Vitest with jsdom environment and includes comprehensive test setup:
-
-- **Testing Library**: React Testing Library with jest-dom matchers
-- **Test Environment**: jsdom with mocked browser APIs (matchMedia, scrollTo, IntersectionObserver, ResizeObserver)
-- **Test App**: `TestApp` component provides all necessary context providers for testing
-
-The project includes a `TestApp` component that provides all necessary context providers for testing. Wrap components with this component to provide required context providers:
+Vitest + jsdom, with React Testing Library and jest-dom matchers. Mocked browser APIs: `matchMedia`, `scrollTo`, `IntersectionObserver`, `ResizeObserver`. Wrap components in `TestApp` to provide context providers:
```tsx
import { describe, it, expect } from 'vitest';
@@ -1104,12 +366,7 @@ import { MyComponent } from './MyComponent';
describe('MyComponent', () => {
it('renders correctly', () => {
- render(
-
-
-
- );
-
+ render();
expect(screen.getByText('Expected text')).toBeInTheDocument();
});
});
@@ -1117,32 +374,36 @@ describe('MyComponent', () => {
## Validating Your Changes
-**CRITICAL**: After making any code changes, you must validate your work by running available validation tools.
+**Your task is not finished until the code type-checks and builds without errors.** In priority order:
-**Your task is not considered finished until the code successfully type-checks and builds without errors.**
-
-### Validation Priority Order
-
-Run available tools in this priority order:
-
-1. **Type Checking** (Required): Ensure TypeScript compilation succeeds
-2. **Building/Compilation** (Required): Verify the project builds successfully
-3. **Linting** (Recommended): Check code style and catch potential issues
-4. **Tests** (If Available): Run existing test suite
-5. **Git Commit** (Required): Create a commit with your changes when finished
-
-**Minimum Requirements:**
-- Code must type-check without errors
-- Code must build/compile successfully
-- Fix any critical linting errors that would break functionality
-- Create a git commit when your changes are complete
-
-The validation ensures code quality and catches errors before deployment, regardless of the development environment.
+1. **Type check** (required)
+2. **Build/compile** (required)
+3. **Lint** (recommended; fix anything critical)
+4. **Run tests** (if available)
+5. **Git commit** (required)
### Using Git
-If git is available in your environment (through a `shell` tool, or other git-specific tools), you should utilize `git log` to understand project history. Use `git status` and `git diff` to check the status of your changes, and if you make a mistake use `git checkout` to restore files.
+Use `git status` / `git diff` to review changes and `git log` to learn project conventions. If you make a mistake, `git checkout` restores files.
-When your changes are complete and validated, create a git commit with a descriptive message summarizing your changes.
+**Always commit when you are finished.** Non-negotiable — every completed task ends with a commit. Don't wait for the user to ask.
-**ALWAYS commit when you are finished making changes. This is non-negotiable -- every completed task must end with a git commit. Never leave uncommitted changes. Do not wait for the user to ask; committing is part of completing the task.**
\ No newline at end of file
+## Specialized Skills
+
+Load via the `skill` tool when the task matches:
+
+- **`ai-chat`** — AI chat UIs, streaming, Shakespeare AI integration.
+- **`capacitor`** — wrap the app as a native iOS/Android app (haptics, share sheet, Keychain/KeyStore, deep links, safe-area CSS).
+- **`edit-profile`** — drop-in form for editing kind-0 profile metadata.
+- **`file-uploads`** — Blossom file upload + NIP-94 imeta tags for attaching media to events.
+- **`nip19-routing`** — populate `NIP19Page`, build NIP-19 links, secure filters for addressable events.
+- **`nip85-stats`** — NIP-85 Trusted Assertion hooks for follower counts, reactions, zaps, and other engagement stats.
+- **`nostr-comments`** — comment systems for any Nostr event or NIP-73 external identifier.
+- **`nostr-encryption`** — NIP-44 / NIP-04 via the user's signer (DMs, private notes).
+- **`nostr-infinite-scroll`** — paginated feeds for Nostr events.
+- **`nostr-relay-pools`** — `nostr.relay(url)` / `nostr.group([urls])` for targeted relay calls.
+- **`note-content`** — render kind 1/11/1111 content (links, hashtags, mentions, emoji, media, invoices, embeds).
+- **`nwc`** — Nostr Wallet Connect, WebLN, Lightning zaps (NIP-57).
+- **`plausible-analytics`** — Plausible tracking wired through `AppConfig`.
+- **`relay-management`** — settings UI for editing the user's NIP-65 relay list.
+- **`theming`** — fonts (@fontsource), color schemes, light/dark, component styling patterns.