Skip to content

fix(noctalia): improve bar visibility - #1692

Merged
shunkakinoki merged 1 commit into
mainfrom
final-noctalia-fixes
May 7, 2026
Merged

fix(noctalia): improve bar visibility#1692
shunkakinoki merged 1 commit into
mainfrom
final-noctalia-fixes

Conversation

@shunkakinoki

@shunkakinoki shunkakinoki commented May 7, 2026

Copy link
Copy Markdown
Owner

Changes

  • Show Noctalia tray items inline instead of hiding them in the drawer.
  • Keep seconds visible in the clock's horizontal, vertical, and tooltip formats.
  • Move the native app-enabled Workspace widget to the center bar section so it does not duplicate the left bar, while preserving numbered workspace badges.

Testing

  • shellspec spec/noctalia_bar_spec.sh
  • nix-instantiate --parse config/noctalia/default.nix >/dev/null
  • make nix-switch SUDO='sudo -n' activation verified through home-manager-skakinoki.service
  • Restarted Noctalia and verified the new instance loaded configuration without workspace widget errors.

Generated with Codex.


Summary by cubic

Improves Noctalia bar visibility by showing tray items inline, keeping seconds on the clock, and centering the Workspace widget to avoid duplication.

  • Bug Fixes
    • Tray now shows items inline (drawerEnabled = false) instead of hiding them in a drawer.
    • Clock keeps seconds in horizontal, vertical, and tooltip formats.
    • Moved native app-enabled Workspace widget to the center; preserves numbered badges and removes duplicate on the left.

Written for commit 48a1755. Summary will update on new commits.

Co-authored-by: Codex <noreply@openai.com>
@indent-zero

indent-zero Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor
PR Summary

Tightens the Noctalia bar configuration so workspace pills, tray icons, and clock readouts are actually visible at a glance. Replaces the no-op Workspaces widget id (not registered upstream — the singular Workspace is the canonical id) with a properly configured Workspace in a new widgets.center section, disables the Tray drawer to render tray items inline, and adds vertical/tooltip clock formats. Shellspec coverage is extended in lockstep so each setting is enforced by tests.

  • config/noctalia/default.nix: removed { id = "Workspaces"; } from widgets.left and added widgets.center containing a Workspace widget with labelMode = "index", showApplications = true, showApplicationsHover = false, showBadge = true, unfocusedIconsOpacity = 0.55.
  • config/noctalia/default.nix: changed the Tray entry from a bare { id = "Tray"; } to { id = "Tray"; drawerEnabled = false; } so unpinned tray items are no longer hidden behind the drawer.
  • config/noctalia/default.nix: extended the Clock widget with formatVertical = "HH mm ss - dd MM" and tooltipFormat = "yyyy/MM/dd HH:mm:ss" to keep seconds visible in vertical and tooltip modes.
  • spec/noctalia_bar_spec.sh: added four assertions covering the inline tray drawer, the absence of any Workspace entry on the left bar, the centered numbered workspace widget options, and the clock format strings.

Issues

No issues found.

CI Checks

Waiting for CI checks...

@mesa-dot-dev

mesa-dot-dev Bot commented May 7, 2026

Copy link
Copy Markdown

You do not have enough credits to review this pull request. Please purchase more credits to continue.

@shunkakinoki shunkakinoki added the bug Indicates an unexpected problem or unintended behavior. label May 7, 2026
@coderabbitai

coderabbitai Bot commented May 7, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Summary by CodeRabbit

  • New Features

    • Added Workspace widget to the bar center section with customizable display options, badge configuration, and icon opacity control
    • Enhanced Clock widget with vertical formatting and tooltip support capabilities
  • Tests

    • Extended test coverage to verify workspace widget settings, clock display formats, and bar widget arrangement configuration

Walkthrough

Bar widget configuration for noctalia is updated with new center-aligned workspace widget and extended clock formatting. The clock gains vertical and tooltip format options. Right-side widgets are reformatted while retaining functionality. Tests validate the new layout structure and configuration fields.

Changes

Noctalia bar widget configuration and testing

