diff --git a/docs/ADMIN_PAGES_GUIDE.md b/docs/ADMIN_PAGES_GUIDE.md new file mode 100644 index 0000000..d3e19e0 --- /dev/null +++ b/docs/ADMIN_PAGES_GUIDE.md @@ -0,0 +1,304 @@ +# ADMIN PAGES GUIDE: Spark Platform + +> **BLUF**: 25+ admin page directories, 66 admin page files. All routes prefixed with `/admin/`. + +--- + +## 1. Command Station + +### Main Dashboard + +| Path | File | Purpose | +|------|------|---------| +| `/admin` | `pages/admin/index.astro` | Mission Control overview | + +Components: `SystemMonitor.tsx`, `SystemStatusBar.tsx` + +Features: +- Sub-station status indicators +- API health monitoring +- Content integrity checks +- Quick actions + +--- + +## 2. Launchpad (Sites Module) + +### Site Management + +| Path | File | Purpose | +|------|------|---------| +| `/admin/sites` | `pages/admin/sites/index.astro` | Site list | +| `/admin/sites/[id]` | `pages/admin/sites/[id]/index.astro` | Site dashboard | +| `/admin/sites/edit` | `pages/admin/sites/edit.astro` | Site settings editor | +| `/admin/sites/jumpstart` | `pages/admin/sites/jumpstart.astro` | Quick setup wizard | +| `/admin/sites/import` | `pages/admin/sites/import.astro` | WordPress importer | +| `/admin/sites/editor/[id]` | `pages/admin/sites/editor/[id].astro` | Page block editor | + +Components: `SitesManager.tsx`, `SiteEditor.tsx`, `SiteDashboard.tsx`, `JumpstartWizard.tsx`, `WPImporter.tsx` + +--- + +## 3. Content Factory + +### Factory Dashboard + +| Path | File | Purpose | +|------|------|---------| +| `/admin/factory` | `pages/admin/factory/index.astro` | Kanban board | +| `/admin/factory/articles` | `pages/admin/factory/articles.astro` | Article workbench | +| `/admin/content-factory` | `pages/admin/content-factory.astro` | Simple generator | + +Components: `KanbanBoard.tsx`, `ArticleWorkbench.tsx`, `ContentFactoryDashboard.tsx` + +--- + +## 4. Intelligence Library + +### Intelligence Hub + +| Path | File | Purpose | +|------|------|---------| +| `/admin/intelligence` | `pages/admin/intelligence/index.astro` | Module overview | +| `/admin/intelligence/avatars` | `pages/admin/intelligence/avatars.astro` | Avatar manager | +| `/admin/intelligence/variants` | `pages/admin/intelligence/variants.astro` | Avatar variants | +| `/admin/intelligence/geo` | `pages/admin/intelligence/geo.astro` | Geo intelligence map | +| `/admin/intelligence/spintax` | `pages/admin/intelligence/spintax.astro` | Spintax dictionaries | +| `/admin/intelligence/patterns` | `pages/admin/intelligence/patterns.astro` | Cartesian patterns | + +Components: `AvatarIntelligenceManager.tsx`, `GeoIntelligenceManager.tsx`, `SpintaxManager.tsx`, `CartesianManager.tsx` + +--- + +## 5. SEO Engine + +### Campaign & Article Management + +| Path | File | Purpose | +|------|------|---------| +| `/admin/seo/campaigns` | `pages/admin/seo/campaigns.astro` | Campaign list | +| `/admin/seo/articles` | `pages/admin/seo/articles.astro` | Article management | +| `/admin/seo/headlines` | `pages/admin/seo/headlines.astro` | Headline inventory | +| `/admin/seo/fragments` | `pages/admin/seo/fragments.astro` | Content fragments | +| `/admin/seo/wizard` | `pages/admin/seo/wizard.astro` | Campaign wizard | + +Components: `CampaignWizard.tsx`, `ArticleList.tsx`, `HeadlineGenerator.tsx`, `FragmentsManager.tsx` + +--- + +## 6. Content Management + +### Pages & Posts + +| Path | File | Purpose | +|------|------|---------| +| `/admin/pages` | `pages/admin/pages/index.astro` | Pages list | +| `/admin/pages/edit/[id]` | `pages/admin/pages/edit/[id].astro` | Page editor | +| `/admin/posts` | `pages/admin/posts/index.astro` | Posts list | +| `/admin/posts/edit/[id]` | `pages/admin/posts/edit/[id].astro` | Post editor | +| `/admin/content/avatars` | `pages/admin/content/avatars.astro` | Legacy avatar content | +| `/admin/content/geo_clusters` | `pages/admin/content/geo_clusters.astro` | Legacy geo content | + +Components: `PageEditor.tsx`, `PostEditor.tsx`, `PageList.tsx`, `PostList.tsx` + +--- + +## 7. Collections (Generic CRUD) + +### Collection Manager + +| Path | File | Purpose | +|------|------|---------| +| `/admin/collections` | `pages/admin/collections/index.astro` | Collection browser | +| `/admin/collections/page-blocks` | `pages/admin/collections/page-blocks.astro` | Page blocks | +| `/admin/collections/offer-blocks` | `pages/admin/collections/offer-blocks.astro` | Offer templates | +| `/admin/collections/headline-inventory` | `pages/admin/collections/headline-inventory.astro` | Headlines | +| `/admin/collections/content-fragments` | `pages/admin/collections/content-fragments.astro` | Fragments | + +Components: `GenericCollectionManager.tsx` + +--- + +## 8. Analytics + +### Analytics Dashboard + +| Path | File | Purpose | +|------|------|---------| +| `/admin/analytics` | `pages/admin/analytics/index.astro` | Metrics overview | +| `/admin/analytics/events` | `pages/admin/analytics/events.astro` | Event log | +| `/admin/analytics/conversions` | `pages/admin/analytics/conversions.astro` | Conversion tracking | +| `/admin/analytics/pageviews` | `pages/admin/analytics/pageviews.astro` | Pageview data | + +Components: `MetricsDashboard.tsx`, `StatCard.tsx`, `ChartWidget.tsx` + +--- + +## 9. Leads + +### Lead Management + +| Path | File | Purpose | +|------|------|---------| +| `/admin/leads` | `pages/admin/leads/index.astro` | Leads list | +| `/admin/leads/[id]` | `pages/admin/leads/[id].astro` | Lead detail | + +Components: `LeadManager.tsx`, `LeadTable.tsx` + +--- + +## 10. Media + +### Asset Management + +| Path | File | Purpose | +|------|------|---------| +| `/admin/media` | `pages/admin/media/index.astro` | Media browser | +| `/admin/media/templates` | `pages/admin/media/templates.astro` | Image templates | + +Components: `ImageTemplateEditor.tsx` + +--- + +## 11. Locations + +### Geographic Data + +| Path | File | Purpose | +|------|------|---------| +| `/admin/locations` | `pages/admin/locations.astro` | Location browser | + +Components: `LocationBrowser.tsx` + +--- + +## 12. Scheduler + +### Content Scheduling + +| Path | File | Purpose | +|------|------|---------| +| `/admin/scheduler` | `pages/admin/scheduler/index.astro` | Calendar view | + +Components: `SchedulerCalendar.tsx` + +--- + +## 13. Assembler + +### Article Assembly + +| Path | File | Purpose | +|------|------|---------| +| `/admin/assembler` | `pages/admin/assembler/index.astro` | Assembly dashboard | +| `/admin/assembler/templates` | `pages/admin/assembler/templates.astro` | Template list | +| `/admin/assembler/preview` | `pages/admin/assembler/preview.astro` | Preview tool | + +Components: `AssemblerDashboard.tsx`, `TemplateList.tsx` + +--- + +## 14. Automations + +### Workflow Automation + +| Path | File | Purpose | +|------|------|---------| +| `/admin/automations` | `pages/admin/automations/index.astro` | Automation list | + +Components: `AutomationBuilder.tsx` + +--- + +## 15. System + +### System Administration + +| Path | File | Purpose | +|------|------|---------| +| `/admin/system` | `pages/admin/system/index.astro` | System overview | +| `/admin/system/work-log` | `pages/admin/system/work-log.astro` | Activity log | + +Components: `LogViewer.tsx`, `WorkLogViewer.tsx` + +--- + +## 16. Settings + +### Platform Configuration + +| Path | File | Purpose | +|------|------|---------| +| `/admin/settings` | `pages/admin/settings.astro` | Settings manager | + +Components: `SettingsManager.tsx` + +--- + +## 17. Testing + +### Diagnostics + +| Path | File | Purpose | +|------|------|---------| +| `/admin/testing` | `pages/admin/testing/index.astro` | Test suite | +| `/admin/testing/connection` | `pages/admin/testing/connection.astro` | API tests | +| `/admin/testing/schema` | `pages/admin/testing/schema.astro` | Schema validation | +| `/admin/testing/render` | `pages/admin/testing/render.astro` | Block render tests | +| `/admin/testing/results` | `pages/admin/testing/results.astro` | Test results | + +Components: `TestRunner.tsx`, `ConnectionTester.tsx`, `TestResults.tsx` + +--- + +## 18. Preview Routes + +| Path | File | Purpose | +|------|------|---------| +| `/preview/site/[id]` | `pages/preview/site/[id].astro` | Site preview | +| `/preview/page/[id]` | `pages/preview/page/[id].astro` | Page preview | +| `/preview/post/[id]` | `pages/preview/post/[id].astro` | Post preview | +| `/preview/article/[id]` | `pages/preview/article/[id].astro` | Article preview | + +--- + +## 19. Quick Reference Table + +| Module | Root Path | Page Count | +|--------|-----------|------------| +| Command Station | `/admin` | 1 | +| Launchpad | `/admin/sites/*` | 6 | +| Factory | `/admin/factory/*` | 4 | +| Intelligence | `/admin/intelligence/*` | 6 | +| SEO Engine | `/admin/seo/*` | 5 | +| Content | `/admin/pages/*`, `/admin/posts/*` | 6 | +| Collections | `/admin/collections/*` | 10 | +| Analytics | `/admin/analytics/*` | 4 | +| Leads | `/admin/leads/*` | 2 | +| Media | `/admin/media/*` | 1 | +| Locations | `/admin/locations` | 1 | +| Scheduler | `/admin/scheduler/*` | 1 | +| Assembler | `/admin/assembler/*` | 5 | +| Automations | `/admin/automations/*` | 1 | +| System | `/admin/system/*` | 1 | +| Settings | `/admin/settings` | 1 | +| Testing | `/admin/testing/*` | 5 | +| Preview | `/preview/*` | 4 | +| **Total** | | **66** | + +--- + +## 20. Access URLs + +### Production + +``` +https://spark.jumpstartscaling.com/admin +https://launch.jumpstartscaling.com/preview/... +``` + +### Local Development + +``` +http://localhost:4321/admin +``` diff --git a/docs/API_REFERENCE.md b/docs/API_REFERENCE.md new file mode 100644 index 0000000..51353cc --- /dev/null +++ b/docs/API_REFERENCE.md @@ -0,0 +1,565 @@ +# API REFERENCE: Spark Platform Endpoints + +> **BLUF**: 30+ API endpoints organized by module. Public endpoints require no auth. Admin endpoints require Bearer token. God-mode requires X-God-Token header. + +--- + +## 1. Authentication + +### Header Format + +``` +Authorization: Bearer +``` + +### God-Mode Header + +``` +X-God-Token: +``` + +--- + +## 2. Public Endpoints (No Auth Required) + +### 2.1 Lead Submission + +**POST** `/api/lead` + +Submit a lead form. + +| Field | Type | Required | Description | +|-------|------|----------|-------------| +| name | string | Yes | Contact name | +| email | string | Yes | Contact email | +| site_id | string | No | Originating site UUID | +| source | string | No | Lead source identifier | + +**Request:** +```json +{ + "name": "John Doe", + "email": "john@example.com", + "site_id": "uuid-here", + "source": "landing-page" +} +``` + +**Response:** `201 Created` +```json +{ + "success": true, + "id": "lead-uuid" +} +``` + +--- + +### 2.2 Form Submission + +**POST** `/api/forms/submit` + +Submit a generic form. + +| Field | Type | Required | Description | +|-------|------|----------|-------------| +| form_id | string | Yes | Form definition UUID | +| data | object | Yes | Form field values | + +**Request:** +```json +{ + "form_id": "form-uuid", + "data": { + "name": "Jane Doe", + "email": "jane@example.com", + "message": "Hello" + } +} +``` + +**Response:** `201 Created` +```json +{ + "success": true, + "submission_id": "submission-uuid" +} +``` + +--- + +### 2.3 Analytics Tracking + +**POST** `/api/track/pageview` + +Record a page view. + +| Field | Type | Description | +|-------|------|-------------| +| site_id | string | Site UUID | +| page_path | string | URL path | +| session_id | string | Anonymous session | + +**POST** `/api/track/event` + +Record a custom event. + +| Field | Type | Description | +|-------|------|-------------| +| site_id | string | Site UUID | +| event_name | string | Event identifier | +| page_path | string | URL path | + +**POST** `/api/track/conversion` + +Record a conversion. + +| Field | Type | Description | +|-------|------|-------------| +| site_id | string | Site UUID | +| lead_id | string | Lead UUID | +| conversion_type | string | Conversion category | +| value | number | Monetary value | + +--- + +## 3. SEO Engine Endpoints (Auth Required) + +### 3.1 Headline Generation + +**POST** `/api/seo/generate-headlines` + +Generate headline permutations from spintax. + +| Field | Type | Description | +|-------|------|-------------| +| campaign_id | string | Campaign UUID | +| spintax_root | string | Spintax template | +| limit | number | Max headlines (default: 1000) | + +**Request:** +```json +{ + "campaign_id": "campaign-uuid", + "spintax_root": "{Best|Top|Leading} {Dentist|Dental Clinic} in {City}", + "limit": 100 +} +``` + +**Response:** +```json +{ + "generated": 100, + "headlines": [ + "Best Dentist in Austin", + "Top Dental Clinic in Austin", + ... + ] +} +``` + +--- + +### 3.2 Article Generation + +**POST** `/api/seo/generate-article` + +Generate a single article. + +| Field | Type | Description | +|-------|------|-------------| +| campaign_id | string | Campaign UUID | +| headline | string | Article headline | +| location | object | {city, state, county} | +| avatar_id | string | Target avatar UUID | + +**Request:** +```json +{ + "campaign_id": "campaign-uuid", + "headline": "Best Dentist in Austin", + "location": { + "city": "Austin", + "state": "TX", + "county": "Travis" + }, + "avatar_id": "avatar-uuid" +} +``` + +**Response:** +```json +{ + "article_id": "article-uuid", + "title": "Best Dentist in Austin", + "content": "", + "meta_title": "Best Dentist in Austin, TX | YourBrand", + "meta_description": "Looking for..." +} +``` + +--- + +### 3.3 Batch Operations + +**GET** `/api/seo/articles` + +List generated articles. + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| site_id | string | Filter by site | +| campaign_id | string | Filter by campaign | +| status | string | Filter by status | +| limit | number | Results per page | +| offset | number | Pagination offset | + +**POST** `/api/seo/approve-batch` + +Approve multiple articles. + +| Field | Type | Description | +|-------|------|-------------| +| article_ids | string[] | Article UUIDs to approve | + +**POST** `/api/seo/publish-article` + +Publish a single article. + +| Field | Type | Description | +|-------|------|-------------| +| article_id | string | Article UUID | + +--- + +### 3.4 Content Processing + +**POST** `/api/seo/insert-links` + +Insert internal links into article content. + +| Field | Type | Description | +|-------|------|-------------| +| article_id | string | Article UUID | +| max_links | number | Maximum links to insert | +| min_distance | number | Minimum words between links | + +**POST** `/api/seo/scan-duplicates` + +Scan for duplicate content. + +| Field | Type | Description | +|-------|------|-------------| +| site_id | string | Site to scan | +| threshold | number | Similarity threshold (0-1) | + +--- + +### 3.5 Scheduling + +**POST** `/api/seo/schedule-production` + +Schedule article production. + +| Field | Type | Description | +|-------|------|-------------| +| campaign_id | string | Campaign UUID | +| target_count | number | Articles to generate | +| velocity_mode | string | RAMP_UP, STEADY, SPIKES | +| start_date | string | ISO date | + +**POST** `/api/seo/sitemap-drip` + +Update sitemap visibility. + +| Field | Type | Description | +|-------|------|-------------| +| site_id | string | Site UUID | +| batch_size | number | URLs per update | + +--- + +### 3.6 Queue + +**POST** `/api/seo/process-queue` + +Process pending queue items. + +| Field | Type | Description | +|-------|------|-------------| +| limit | number | Items to process | +| priority | string | Filter by priority | + +**GET** `/api/seo/stats` + +Get SEO statistics. + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| site_id | string | Filter by site | +| campaign_id | string | Filter by campaign | + +--- + +## 4. Location Endpoints (Auth Required) + +### 4.1 States + +**GET** `/api/locations/states` + +List all US states. + +**Response:** +```json +[ + { "id": "uuid", "name": "Texas", "code": "TX" }, + { "id": "uuid", "name": "California", "code": "CA" }, + ... +] +``` + +### 4.2 Counties + +**GET** `/api/locations/counties` + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| state | string | State UUID or code | + +### 4.3 Cities + +**GET** `/api/locations/cities` + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| county | string | County UUID | +| limit | number | Results (default: 50) | + +--- + +## 5. Campaign Endpoints (Auth Required) + +### 5.1 Campaigns CRUD + +**GET** `/api/campaigns` + +List campaigns. + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| site_id | string | Filter by site | +| status | string | Filter by status | + +**POST** `/api/campaigns` + +Create campaign. + +| Field | Type | Description | +|-------|------|-------------| +| site_id | string | Site UUID | +| name | string | Campaign name | +| headline_spintax_root | string | Spintax template | +| target_word_count | number | Word count target | +| location_mode | string | city, county, state | + +--- + +## 6. Admin Endpoints (Auth Required) + +### 6.1 Import + +**POST** `/api/admin/import-blueprint` + +Import site from external source. + +| Field | Type | Description | +|-------|------|-------------| +| source_url | string | WordPress URL | +| site_name | string | New site name | +| import_pages | boolean | Include pages | +| import_posts | boolean | Include posts | + +### 6.2 Work Log + +**GET** `/api/admin/worklog` + +Get system activity log. + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| limit | number | Results per page | +| level | string | Filter by level | +| entity_type | string | Filter by entity | + +### 6.3 Queue Status + +**GET** `/api/admin/queues` + +Get queue status. + +**Response:** +```json +{ + "pending": 42, + "processing": 5, + "completed_today": 150, + "failed_today": 3 +} +``` + +--- + +## 7. Analytics Endpoints (Auth Required) + +### 7.1 Dashboard + +**GET** `/api/analytics/dashboard` + +Get analytics summary. + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| site_id | string | Site UUID | +| start_date | string | ISO date | +| end_date | string | ISO date | + +**Response:** +```json +{ + "pageviews": 1234, + "unique_sessions": 567, + "events": 89, + "conversions": 12, + "top_pages": [...], + "trend": [...] +} +``` + +--- + +## 8. Intelligence Endpoints (Auth Required) + +### 8.1 Patterns + +**GET** `/api/intelligence/patterns` + +Get Cartesian patterns. + +Query Parameters: +| Param | Type | Description | +|-------|------|-------------| +| category | string | Filter by category | + +--- + +## 9. Media Endpoints (Auth Required) + +### 9.1 Templates + +**GET** `/api/media/templates` + +List image templates. + +**POST** `/api/media/templates` + +Create image template. + +| Field | Type | Description | +|-------|------|-------------| +| name | string | Template name | +| svg_content | string | SVG markup | +| variables | object | Token definitions | + +--- + +## 10. Assembler Endpoints (Auth Required) + +### 10.1 Preview + +**POST** `/api/assembler/preview` + +Preview assembled article. + +| Field | Type | Description | +|-------|------|-------------| +| template_id | string | Template UUID | +| variables | object | Token values | + +### 10.2 Templates + +**GET** `/api/assembler/templates` + +List assembly templates. + +--- + +## 11. Factory Endpoints (Auth Required) + +### 11.1 Send to Factory + +**POST** `/api/factory/send-to-factory` + +Queue content for processing. + +| Field | Type | Description | +|-------|------|-------------| +| source | string | wordpress, manual | +| source_id | string | Source item ID | +| target_site_id | string | Destination site | + +--- + +## 12. God-Mode Endpoints (Elevated Auth) + +### 12.1 Schema Operations + +**POST** `/god/schema/collections/create` + +Create new collection. + +**POST** `/god/schema/relations/create` + +Create new relation. + +**GET** `/god/schema/snapshot` + +Export full schema YAML. + +### 12.2 Data Operations + +**POST** `/god/data/bulk-insert` + +Insert multiple records. + +| Field | Type | Description | +|-------|------|-------------| +| collection | string | Target collection | +| items | object[] | Records to insert | + +--- + +## 13. Error Responses + +| Status | Meaning | +|--------|---------| +| 400 | Bad Request - invalid input | +| 401 | Unauthorized - missing/invalid token | +| 403 | Forbidden - insufficient permissions | +| 404 | Not Found - resource doesn't exist | +| 500 | Server Error - internal failure | + +**Error Format:** +```json +{ + "error": true, + "message": "Description of error", + "code": "ERROR_CODE" +} +``` diff --git a/docs/COMPONENT_LIBRARY.md b/docs/COMPONENT_LIBRARY.md new file mode 100644 index 0000000..e0a425c --- /dev/null +++ b/docs/COMPONENT_LIBRARY.md @@ -0,0 +1,325 @@ +# COMPONENT LIBRARY: Spark Platform UI Catalog + +> **BLUF**: 182 React components in 14 directories. Admin (95 files), Blocks (25 files), UI (18 files). + +--- + +## 1. Component Organization + +``` +frontend/src/components/ +├── admin/ # 95 files - Dashboard components +├── analytics/ # 4 files - Analytics widgets +├── assembler/ # 8 files - Article assembly +├── automations/ # 1 file - Workflow automation +├── blocks/ # 25 files - Page builder blocks +├── collections/ # 1 file - Generic collection UI +├── debug/ # 1 file - Debug utilities +├── engine/ # 4 files - Rendering engine +├── factory/ # 9 files - Content Factory +├── intelligence/ # 7 files - Intelligence Library +├── layout/ # 1 file - Layout components +├── providers/ # 1 file - React providers +├── testing/ # 7 files - Test utilities +└── ui/ # 18 files - Shadcn primitives +``` + +--- + +## 2. Admin Components + +Location: `frontend/src/components/admin/` + +### 2.1 Intelligence Managers + +| Component | File | Purpose | +|-----------|------|---------| +| AvatarIntelligenceManager | `intelligence/AvatarIntelligenceManager.tsx` | Avatar CRUD + stats | +| GeoIntelligenceManager | `intelligence/GeoIntelligenceManager.tsx` | Map + location CRUD | +| SpintaxManager | `intelligence/SpintaxManager.tsx` | Dictionary editor | +| CartesianManager | `intelligence/CartesianManager.tsx` | Pattern builder | +| PatternAnalyzer | `intelligence/PatternAnalyzer.tsx` | Pattern testing | +| OfferBlocksManager | `intelligence/OfferBlocksManager.tsx` | Offer template CRUD | +| IntelligenceDashboard | `intelligence/IntelligenceDashboard.tsx` | Module overview | + +### 2.2 Factory Components + +| Component | File | Purpose | +|-----------|------|---------| +| KanbanBoard | `factory/KanbanBoard.tsx` | Drag-drop workflow | +| ArticleWorkbench | `factory/ArticleWorkbench.tsx` | Article editing | +| BulkGrid | `factory/BulkGrid.tsx` | Multi-select operations | +| JobsMonitor | `factory/JobsMonitor.tsx` | Queue status | +| SendToFactoryButton | `factory/SendToFactoryButton.tsx` | Factory trigger | + +### 2.3 SEO Components + +| Component | File | Purpose | +|-----------|------|---------| +| CampaignWizard | `seo/CampaignWizard.tsx` | Campaign creation wizard | +| ArticleList | `seo/ArticleList.tsx` | Article table | +| HeadlineGenerator | `seo/HeadlineGenerator.tsx` | Headline permutation UI | +| FragmentsManager | `seo/FragmentsManager.tsx` | Fragment CRUD | +| ArticleEditor | `seo/ArticleEditor.tsx` | Single article edit | +| ArticlePreview | `seo/ArticlePreview.tsx` | Preview renderer | + +### 2.4 Sites Components + +| Component | File | Purpose | +|-----------|------|---------| +| SitesManager | `sites/SitesManager.tsx` | Site list + actions | +| SiteEditor | `sites/SiteEditor.tsx` | Site settings | +| SiteDashboard | `sites/SiteDashboard.tsx` | Site overview | +| PagesList | `sites/PagesList.tsx` | Page management | +| NavigationEditor | `sites/NavigationEditor.tsx` | Menu builder | +| ThemeSettings | `sites/ThemeSettings.tsx` | Theme configuration | + +### 2.5 Content Components + +| Component | File | Purpose | +|-----------|------|---------| +| PageEditor | `content/PageEditor.tsx` | Block-based editor | +| PostEditor | `content/PostEditor.tsx` | Blog post editor | +| ContentFactoryDashboard | `content/ContentFactoryDashboard.tsx` | Factory overview | +| VisualBlockEditor | `content/VisualBlockEditor.tsx` | Visual editor | + +### 2.6 System Components + +| Component | File | Purpose | +|-----------|------|---------| +| SystemMonitor | `system/SystemMonitor.tsx` | Health dashboard | +| SystemStatusBar | `system/SystemStatusBar.tsx` | Status indicator | +| SettingsManager | `SettingsManager.tsx` | Platform settings | +| LogViewer | `system/LogViewer.tsx` | Work log viewer | +| WPImporter | `import/WPImporter.tsx` | WordPress import | +| JumpstartWizard | `jumpstart/JumpstartWizard.tsx` | Quick site setup | + +### 2.7 Testing Components + +| Component | File | Purpose | +|-----------|------|---------| +| TestRunner | `testing/TestRunner.tsx` | Test executor | +| TestResults | `testing/TestResults.tsx` | Results display | +| ConnectionTester | `testing/ConnectionTester.tsx` | API tests | + +--- + +## 3. Block Components + +Location: `frontend/src/components/blocks/` + +### Page Builder Blocks + +| Block | File | Description | +|-------|------|-------------| +| HeroBlock | `HeroBlock.tsx` | Full-width header with CTA | +| RichTextBlock | `RichTextBlock.tsx` | SEO-optimized prose | +| ColumnsBlock | `ColumnsBlock.tsx` | Multi-column layout | +| MediaBlock | `MediaBlock.tsx` | Image/video with caption | +| StepsBlock | `StepsBlock.tsx` | Numbered process | +| QuoteBlock | `QuoteBlock.tsx` | Testimonial/blockquote | +| GalleryBlock | `GalleryBlock.tsx` | Image grid | +| FAQBlock | `FAQBlock.tsx` | Accordion with schema.org | +| PostsBlock | `PostsBlock.tsx` | Blog listing | +| FormBlock | `FormBlock.tsx` | Lead capture form | +| CTABlock | `CTABlock.tsx` | Call-to-action | +| MapBlock | `MapBlock.tsx` | Embedded map | +| CardBlock | `CardBlock.tsx` | Card layout | +| DividerBlock | `DividerBlock.tsx` | Section separator | +| SpacerBlock | `SpacerBlock.tsx` | Vertical spacing | +| HeaderBlock | `HeaderBlock.tsx` | Section header | +| ListBlock | `ListBlock.tsx` | Bullet/numbered list | +| TableBlock | `TableBlock.tsx` | Data table | +| CodeBlock | `CodeBlock.tsx` | Code snippet | +| EmbedBlock | `EmbedBlock.tsx` | External embed | + +### Block Renderer + +| Component | File | Purpose | +|-----------|------|---------| +| BlockRenderer | `engine/BlockRenderer.tsx` | JSON → component mapper | +| BlockWrapper | `engine/BlockWrapper.tsx` | Styling container | + +--- + +## 4. UI Components (Shadcn-style) + +Location: `frontend/src/components/ui/` + +### Form Controls + +| Component | File | Usage | +|-----------|------|-------| +| Button | `button.tsx` | `