Mobile App Wireframe Kit
Run ID: 69cb3e5b61b1021a29a873f72026-03-31Design
PantheraHive BOS
BOS Dashboard

This deliverable provides a comprehensive Mobile App Wireframe Specification, detailing screen flows, a reusable component library, interaction patterns, and essential developer handoff notes. This specification serves as a foundational blueprint for development, ensuring clarity and consistency across the application.


Mobile App Wireframe Kit Specification

This document outlines the complete wireframe specification for the mobile application. It provides a structured definition of all user interface elements, their interactions, and the overall user flow, enabling efficient and accurate development.


1. Global Design Principles & Naming Conventions

1.1 Design Principles

1.2 Naming Conventions


2. Screen Flow Definition

This section defines the primary user journeys and transitions between key screens.

2.1 Core User Flows

text • 172 chars
---

## 3. Component Library Specification

This section defines the reusable UI components with their properties, states, and usage guidelines.

### 3.1 Base Components

Sandboxed live preview

Mobile App Wireframe Kit: Study Plan for Professional Wireframe Specification

This detailed study plan outlines the necessary steps, resources, and milestones to achieve proficiency in generating comprehensive mobile app wireframe specifications. The goal is to equip you with the knowledge and skills to produce a professional deliverable including screen flows, a robust component library, interaction patterns, and clear developer handoff notes.


1. Learning Objectives

By the end of this study plan, you will be able to:

  • Understand Core UX/UI Principles: Differentiate between wireframes, mockups, and prototypes, and apply fundamental mobile UX/UI best practices.
  • Master a Wireframing Tool: Achieve proficiency in a leading wireframing and prototyping tool (e.g., Figma, Adobe XD, Sketch) to create high-quality wireframes.
  • Design Effective Screen Flows: Map out user journeys and create logical, intuitive screen flows that represent key user interactions and navigation paths.
  • Develop a Reusable Component Library: Design, categorize, and document a consistent set of UI components for efficiency and scalability.
  • Incorporate Interaction Patterns: Understand and apply common mobile interaction patterns, gestures, and feedback mechanisms.
  • Generate Comprehensive Specifications: Create detailed wireframe specifications, including annotations, states, and business logic.
  • Prepare for Developer Handoff: Organize and document wireframes effectively for seamless collaboration and implementation by development teams.

2. Weekly Schedule (4-Week Intensive Plan)

This schedule assumes approximately 10-15 hours of focused study and practical application per week.

Week 1: Foundations & Tooling Mastery

  • Focus: Introduction to wireframing, UX/UI basics, and tool proficiency.
  • Topics:

* Day 1-2: Introduction to UX/UI design principles, the role of wireframes in the design process, and differentiating between various design artifacts (wireframes, mockups, prototypes).

* Day 3-4: Deep dive into your chosen wireframing tool (Figma, Adobe XD, Sketch). Learn core functionalities: artboards/frames, basic shapes, text, layers, grouping, and auto-layout features.

* Day 5-7: Hands-on exercises: Recreate simple, common mobile app screens (e.g., login, profile, settings) using your chosen tool. Focus on layout, alignment, and basic UI elements.

  • Deliverable: Recreated basic mobile app screens in your chosen tool.

Week 2: Screen Flows & Information Architecture

  • Focus: Understanding user journeys and mapping out application flows.
  • Topics:

* Day 1-2: User research basics (personas, user stories), task analysis, and defining key user flows for a sample mobile application.

* Day 3-4: Information Architecture (IA) principles: structuring content, navigation patterns (tab bars, navigation drawers, breadcrumbs), and hierarchy.

* Day 5-7: Practical application: Design a multi-screen user flow for a simple app feature (e.g., "Add Item to Cart," "Book an Appointment"). Create clear connections between screens, indicating user actions and system responses.

  • Deliverable: A complete wireframe flow for a core app feature, demonstrating clear navigation and user interaction paths.

Week 3: Component Library & Interaction Patterns

  • Focus: Building reusable UI components and understanding mobile interaction.
  • Topics:

* Day 1-2: Principles of design systems and component-based design. Understanding atomic design methodology.

* Day 3-4: Building a component library: Create reusable wireframe components (buttons, input fields, cards, navigation bars, modals, alerts). Document their states (e.g., default, hover, active, disabled) and variations.

* Day 5-7: Mobile interaction patterns: Explore common gestures (tap, swipe, pinch), animations, feedback mechanisms (haptic, visual), and micro-interactions. Apply these concepts to your wireframes.

  • Deliverable: A foundational wireframe component library with at least 10-15 documented components and examples of applied interaction patterns within your screen flows.

Week 4: Specification & Developer Handoff

  • Focus: Finalizing the wireframe specification and preparing for development.
  • Topics:

* Day 1-2: Structuring a comprehensive wireframe specification document. Adding annotations, explaining complex logic, edge cases, and user feedback.

* Day 3-4: Developer handoff best practices: Organizing files, naming conventions, exporting assets (if applicable), and using collaboration features of your chosen tool.

* Day 5-7: Final project: Consolidate all learned concepts by creating a complete wireframe specification for a chosen mobile app feature or a small application. Include screen flows, component usage, interaction notes, and detailed annotations.

  • Deliverable: A complete mobile app wireframe specification, including screen flows, component library usage, interaction notes, and developer handoff notes, ready for presentation.

3. Recommended Resources

Wireframing & Prototyping Tools:

  • Figma: Industry-standard for collaborative design. Extensive community resources and plugins.

Resource*: Figma Learn (learn.figma.com), Figma Community Files.

  • Adobe XD: Part of the Adobe Creative Cloud suite, good for integrating with other Adobe products.

Resource*: Adobe XD Learn & Support.

  • Sketch: Popular among macOS users, strong plugin ecosystem.

Resource*: Sketch Tutorials, Sketch Libraries.

  • Balsamiq: Excellent for low-fidelity wireframing, focusing purely on structure and content.

Resource*: Balsamiq Documentation & Examples.

  • Miro / Mural: For collaborative brainstorming, user flows, and whiteboard-style wireframing.

Books & Articles:

  • "Don't Make Me Think, Revisited" by Steve Krug: Essential reading for usability and intuitive design.
  • "The Design of Everyday Things" by Don Norman: Fundamental principles of human-centered design.
  • "Designing Interfaces" by Jenifer Tidwell: A comprehensive guide to common UI patterns.
  • Nielsen Norman Group (NN/g): Extensive library of UX research articles and guidelines (nngroup.com).
  • Smashing Magazine: Regular articles on UX, UI, and front-end development (smashingmagazine.com).
  • UX Planet / Medium: Curated articles from UX professionals (uxplanet.org).

Online Courses & Tutorials:

  • Google UX Design Professional Certificate (Coursera): Comprehensive program covering the entire UX design process.
  • Udemy / Skillshare: Numerous courses on Figma, Adobe XD, Sketch, and mobile UX design.
  • Interaction Design Foundation (IxDF): In-depth courses on various UX topics, including Mobile User Experience (interaction-design.org).
  • YouTube Channels: Search for specific tool tutorials (e.g., "Figma wireframe tutorial," "Adobe XD prototyping").

Design Systems & Guidelines:

  • Google Material Design Guidelines: Comprehensive guidelines for Android app design (material.io).
  • Apple Human Interface Guidelines: Official guidelines for iOS app design (developer.apple.com/design/human-interface-guidelines).
  • Atlassian Design System, Shopify Polaris, IBM Carbon: Examples of robust component libraries and design systems for inspiration.

Templates & UI Kits:

  • Figma Community: Search for "wireframe kits," "mobile UI kits," and "flowchart kits."
  • Adobe XD Resources: Similar resources available directly within XD.
  • UI8.net / Envato Elements: Premium UI kits and templates for various tools.

4. Milestones

  • End of Week 1: Demonstrated proficiency in chosen wireframing tool; successfully recreated 3-5 common mobile app screens.
  • End of Week 2: Completed wireframe flow for a key mobile app feature, clearly indicating user paths and navigation.
  • End of Week 3: Established a foundational wireframe component library with documented usage and incorporated examples of mobile interaction patterns.
  • End of Week 4: Submitted a complete mobile app wireframe specification for a small application or complex feature, including detailed screen flows, component library usage, interaction notes, and developer handoff documentation.

5. Assessment Strategies

  • Practical Application (Weekly Tasks): Successful completion of the hands-on deliverables outlined in the weekly schedule. This demonstrates practical skill acquisition.
  • Self-Review Checklists: Use predefined checklists to review your wireframes for consistency, completeness, clarity, and adherence to mobile UX best practices.
  • Peer Feedback (Optional): If working in a team or study group, solicit constructive feedback on your wireframes and documentation from peers.
  • Final Project Review: The ultimate assessment will be the comprehensive mobile app wireframe specification created in Week 4. It should be evaluated against the initial learning objectives for completeness, accuracy, usability, and developer readiness.
  • Concept Explanations: Be prepared to articulate design choices, justify interaction patterns, and explain the rationale behind your component library structure.

This study plan provides a structured approach to mastering the creation of professional mobile app wireframe specifications. By diligently following these steps and leveraging the recommended resources, you will be well-prepared to deliver high-quality design artifacts.

yaml

InteractionPatterns:

- name: Tap

description: Standard single touch interaction.

trigger: "User briefly touches and releases a UI element."

action: "Activates the element's primary function (e.g., button press, link navigation)."

feedback: "Visual change (e.g., button state change), haptic feedback (optional)."

notes: "Ensure sufficient tap target sizes (min 44x44 dp)."

- name: Long Press

description: Extended touch interaction.

trigger: "User touches and holds a UI element for a predefined duration (e.g., 500ms)."

action: "Reveals secondary actions or contextual menus."

feedback: "Visual change (e.g., highlight, scale), haptic feedback."

notes: "Clearly indicate elements that support long press through visual cues or onboarding."

- name: Swipe (Horizontal)

description: Lateral finger movement.

trigger: "User touches an element and drags horizontally."

action: "Can be used for:

- Navigating between tabs/pages (e.g., image carousels).

- Revealing hidden actions (e.g., delete/archive on list items).

- Dismissing elements (e.g., cards, notifications)."

feedback: "Element follows finger movement, snap-to-grid/animation on release."

notes: "Clearly define swipe direction and its corresponding action. Avoid conflicting with system gestures."

- name: Swipe (Vertical)

description: Vertical finger movement.

trigger: "User touches an element and drags vertically."

action: "Scrolling content (default), pull-to-refresh (at top of scrollable area), pull-to-load-more (at bottom)."

feedback: "Content scrolls, pull-to-refresh spinner appears."

notes: "Standard for content navigation. Ensure clear visual cues for pull-to-refresh/load more."

- name: Form Submission

description: Process of sending user-entered data.

trigger: "Tap 'Submit' / 'Save' / 'Continue' button after filling form fields."

action: "

1. Client-side validation of input fields.

2. Disable submit button and show Loader_Spinner.

3. Send data to server.

4. Handle server response."

feedback: "

- Success: Navigate to next screen, show success message (

gemini Output

Mobile App Wireframe Kit: Complete Specification

Date: October 26, 2023

Version: 1.0

Prepared For: [Customer Name/Team]


1. Executive Summary

This document provides a comprehensive Mobile App Wireframe Kit, detailing the structural blueprint and foundational interactions for your mobile application. It encompasses detailed screen flows, a standardized component library, defined interaction patterns, and crucial developer handoff notes. The aim is to establish a clear, consistent, and actionable framework for subsequent design and development phases, ensuring alignment on user experience and technical implementation.


2. Introduction to the Mobile App Wireframe Kit

This Wireframe Kit serves as the definitive guide for understanding the core functionality, user journeys, and visual structure of the mobile application. It is designed to facilitate collaboration between stakeholders, designers, and developers by providing a common language and reference point.

Purpose:

  • To visualize the app's structure and layout at a low fidelity.
  • To define key user flows and navigation pathways.
  • To establish a consistent set of reusable UI components.
  • To document standard interaction behaviors.
  • To provide clear instructions for development teams.

How to Use This Document:

  • Stakeholders: Review screen flows and interaction patterns to validate core user journeys and business objectives.
  • Designers: Utilize the component library and interaction patterns as a foundation for high-fidelity mockups and prototypes.
  • Developers: Refer to the component library, interaction patterns, and developer handoff notes for technical implementation and front-end development.

3. Core Wireframes & Screen Flows

This section outlines the primary screens and the navigational pathways users will take through the application. Each flow describes a key user journey, connecting individual screens to illustrate the complete experience.

Naming Convention:

  • S-XXX: Screen Identifier (e.g., S-001: Splash Screen)
  • C-XXX: Component Identifier (e.g., C-001: Primary Button)

3.1. General Screen Structure

All screens generally adhere to a common structure:

  • Status Bar: Top-most area displaying time, battery, network status.
  • Navigation Bar / Header: Contains screen title, back button, or action buttons.
  • Content Area: Main region for displaying information and interactive elements.
  • Tab Bar / Bottom Navigation: Persistent navigation at the bottom (if applicable).

3.2. Key User Journeys & Flows

##### 3.2.1. Onboarding & Account Creation Flow

Objective: Guide new users through the initial setup, introducing key features, and enabling account creation or login.

  • S-001: Splash Screen

* Description: Displays app logo and branding briefly upon launch.

* Navigation: Auto-advances to S-002 after 2-3 seconds.

  • S-002: Welcome / Onboarding Carousel (3 screens)

* Description: Illustrates key app benefits with short text and imagery. Includes "Skip" and "Next" buttons.

* Navigation:

* "Next" button: Advances to the next carousel screen (S-002a -> S-002b -> S-002c).

* "Skip" button / Last carousel "Get Started" button: Navigates to S-003.

  • S-003: Login / Sign Up Options

* Description: Presents options to "Log In" or "Create Account". Includes social login options (Google, Apple).

* Navigation:

* "Log In" button: Navigates to S-004.

* "Create Account" button: Navigates to S-005.

* Social Login buttons: Initiates respective OAuth flow, then navigates to S-006 upon success.

  • S-004: Login Screen

* Description: Fields for Email/Username and Password. "Forgot Password" link. "Log In" button.

* Navigation:

* "Log In" button (on success): Navigates to S-006.

* "Forgot Password" link: Navigates to S-007.

* Back button: Navigates to S-003.

  • S-005: Create Account Screen

* Description: Fields for Name, Email, Password, Confirm Password. "Create Account" button. Checkbox for "Agree to Terms & Conditions".

* Navigation:

* "Create Account" button (on success): Navigates to S-006 (or S-008 for email verification).

* Back button: Navigates to S-003.

  • S-006: Home Screen (Logged In)

* Description: Main dashboard/feed of the app.

* Navigation: Serves as the primary entry point post-login/onboarding.

  • S-007: Forgot Password Screen

* Description: Field for Email. "Reset Password" button. Instructions for email check.

* Navigation:

* "Reset Password" button: Displays success message (e.g., Toast), then back to S-004.

* Back button: Navigates to S-004.

  • S-008: Email Verification Screen (Optional)

* Description: Informs user to check email for verification link. Resend option.

* Navigation:

* "Resend Email" button: Retries sending verification email.

* "Continue" button (after verification): Navigates to S-006.

##### 3.2.2. Product Browsing & Detail Flow (Example: E-commerce App)

Objective: Allow users to browse products, view details, and add items to a cart.

  • S-010: Home Screen / Category Listing

* Description: Displays featured products, categories, or a personalized feed. Includes a search bar and a bottom navigation bar.

* Navigation:

* Tap on a product card: Navigates to S-011.

* Tap on a category: Navigates to S-012.

* Tap search bar: Navigates to S-013.

* Bottom Navigation: Home (S-010), Categories (S-012), Cart (S-015), Profile (S-020).

  • S-011: Product Detail Screen

* Description: Displays product image gallery, name, price, description, reviews, size/color options, "Add to Cart" button.

* Navigation:

* "Add to Cart" button: Adds item to cart, displays confirmation (e.g., Toast), remains on S-011.

* Back button: Navigates to previous screen (S-010 or S-012).

* Tap on review section: Navigates to S-014 (Product Reviews).

  • S-012: Product Category Screen

* Description: Displays a grid or list of products within a selected category. Includes filters and sort options.

* Navigation:

* Tap on a product card: Navigates to S-011.

* Tap filter icon: Opens filter modal/bottom sheet (M-001).

* Back button: Navigates to S-010.

  • S-013: Search Results Screen

* Description: Displays search input, recent searches/suggestions, and a list of search results.

* Navigation:

* Tap on a search result: Navigates to S-011.

* Back button: Navigates to S-010.

  • S-014: Product Reviews Screen

* Description: Lists all reviews for a specific product. Option to "Write a Review".

* Navigation:

* "Write a Review" button: Navigates to S-014a (Write Review Form).

* Back button: Navigates to S-011.

  • S-015: Shopping Cart Screen

* Description: Lists items in the cart, quantities, subtotal, shipping options, "Checkout" button.

* Navigation:

* "Checkout" button: Navigates to S-016 (Checkout Flow).

* Back button: Navigates to previous screen (e.g., S-011).


4. Component Library

This section defines the reusable UI components that form the building blocks of the application. Standardizing these components ensures consistency, accelerates design and development, and improves maintainability.


4.1. Basic Input & Display Elements

  • C-001: Primary Button

* Description: Main call-to-action button. High visual emphasis.

* States: Default, Pressed, Disabled, Loading (with spinner).

* Properties: Text label, Optional icon (left/right).

* Usage: "Submit," "Next," "Add to Cart," "Sign Up."

  • C-002: Secondary Button

* Description: Alternative actions, less emphasis than primary.

* States: Default, Pressed, Disabled.

* Properties: Text label, Optional icon.

* Usage: "Cancel," "Skip," "Learn More."

  • C-003: Tertiary / Ghost Button

* Description: Minimal visual emphasis, often text-only or icon-only.

* States: Default, Pressed, Disabled.

* Properties: Text label, Icon.

* Usage: "Forgot Password," "View All," "Edit."

  • C-004: Text Field

* Description: Allows users to input text.

* States: Default, Focused, Error, Disabled, Filled.

* Properties: Label, Placeholder text, Helper text, Leading/Trailing icon, Keyboard type (text, number, email, password).

* Usage: Forms, search inputs.

  • C-005: Checkbox

* Description: Allows selection of multiple options from a set.

* States: Unchecked, Checked, Disabled.

* Properties: Label.

* Usage: Terms & Conditions, multiple choice filters.

  • C-006: Radio Button

* Description: Allows selection of a single option from a set.

* States: Unselected, Selected, Disabled.

* Properties: Label.

* Usage: Gender selection, single choice options.

  • C-007: Toggle Switch

* Description: On/Off switch for settings or features.

* States: Off, On, Disabled.

* Properties: Label.

* Usage: Push notifications, dark mode.

  • C-008: Icon

* Description: Small visual symbols representing actions or concepts.

* Properties: Size (e.g., 24x24dp), Color, Type (outline, filled).

* Usage: Navigation, actions, status indicators.

  • C-009: Avatar / Profile Picture

* Description: Circular image representing a user or entity.

* Properties: Size (small, medium, large), Placeholder (initials or generic icon).

* Usage: User profiles, comments.


4.2. Navigation & Layout Components

  • C-010: Top Navigation Bar / Header

* Description: Top area of the screen, typically containing title, back button, and optional

mobile_app_wireframe_kit.txt
Download source file
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);}});}