--- name: docs description: Generate or update documentation for Terrae components argument-hint: [component-name] --- # Docs Skill Generate or update documentation for Terrae components. ## Reference Use `src/app/docs/lines-animated/page.tsx` as the reference for component documentation structure and patterns. ## Instructions 1. **Determine Documentation Type** Ask the user what they need: - Component documentation page - Weeklog entry - README update - API reference 2. **For Component Documentation** Location: `src/app/docs/{component-name}/page.tsx` Examples Location: `src/app/docs/_components/examples/{example-name}.tsx` Structure: - Title and description (in DocsLayout) - Installation section - First example (directly after installation, NO title/description) - Additional examples (each with DocsSection title and description) - Animation Modes or similar feature explanations (if applicable) - Properties table - Use Cases grid (exactly 2 use cases, not more) - Performance Tips 3. **Example Component Patterns** - Use `h-full w-full` for the container div (NOT fixed heights like `h-[400px]`) - The ComponentPreview wrapper handles sizing - Always get accessToken from environment variable - Example structure: ```tsx export const ExampleName = () => { const accessToken = process.env.NEXT_PUBLIC_MAPBOX_ACCESS_TOKEN || "" return (