Layer / File(s) Summary
Clock widget formatting
config/noctalia/default.nix
Clock widget in widgets.left gains formatVertical and tooltipFormat attributes alongside the existing formatHorizontal.
Center workspace widget
config/noctalia/default.nix
New widgets.center section introduces a Workspace widget configured with index label mode, application name/icon toggles, badge visibility, and unfocused icon opacity.
Right widgets reorganization
config/noctalia/default.nix
The widgets.right section expands from inline Tray entry to multi-line block format, explicitly configuring tray drawer settings while preserving existing right-side widgets.
Configuration validation tests
spec/noctalia_bar_spec.sh
Four new test assertions validate tray inline rendering with drawerEnabled = false, left bar workspace exclusion, center workspace configuration fields (index label mode, app display toggles, badge and opacity settings), and clock format retention across horizontal, vertical, and tooltip contexts.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Poem

🐰 The bar grows wise, with widgets neat,
Clock shows time in ways so sweet,
Center stage for workspace pride,
Right side tidy, tested, tried!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title 'fix(noctalia): improve bar visibility' is related to the changeset, which improves Noctalia bar visibility by showing tray items inline, keeping seconds on the clock, and centering the Workspace widget.
Description check ✅ Passed The description is directly related to the changeset, providing clear details about tray visibility, clock format changes, and Workspace widget repositioning, all matching the file modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch final-noctalia-fixes

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@mesa-dot-dev

mesa-dot-dev Bot commented May 7, 2026

Copy link
Copy Markdown

Mesa Description

TL;DR

Fixes Noctalia bar visibility issues.

What changed?

  • Show Noctalia tray items inline instead of hiding them in the drawer.
  • Keep seconds visible in the clock's horizontal, vertical, and tooltip formats.
  • Move the native app-enabled Workspace widget to the center bar section so it does not duplicate the left bar, while preserving numbered workspace badges.

Description generated by Mesa. Update settings

@coderabbitai coderabbitai Bot 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.

🧹 Nitpick comments (1)
spec/noctalia_bar_spec.sh (1)

18-18: ⚡ Quick win

Harden block-end matching to avoid whitespace-coupled test failures.

Line 18 and Line 32 depend on exact indentation, so formatting-only Nix changes can break tests. Prefer end-patterns that ignore leading spaces.

Diff suggestion
-It 'does not duplicate the workspace widget on the left bar'
-When run bash -c "awk '/widgets.left = \\[/{in_left=1} in_left && /id =/ {print} in_left && /^        \\];/{exit}' '$CONFIG'"
+It 'does not duplicate the workspace widget on the left bar'
+When run bash -c "awk '/widgets.left = \\[/{in_left=1} in_left && /id =/ {print} in_left && /^[[:space:]]*\\];/{exit}' '$CONFIG'"
@@
-It 'keeps seconds visible in clock formats'
-When run bash -c "awk '/id = \"Clock\";/{in_clock=1} in_clock && /^          }/{exit} in_clock{print}' '$CONFIG'"
+It 'keeps seconds visible in clock formats'
+When run bash -c "awk '/id = \"Clock\";/{in_clock=1} in_clock && /^[[:space:]]*}/{exit} in_clock{print}' '$CONFIG'"

Also applies to: 32-32

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@spec/noctalia_bar_spec.sh` at line 18, The awk end-pattern is tightly coupled
to indentation (the pattern in the awk invocation that currently uses /^       
\];/); change the exit condition in both occurrences (the awk pipeline that
starts with '/widgets.left = \[/{in_left=1}') to match a closing bracket
regardless of leading whitespace, e.g. replace the /^        \];/ check with
/^[[:space:]]*\];/ (or /^[ \t]*\];/), so the block-end detection is resilient to
formatting-only whitespace changes.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@spec/noctalia_bar_spec.sh`:
- Line 18: The awk end-pattern is tightly coupled to indentation (the pattern in
the awk invocation that currently uses /^        \];/); change the exit
condition in both occurrences (the awk pipeline that starts with '/widgets.left
= \[/{in_left=1}') to match a closing bracket regardless of leading whitespace,
e.g. replace the /^        \];/ check with /^[[:space:]]*\];/ (or /^[ \t]*\];/),
so the block-end detection is resilient to formatting-only whitespace changes.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 3066acf0-5e92-4162-a470-d27e91e48b90

📥 Commits

