Skip to content

UI: introduce top app bar, convert sidebar to navigation rail, refresh styling and tokens - #28

Merged
DavidSeyserGit merged 1 commit into
cursor/material3-ui-ca4bfrom
codex/redesign-ui-according-to-material-3-guidelines
Jul 9, 2026
Merged

UI: introduce top app bar, convert sidebar to navigation rail, refresh styling and tokens#28
DavidSeyserGit merged 1 commit into
cursor/material3-ui-ca4bfrom
codex/redesign-ui-according-to-material-3-guidelines

Conversation

@DavidSeyserGit

Copy link
Copy Markdown
Contributor

Motivation

  • Modernize the app chrome by moving to a compact navigation rail and adding a top app bar using Material 3 design tokens.
  • Improve visual hierarchy, spacing, elevation and responsive behavior across the UI.
  • Improve markup semantics and accessibility of the primary navigation and header.

Description

  • Added and updated CSS design tokens and variables (e.g. --space-10, --radius-xl, --topbar-h, --md-elevation-1/2, --md-state-hover, --md-state-focus) and migrated many surfaces to color-mix and elevation shadows.
  • Restyled the left chrome into a compact navigation rail by reducing --sidebar-w, adjusting .brand, .nav-item, .nav-label, hover/active indicators, and updating cards/metrics/garden-map to new radii/shadows and spacing.
  • Introduced #top-app-bar with .top-app-bar-title, .top-app-bar-subtitle, and .top-app-bar-actions, moved the status block and action buttons into the header, and added ARIA labels and updated markup in index.html (brand mark/wordmark, header structure).
  • Small JS refactor in js/main.js to extract refreshAll and bind it to the refresh button, leaving ESTOP handling unchanged.

Testing

  • Performed a local frontend build and a quick dev-server smoke test which loaded the page and exercised the header/refresh/estop interactions without runtime errors.
  • No changes to the project test suite were added and no new automated unit tests were included in this change.

Codex Task

@DavidSeyserGit
DavidSeyserGit marked this pull request as ready for review July 9, 2026 20:05
Copilot AI review requested due to automatic review settings July 9, 2026 20:05
@cursor

cursor Bot commented Jul 9, 2026

Copy link
Copy Markdown

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

@DavidSeyserGit
DavidSeyserGit merged commit c697356 into cursor/material3-ui-ca4b Jul 9, 2026
9 checks passed
<div class="kicker">Field robotics</div>
<div class="title">TWFarmBot</div>
<aside id="sidebar" aria-label="Primary navigation rail">
<div class="brand" aria-label="TWFarmBot">

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SUGGESTION: aria-label on a plain <div> without a role is ignored by assistive technology.

The label won't be exposed to screen readers. If an accessible name is intended here, add an explicit role (e.g. role="img" for the brand mark) or move the label to an element with an implicit role. The parent <aside> already provides a navigation landmark label. The aria-hidden="true" on .brand-mark also means the visible brand text is the only exposed part, so the extra label adds no value as written.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

@kilo-code-bot

kilo-code-bot Bot commented Jul 9, 2026

Copy link
Copy Markdown

Code Review Summary

Status: 1 Issue Found | Recommendation: Address before merge

Overview

Severity Count
CRITICAL 0
WARNING 0
SUGGESTION 1
Issue Details (click to expand)

SUGGESTION

File Line Issue
apps/ui/src/twfarmbot_ui/static/index.html 27 aria-label on a plain <div> without a role is ignored by assistive technology; the brand label adds no value as written.
Files Reviewed (3 files)
  • apps/ui/src/twfarmbot_ui/static/app.css - 0 issues
  • apps/ui/src/twfarmbot_ui/static/index.html - 1 issue
  • apps/ui/src/twfarmbot_ui/static/js/main.js - 0 issues

Fix these issues in Kilo Cloud


Reviewed by hy3-20260706:free · Input: 74.4K · Output: 7.5K · Cached: 168.6K

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modernizes the UI chrome by introducing a fixed Material 3–styled top app bar, converting the left sidebar into a compact navigation rail, and refreshing spacing/radii/elevation tokens to improve layout hierarchy and responsiveness.

Changes:

  • Added a fixed #top-app-bar layout and moved status + primary actions (Refresh/ESTOP) into the header.
  • Refreshed design tokens (spacing, radii, elevation/state colors) and updated surfaces (cards/metrics/map) to new Material 3 styling.
  • Minor JS refactor to extract a refreshAll handler and bind it to the refresh button.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
apps/ui/src/twfarmbot_ui/static/js/main.js Extracts and reuses a refreshAll click handler for the refresh button.
apps/ui/src/twfarmbot_ui/static/index.html Reworks chrome markup: navigation rail <aside> + new top app bar header content/actions.
apps/ui/src/twfarmbot_ui/static/app.css Introduces new tokens and restyles navigation rail/top bar and key surfaces with updated elevation/spacing.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

<span class="brand-mark" aria-hidden="true">eco</span>
<span class="brand-wordmark">TWFarmBot</span>
</div>
<nav id="nav" aria-label="Main navigation"></nav>
Comment on lines +236 to +238
.nav-item:hover::before { background: var(--md-state-hover); }
.nav-item.active { color: var(--md-sys-color-on-secondary-container); font-weight: 600; }
.nav-item.active::before { background: var(--md-sys-color-secondary-container); }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants