Training Course Builder
Run ID: 69cc4fa68f41b62a970c28522026-03-31Education
PantheraHive BOS
BOS Dashboard

Build a complete training course with modules, lesson plans, quizzes, hands-on exercises, and certification criteria for any subject.

Step 1: Research & Design Requirements for "Training Course Builder"

This document outlines the detailed design specifications, wireframe descriptions, color palette, and user experience (UX) recommendations for the "Training Course Builder" application. The goal is to create an intuitive, powerful, and aesthetically pleasing platform that empowers users to build comprehensive training courses for any subject with ease.


1. Design Specifications

The Training Course Builder will be a web-based application focused on empowering course creators.

1.1 Core Functionality

  • Course Creation & Management:

* Ability to create new courses from scratch.

* Manage existing courses (edit, delete, duplicate, publish/unpublish).

* Set course title, description, category, target audience, and learning objectives.

* Upload course thumbnail/cover image.

  • Module Management:

* Create, edit, delete, and reorder modules within a course.

* Set module titles and descriptions.

  • Lesson Management:

* Create, edit, delete, and reorder lessons within modules.

* Support for various content types: text, images, videos, audio, external links, downloadable files (PDF, DOCX, PPTX).

* Rich Text Editor (WYSIWYG) for lesson content.

* Ability to embed media directly.

  • Quiz Builder:

* Create multiple-choice, true/false, fill-in-the-blank, and short-answer questions.

* Set correct answers, point values, and feedback for each question.

* Randomize question order within a quiz.

* Set passing score percentage.

* Configure quiz attempts allowed.

  • Hands-on Exercise Management:

* Define exercise instructions, requirements, and submission guidelines.

* Specify expected output or artifacts.

* Option for file uploads or text-based submissions by learners.

* Provide grading criteria or rubrics for instructors.

  • Certification Criteria:

* Define conditions for course completion and certification (e.g., complete all lessons, pass all quizzes, submit all exercises).

* Customizable certificate template with dynamic fields (learner name, course name, date, instructor signature/logo).

* Automated certificate generation upon successful completion.

  • Course Settings:

* Visibility settings (public, private, password-protected).

* Prerequisites (if any).

* Drip content options (release modules/lessons on specific dates or after previous completion).

  • Preview Mode:

* Ability to preview the course content and flow from a learner's perspective.

  • Collaboration (Future Scope/Advanced):

* Ability for multiple instructors/designers to collaborate on a single course.

1.2 User Roles

  • Course Creator/Admin: Full access to create, edit, manage, and publish courses. This is the primary user for this builder.
  • Learner: (Out of scope for this builder step, but the output created by this builder will be consumed by Learners).

1.3 Technology & Performance

  • Responsive Design: Optimized for desktop, tablet, and mobile browsers.
  • Fast Loading Times: Efficient asset loading and optimized database queries.
  • Secure: Data encryption, secure authentication, and authorization.
  • Scalable: Architecture designed to handle a growing number of courses and users.

2. Wireframe Descriptions

The wireframes will prioritize clarity, ease of use, and efficient content creation.

2.1 Dashboard / Course Overview

  • Layout: Grid or list view of all created courses.
  • Elements:

* "Create New Course" prominent button.

* Course cards/rows displaying: Course Title, Thumbnail, Status (Draft, Published), Progress (e.g., "70% complete"), Actions (Edit, Duplicate, Preview, Delete).

* Search and Filter options (by category, status).

* Left-hand navigation for "My Courses," "Templates," "Settings."

2.2 Course Creation Wizard (Step-by-Step)

  • Layout: Multi-step form with clear progress indicators (e.g., Step 1 of 5).
  • Step 1: Basic Information: Course Title, Short Description, Long Description (WYSIWYG), Category, Target Audience.
  • Step 2: Media & Branding: Course Thumbnail Upload, Instructor Bio, Welcome Video (optional).
  • Step 3: Structure: Initial module creation (e.g., "Module 1: Introduction").
  • Step 4: Settings: Visibility, Prerequisites, Pricing (if applicable), Drip Content.
  • Step 5: Review & Publish: Summary of settings, "Save Draft" and "Publish Course" buttons.

2.3 Course Editor (Module & Lesson Management)

  • Layout: Two-column layout.

* Left Column (Navigation Tree): Hierarchical view of Course -> Modules -> Lessons. Drag-and-drop functionality for reordering. Buttons for "Add Module," "Add Lesson."