Reviewing files that changed from the base of the PR and between d1f9c20 and 48a1755.

📒 Files selected for processing (2)
  • config/noctalia/default.nix
  • spec/noctalia_bar_spec.sh

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request reorganizes the Noctalia bar layout by moving the workspace widget to a new center section and configuring the clock and tray widgets. It also introduces a suite of shell tests to validate these configuration changes. The review feedback suggests improving the reliability of the test scripts by removing fragile indentation anchors and refining the scoping of awk commands to avoid potential false positives.

Comment thread spec/noctalia_bar_spec.sh
End

It 'shows tray items inline instead of hiding them in the drawer'
When run bash -c "awk '/id = \"Tray\";/{in_tray=1} in_tray && /drawerEnabled = false;/{print; exit}' '$CONFIG'"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The awk script for the Tray widget is not scoped to the widget block. If drawerEnabled = false; appears later in the file for a different widget, this test could produce a false positive. Consider exiting the script if the closing brace of the block is reached without finding the property.

Suggested change
When run bash -c "awk '/id = \"Tray\";/{in_tray=1} in_tray && /drawerEnabled = false;/{print; exit}' '$CONFIG'"
When run bash -c "awk '/id = \"Tray\";/{in_tray=1} in_tray && /drawerEnabled = false;/{print; exit} in_tray && /}/{exit}' '$CONFIG'"

Comment thread spec/noctalia_bar_spec.sh
End

It 'does not duplicate the workspace widget on the left bar'
When run bash -c "awk '/widgets.left = \\[/{in_left=1} in_left && /id =/ {print} in_left && /^ \\];/{exit}' '$CONFIG'"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The use of a hardcoded indentation anchor (^ ) makes this test fragile and inconsistent with the existing test pattern on line 8. Removing the anchor makes the test more robust against formatting changes.

Suggested change
When run bash -c "awk '/widgets.left = \\[/{in_left=1} in_left && /id =/ {print} in_left && /^ \\];/{exit}' '$CONFIG'"
When run bash -c "awk '/widgets.left = \\[/{in_left=1} in_left && /id =/ {print} in_left && /\\];/{exit}' '$CONFIG'"
References
  1. Maintain consistency with established patterns for writing scripts that are extracted from Nix expressions. The existing test on line 8 uses a more robust pattern without hardcoded indentation anchors.

Comment thread spec/noctalia_bar_spec.sh
End

It 'shows applications inside the centered numbered workspace widget'
When run bash -c "awk '/widgets.center = \\[/{in_center=1} in_center && /^ \\];/{exit} in_center{print}' '$CONFIG'"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The use of a hardcoded indentation anchor (^ ) makes this test fragile. Removing the anchor ensures the test remains valid even if the file is reformatted and maintains consistency with established patterns.

Suggested change
When run bash -c "awk '/widgets.center = \\[/{in_center=1} in_center && /^ \\];/{exit} in_center{print}' '$CONFIG'"
When run bash -c "awk '/widgets.center = \\[/{in_center=1} in_center && /\\];/{exit} in_center{print}' '$CONFIG'"
References
  1. Maintain consistency with established patterns for writing scripts that are extracted from Nix expressions.

Comment thread spec/noctalia_bar_spec.sh
End

It 'keeps seconds visible in clock formats'
When run bash -c "awk '/id = \"Clock\";/{in_clock=1} in_clock && /^ }/{exit} in_clock{print}' '$CONFIG'"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The use of a hardcoded indentation anchor (^ ) makes this test fragile. Removing the anchor improves maintainability and maintains consistency with established patterns.

Suggested change
When run bash -c "awk '/id = \"Clock\";/{in_clock=1} in_clock && /^ }/{exit} in_clock{print}' '$CONFIG'"
When run bash -c "awk '/id = \"Clock\";/{in_clock=1} in_clock && /}/{exit} in_clock{print}' '$CONFIG'"
References
  1. Maintain consistency with established patterns for writing scripts that are extracted from Nix expressions.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 2 files

@shunkakinoki
shunkakinoki merged commit acea66e into main May 7, 2026
33 of 34 checks passed
@shunkakinoki
shunkakinoki deleted the final-noctalia-fixes branch May 7, 2026 10:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Indicates an unexpected problem or unintended behavior.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant