Product Roadmap Builder
Run ID: 69caeaf6c8ebe3066ba6f7152026-03-30Business
PantheraHive BOS
BOS Dashboard

Build a strategic product roadmap with feature prioritization, milestone planning, resource allocation, risk assessment, and stakeholder communication plan.

Product Roadmap Builder: Research & Design Requirements

This document outlines the comprehensive design specifications, wireframe descriptions, color palettes, and user experience (UX) recommendations for the "Product Roadmap Builder" tool. This foundational design will ensure a robust, intuitive, and highly functional platform for strategic product planning.


1. Detailed Design Specifications

The Product Roadmap Builder will be designed as a modular, integrated platform, enabling users to manage all aspects of product strategy from conception to delivery.

1.1 Core Modules & Functionalities

  1. Roadmap Management Module:

* Create/Manage Roadmaps:

* Fields: Roadmap Name, Description, Owner, Stakeholders, Start Date, End Date, Status (Draft, Active, Archived), Type (Strategic, Release, Feature, Portfolio).

* Functionality: Create new roadmaps, edit existing, duplicate, delete, search, filter.

* Roadmap Views:

* Timeline View: Visual representation of features/initiatives over time with milestones.

* Kanban/Board View: Card-based view for status tracking (e.g., Backlog, In Progress, Done).

* List View: Detailed tabular view for filtering and bulk actions.

* Swimlane View: Grouping by teams, products, or strategic themes.

  1. Feature & Initiative Management Module:

* Create/Manage Features/Initiatives:

* Fields: Name, Unique ID, Description, Status (Planned, In Progress, Completed, On Hold, Canceled), Priority (High, Medium, Low, Critical), Strategic Theme Alignment, Product Area, Owner, Contributors, Estimated Effort (e.g., Story Points, T-shirt Size), Start Date, Due Date, Dependencies (pre-requisites, blockers), Acceptance Criteria, Linked Documents/Attachments.

* Functionality: CRUD operations, bulk editing, linking to epics/user stories (if integrated with development tools).

* Categorization & Tagging: Customizable tags for filtering and organization (e.g., by customer segment, technology, risk level).

  1. Prioritization Engine Module:

* Prioritization Frameworks:

* Configurable Templates: RICE (Reach, Impact, Confidence, Effort), WSJF (Weighted Shortest Job First), MoSCoW (Must, Should, Could, Won't), Value vs. Effort Matrix.

* Customizable Scoring: Ability to define custom criteria and weighting.

* Visualization: Interactive matrix views (e.g., 2x2 grid for Value vs. Effort), ranked lists.

* Automated Scoring: Calculation based on user input for selected framework.

  1. Milestone & Release Planning Module:

* Create/Manage Milestones:

* Fields: Milestone Name, Description, Date, Status (Planned, Achieved, Missed), Associated Features/Deliverables.

* Functionality: Link milestones to specific roadmap items or releases.

* Release Management:

* Fields: Release Name, Version, Target Date, Scope (linked features), Status.

* Functionality: Group features into planned releases.

  1. Resource Allocation & Capacity Planning Module:

* Team/Resource Management:

* Fields: Team Name, Members, Roles, Availability (e.g., FTE, % allocation).

* Functionality: Assign features/initiatives to teams or individuals.

* Capacity View: Visual representation of team workload against capacity, highlighting over/under-allocation.

* Effort Tracking: Integration potential with project management tools for actual vs. estimated effort.

  1. Risk Assessment & Management Module:

* Identify Risks:

* Fields: Risk Name, Description, Category (Technical, Market, Resource, Financial), Likelihood (High, Medium, Low), Impact (High, Medium, Low), Mitigation Strategy, Owner, Status.

* Risk Matrix: Visualization of risks based on likelihood and impact.

* Mitigation Tracking: Ability to assign and track mitigation tasks.

  1. Stakeholder Communication & Collaboration Module:

* Comment & Discussion: Inline comments on features/roadmaps.

* Notifications: Real-time updates on changes, assignments, deadlines.

* Sharing & Permissions: Configurable access levels (Viewer, Editor, Admin) for roadmaps and features.

* Export Options: PDF, CSV, Image (for timeline views).

* Presentation Mode: Clean, focused view for presenting roadmaps to stakeholders.

  1. Reporting & Analytics Module:

* Pre-built Reports: Roadmap Progress, Feature Velocity, Risk Exposure, Resource Utilization.

* Custom Report Builder: Drag-and-drop interface for creating custom reports.

* Dashboards: Customizable widgets displaying key metrics (e.g., % completion by theme, top risks, upcoming milestones).

1.2 Data Model Considerations (Simplified)

  • Roadmap: ID, Name, Description, OwnerID, StartDate, EndDate, Status, Type
  • Feature/Initiative: ID, RoadmapID, Name, Description, Status, Priority, ThemeID, ProductAreaID, OwnerID, EstimatedEffort, StartDate, DueDate, Dependencies[], AcceptanceCriteria, Tags[]
  • Milestone: ID, RoadmapID, Name, Date, Status, Description, LinkedFeatures[]
  • Release: ID, RoadmapID, Name, Version, TargetDate, Status, ScopeFeatures[]
  • StrategicTheme: ID, Name, Description
  • User: ID, Name, Email, Role, Permissions[]
  • Team: ID, Name, Members[]
  • Risk: ID, RoadmapID, FeatureID, Name, Description, Category, Likelihood, Impact, MitigationStrategy, OwnerID, Status
  • PrioritizationScore: FeatureID, Framework, CriteriaScores[], TotalScore

2. Wireframe Descriptions

Below are descriptions for key screens, focusing on layout and primary interactive elements.

2.1 Dashboard / Roadmap Overview

  • Layout:

* Top Navigation Bar: Logo, Search, User Profile/Settings, Notifications.

* Left Sidebar: Main navigation (Dashboard, Roadmaps, Features, Teams, Reports, Settings).

* Main Content Area (Grid/Card Layout):

* "My Roadmaps" Section: Displays cards for recently accessed or favorite roadmaps. Each card shows Roadmap Name, Status, Progress Bar, Owner, and quick actions (View, Edit, Share).

* "Upcoming Milestones" Widget: List of 3-5 nearest milestones across all active roadmaps, with date and associated roadmap.

* "Key Metrics / Alerts" Widget: Customizable widgets showing overall progress, high-priority features needing attention, or critical risks.

* "Quick Actions" Section: Buttons for "Create New Roadmap," "Add New Feature."

  • Key Elements: Search bar, filter options for roadmaps, progress indicators, quick action buttons.

2.2 Feature Details / Creation Screen

  • Layout:

* Top Header: Feature Name (editable), Status dropdown, Priority dropdown, "Save" / "Cancel" buttons, "Delete" button.

* Main Content Area (Two Columns):

* Left Column (Core Details):

* Section 1: Basic Info: Feature Name (large input), Description (rich text editor), Associated Roadmap (dropdown), Strategic Theme (dropdown/multi-select).

* Section 2: Ownership & Dates: Owner (user picker), Contributors (multi-user picker), Start Date (date picker), Due Date (date picker).

* Section 3: Effort & Progress: Estimated Effort (input field with unit dropdown), Progress Bar (slider or input).

* Section 4: Tags & Categories: Input field for adding tags, displaying existing tags as pills.

* Right Column (Advanced Details & Collaboration):

* Section 1: Dependencies: List of linked features (pre-requisites, blockers) with "Add Dependency" button.

* Section 2: Acceptance Criteria: Bulleted list input field.

* Section 3: Attachments: Drag-and-drop area for files, list of attached files.

* Section 4: Comments/Activity Log: Threaded comment section, activity history for the feature.

  • Key Elements: Rich text editor, various input types (text, dropdown, date picker, user picker), interactive lists for dependencies and comments.

2.3 Roadmap Timeline View

  • Layout:

* Top Header: Roadmap Name, View Selector (Timeline, Kanban, List), Filters (by Theme, Status, Owner), "Add Feature" button, "Export" button.

* Left Sidebar (Optional, Collapsible): List of strategic themes or product areas, allowing users to toggle visibility or filter.

* Main Content Area (Gantt Chart Style):

* Vertical Axis: Strategic Themes / Product Areas / Teams (configurable swimlanes).

* Horizontal Axis: Time scale (configurable: Weeks, Months, Quarters, Years).

* Feature Bars: Rectangular bars representing features, sized by duration, colored by status or theme. Hovering over a bar reveals a tooltip with feature details.

* Milestone Markers: Diamond or star icons on the timeline, linked to specific dates.

* Dependency Lines: Optional lines connecting feature bars to show dependencies.

* "Today" Line: Vertical line indicating the current date.

  • Key Elements: Interactive timeline (zoom, pan), draggable feature bars (to adjust dates), clickable bars to open feature details, filter options, milestone indicators.

2.4 Prioritization Matrix (Value vs. Effort)

  • Layout:

* Top Header: Roadmap Name, Prioritization Framework Selector (RICE, WSJF, Value vs. Effort), "Add Feature" button, "Settings" (for framework criteria).

* Main Content Area (2x2 Grid):

* X-axis: Effort (Low to High).

* Y-axis: Value (Low to High).

* Quadrants: "Quick Wins" (High Value, Low Effort), "Big Bets" (High Value, High Effort), "Fill-ins" (Low Value, Low Effort), "Time Sinks" (Low Value, High Effort).

* Feature Bubbles/Cards: Each feature is represented by a circle or small card, positioned according to its calculated Value and Effort scores. Size of the bubble could represent another metric (e.g., RICE Reach). Hovering reveals feature name and scores.

* Interactive Controls: Ability to drag and drop features between quadrants (which updates their scores/priority), filters to show specific feature sets.

  • Key Elements: Interactive grid, draggable elements, real-time score updates, configurable axes, filters.

3. Color Palettes

A professional, clean, and accessible color palette will be used to enhance readability and user experience.

  • Primary Brand Color: #007bff (A vibrant, trustworthy blue - commonly used for primary actions and branding)
  • Secondary Accent Color: #28a745 (A confident green - for success states, "Add" buttons, positive indicators)
  • Tertiary Accent Color: #ffc107 (A warm yellow - for warnings, pending states, attention-grabbing elements)
  • Neutral Colors (Text & Backgrounds):

* #343a40 (Dark Gray - for primary text, headings)

* #6c757d (Medium Gray - for secondary text, disabled states)

* #f8f9fa (Light Gray - for subtle backgrounds, card borders)

* #ffffff (White - for main content backgrounds, cards)

  • Semantic Colors:

* Success: #28a745 (Green)

* Warning: #ffc107 (Yellow)

* Danger/Error: #dc3545 (Red)

* Info: #17a2b8 (Light Blue)

  • Data Visualization Colors: A set of distinct, accessible colors will be defined for charts and graphs, ensuring good contrast and differentiation. (e.g., a palette of 5-7 distinct colors for roadmap themes or feature statuses).

4. UX Recommendations

User experience is paramount for a tool as critical as a Product Roadmap Builder.

4.1 Clarity & Consistency

  • Intuitive Navigation: Clear, consistent navigation elements (left sidebar, top bar) with easily recognizable icons.
  • Consistent Terminology: Use consistent language across the platform (e.g., always "Feature," not sometimes "Initiative" unless clearly defined as different entities).
  • Visual Hierarchy: Use size, color, and spacing to guide the user's eye to the most important information. Headings, subheadings, and body text should have clear visual distinctions.
  • Standard UI Patterns: Employ common UI patterns for forms, tables, and interactive elements to reduce cognitive load.

4.2 Feedback & Responsiveness

  • Instant Feedback: Provide immediate visual feedback for user actions (e.g., loading spinners, success messages, error alerts, button state changes).
  • Error Handling: Clear, concise, and actionable error messages that explain what went wrong and how to fix it.
  • Responsiveness: Ensure the application is fully responsive and adaptable to various screen sizes (desktop, tablet, potentially mobile for viewing).
  • Performance: Optimize for fast loading times and smooth interactions, especially with complex views like the timeline and matrix.

4.3 Efficiency & Productivity

  • Keyboard Shortcuts: Implement useful keyboard shortcuts for common actions (e.g., create new feature, save, navigate).
  • Bulk Actions: Allow users to perform actions on multiple items simultaneously (e.g., change status, assign owner, delete).
  • Drag-and-Drop: Utilize drag-and-drop functionality where appropriate (e.g., reordering features in a list, moving features on a timeline or matrix).
  • Search & Filtering: Robust search and filtering capabilities across all modules to quickly find specific items.
  • Personalization: Allow users to customize dashboards, preferred views, and notification settings.

4.4 Accessibility

  • WCAG Compliance: Design with Web Content Accessibility Guidelines (WCAG) in mind (e.g., sufficient color contrast, keyboard navigation, screen reader compatibility).
  • Alternative Text: Provide descriptive alt text for all images and non-text content.
  • Focus States: Clearly visible focus indicators for interactive elements for keyboard users.
  • Font Readability: Use legible fonts and ensure adequate font sizes.

4.5 Data Visualization

  • Clear Labeling: All charts and graphs should have clear titles, axis labels, and legends.
  • Interactive Tooltips: Provide detailed information on hover for data points in charts and timeline bars.
  • Color Blindness Consideration: Use color palettes that are distinguishable for users with color vision deficiencies. Avoid relying solely on color to convey information.

4.6 Collaboration & Communication

  • Real-time Updates: Implement mechanisms for real-time updates when multiple users are collaborating on the same roadmap or feature.
  • Inline Comments: Facilitate direct feedback and discussions on specific items.
  • Clear Notifications: Provide configurable notifications for relevant changes or assignments.

By adhering to these detailed design specifications and UX recommendations, the Product Roadmap Builder will provide an exceptional, powerful, and user-friendly experience for product managers and their stakeholders.

gemini Output

This output provides detailed design specifications, wireframe descriptions, color palettes, and UX recommendations for the "Product Roadmap Builder" application. This information will guide the design and development teams in creating a professional, user-friendly, and effective tool.


Product Roadmap Builder: Design Specifications

1. Overall Application Layout & Navigation

The application will feature a modern, responsive web design primarily optimized for desktop use, with graceful degradation for tablet experiences.

  • Persistent Left Sidebar Navigation:

* Purpose: Provides primary navigation to top-level application sections.

* Components: Application Logo, main navigation links (e.g., Dashboard, My Roadmaps, Templates, Settings), User Profile/Logout at the bottom.

* Behavior: Collapsible to

gemini Output

This document outlines the final design specifications, wireframe descriptions, color palettes, and user experience (UX) recommendations for the "Product Roadmap Builder" application. The goal is to create an intuitive, powerful, and visually appealing tool that empowers product teams to strategically plan, visualize, and communicate their product roadmaps effectively.

1. Overall Design Philosophy

The design philosophy centers around Clarity, Flexibility, and Actionability.

  • Clarity: Information should be easy to understand, with clear hierarchies and intuitive navigation. Visualizations should simplify complex data.
  • Flexibility: The tool must adapt to various roadmap methodologies (Now/Next/Later, timeline, Kanban) and allow for customization to suit different team needs.
  • Actionability: Users should be able to quickly add, edit, prioritize, and communicate roadmap items, turning strategy into tangible tasks.

The aesthetic will be modern, clean, and professional, using a balanced color palette and consistent iconography to ensure a seamless user experience.

2. Core UI Components & Interactions

2.1 Global Navigation

  • Type: Left-hand persistent sidebar navigation.
  • Elements:

* Product Logo/Name at the top.

* Primary navigation links: Dashboard, Roadmap, Features, Resources, Risks, Settings.

* User Profile/Account settings at the bottom of the sidebar.

* Collapse/Expand toggle for the sidebar.

  • Interaction: Active link clearly highlighted. Tooltips on hover when collapsed.

2.2 Top Bar / Contextual Header

  • Elements:

* Current Product/Roadmap Name (editable dropdown for switching products).

* Global "Add New" button (e.g., + Feature, + Milestone).

* View Selector (e.g., Timeline, Board, List for Roadmap view).

* Share/Export Options.

* Search bar.

* Notifications icon.

  • Interaction: Context-sensitive actions appear based on the current page.

2.3 Data Display & Input

  • Cards: Used for features/initiatives in board views. Should be draggable and contain key info (title, priority, owner, status, dates).
  • Tables: Used for list views (features, resources, risks). Sortable, filterable, with inline editing capabilities where appropriate.
  • Forms & Modals: Dedicated modals or side-drawers for adding/editing detailed information (features, milestones, resources). Input fields will include:

* Text inputs (single-line, multi-line rich text).

* Dropdowns (single-select, multi-select).

* Date pickers (single date, date range).

* Tags/Labels input.

* File upload.

* Progress sliders (e.g., for completion percentage).

  • Prioritization Matrix/Tool: Interactive grid or wizard for applying prioritization frameworks (e.g., RICE, WSJF) with input fields for scores and calculated output.

2.4 Visualizations

  • Timeline (Gantt-like): Horizontal bars representing features/milestones against a time axis. Drag-and-drop for rescheduling, resizing for duration. Swimlanes for grouping.
  • Kanban Boards: Columns representing stages (e.g., Now, Next, Later; To Do, In Progress, Done) with draggable feature cards.
  • Charts/Graphs: For resource utilization, risk distribution, feature progress. (e.g., pie charts, bar graphs).

3. Detailed Screen-Specific Wireframe Descriptions

3.1 Dashboard (Overview)

  • Layout: Grid-based, responsive.
  • Top Bar: Product Name, "Add New" button, Search, Notifications, User Profile.
  • Left Sidebar: Global Navigation.
  • Main Content Area:

* Section 1: Roadmap Summary (Top Left)

* Card: "Features in Progress" (count, link to list).

* Card: "Upcoming Milestones" (count, link to list).

* Card: "High-Priority Risks" (count, link to list).

* Card: "Resource Utilization" (simple bar chart or percentage).

* Section 2: Quick Roadmap View (Top Right)

* Mini "Now, Next, Later" board or simplified timeline showing key features/milestones. Interactive on hover.

* Section 3: Recent Activity Feed (Bottom Left)

* List of recent changes, comments, updates by team members. Timestamp, user avatar.

* Section 4: Key Metrics/Analytics (Bottom Right)

* Configurable widgets: e.g., "Feature Completion Rate," "Time to Market Trends," "Prioritization Distribution."

3.2 Roadmap View (Main) - Timeline

  • Layout: Full-width content area with scroll.
  • Top Bar: Product Name, Filters (Team, Status, Priority, Tags), Zoom controls (Day, Week, Month, Quarter, Year), View Selector (Timeline active), "Add Feature" button, Share/Export.
  • Left Sidebar: Global Navigation.
  • Main Content Area:

* Left Pane (Fixed Width): Swimlane/Group headers (e.g., "Product Area A," "Team X," "Strategic Theme Y"). Expand/Collapse option for each.

* Right Pane (Scrollable):

* Time Axis: Horizontal header with dynamically changing units based on zoom level (e.g., "Q1 2024," "Jan 2024," "Week 1").

* Feature Bars: Horizontal bars within swimlanes, representing individual features.

* Visual: Color-coded by status/priority. Shows feature title.

* Interaction: Draggable (re-schedule), Resizable (adjust duration). Click to open Feature Detail Modal. Hover to see quick details (tooltip).

* Milestone Markers: Vertical lines or diamond shapes on the time axis, with milestone name.

* Dependencies: Thin lines/arrows connecting feature bars, indicating dependencies.

3.3 Roadmap View (Main) - Board (Kanban)

  • Layout: Full-width content area with horizontal scroll if many columns.
  • Top Bar: Product Name, Filters (Team, Status, Priority, Tags), View Selector (Board active), "Add Feature" button, Share/Export.
  • Left Sidebar: Global Navigation.
  • Main Content Area:

* Columns: Configurable columns (e.g., "Now," "Next," "Later"; "Q1," "Q2," "Q3"; or custom stages). Each column has a title and a count of items.

* "Add Feature" Card: A "+" card at the bottom of each column for quick addition.

* Feature Cards:

* Visual: Title, Priority Tag (color-coded), Assignee Avatar, Status Tag, Due Date (if applicable), Progress Bar (optional).

* Interaction: Draggable between columns (status change), Draggable within columns (reorder). Click to open Feature Detail Modal.

3.4 Feature Detail Modal / Side Drawer

  • Trigger: Click on a feature bar (Timeline) or feature card (Board/List).
  • Layout: Full-height side drawer (from right) or central modal.
  • Sections:

* Header: Feature Title (editable), Status dropdown, Priority dropdown, Close button.

* Key Details:

* Description (rich text editor).

* Owner/Team (user/team selector).

* Strategic Theme/Pillar (dropdown/tags).

* Start Date / End Date (date picker).

* Milestones (multi-select dropdown to associate with defined milestones).

* Dependencies (link to other features, search functionality).

* Resources (link to specific resources/teams, capacity info).

* Prioritization:

* Section for RICE/WSJF scores (input fields for Reach, Impact, Confidence, Effort / Time Criticality, Business Value, Risk Reduction, Job Size).

* Calculated Score displayed prominently.

* Acceptance Criteria: List of actionable items.

* Risks: Linked risks (add new, link existing).

* Attachments: File upload/management.

* Comments/Activity Log: Threaded comments, system activity log (who changed what, when).

* Footer: Save, Cancel, Delete buttons.

4. Color Palette & Typography

4.1 Color Palette

The palette is designed for professionalism, clarity, and accessibility, using a primary brand color with complementary and semantic accents.

  • Primary Brand Color: #007BFF (A vibrant, trustworthy blue) - Used for primary buttons, active states, key highlights.
  • Secondary Accent Color: #28A745 (A confident green) - Used for success messages, "on track" status, positive actions.
  • Tertiary Accent Color: #FFC107 (An engaging amber) - Used for warnings, "in progress" status, attention-grabbing elements.
  • Alert/Danger Color: #DC3545 (A clear red) - Used for errors, critical risks, "blocked" status.
  • Neutral Palette:

* Backgrounds: #F8F9FA (Light gray) - Main application background.

* Card/Container Backgrounds: #FFFFFF (White) - For content cards, modals.

* Text (Primary): #343A40 (Dark charcoal) - Headings, main body text.

* Text (Secondary): #6C757D (Medium gray) - Helper text, descriptions, inactive states.

* Borders/Dividers: #DEE2E6 (Light border gray).

  • Status/Priority Tags (Examples):

* High Priority: #DC3545 (Red)

* Medium Priority: #FFC107 (Amber)

* Low Priority: #007BFF (Blue)

* On Track: #28A745 (Green)

* At Risk: #FD7E14 (Orange)

* Blocked: #6C757D (Gray)

4.2 Typography

  • Font Family: A clean, modern sans-serif font like Inter or Roboto. These fonts offer excellent readability across various screen sizes and weights.
  • Headings (H1, H2, H3): Bold or Semi-Bold, progressively smaller sizes for clear hierarchy.

* H1: 2.25rem (36px)

* H2: 1.75rem (28px)

* H3: 1.25rem (20px)

  • Body Text: Regular weight, comfortable reading size.

* Paragraphs: 1rem (16px)

* Small Text/Labels: 0.875rem (14px)

  • Line Height: Consistent line height (e.g., 1.5) for readability.

5. Key UX Principles & Recommendations

5.1 Intuitive Navigation & Information Architecture

  • Clear Labels: Use unambiguous labels for all navigation items, buttons, and fields.
  • Consistent Placement: Place common actions (e.g., "Add New," "Share") in predictable locations across the application.
  • Breadcrumbs: Implement breadcrumbs for deep navigation paths to aid user orientation.
  • Search & Filter: Robust global search and context-specific filters on all list/board views.

5.2 Efficiency & Productivity

  • Keyboard Shortcuts: Offer keyboard shortcuts for common actions (e.g., Ctrl+K for global search, Esc to close modals).
  • Bulk Actions: Allow users to select multiple features/items and perform actions (e.g., change status, assign owner) in bulk.
product_roadmap_builder.md
Download as Markdown
Copy all content
Full output as text
Download ZIP
IDE-ready project ZIP
Copy share link
Permanent URL for this run
Get Embed Code
Embed this result on any website
Print / Save PDF
Use browser print dialog
\n\n\n"); var hasSrcMain=Object.keys(extracted).some(function(k){return k.indexOf("src/main")>=0;}); if(!hasSrcMain) zip.file(folder+"src/main."+ext,"import React from 'react'\nimport ReactDOM from 'react-dom/client'\nimport App from './App'\nimport './index.css'\n\nReactDOM.createRoot(document.getElementById('root')!).render(\n \n \n \n)\n"); var hasSrcApp=Object.keys(extracted).some(function(k){return k==="src/App."+ext||k==="App."+ext;}); if(!hasSrcApp) zip.file(folder+"src/App."+ext,"import React from 'react'\nimport './App.css'\n\nfunction App(){\n return(\n
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n
\n )\n}\nexport default App\n"); zip.file(folder+"src/index.css","*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#f0f2f5;color:#1a1a2e}\n.app{min-height:100vh;display:flex;flex-direction:column}\n.app-header{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;padding:40px}\nh1{font-size:2.5rem;font-weight:700}\n"); zip.file(folder+"src/App.css",""); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/pages/.gitkeep",""); zip.file(folder+"src/hooks/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\n## Open in IDE\nOpen the project folder in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Vue (Vite + Composition API + TypeScript) --- */ function buildVue(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "type": "module",\n "scripts": {\n "dev": "vite",\n "build": "vue-tsc -b && vite build",\n "preview": "vite preview"\n },\n "dependencies": {\n "vue": "^3.5.13",\n "vue-router": "^4.4.5",\n "pinia": "^2.3.0",\n "axios": "^1.7.9"\n },\n "devDependencies": {\n "@vitejs/plugin-vue": "^5.2.1",\n "typescript": "~5.7.3",\n "vite": "^6.0.5",\n "vue-tsc": "^2.2.0"\n }\n}\n'); zip.file(folder+"vite.config.ts","import { defineConfig } from 'vite'\nimport vue from '@vitejs/plugin-vue'\nimport { resolve } from 'path'\n\nexport default defineConfig({\n plugins: [vue()],\n resolve: { alias: { '@': resolve(__dirname,'src') } }\n})\n"); zip.file(folder+"tsconfig.json",'{"files":[],"references":[{"path":"./tsconfig.app.json"},{"path":"./tsconfig.node.json"}]}\n'); zip.file(folder+"tsconfig.app.json",'{\n "compilerOptions":{\n "target":"ES2020","useDefineForClassFields":true,"module":"ESNext","lib":["ES2020","DOM","DOM.Iterable"],\n "skipLibCheck":true,"moduleResolution":"bundler","allowImportingTsExtensions":true,\n "isolatedModules":true,"moduleDetection":"force","noEmit":true,"jsxImportSource":"vue",\n "strict":true,"paths":{"@/*":["./src/*"]}\n },\n "include":["src/**/*.ts","src/**/*.d.ts","src/**/*.tsx","src/**/*.vue"]\n}\n'); zip.file(folder+"env.d.ts","/// \n"); zip.file(folder+"index.html","\n\n\n \n \n "+slugTitle(pn)+"\n\n\n
\n \n\n\n"); var hasMain=Object.keys(extracted).some(function(k){return k==="src/main.ts"||k==="main.ts";}); if(!hasMain) zip.file(folder+"src/main.ts","import { createApp } from 'vue'\nimport { createPinia } from 'pinia'\nimport App from './App.vue'\nimport './assets/main.css'\n\nconst app = createApp(App)\napp.use(createPinia())\napp.mount('#app')\n"); var hasApp=Object.keys(extracted).some(function(k){return k.indexOf("App.vue")>=0;}); if(!hasApp) zip.file(folder+"src/App.vue","\n\n\n\n\n"); zip.file(folder+"src/assets/main.css","*{margin:0;padding:0;box-sizing:border-box}body{font-family:system-ui,sans-serif;background:#fff;color:#213547}\n"); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/views/.gitkeep",""); zip.file(folder+"src/stores/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\nOpen in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Angular (v19 standalone) --- */ function buildAngular(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var sel=pn.replace(/_/g,"-"); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "scripts": {\n "ng": "ng",\n "start": "ng serve",\n "build": "ng build",\n "test": "ng test"\n },\n "dependencies": {\n "@angular/animations": "^19.0.0",\n "@angular/common": "^19.0.0",\n "@angular/compiler": "^19.0.0",\n "@angular/core": "^19.0.0",\n "@angular/forms": "^19.0.0",\n "@angular/platform-browser": "^19.0.0",\n "@angular/platform-browser-dynamic": "^19.0.0",\n "@angular/router": "^19.0.0",\n "rxjs": "~7.8.0",\n "tslib": "^2.3.0",\n "zone.js": "~0.15.0"\n },\n "devDependencies": {\n "@angular-devkit/build-angular": "^19.0.0",\n "@angular/cli": "^19.0.0",\n "@angular/compiler-cli": "^19.0.0",\n "typescript": "~5.6.0"\n }\n}\n'); zip.file(folder+"angular.json",'{\n "$schema": "./node_modules/@angular/cli/lib/config/schema.json",\n "version": 1,\n "newProjectRoot": "projects",\n "projects": {\n "'+pn+'": {\n "projectType": "application",\n "root": "",\n "sourceRoot": "src",\n "prefix": "app",\n "architect": {\n "build": {\n "builder": "@angular-devkit/build-angular:application",\n "options": {\n "outputPath": "dist/'+pn+'",\n "index": "src/index.html",\n "browser": "src/main.ts",\n "tsConfig": "tsconfig.app.json",\n "styles": ["src/styles.css"],\n "scripts": []\n }\n },\n "serve": {"builder":"@angular-devkit/build-angular:dev-server","configurations":{"production":{"buildTarget":"'+pn+':build:production"},"development":{"buildTarget":"'+pn+':build:development"}},"defaultConfiguration":"development"}\n }\n }\n }\n}\n'); zip.file(folder+"tsconfig.json",'{\n "compileOnSave": false,\n "compilerOptions": {"baseUrl":"./","outDir":"./dist/out-tsc","forceConsistentCasingInFileNames":true,"strict":true,"noImplicitOverride":true,"noPropertyAccessFromIndexSignature":true,"noImplicitReturns":true,"noFallthroughCasesInSwitch":true,"paths":{"@/*":["src/*"]},"skipLibCheck":true,"esModuleInterop":true,"sourceMap":true,"declaration":false,"experimentalDecorators":true,"moduleResolution":"bundler","importHelpers":true,"target":"ES2022","module":"ES2022","useDefineForClassFields":false,"lib":["ES2022","dom"]},\n "references":[{"path":"./tsconfig.app.json"}]\n}\n'); zip.file(folder+"tsconfig.app.json",'{\n "extends":"./tsconfig.json",\n "compilerOptions":{"outDir":"./dist/out-tsc","types":[]},\n "files":["src/main.ts"],\n "include":["src/**/*.d.ts"]\n}\n'); zip.file(folder+"src/index.html","\n\n\n \n "+slugTitle(pn)+"\n \n \n \n\n\n \n\n\n"); zip.file(folder+"src/main.ts","import { bootstrapApplication } from '@angular/platform-browser';\nimport { appConfig } from './app/app.config';\nimport { AppComponent } from './app/app.component';\n\nbootstrapApplication(AppComponent, appConfig)\n .catch(err => console.error(err));\n"); zip.file(folder+"src/styles.css","* { margin: 0; padding: 0; box-sizing: border-box; }\nbody { font-family: system-ui, -apple-system, sans-serif; background: #f9fafb; color: #111827; }\n"); var hasComp=Object.keys(extracted).some(function(k){return k.indexOf("app.component")>=0;}); if(!hasComp){ zip.file(folder+"src/app/app.component.ts","import { Component } from '@angular/core';\nimport { RouterOutlet } from '@angular/router';\n\n@Component({\n selector: 'app-root',\n standalone: true,\n imports: [RouterOutlet],\n templateUrl: './app.component.html',\n styleUrl: './app.component.css'\n})\nexport class AppComponent {\n title = '"+pn+"';\n}\n"); zip.file(folder+"src/app/app.component.html","
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n \n
\n"); zip.file(folder+"src/app/app.component.css",".app-header{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:60vh;gap:16px}h1{font-size:2.5rem;font-weight:700;color:#6366f1}\n"); } zip.file(folder+"src/app/app.config.ts","import { ApplicationConfig, provideZoneChangeDetection } from '@angular/core';\nimport { provideRouter } from '@angular/router';\nimport { routes } from './app.routes';\n\nexport const appConfig: ApplicationConfig = {\n providers: [\n provideZoneChangeDetection({ eventCoalescing: true }),\n provideRouter(routes)\n ]\n};\n"); zip.file(folder+"src/app/app.routes.ts","import { Routes } from '@angular/router';\n\nexport const routes: Routes = [];\n"); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nng serve\n# or: npm start\n\`\`\`\n\n## Build\n\`\`\`bash\nng build\n\`\`\`\n\nOpen in VS Code with Angular Language Service extension.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n.angular/\n"); } /* --- Python --- */ function buildPython(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var reqMap={"numpy":"numpy","pandas":"pandas","sklearn":"scikit-learn","tensorflow":"tensorflow","torch":"torch","flask":"flask","fastapi":"fastapi","uvicorn":"uvicorn","requests":"requests","sqlalchemy":"sqlalchemy","pydantic":"pydantic","dotenv":"python-dotenv","PIL":"Pillow","cv2":"opencv-python","matplotlib":"matplotlib","seaborn":"seaborn","scipy":"scipy"}; var reqs=[]; Object.keys(reqMap).forEach(function(k){if(src.indexOf("import "+k)>=0||src.indexOf("from "+k)>=0)reqs.push(reqMap[k]);}); var reqsTxt=reqs.length?reqs.join("\n"):"# add dependencies here\n"; zip.file(folder+"main.py",src||"# "+title+"\n# Generated by PantheraHive BOS\n\nprint(title+\" loaded\")\n"); zip.file(folder+"requirements.txt",reqsTxt); zip.file(folder+".env.example","# Environment variables\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\npython3 -m venv .venv\nsource .venv/bin/activate\npip install -r requirements.txt\n\`\`\`\n\n## Run\n\`\`\`bash\npython main.py\n\`\`\`\n"); zip.file(folder+".gitignore",".venv/\n__pycache__/\n*.pyc\n.env\n.DS_Store\n"); } /* --- Node.js --- */ function buildNode(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var depMap={"mongoose":"^8.0.0","dotenv":"^16.4.5","axios":"^1.7.9","cors":"^2.8.5","bcryptjs":"^2.4.3","jsonwebtoken":"^9.0.2","socket.io":"^4.7.4","uuid":"^9.0.1","zod":"^3.22.4","express":"^4.18.2"}; var deps={}; Object.keys(depMap).forEach(function(k){if(src.indexOf(k)>=0)deps[k]=depMap[k];}); if(!deps["express"])deps["express"]="^4.18.2"; var pkgJson=JSON.stringify({"name":pn,"version":"1.0.0","main":"src/index.js","scripts":{"start":"node src/index.js","dev":"nodemon src/index.js"},"dependencies":deps,"devDependencies":{"nodemon":"^3.0.3"}},null,2)+"\n"; zip.file(folder+"package.json",pkgJson); var fallback="const express=require(\"express\");\nconst app=express();\napp.use(express.json());\n\napp.get(\"/\",(req,res)=>{\n res.json({message:\""+title+" API\"});\n});\n\nconst PORT=process.env.PORT||3000;\napp.listen(PORT,()=>console.log(\"Server on port \"+PORT));\n"; zip.file(folder+"src/index.js",src||fallback); zip.file(folder+".env.example","PORT=3000\n"); zip.file(folder+".gitignore","node_modules/\n.env\n.DS_Store\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\n\`\`\`\n\n## Run\n\`\`\`bash\nnpm run dev\n\`\`\`\n"); } /* --- Vanilla HTML --- */ function buildVanillaHtml(zip,folder,app,code){ var title=slugTitle(app); var isFullDoc=code.trim().toLowerCase().indexOf("=0||code.trim().toLowerCase().indexOf("=0; var indexHtml=isFullDoc?code:"\n\n\n\n\n"+title+"\n\n\n\n"+code+"\n\n\n\n"; zip.file(folder+"index.html",indexHtml); zip.file(folder+"style.css","/* "+title+" — styles */\n*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#fff;color:#1a1a2e}\n"); zip.file(folder+"script.js","/* "+title+" — scripts */\n"); zip.file(folder+"assets/.gitkeep",""); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Open\nDouble-click \`index.html\` in your browser.\n\nOr serve locally:\n\`\`\`bash\nnpx serve .\n# or\npython3 -m http.server 3000\n\`\`\`\n"); zip.file(folder+".gitignore",".DS_Store\nnode_modules/\n.env\n"); } /* ===== MAIN ===== */ var sc=document.createElement("script"); sc.src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.10.1/jszip.min.js"; sc.onerror=function(){ if(lbl)lbl.textContent="Download ZIP"; alert("JSZip load failed — check connection."); }; sc.onload=function(){ var zip=new JSZip(); var base=(_phFname||"output").replace(/\.[^.]+$/,""); var app=base.toLowerCase().replace(/[^a-z0-9]+/g,"_").replace(/^_+|_+$/g,"")||"my_app"; var folder=app+"/"; var vc=document.getElementById("panel-content"); var panelTxt=vc?(vc.innerText||vc.textContent||""):""; var lang=detectLang(_phCode,panelTxt); if(_phIsHtml){ buildVanillaHtml(zip,folder,app,_phCode); } else if(lang==="flutter"){ buildFlutter(zip,folder,app,_phCode,panelTxt); } else if(lang==="react-native"){ buildReactNative(zip,folder,app,_phCode,panelTxt); } else if(lang==="swift"){ buildSwift(zip,folder,app,_phCode,panelTxt); } else if(lang==="kotlin"){ buildKotlin(zip,folder,app,_phCode,panelTxt); } else if(lang==="react"){ buildReact(zip,folder,app,_phCode,panelTxt); } else if(lang==="vue"){ buildVue(zip,folder,app,_phCode,panelTxt); } else if(lang==="angular"){ buildAngular(zip,folder,app,_phCode,panelTxt); } else if(lang==="python"){ buildPython(zip,folder,app,_phCode); } else if(lang==="node"){ buildNode(zip,folder,app,_phCode); } else { /* Document/content workflow */ var title=app.replace(/_/g," "); var md=_phAll||_phCode||panelTxt||"No content"; zip.file(folder+app+".md",md); var h=""+title+""; h+="

"+title+"

"; var hc=md.replace(/&/g,"&").replace(//g,">"); hc=hc.replace(/^### (.+)$/gm,"

$1

"); hc=hc.replace(/^## (.+)$/gm,"

$1

"); hc=hc.replace(/^# (.+)$/gm,"

$1

"); hc=hc.replace(/\*\*(.+?)\*\*/g,"$1"); hc=hc.replace(/\n{2,}/g,"

"); h+="

"+hc+"

Generated by PantheraHive BOS
"; zip.file(folder+app+".html",h); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\nFiles:\n- "+app+".md (Markdown)\n- "+app+".html (styled HTML)\n"); } zip.generateAsync({type:"blob"}).then(function(blob){ var a=document.createElement("a"); a.href=URL.createObjectURL(blob); a.download=app+".zip"; a.click(); URL.revokeObjectURL(a.href); if(lbl)lbl.textContent="Download ZIP"; }); }; document.head.appendChild(sc); } function phShare(){navigator.clipboard.writeText(window.location.href).then(function(){var el=document.getElementById("ph-share-lbl");if(el){el.textContent="Link copied!";setTimeout(function(){el.textContent="Copy share link";},2500);}});}function phEmbed(){var runId=window.location.pathname.split("/").pop().replace(".html","");var embedUrl="https://pantherahive.com/embed/"+runId;var code='';navigator.clipboard.writeText(code).then(function(){var el=document.getElementById("ph-embed-lbl");if(el){el.textContent="Embed code copied!";setTimeout(function(){el.textContent="Get Embed Code";},2500);}});}