Skip to content

Integration Branch (testing-102)#357

Open
Q1WP wants to merge 114 commits intobuildbotics:masterfrom
Q1WP:testing-102
Open

Integration Branch (testing-102)#357
Q1WP wants to merge 114 commits intobuildbotics:masterfrom
Q1WP:testing-102

Conversation

@Q1WP
Copy link
Copy Markdown
Contributor

@Q1WP Q1WP commented Dec 29, 2025

Source Branch: testing-102
Base Version: 2.0.7

Summary

Integration branch merging all three feature branches (bugfixes-complete, feature/macros-and-service-tracking, feature/ui-tweaks) with carefully resolved conflicts. This branch represents the complete, tested enhancement package.

Purpose

This branch serves as:

  1. Reference implementation showing how the three feature branches integrate
  2. Conflict resolution guide for maintainers doing their own merges
  3. Complete testing target with all features working together

Recommendation: Maintainers may prefer to merge the three source branches individually in sequence, using this branch as a reference for conflict resolution decisions.


Merge Sequence

The three feature branches were developed in parallel against the same base, leading to conflicts when integrated:

Phase Branch Merged Conflicts Files
1 bugfixes-complete Clean
2 feature/macros-and-service-tracking 15 8
3 feature/ui-tweaks 73 12

Total: 88 conflicts resolved across 12 files


Phase 2: macros-service after bugfixes

State.py — reset() method

Both branches modified the reset behavior.

Branch Changes
bugfixes Clears distance_mode, clears %dreferenced, clears macro state
macros-service Clears macro state only

Resolution: Take bugfixes — safety-critical behavior (distance mode reset, reference clearing) must be preserved.

Config.py — Macro iteration variable

Branch Code
bugfixes Uses macro_id (undefined)
macros-service Uses i + 1 (correct)

Resolution: Take macros-service — fixes the bug.

Planner.py — get_modal_state() guard

Branch Code
bugfixes Calls get_modal_state() directly
macros-service Adds hasattr() guard first

Resolution: Take macros-service — prevents crashes on older camotics.so without the method.

FileSystem.py — Warning on missing macro source

Branch Behavior
bugfixes Logs warning when macro source not found
macros-service Silent (expected for pre-existing configs)

Resolution: Take macros-service — don't warn on expected behavior.

app.js — State initialization

Branch Changes
bugfixes Full state object with all properties initialized
macros-service Partial initialization

Resolution: Take bugfixes — Vue 1.x reactivity requires pre-initialized properties.

view-control.js — Safety features

Branch Changes
bugfixes program-cleared, program-reloaded events; _get_unreferenced_axes()
macros-service Macro tab filtering, visibility

Resolution: Take bugfixes — safety features required for proper operation.


Phase 3: ui-tweaks after merged branch

view-control.js/pug/styl — Complete redesign

ui-tweaks contains a complete redesign of the control page. Attempting line-by-line merge would be error-prone and time-consuming.

Resolution: Take ui-tweaks versions directly after verifying they contain all required safety features:

  • _get_unreferenced_axes() method
  • _format_reference_error() method
  • skip_reference_check handling in run_macro()
  • program-cleared event handler
  • program-reloaded event handler

view-macros.pug/styl — Confirmation UI placement

Branch Design
macros-service Confirmation checkbox on Safety tab
ui-tweaks Confirmation checkbox inline in macro list

Resolution: Take macros-service versions — the Safety tab design correctly separates concerns:

  • Macros tab: visibility control only (eye icon)
  • Safety tab: confirmation + reference-check bypass

app.js — Multiple features

Manual merge required to preserve features from both branches:

Feature Source
popupMessagesHeader Vue reactivity fix bugfixes
Strict camera_available check (=== true) bugfixes
initialized flag and E-stop handling bugfixes
is_fullscreen state ui-tweaks

Critical Detail: The popupMessagesHeader computed property must read state.s unconditionally BEFORE any conditional logic. Vue 1.x only tracks dependencies that are read during initial evaluation. If state.s is only read inside a conditional that's initially false, Vue won't re-evaluate when it changes.

// CORRECT - read state.s first
popupMessagesHeader() {
  let speed = parseFloat(this.state.s)  // Always read
  let toolType = this.config.tool && this.config.tool['tool-type']
  if (toolType && toolType !== 'Disabled' && !isNaN(speed)) {
    return 'GCode Messages - Spindle: ' + Math.round(speed) + ' RPM'
  }
  return 'GCode Messages'
}

program.js — Cache busting

Branch Implementation
bugfixes Simple url + '?_t=' + timestamp
ui-tweaks Checks for existing query params (? vs &)

Resolution: Take ui-tweaks — handles URLs that already have query parameters.

Addition: Preserve this.time = 0 initialization from bugfixes for Vue reactivity.

Other simple conflicts

File Resolution Rationale
files.js ui-tweaks location_menu_open with click-outside guards
index.pug ui-tweaks Camera link hidden when on camera view
style.styl ui-tweaks Max-width centering for alerts
view-editor.styl bugfixes Flexbox layout more robust than fixed height
macros.styl ui-tweaks Tighter margins (cosmetic)

Conflict Resolution Principles

These principles guided all resolution decisions:

  1. Safety First — When in doubt, preserve safety-critical code
  2. Vue 1.x Reactivity — All state properties must be initialized before use
  3. Complete Redesigns — Take whole files rather than line-by-line merge
  4. Feature Separation — Respect intentional design decisions
  5. Backwards Compatibility — Preserve guards for older library versions
  6. Bug Fixes Win — Actual bug fixes take precedence over other changes

Testing Instance

All changes deployed and testable at:
http://bbctrl.dyndns.org:8091

This is a standalone controller not connected to a machine. The following cannot be tested remotely:

  • Motor movement
  • Spindle feedback (RPM display)
  • Position reference after actual homing
  • E-stop behavior

Files Summary

New Files (11)

  • src/py/bbctrl/Service.py
  • src/py/bbctrl/ServiceHandler.py
  • src/resources/service-template.json
  • src/js/view-macros.js
  • src/js/view-service.js
  • src/js/axis-row.js
  • src/pug/templates/view-macros.pug
  • src/pug/templates/view-service.pug
  • src/pug/templates/axis-row.pug
  • src/stylus/view-macros.styl
  • src/stylus/view-service.styl

Conflict Files (12)

  • src/py/bbctrl/State.py
  • src/py/bbctrl/Config.py
  • src/py/bbctrl/Planner.py
  • src/py/bbctrl/FileSystem.py
  • src/js/app.js
  • src/js/view-control.js
  • src/js/program.js
  • src/js/files.js
  • src/pug/templates/view-control.pug
  • src/pug/index.pug
  • src/stylus/view-control.styl
  • src/stylus/macros.styl

Verification Checklist

Safety-critical features preserved:

Backend:

  • State.reset() clears active_program
  • State.reset() sets distance_mode to 90
  • State.reset() clears %dreferenced for all motors
  • Planner._update_modal_state() has hasattr guard
  • FileSystem.is_protected_path() blocks macro directory access

Frontend:

  • app.js initializes all state properties for Vue reactivity
  • app.js popupMessagesHeader reads state.s before conditional
  • app.js clears selection on E-stop
  • view-control.js has _get_unreferenced_axes()
  • view-control.js has _format_reference_error()
  • view-control.js checks skip_reference_check in run_macro()
  • view-control.js handles program-cleared event
  • view-control.js handles program-reloaded event
  • program.js initializes this.time = 0

UI Design:

  • view-macros.pug has Safety tab (not inline confirm)
  • view-macros.pug macro list has visibility column only
  • view-macros.styl styling matches pug structure

For Maintainers

If merging branches individually instead of using this integration branch:

  1. Merge bugfixes-complete first — Foundation safety fixes
  2. Merge macros-service second — Watch for State.py conflicts; keep bugfixes safety code
  3. Merge ui-tweaks last — Take whole view-control.* files after verifying safety features present; keep macros-service view-macros.* files

The most critical conflict is State.py reset() — ensure the final version includes:

self.set('distance_mode', 90)
for i in range(4):
    self.set('%dhomed' % i, 0)
    self.set('%dreferenced' % i, 0)

Q1WP added 30 commits December 3, 2025 12:41
…handling

Bug buildbotics#1: Startup file clearing
- State.reset() clears active_program on boot
- Frontend clears selected_program on connect if no active_program
- E-stop clears programs for safety

Bug buildbotics#2: Macro file isolation & orphan cleanup
- Protected macros/ directory blocks user edits (403)
- Files copied to macros/ with isolation naming
- Orphaned macro files cleaned up on config save

Bug buildbotics#3: Macro UI updates during run
- State tracks _running_macro and _previous_program
- MacroHandler calls start_macro() before execution
- Planner._end_program() restores previous program via end_macro()

Bug buildbotics#4: Editor save dialog navigation
- check_save() returns proper boolean values
- revert() returns true after clearing modified state
- route-changing handler continues navigation after save/discard

Bug buildbotics#5: File reload cache
- No-cache headers on file API responses
- Cache-busting ?_t= timestamp parameter on requests
- files.js calls refresh_selected_program() after upload

Bug buildbotics#6: Spindle speed in modal
- popupMessagesHeader computed property shows RPM during M0 pause

Bug buildbotics#7: Color picker hex input
- Direct hex code entry with validation (already in branch)

Bug buildbotics#8: Button text overflow
- white-space: normal allows multi-line macro button text
- Flexbox centering for proper alignment
Macro Enhancements:
- Add dedicated Macros page with top-level menu item
- Implement tab system for organizing macros into groups
- Add visibility toggle to show/hide macros on control page
- Add confirmation dialog option before running macros
- Display macro tabs as clickable tab bar on control page
- Settings tab appears in tab bar linking to Macros page

Service Tracking:
- Add dedicated Service page with dashboard, items, and notes views
- Track power-on, spindle, and motion hours automatically
- Support configurable maintenance intervals per hour type
- Display service warning banner on control page when items are due
- Add service completion history and manual hour entry
- Include export functionality for service data

Control Page:
- Macro tab bar now always visible with Settings tab on right
- Service warning banner shows count of due maintenance items
Service Page Navbar:
- Add Login button for unauthenticated users (far right)
- Add Save button that appears when changes are pending
- Add "Saved" status indicator when no pending changes
- Use spacer to push action buttons to far right

Dirty Form Tracking:
- Track modified state for item and note editors
- Show confirmation dialog when navigating away with unsaved changes
- Add Cancel button confirmation to prevent accidental data loss
- Implement markModified(), clearModified(), checkUnsavedChanges() helpers

Service Items Layout:
- Move status badge (duration) next to label instead of far right
- Relocate action buttons to vertical column on right side of card
- Add visual separator between content and actions
- Complete button now always visible (not just when due)

Dashboard Upcoming List:
- Display duration inline with label using pill-style badge
- Keep interval info on right as secondary information
- Improve visual grouping of related information

Form Fixes:
- Fix input overflow in Add Item editor using flexbox rows
- Remove non-functional .small class from button elements
- Apply button sizing via container CSS instead
Macro List Layout:
- Restructure as two-row records for better readability
- Row 1: drag grip, index, visibility, confirm, tab, color, delete
- Row 2: name and file inputs (indented to align with content)
- Move drag handle to far left of each row
- Simplify index display (remove "#", lighter weight)
- Align header text with column centers

Delete Confirmations:
- Add confirmation dialog before deleting macros
- Add confirmation dialog before deleting tabs
- Tab deletion shows count of macros that will be moved