* Right Column (Content Editor): Dynamic area displaying the selected module/lesson's content.

  • Module Editor View: Module Title, Description, "Add Lesson" button.
  • Lesson Editor View:

* Lesson Title.

* WYSIWYG Content Area: Toolbar for formatting (bold, italic, lists, headings), media embeds (image, video, audio), link insertion, code blocks, file uploads.

* "Add Quiz," "Add Exercise" buttons (contextual).

* "Save Lesson" button.

* "Preview Lesson" button.

2.4 Quiz Builder

  • Layout: Question list on the left, question editor on the right.
  • Elements:

* "Add Question" button (with dropdown for question types: MCQ, True/False, Fill-in-the-Blank, Short Answer).

* List of existing questions (with drag-and-drop reordering).

* Question Editor:

* Question Text field.

* Answer input fields (dynamically changes based on question type).

* Correct Answer selection/input.

* Point Value field.

* Optional Feedback field (for correct/incorrect answers).

* "Save Question" / "Delete Question" buttons.

* Quiz Settings: Passing Score, Attempts Allowed, Time Limit (optional).

2.5 Exercise Builder

  • Layout: Single-page form for defining an exercise.
  • Elements:

* Exercise Title.

* Instructions (WYSIWYG editor).

* Requirements/Deliverables (e.g., "Submit a 500-word essay," "Upload a Python script").

* Submission Type (File Upload, Text Input, External Link).

* Grading Criteria/Rubric (WYSIWYG or structured input).

* Due Date (optional).

* "Save Exercise" button.

2.6 Certification Settings

  • Layout: Form-based.
  • Elements:

* Completion Criteria Checklist (e.g., "Complete all lessons," "Pass all quizzes," "Submit all exercises").

* Certificate Template Customization:

* Preview of the certificate.

* Fields for Course Title, Learner Name, Date of Completion, Instructor Signature/Logo upload.

* Text editor for custom message.

* "Save Settings" button.


3. Color Palette

The chosen palette aims for professionalism, approachability, and excellent readability.

3.1 Primary Colors

  • Deep Teal / Navy Blue (#004D40 or #1A2F4B): Dominant for headers, primary buttons, branding elements. Conveys professionalism, trust, and stability.
  • Vibrant Green / Sky Blue (#4CAF50 or #2196F3): Accent color for calls-to-action, active states, progress indicators. Evokes growth, success, and clarity.

3.2 Secondary Colors

  • Light Gray / Off-White (#F5F5F5 or #FAFAFA): Backgrounds, content areas. Provides a clean, minimalist canvas.
  • Medium Gray (#757575): Secondary text, subtle borders, inactive elements. Ensures good contrast without being overly dominant.

3.3 Semantic Colors

  • Success (#4CAF50): For successful actions, completion messages.
  • Warning (#FFC107): For cautionary alerts, pending actions.
  • Error (#F44336): For error messages, critical alerts.

3.4 Typography Colors

  • Dark Gray (#212121): Primary text for maximum readability.
  • Medium Gray (#757575): Secondary text, placeholders, subheadings.

3.5 Accessibility Considerations

  • Ensure sufficient contrast ratios (WCAG 2.1 AA or AAA standards) between text and background colors.
  • Utilize color in conjunction with other visual cues (icons, text) to convey meaning, especially for semantic colors.

4. UX Recommendations

User experience is paramount for a powerful yet easy-to-use course builder.

4.1 Intuitive Navigation & Information Architecture

  • Clear Hierarchy: A logical structure from "Course" to "Module" to "Lesson/Quiz/Exercise."
  • Persistent Global Navigation: Easy access to "My Courses," "Templates," "Account Settings" from anywhere in the application.
  • Contextual Navigation: Left-hand tree view in the Course Editor for quick jumps between modules and lessons.
  • Breadcrumbs: Always show the user's current location within the course structure (e.g., "Course Name > Module Name > Lesson Name").

4.2 Content Creation & Editing

  • WYSIWYG Editor: Provide a robust, user-friendly rich text editor with common formatting options, media embedding, and code block support.
  • Drag-and-Drop: Implement drag-and-drop functionality for reordering modules, lessons, and quiz questions. This offers a highly intuitive interaction.
  • In-line Editing: Allow for quick edits of titles and descriptions directly within the main view where possible.
  • Autosave: Automatically save work in progress to prevent data loss, with clear visual feedback (e.g., "Saving..." then "Saved").
  • Version Control (Advanced/Future): Option to revert to previous versions of content.

4.3 Feedback & Guidance

  • Clear Call-to-Actions (CTAs): Buttons should be clearly labeled and visually distinct.
  • Progress Indicators: For multi-step processes (like course creation wizards), show users their progress.
  • Tooltips & Onboarding: Provide helpful tooltips for complex features and a brief onboarding tour for first-time users.
  • Validation & Error Messages: Provide immediate, clear, and actionable feedback for form validations and errors.
  • Confirmation Dialogs: For destructive actions (e.g., deleting a course), require explicit confirmation.

4.4 Efficiency & Control

  • Keyboard Shortcuts: Offer common keyboard shortcuts for power users (e.g., Ctrl+S for save).
  • Undo/Redo (Advanced/Future): For content editing.
  • Bulk Actions: Ability to select and perform actions on multiple items (e.g., delete multiple lessons).
  • Search & Filter: Robust search and filtering capabilities on the course dashboard and within content lists.

4.5 Accessibility

  • WCAG Compliance: Design with Web Content Accessibility Guidelines (WCAG 2.1 AA) in mind.
  • Keyboard Navigation: Ensure all interactive elements are accessible via keyboard.
  • Screen Reader Compatibility: Use proper semantic HTML and ARIA attributes.
  • High Contrast Mode: Offer an optional high-contrast theme for users with visual impairments.

4.6 Responsiveness

  • Mobile-First Approach: Design for smaller screens first, then progressively enhance for larger screens, ensuring a consistent experience across all devices.
  • Fluid Layouts: Use responsive grids and flexible images to adapt to different screen sizes.

This detailed output provides a solid foundation for the subsequent steps of development, ensuring that the "Training Course Builder" is robust, user-friendly, and capable of meeting the diverse needs of course creators.

gemini Output

Training Course Builder: Design Specifications & UX Recommendations

This document outlines the detailed design specifications, wireframe descriptions, color palette, and user experience (UX) recommendations for the "Training Course Builder" application. The goal is to create an intuitive, powerful, and professional tool that enables users to efficiently build comprehensive training courses.


1. Detailed Design Specifications

The Training Course Builder will empower instructors and administrators to craft structured learning experiences.

1.1 Functional Requirements

  • Course Management:

* Create, edit, delete, and duplicate courses.

* Set course title, description, thumbnail image, category, and tags.

* Define course prerequisites and target audience.

* Set course pricing (if applicable) and enrollment options.

* Publish/unpublish courses.

* Preview course content as a learner.

  • Module Management:

* Create, edit, delete, and reorder modules within a course (drag-and-drop).

* Set module title and description.

* Define module completion criteria.

  • Lesson Management:

* Create, edit, delete, and reorder lessons within a module (drag-and-drop).

* Support various content types within lessons:

* Rich Text Editor (WYSIWYG) for text, images, tables, links.

* Video embeds (YouTube, Vimeo, custom uploads).

* Audio embeds.

* File attachments (PDF, PPT, DOCX, etc.).

* Code blocks.

* Embeddable content (e.g., interactive simulations, external tools).

* Set lesson title and description.

* Mark lessons as optional/required.

* Set estimated lesson duration.

  • Quiz Builder:

* Create standalone quizzes or attach to lessons/modules.

* Support multiple question types:

* Multiple Choice (single answer)

* Multiple Select (multiple answers)

* True/False

* Short Answer (text input)

* Matching

* Sequencing/Ordering

* Set correct answers and provide optional feedback for each answer.

* Assign points/weight to questions.

* Randomize question order.

* Set time limits for quizzes.

* Define passing score.

* Allow multiple attempts with configurable cool-down periods.

  • Hands-on Exercise Builder:

* Create detailed exercise descriptions with rich text and media.

* Define submission requirements (e.g., file upload, text input, code submission).

* Provide starter files or templates for exercises.

* Set grading criteria/rubrics.

* Allow for peer review options.

  • Certification Criteria:

* Define criteria for course completion and certification:

* Completion of all required modules/lessons.

* Minimum score on quizzes.

* Submission and approval of exercises.

* Total time spent in the course.

* Design and customize digital certificates (template editor for text, logos, dynamic fields).

* Automate certificate generation upon successful completion.

  • Content Library/Assets:

* Upload and manage media files (images, videos, documents) in a central library.

* Reuse assets across multiple courses/lessons.

  • Version Control & Autosave:

* Automatic saving of course progress.

* Ability to revert to previous versions of course content (optional, advanced feature).

  • Collaboration (Future Consideration):

* Multiple instructors/authors can contribute to a single course with role-based permissions.

1.2 User Flows (High-Level)

  1. Create New Course:

* Dashboard → "New Course" button → Enter basic course info (title, description) → Course Editor.

  1. Edit Existing Course:

* Dashboard → Select Course → "Edit Course" button → Course Editor.

  1. Add Module:

* Course Editor → "Add Module" button → Enter module details → Module added to list.

  1. Add Lesson:

* Course Editor (within Module) → "Add Lesson" button → Select content type → Lesson Editor.

  1. Build a Quiz:

* Lesson/Module Editor → "Add Quiz" → Quiz Builder interface → Define questions, answers, settings.

  1. Setup Certification:

* Course Editor → "Certification" tab → Define criteria, design certificate.

  1. Publish Course:

* Course Editor → "Publish" button → Confirmation → Course live.

1.3 Data Model (Conceptual)

  • Course: id, title, description, thumbnail_url, category, tags, status (draft, published, archived), price, prerequisites, target_audience, created_by, created_at, updated_at.
  • Module: id, course_id, title, description, order, completion_criteria.
  • Lesson: id, module_id, title, description, type (text, video, quiz, exercise), content_data (JSON/HTML), order, duration, is_required.
  • Quiz: id, lesson_id (optional), module_id (optional), title, description, passing_score, time_limit, attempts_allowed, shuffle_questions.
  • Question: id, quiz_id, type, text, options (for MC/MS), correct_answer_data, points, feedback.
  • Exercise: id, lesson_id (optional), module_id (optional), title, description, submission_type, starter_files_url, grading_rubric.
  • Certificate: id, course_id, template_html, criteria_json.
  • Asset: id, filename, url, type, uploaded_by, uploaded_at.

2. Wireframe Descriptions

The following describes key screens and their components.

2.1 Course Dashboard (Overview)

  • Layout: Left sidebar for navigation (Courses, Assets, Settings), main content area for course list.
  • Elements:

* Header: "Courses" title, "New Course" button (primary action), Search bar, Filter/Sort options (e.g., Drafts, Published, Category).

* Course Cards/List: Each card represents a course.

* Course thumbnail, title, status (Draft/Published), last updated date.

* Progress bar/stats (e.g., number of modules/lessons).

* Action buttons: "Edit," "Preview," "Duplicate," "Delete" (ellipsis menu for more options).

2.2 Course Editor (Structure View)

  • Layout: Top header for course-level actions, left sidebar for course settings/tabs, main content area for module/lesson structure.
  • Elements:

* Header: Course Title (editable), "Save Draft," "Publish," "Preview Course" buttons.

* Left Sidebar (Course Settings Tabs):

* "Structure" (default view: Modules & Lessons)

* "Details" (Course title, description, thumbnail, category, tags)

* "Pricing & Enrollment"

* "Certification"

* "Settings" (Advanced options)

* Main Content Area (Structure):

* "Add Module" Button: Prominently displayed.

* Module Cards/Sections: Collapsible sections.

* Module Title (editable), description.

* "Add Lesson," "Add Quiz," "Add Exercise" buttons within each module.

* Drag handle for reordering modules.

* Module-level actions (Edit, Delete, Duplicate - via ellipsis menu).

* Lesson/Quiz/Exercise Items: Nested within modules.

* Icon indicating content type (text, video, quiz, exercise).

* Item Title (editable).

* Estimated duration/points.

* Drag handle for reordering items within a module.

* Item-level actions (Edit Content, Delete, Duplicate - via ellipsis menu).

2.3 Lesson Editor (Rich Content)

  • Layout: Top header for lesson actions, main content area for editor, right sidebar for lesson settings.
  • Elements:

* Header: Lesson Title (editable), "Save," "Preview Lesson," "Back to Course Structure" buttons.

* Main Content Area:

* Rich Text Editor (WYSIWYG): Standard formatting tools (bold, italic, lists, headings, links, images, video embeds).

* Specific Content Blocks: Buttons/menus to insert specific content types (e.g., "Add Video," "Add File," "Add Code Block," "Embed HTML").

* Right Sidebar (Lesson Settings):

* "Lesson Type" (display only, e.g., "Text & Media")

* "Estimated Duration" input.

* "Required/Optional" toggle.

* "Associated Quiz/Exercise" (link to existing or create new).

* "Visibility" (e.g., published/draft).

2.4 Quiz Builder

  • Layout: Top header for quiz actions, main content area for question list, right sidebar for quiz settings.
  • Elements:

* Header: Quiz Title (editable), "Save Quiz," "Preview Quiz," "Back to Lesson/Module" buttons.

* Main Content Area:

* "Add Question" Button: Dropdown for question types (MC, MS, T/F, Short Answer, etc.).

* Question Cards: Each card represents a question.

* Question Text (editable).

* Answer input fields (radio buttons, checkboxes, text areas) with correct answer indicators.

* Feedback fields (optional).

* Points input.

* Drag handle for reordering questions.

* Question-level actions (Edit, Delete, Duplicate - via ellipsis menu).

* Right Sidebar (Quiz Settings):

* "Passing Score (%)" input.

* "Time Limit" input (minutes).

* "Attempts Allowed" input.

* "Shuffle Questions" toggle.

* "Show Correct Answers After Submission" toggle.

2.5 Certification Settings

  • Layout: Top header, main content area for criteria definition and certificate design.
  • Elements:

* Header: "Certification Settings" title, "Save Changes" button.

* Criteria Section:

* Checkboxes/Toggles for various criteria: "Complete all required lessons," "Achieve X% on all quizzes," "Submit all exercises."

* Input fields for specific thresholds (e.g., percentage for quizzes).

* Certificate Design Section:

* "Choose Template" dropdown/gallery.

* Live Preview Area: Displays the certificate with dynamic fields.

* Customization Options:

* Upload Course Logo.

* Fields for Certificate Title, Instructor Name, Issuer Name.

* Toggle for dynamic fields (Learner Name, Completion Date, Course Name).

* Simple text editor for additional static text.

* Color picker for text/background (limited to template options).


3. Color Palette

A professional, clean, and engaging color palette will be used to ensure a pleasant user experience.

  • Primary Brand Color: #2E86DE (Ocean Blue)

* Usage: Main call-to-action buttons ("New Course," "Publish"), active navigation states, primary headings, progress indicators. Evokes trust, professionalism, and clarity.

  • Secondary Accent Color: #28B463 (Emerald Green)

* Usage: Success messages, "Save" buttons, positive feedback, completion indicators. Represents growth and success.

  • Tertiary Accent Color: #F4D03F (Sunshine Yellow)

* Usage: Warning messages, highlights for important notices, interactive elements that need to stand out without being a primary action.

  • Neutral Tones (Backgrounds & Text):

* Background (Light): #F8F9FA (Light Gray/Off-White): Clean and spacious feel for main content areas.

* Background (Mid): #E9ECEF (Lighter Gray): For secondary panels, card backgrounds, or subtle section separation.

* Text (Primary): #212529 (Dark Charcoal): For main body text, ensuring high readability.

* Text (Secondary): #6C757D (Medium Gray): For descriptions, subheadings, helper text.

* Borders/Dividers: #DEE2E6 (Light Blue-Gray): Subtle separation of elements.

  • Error Color: #DC3545 (Crimson Red)

* Usage: Error messages, delete actions, validation failures.


4. UX Recommendations

These recommendations focus on usability, accessibility, and overall user satisfaction.

  1. Intuitive Navigation & Information Architecture:

* Clear Hierarchy: Use clear headings, subheadings, and visual cues to define content hierarchy.

* Persistent Navigation: A consistent left sidebar or top bar for main application navigation (Courses, Assets, Settings) and within the Course Editor (Structure, Details, Certification).

* Breadcrumbs: Implement breadcrumbs for deep navigation paths (e.g., Course Name > Module Name > Lesson Name) to help users understand their location.

  1. Drag-and-Drop Functionality:

* Reordering: Enable drag-and-drop for reordering modules, lessons, quizzes, and questions within their respective lists. Provide clear visual feedback during dragging (e.g., ghost element, highlight drop zone).

  1. In-line Editing & Contextual Actions:

* Direct Editing: Allow users to directly click and edit titles/descriptions of courses, modules, and lessons without navigating to a separate edit screen where possible.

* Ellipsis Menus (...): Use ellipsis menus for secondary actions (Delete, Duplicate, Settings) on course cards, module items, and lesson items to keep the interface clean.

  1. Rich Text Editor (WYSIWYG):

* Robust & Familiar: Provide a feature-rich yet intuitive WYSIWYG editor for lesson content, similar to common word processors (e.g., TinyMCE, CKEditor).

* Media Integration: Easy insertion of images, videos (embed/upload), and file attachments directly within the editor.

  1. Real-time Feedback & Autosave:

* Autosave: Implement an autosave feature for all content creation (lessons, quizzes, exercises) to prevent data loss. Display a clear "Saving..." / "Saved" status indicator.

* Validation: Provide immediate feedback for form validation errors.

  1. Preview Functionality:

* "Preview as Learner": Offer a dedicated preview mode to allow instructors to see exactly how learners will experience the course, modules, lessons, quizzes, and exercises.

* Live Previews: For certificate design and rich text content, provide a live preview as edits are made.

  1. Accessibility (WCAG 2.1 AA Compliance):

* Keyboard Navigation: Ensure all interactive elements are reachable and operable via keyboard.

* Screen Reader Compatibility: Use proper semantic HTML, ARIA attributes

gemini Output

Finalizing Design Assets for the Training Course Builder

This document outlines the detailed design specifications, wireframe descriptions, color palettes, and user experience (UX) recommendations for the "Training Course Builder." The goal is to create an intuitive, powerful, and visually appealing platform that empowers users to efficiently build, manage, and deploy high-quality training courses.


1. Overall Design Philosophy

The design of the Training Course Builder will prioritize:

  • Clarity & Simplicity: A clean, uncluttered interface that minimizes cognitive load.
  • Efficiency: Streamlined workflows and intuitive tools to expedite course creation.
  • Flexibility: Adaptable components to support diverse content types and course structures.
  • Consistency: Uniform design elements and interactions across the platform for predictability.
  • Professionalism: A polished, modern aesthetic that instills confidence and reflects the quality of the courses built.
  • User Empowerment: Providing tools that give creators full control while guiding them through best practices.

2. Detailed Design Specifications

2.1. Dashboard / Course Overview

  • Purpose: Central hub for managing all created courses.
  • Components:

* Header: Logo, user profile/settings, "New Course" button.

* Course Listing: Cards or table view for each course, displaying:

* Course Title & Description

* Status (Draft, Published, Archived)

* Last Edited Date

* Progress Indicator (e.g., % complete of content)

* Action Buttons (Edit, Preview, Publish/Unpublish, Archive, Delete, Duplicate).

* Filters & Search: By status, title, creation date, etc.

* Analytics Overview (Optional): High-level metrics for published courses (e.g., total learners, completion rate).

  • Interaction: Click on a course card/row to enter the Course Editor.

2.2. Course Structure Editor (Modules & Lessons)

  • Purpose: Define the hierarchical structure of the course.
  • Layout: Two-panel or three-panel layout.

* Left Panel (Navigation Tree): Hierarchical view of Modules and Lessons.

* Drag-and-drop functionality for reordering.

* Context menu (right-click or ellipsis icon) for Add Module, Add Lesson, Edit, Duplicate, Delete.

* Visual indicators for content completion status within each lesson.

* Main Content Area (Overview/Settings):

* Course Settings: Title, description, thumbnail image, category, tags, target audience, prerequisites.

* Module Settings (when a module is selected): Title, description, learning objectives.

* Lesson Settings (when a lesson is selected): Title, type (Content, Quiz, Exercise), duration estimate, learning objectives.

* Global Course Settings: Certification criteria, grading schema, access control.

  • Key Features:

* Drag-and-Drop: For reordering modules and lessons.

* Bulk Actions: Select multiple items for deletion or reordering.

* Progress Indicators: Visual cues on the tree to show which lessons/modules have content.

2.3. Content Editor Interface

  • Purpose: Create and manage the actual lesson content.
  • Layout:

* Left Sidebar: Course structure navigation (collapsed or expanded).

* Main Editor Area: Rich Text Editor (WYSIWYG) with extensive formatting options.

* Right Sidebar (Contextual): Lesson-specific settings (e.g., duration, tags, visibility) or asset library.

  • Components:

* Rich Text Editor:

* Standard formatting (bold, italics, underline, lists, headings).

* Media embedding (images, videos from URL/upload, audio).

* Code blocks, tables, hyperlinks.

* Callout boxes/info panels.

* File attachments.

* Version history/undo-redo.

* Content Blocks: Ability to add pre-defined content blocks (e.g., "Key Takeaway," "Discussion Prompt," "Further Reading").

* Preview Mode: Toggle to see how the content will appear to learners.

2.4. Quiz Builder Interface

  • Purpose: Create interactive quizzes to assess learning.
  • Layout: Similar to Content Editor, with a focus on question types.
  • Components:

* Question List: Sidebar listing all questions in the quiz, with drag-and-drop reordering.

* Question Editor (Main Area):

* Question Type Selector: Multiple Choice (single/multiple answer), True/False, Short Answer, Matching, Fill-in-the-Blanks.

* Question Text Input: Rich text editor for question prompt.

* Answer Options Input: Dynamic fields based on question type.

* Correct Answer Selection: Clear indicators.

* Feedback Fields: For correct/incorrect answers.

* Point Value: Assign points per question.

* Media Support: Add images/videos to questions or answers.

* Quiz Settings (Right Sidebar):

* Passing score, time limit, number of attempts, randomize questions/answers, show answers immediately/at end.

  • Key Features:

* Question Bank Integration: Ability to pull questions from a central bank.

* Preview Question: See how a single question looks.

2.5. Hands-on Exercise Builder Interface

  • Purpose: Define practical exercises and their evaluation.
  • Layout:

* Left Sidebar: Exercise list if multiple exercises in one lesson.

* Main Editor Area:

* Exercise Instructions: Rich text editor for detailed steps, requirements, examples.

* Resources/Files: Upload starter files, templates, or reference materials.

* Submission Type: Text input, file upload, URL submission.

* Evaluation Criteria/Rubric Builder: Define specific criteria, point values, and performance levels.

* Example Solution (Optional): Provide a model answer for instructors.

* Grading Guidelines: Instructions for evaluators.

* Right Sidebar: Exercise settings (e.g., due date, peer review option, visibility).

2.6. Certification Criteria & Template Editor

  • Purpose: Define requirements for course completion and design the certificate.
  • Components:

* Criteria Definition:

* List of requirements (e.g., "Complete all modules," "Achieve 80% on final quiz," "Submit all exercises").

* Ability to add custom criteria.

* Certificate Template Designer:

* Visual editor for certificate layout.

* Placeholders for dynamic data: Course Title, Learner Name, Date of Completion, Instructor Signature, Course ID.

* Upload custom logos, background images.

* Font selection, color customization.

* Preview of the generated certificate.

* Issuance Settings: Automatic vs. Manual issuance.

2.7. Preview & Publishing

  • Purpose: Review the course from a learner's perspective and deploy it.
  • Preview Mode:

* Toggle to view the entire course as a learner would.

* Navigation allows moving through modules and lessons.

* Test quizzes and exercises.

* Responsive design preview for different devices (desktop, tablet, mobile).

  • Publishing Options:

* Publish to Platform: Make the course available within the integrated learning environment.

* SCORM/xAPI Export: Downloadable package for other LMS platforms.

* Shareable Link: Generate a link for direct access (if applicable).

* Access Control: Public, Private (invite-only), Password Protected.

* Versioning: Option to publish as a new version, keeping previous versions accessible.

2.8. Global Elements

  • Top Navigation Bar: Logo, Course Title (contextual), "Save" status, "Preview" button, "Publish" button, User Profile/Settings.
  • Left Global Sidebar (Collapsed/Expandable): For navigating between major sections of the builder (Dashboard, Course Editor, Asset Library, Analytics, Settings).
  • Notifications & Alerts: Toast messages for success, error, or warning.
  • Modals & Dialogs: For confirmation, settings, or complex inputs.

3. Wireframe Descriptions (Key Screens)

3.1. Wireframe: Dashboard - Course Listing

  • Layout: Full-width content area.
  • Header: [Logo] [User Profile/Settings] [New Course Button]
  • Filters/Search: [Search Bar] [Dropdown: All Courses] [Dropdown: Status] [Button: Apply Filters]
  • Course Cards (Grid View):

* [Course Thumbnail]

* [Course Title]

* [Short Description]

* [Status Tag: Draft/Published]

* [Progress Bar: 75% Complete]

* [Last Edited: MM/DD/YYYY]

* [Ellipsis Menu: Edit, Preview, Publish, Delete]

  • Empty State: "No courses created yet. Start building your first course!" with a prominent "Create New Course" button.

3.2. Wireframe: Course Structure Editor

  • Layout: Two-panel, fixed left sidebar, scrollable main content.
  • Top Bar: [Back to Dashboard] [Course Title] [Save Status] [Preview Button] [Publish Button]
  • Left Panel (Course Tree - 25% width):

* [Course Title (non-editable)]

* [Add Module Button]

* [Module 1 Title]

* [Lesson 1.1 Title (Content)]

* [Lesson 1.2 Title (Quiz)]

* [Lesson 1.3 Title (Exercise)]

* [Module 2 Title]

* [Lesson 2.1 Title (Content)]

(Each item in the tree has drag handles and an ellipsis menu for actions)*

  • Main Content Area (75% width):

* If Course Selected: <h2>Course Settings</h2> [Input: Course Title] [Textarea: Course Description] [Upload: Thumbnail] [Dropdown: Category] [Input: Tags] [Section: Certification Criteria Link]

* If Module Selected: <h2>Module Settings</h2> [Input: Module Title] [Textarea: Description] [Textarea: Learning Objectives]

* If Lesson Selected: <h2>Lesson Settings</h2> [Input: Lesson Title] [Dropdown: Lesson Type (Content, Quiz, Exercise)] [Input: Estimated Duration] [Textarea: Learning Objectives] [Button: Go to Content Editor]

3.3. Wireframe: Lesson Content Editor

  • Layout: Three-panel, collapsible left and right sidebars, central editor.
  • Top Bar: [Back to Structure] [Lesson Title] [Save Status] [Preview Lesson Button]
  • Left Panel (Course Tree - Collapsed/Expandable): [Course Navigation (Module/Lesson list)]
  • Main Editor Area (Central - 70% width):

* [Rich Text Editor Toolbar]

* [Content Area (WYSIWYG)]

* [Add Content Block Button]

  • Right Panel (Contextual Settings - 30% width):

* <h3>Lesson Properties</h3> [Dropdown: Visibility] [Input: Tags]

* <h3>Media Library</h3> [Upload Button] [List of uploaded images/videos]

3.4. Wireframe: Quiz Builder

  • Layout: Two-panel, fixed left sidebar, scrollable main content.
  • Top Bar: [Back to Structure] [Quiz Title] [Save Status] [Preview Quiz Button]
  • Left Panel (Question List - 30% width):

* <h3>Questions</h3> [Add Question Button]

* [Question 1: Multiple Choice] [Drag Handle] [Ellipsis Menu]

* [Question 2: True/False] [Drag Handle] [Ellipsis Menu]

* [Question 3: Short Answer] [Drag Handle] [Ellipsis Menu]

  • Main Content Area (Question Editor - 70% width):

* <h3>Edit Question X</h3>

* [Dropdown: Question Type (Multiple Choice)]

* [Textarea: Question Text]

* [Upload: Question Image/Video]

* For Multiple Choice:

* [Input: Option A] [Checkbox: Correct] [Button: Add Option]

* [Input: Option B] [Checkbox: Correct]

* [Input: Point Value]

* [Textarea: Feedback for Correct Answer]

* [Textarea: Feedback for Incorrect Answer]

* [Button: Save Question]


4. Color Palette

The chosen color palette aims for professionalism, approachability, and optimal readability.

  • Primary Brand Color (Accent): #007BFF (A vibrant, professional blue)

Usage*: Call-to-action buttons, active navigation states, progress bars, primary headings.

  • Secondary Brand Color: #28A745 (A confident, positive green)

Usage*: Success messages, "Publish" buttons, completion indicators.

  • Neutral Backgrounds:

#F8F9FA (Lightest grey, almost white) - Usage*: Main content backgrounds, card backgrounds.

#E9ECEF (Light grey) - Usage*: Sidebar backgrounds, subtle section dividers.

#DEE2E6 (Medium grey) - Usage*: Borders, inactive elements.

  • Text Colors:

#212529 (Dark charcoal) - Usage*: Primary body text, headings.

#6C757D (Medium grey) - Usage*: Secondary text, labels, placeholder text.

#FFFFFF (White) - Usage*: Text on primary brand color backgrounds.

  • Alert/Warning Colors:

#DC3545 (Red) - Usage*: Error messages, delete actions.

*

training_course_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);}});}