Styling:
- Consistent column widths between header and rows
- Uppercase labels for Name/File fields
- Improved visual hierarchy with row grouping
Navbar Styling:
- Switch both Service and Macros pages to dark navbar (buildbotics#333 background)
- Consistent styling with light text and hover effects

Service Items:
- Move action buttons to single row below item content
- Add text labels to all buttons (Mark Complete, Edit, Delete)
- Change color bar from vertical left to horizontal top

Service Item Editor:
- Label field on full-width row
- Track By, Interval, and Color on second row
- Normalize input heights to 38px

Macros Layout:
- Add spacer column to push Color and Trash to far right
- Widen color picker area for better hex input display
- Move trash icon to far right column

Macros Navbar:
- Add button changes contextually (Add Macro vs Add Tab)
- Remove redundant Add Tab button from Tabs content area
Macro file isolation improvements:

- Use 4-character GUID in isolated filenames instead of macro ID/name
  Format: macro_<4-char-guid>_<original_filename>
  Example: macro_a7f3_init.nc

- Auto-isolate macros on config load
  Handles firmware updates where existing macros have unprotected paths.
  Only triggers if macros exist that aren't already in macros/ folder.
  Saves config automatically after isolation.

- Simplified isolate_macro() signature
  Removed macro_id and macro_name parameters (no longer needed)
Service Page:
- Move Add Item and Add Note buttons to navbar (context-sensitive)
- Notes card layout matches Items (buttons on bottom row)
- Add text labels to note Edit/Delete buttons
- Remove Add buttons from content areas

Macros Page:
- Column order: Grip, Index, Visible, Confirm, Tab, Color, [spacer], Trash
- Color picker positioned after Tab dropdown (not pushed far right)
- Trash icon pushed to far right via spacer
- Grip icon enlarged (16px, darker color)
- Hex input height/padding/font matches file input exactly

Consistency:
- Both pages use navbar for context-sensitive Add buttons
- Both pages have dark navbar with summary/metrics bar below
- Action button rows have consistent styling across Items and Notes
System Alerts:
- Add alerts section below header for upgrade and service notifications
- Upgrade alert: Shows when new firmware available with link to settings
- Service alert: Shows count of due items with link to service page
- Both alerts are dismissible (X button)
- Dismissals stored in sessionStorage (reset on browser close)
- Dismissal resets when upgrade version changes or new items become due

Camera Visibility:
- Add camera_available to state from Python backend
- Hide camera menu item when camera not available
- Hide camera video preview in header when not available
- Works on all screen sizes (not just mobile)

Files Changed:
- src/pug/index.pug - Add alerts section, conditional camera visibility
- src/js/app.js - Add alert computed properties and dismiss methods
- src/stylus/style.styl - Add alert styling (warning/info colors)
- src/py/bbctrl/State.py - Add camera_available to state snapshot
Camera View Navbar:
- Add dark navbar consistent with service/macros pages
- Replace Settings dropdown with direct "Show Crosshair" toggle
- Toggle shows checkbox icon (checked when active)
- No login button (camera doesn't require authentication)

Camera Offline State:
- Show friendly message when camera unavailable
- Icon: video camera with ban overlay
- Message: "Camera Unavailable" with instructions
- Dark background (#1a1a1a) instead of pure black

Layout Improvements:
- Flexbox layout for proper sizing
- Video centered and contained within viewport
- Navbar stays fixed at top
- Content area fills remaining space

Files Changed:
- src/pug/templates/view-camera.pug - New navbar, offline message
- src/stylus/view-camera.styl - Dark navbar, offline styling
- src/pug/templates/video.pug - Unchanged (included for completeness)
- src/stylus/video.styl - Unchanged (included for completeness)
Navigation Bar:
- Dark navbar consistent with other views (buildbotics#333 background)
- File menu dropdown: Upload File, New Folder
- Selection menu dropdown: Edit, 3D View, Download, Delete
- Dropdown items disabled when no file selected
- Login button for authenticated operations

Locations Sidebar:
- Clean header with "Storage" label
- Home icon for local storage
- USB icon for removable drives
- Eject button appears on hover
- Active location highlighted in blue

Breadcrumbs:
- Improved path display with chevron separators
- Clickable path segments for navigation
- Current folder highlighted
- Action buttons (Upload, New Folder) on right side

File List:
- Header row with uppercase labels
- File type icons based on extension (code, image, archive, etc.)
- Folder icon in gold/amber color
- Selected row highlighted in yellow
- Alternating row colors removed for cleaner look
- Empty folder message with icon

General:
- Consistent spacing and typography
- Smooth hover transitions
- Better color contrast
- Professional appearance matching service/macros views

Files Changed:
- src/pug/templates/view-files.pug - New navbar with dropdowns
- src/pug/templates/files.pug - Improved breadcrumbs and file list
- src/stylus/view-files.styl - Navbar and layout styles
- src/stylus/files.styl - Complete restyling of file browser
- src/js/files.js - Added file_icon() method for file type icons
- src/js/view-files.js - Unchanged (included for completeness)
Macros View Changes:
- Reverted to single row layout (cleaner, less busy)
- All columns on one row: Grip, #, Visible, Confirm, Tab, Color, Name, File, Actions
- Better column spacing and alignment
- Headers centered over column content
- Tab select and Color picker have more spacing between them
- Name and File fields back on same row as other columns
- Folder and Trash icons together in actions column on right
- Hex input styled consistently (28px height, 0.85em font)

Service Tracking - Remove Spindle Hours:
- Removed spindle_hours from Service.py (not all users have machine-controlled spindles)
- Removed spindle tracking from State.py (no more spindle_started/spindle_stopped)
- Updated service-template.json (removed spindle_hours from hours section)
- Updated view-service.pug (removed Spindle from hours bar)
- Updated view-service.js (removed spindleHours computed, hourTypes, labels)
- Service items can now only track: Power-On Hours or Motion Hours

Files Changed:
- src/pug/templates/view-macros.pug - Single row layout
- src/stylus/view-macros.styl - Updated column styles
- src/pug/templates/view-service.pug - Removed spindle hours display
- src/js/view-service.js - Removed spindle computed/methods
- src/py/bbctrl/Service.py - Removed spindle tracking
- src/py/bbctrl/State.py - Removed spindle state tracking
- src/resources/service-template.json - Removed spindle_hours
Camera View:
- Dark navbar with "Show Crosshair" toggle (checkbox style)
- Content area fills available viewport height
- Camera menu always visible in sidebar (not hidden when no camera)
- Header camera preview hidden when camera unavailable
- Offline message: icon with "Camera Unavailable" text when no camera detected
- Dark background (#1a1a1a) for video area

Files View:
- Dark navbar consistent with other views
- File menu dropdown: Edit, 3D View, Download, Delete
- Upload and New Folder buttons in navbar (right side)
- Removed separate sidebar - location now in breadcrumbs
- Location dropdown: Home icon + name with dropdown for USB drives
- Breadcrumbs with chevron separators after location
- Clean file list with type-specific icons
- Empty folder message
- No login button (not needed for this view)

Technical:
- Added show_locations data property to files.js
- Added file_icon() method for file type detection
- Camera availability check from backend state
- Content area height calculated for proper fill

Files Changed:
- src/pug/index.pug - Camera menu always visible
- src/pug/templates/view-camera.pug - New navbar, offline message
- src/pug/templates/video.pug - Unchanged (included)
- src/stylus/view-camera.styl - Full height, dark navbar
- src/stylus/video.styl - Unchanged (included)
- src/pug/templates/view-files.pug - Dark navbar, buttons
- src/pug/templates/files.pug - Location dropdown, breadcrumbs
- src/stylus/view-files.styl - Navbar styles
- src/stylus/files.styl - Location dropdown, clean list
- src/js/files.js - show_locations, file_icon()
- src/js/view-files.js - Unchanged (included)
Macros View Changes:
- Reverted to single row layout (cleaner, less busy)
- All columns on one row: Grip, #, Visible, Confirm, Tab, Color, Name, File, Actions
- Better column spacing and alignment
- Headers centered over column content
- Tab select and Color picker have more spacing between them
- Name and File fields back on same row as other columns
- Folder and Trash icons together in actions column on right
- Hex input styled consistently (28px height, 0.85em font)

Service Tracking - Remove Spindle Hours:
- Removed spindle_hours from Service.py (not all users have machine-controlled spindles)
- Removed spindle tracking from State.py (no more spindle state tracking)
- Updated service-template.json (removed spindle_hours from hours section)
- Updated view-service.pug (removed Spindle from hours bar)
- Updated view-service.js (removed spindleHours computed, hourTypes, labels)
- Service items can now only track: Power-On Hours or Motion Hours

Files Changed:
- src/pug/templates/view-macros.pug - Single row layout
- src/stylus/view-macros.styl - Updated column styles
- src/pug/templates/view-service.pug - Removed spindle hours display
- src/js/view-service.js - Removed spindle computed/methods
- src/py/bbctrl/Service.py - Removed all spindle tracking
- src/py/bbctrl/State.py - Removed spindle state tracking
- src/resources/service-template.json - Removed spindle_hours
Global Navbar Update (navbar.styl):
- Changed background from #444 to buildbotics#333 for consistency
- Added min-height 40px
- Improved nav-item styling with proper padding and hover states
- Dropdown menus with box-shadow and border-radius
- Added .filename styling for editor/viewer
- Added .active class support

Editor View:
- Uses global navbar styles
- Content area fills available height
- CodeMirror editor uses flex layout

3D Viewer:
- Uses global navbar styles
- Content area properly sized
- path-viewer fills available space

Docs View:
- Dark navbar with Help/GCode/License tabs
- Active tab highlighting
- Improved typography for documentation content
- Styled headings (h1, h2, h3), paragraphs, links
- Table styling for GCode reference
- Code block styling
- Max-width 900px for readability

Camera View:
- Dark navbar with crosshair toggle
- Content fills viewport height
- Camera menu always visible in sidebar
- Offline message when no camera

Files View:
- Dark navbar with File dropdown menu
- Upload and New Folder buttons in navbar
- Location dropdown in breadcrumbs (no sidebar)
- Type-specific file icons
- Clean file list with selection highlighting

Files Changed:
- src/stylus/navbar.styl - Global dark navbar
- src/pug/templates/view-editor.pug - Unchanged (uses global)
- src/stylus/view-editor.styl - Flex layout
- src/pug/templates/view-viewer.pug - Unchanged (uses global)
- src/stylus/view-viewer.styl - Flex layout
- src/pug/templates/view-docs.pug - Active state for tabs
- src/stylus/view-docs.styl - Full documentation styling
- src/pug/templates/view-camera.pug - Crosshair toggle
- src/stylus/view-camera.styl - Full height layout
- src/pug/templates/view-files.pug - Navbar buttons
- src/pug/templates/files.pug - Location dropdown
- src/stylus/view-files.styl - Navbar styles
- src/stylus/files.styl - Breadcrumb styles
- src/js/files.js - file_icon(), show_locations
- src/pug/index.pug - Camera menu visibility
Macros View:
- Single row layout with tighter column spacing
- Columns: grip, #, eye, warn, tab, color, name, file, actions
- Proper gaps between tab/color (16px), color/name/file (10px)
- File margin-right 12px prevents folder icon overlap
- Tab dropdown 100px wide to prevent text cutoff
- All inputs use default font size

Service Tracking:
- Removed spindle_hours (not all users have machine-controlled spindles)
- Service items track only: Power-On Hours or Motion Hours
- Updated Service.py, State.py, view-service.js, service-template.json
…ocs styling

Global:
- Dark navbar (buildbotics#333) consistent across all views
- Improved nav-item styling with hover states and dropdowns

Files View & Dialog:
- Simplified breadcrumbs: Home icon + text / folder1 / folder2
- Removed dropdown button, just clickable path segments
- "/" separators instead of chevrons

Docs:
- GCode cheat sheet: section headers with dark background
- Spacer rows transparent, minimal padding
- Unimplemented codes in muted gray
- Help and License pages styled consistently

Editor/Viewer:
- Dark navbar with File/Edit menus
- Filename display in navbar
- Content fills available height

Camera:
- Dark navbar with crosshair toggle
- Menu always visible in sidebar
- Offline message when no camera detected
Fix files breadcrumbs and restore upload button in dialog

Files View & Dialog:
- Breadcrumbs now show actual folder names (Home / macros)
- Skip '/' root entry from paths array
- Home shows alone at root level
- Upload and New Folder buttons in path bar
- Works in both Files view and file browser dialog
Motion Timer:
- State.py update() now tracks 'xx' state transitions
- Calls program_started() when entering RUNNING state
- Calls program_stopped() when leaving RUNNING state
- Fixes motion hours not being recorded

Macros Table Spacing:
- Hex input: normal height (28px), no font-size override
- col-color: width 100px, gap 0.35em between swatch and input
- col-name: margin-left 16px (was 10px)
- col-file: margin-left 16px, input has margin-right 8px
- Prevents folder icon overlap with filename input
- Consistent 16px gaps between color/name/file columns
- Hex color input: added font-size inherit for normal text size
- Increased margin-left on col-file from 16px to 20px for name/file separation
- Updated header to match
Buttons now live in files partial (breadcrumb bar) which is shared
by both Files view and file browser dialog. Removes redundant navbar
buttons to avoid duplication on Files page.
- Hex input: font-size 14px (explicit, matches other inputs)
- col-name: margin-left 24px (was 16px)
- col-file: margin-left 24px (was 20px)
- Consistent gaps between hex→name and name→file columns
- Updated both header and row sections to match
Adjusted column margins and removed explicit font-size overrides
to achieve consistent visual spacing between input fields.
- Restored font-size declaration for hex color input
- Fine-tuned col-name margin-left for better visual balance
Axis Table:
- Wider axis column, narrower position column
- Removed question icon from state (tooltip remains)
- Changed set position icon from gear to bulls-eye (dot-circle-o)
- Added button text (Set, Zero, Home) with responsive hiding
- Better padding and header styling

Macros Section:
- Changed "Settings" tab to "Macros" with th-large icon
- Increased macro button padding (0.4em 0.75em)

Info Tables:
- Increased gap between tables (column-gap 1em)
- Better cell padding and header styling
- Progress bar with border-radius

Bottom Tabs:
- Auto toolbar: background container with border-radius
- MDI: styled container with gap, better input styling
- History: subtle background, hover states on items
- Jog settings: flex layout with gap

Responsive:
- Button text hidden on screens < 940px
- Axis font sizes scale down progressively
MDI Tab:
- Added text to Run/Pause and Stop buttons to match Auto tab styling
- Buttons now show icon + text like Auto tab

I/O Pins Tab:
- Reorganized layout: pin tables at top (main focus)
- Legend below pin tables
- Breakout diagrams moved to bottom as "Connector Reference"
- Cleaner table styling with dark headers

Power Tab:
- Added gap between tables (1.5em)
- Consistent dark headers
- Box shadow for depth
- Better cell padding

Note: Axis table button text (Set/Zero/Home) already implemented
with responsive hiding on screens < 940px
Axis Table:
- Added text prop to bbutton (Set, Zero, Home)
- Buttons now show icon + text properly
- Uses text prop instead of span children (bbutton doesn't support slots)

Power Tab:
- Power Faults table: value left of name (matches Measurements)
- Consistent layout: td (value) then th (label)
- Both pwr_fault and measurements tables use Courier font

I/O Pins Tab:
- Pin column: 2.5em width, centered, bold
- State column: 2em width, centered
- Function column: left-aligned, capitalized
- More compact row layout
Axis Table:
- Header buttons: icon + text (Zero All with circle-o, Home All with home)
- Row buttons: icon + text (Set with dot-circle-o, Zero with circle-o, Home with home)
- Actions column: width 1% to minimize wasted space
- Button font-weight: normal (not bold)

I/O Pins Tab:
- table-layout: fixed for proper column distribution
- Separator now centered at 50%
- Pin column: 3em width
- State column: 2.5em width
- Function column: left-aligned

Page Layout:
- Added padding-bottom 3em to .content for browser UI clearance

Camera in Header:
- Hide when camera unavailable (all screen sizes, not just small)
- Hide when on camera page (no redundant preview)
Axis Table:
- Set button: dot-circle-o (bullseye - set to specific position)
- Zero button: map-marker (pin current location)
- Home button: home (unchanged)
- Icons are now visually distinct

I/O Pins Tab:
- Restored original grid-based layout structure
- Fixed separator centering with table-layout: fixed
- Explicit column widths: pin 2.5em, state 2.5em
- Separator width: 4px

Camera:
- Default to hidden until backend confirms camera available
- Changed: camera_available === true (was !== false)
- No camera UI in header when no camera connected
Q1WP added 29 commits December 18, 2025 11:51
The confirm checkbox was moved to the Safety tab but not removed from the
main Macros tab. This commit removes the duplicate column.

Changes:
- Remove .col-confirm from macro-header in view-macros.pug
- Remove .col-confirm checkbox from macro-row in view-macros.pug
- Remove .col-confirm styling from macro-header in view-macros.styl
- Remove .col-confirm styling from macro-row in view-macros.styl
- Update help text to reference Safety tab for confirmation settings
- Update intro text to remove "confirmation options" mention
…ditor height

Issue buildbotics#1: USB drive access broken
- Restore .files-locations bar in files.pug
- Users can now switch between Home and USB drives

Issue buildbotics#2: Control page tabs pushed off screen on 15.6" touch display
- Reduce vertical margins throughout control page (0.5em -> 0.25em)
- Reduce axis table cell padding (6px 10px -> 4px 8px)
- Reduce info table cell padding and row height
- Reduce macro tab padding (0.4em 1em -> 0.3em 0.75em)
- Reduce tabs section min-height (500px -> 400px)

Issue buildbotics#3: Editor cuts off after ~20 lines
- Revert CodeMirror height from flex layout to calc(100vh - 180px)
- Matches OEM behavior which worked correctly

Issue buildbotics#4: Dropdown menu text bold, ellipsis pushed left
- Add font-weight: normal to dropdown menu items (was inheriting bold from th)
- Add margin-left: auto to dropdown container for right alignment
- Add text-align: right in mobile breakpoint
- Remove CSS hover triggers from dropdown menus (navbar.styl, view-control.styl)
- Dropdowns now click-only, prevents multiple menus open simultaneously
- Restore OEM calc-based height for CodeMirror editor (view-editor.styl)
- Restore OEM calc-based CodeMirror height (was showing only 20 lines)
- Add flex-wrap to settings navbar for mobile (prevents overflow)
- Replace files sidebar with compact location dropdown in breadcrumbs
- Preserves clean file list layout while enabling USB access
- Restore OEM calc-based CodeMirror height (was showing only ~20 lines)
- Prevent horizontal scroll/swipe on settings page mobile
- Fix dropdown menu opening to left and getting cut off
- Adjust CodeMirror height offset to 200px for alert space
- Force vertical dots menu to top-right corner on mobile
- Prevent horizontal scroll on settings page
- Force vertical dots menu to top-right corner on mobile
- Prevent horizontal scroll/swipe on settings page
- Planner.py: Add hasattr check for get_modal_state()
  - Backwards compatible with old camotics.so
  - Silently skips if method doesn't exist
- Config.py: Fix undefined 'macro_id' variable (was i + 1)
- FileSystem.py: Remove noisy warning for missing macro sources
  - Expected behavior for existing configs
- Add User Panel (right side) with Program/MDI/Jog tabs
  - Program tab: filename, metrics, Start/Stop/Edit/View/Open
  - MDI tab: common commands dropdown, input, history
  - Jog tab: moved from bottom tabs
- Add column selector (gear icon) to toggle Offset/Absolute columns
  - Persisted via cookies (col-offset, col-absolute)
- Add Fullscreen button to sidebar nav
- Mobile dialog scroll fix for small screens
- Responsive layout for tablet/mobile

Resolves real estate issues on 1366x768 displays.
- Axis table: Convert action buttons to icon-only (home/zero/set)
- Axis table: Add Home All / Zero All icons in header, centered
- Axis table: Move gear icon to axis name column, left-aligned
- Column selector: Left-align dropdown menu for checkbox alignment
- Program tab: 2-column button layout, fix file size display
- Jog: Convert tab to modal for focused jogging experience
- Add tooltips to all icon buttons and tabs
- Responsive: Jog controls stack vertically on mobile
- Fullscreen: fa-arrows-alt/fa-times icons, "Expand"/"Exit" text
- Axis row actions: reorder to zero → set → home
- Header actions: reorder to zero → home
- Column selector: left-align checkbox labels
- Jog modal: side-by-side on desktop, stacked on mobile (≤940px)
- User panel: min-height 450px to match axis+info tables
- Header icons: reset to 1rem (match axis row icons)
- User panel: reduce min-height to 320px (axis + one info table)
- Jog modal: increase min-width to 650px for side-by-side controls
- Error modal: constrain console height to prevent overflow (max-height: 50vh)
- Remove duplicate async update() method that would cause infinite recursion
- MDI: increase input font size to 1rem, fix history scroll overflow
- User panel: remove fixed min-height, stretch to match axis table
- Fix browser refresh clearing selected program
- Rename fullscreen button "Expand" to "Full"
- Add State column to column selector dropdown
- Move Messages clear button to X icon in tab label
- menu.styl: cursor: pointer on sidebar links
- view-control.styl: overflow: hidden on user-panel, flex-shrink: 0 on
  fixed elements, .tab-action styling for Clear button
- view-control.pug: Clear link in tab bar (visible when Messages active)
- console.js/pug: showToolbar prop to hide toolbar in control page
- view-control.styl: Fix MDI history growing user panel
  - Add height: 0 to flex chain (user-panel-content, panel-mdi, mdi-history)
  - Forces elements to start at 0 and grow only to available space
  - History now scrolls instead of expanding panel
- view-control.styl: Style Clear button as connected tab
  - float: right, white background, matching borders
  - border-bottom: #fff + margin-bottom: -1px to connect to content
  - Only visible when Messages tab active
- Fix MDI history growing user panel:
  - user-panel-content: position relative
  - panel-mdi: position absolute to fill container
  - mdi-history: height calc(100% - 11em) with overflow-y auto
- Style Clear button as connected tab (white bg, borders connect to content)
- Style Macros button to match Clear button (white bg, connected borders)
- Remove macro-tabs margin-bottom so tabs sit on container border
Fix Settings page sticky header/alerts
- Removed overflow-x:hidden that created separate scroll context
- Tables already have .table-responsive wrappers

Fix Control page mobile layout
- Added padding to prevent edge-to-edge content
- Axis header actions now use dropdown menu on mobile (matches row pattern)
- Hide column selector on mobile (defaults are sensible)
- User panel maintains min-height 280px for MDI history
- Jog modal SVGs scale down to prevent cutoff

Fix Macros button border
- Match Clear button style (no visible bottom border)
- view-control.styl: Fix control page horizontal scroll (CodeMirror
  textarea has inline 1000px width), constrain with max-width 100%
- view-control.styl: Fix jog modal SVG clipping - remove overflow:hidden
  from dialog-container/body/content, widen modal to 95vw, scale SVGs 85%
- view-settings.styl: Fix settings page horizontal scroll - GCode
  textareas overflow viewport, constrain with max-width calc(100vw - 2em)
- files.js: Fix TypeError in _closeLocationMenu - guard against
  unmounted component when document click handler fires
Move parseFloat(this.state.s) outside the conditional to ensure
Vue tracks it as a dependency. If state.s was only read inside
the if-block, and the condition was false on first evaluation,
Vue never established the dependency and wouldn't re-evaluate
when state.s changed later.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant