Repository navigation
Conversation
The bar widget can now show peripheral batteries (mouse, headset, ...) next to the system battery, as an ordered list of entries with icon, percentage and an "only when low" option. Battery style is Icon, Solid or Circle, each horizontal or vertical, and entries are separated by a gap, line, dot or their own pill. Color is the plain widget color, Low and charging, or Level. The popout is rebuilt from sections: an overview of the battery (Line, Ring or Card, wavy while charging), the power profile (Circle, Segments, Buttons or Slider) and the devices, each with its own layout and switch. Spacing follows the interface density. When there is no battery the lowest device takes the overview. All looks live in the battery widget options; the popout links to them and to the Battery settings page. The Control Center reuses the popout content and keeps a Battery tile on desktops with peripherals. Config version 47 maps the old values: Theme color becomes Low and charging, Outline becomes Solid, Ring and Duo become Circle with the direction taken from the bar position.
Claude reviewFour layout and rendering bugs, plus some reuse, token and idle-cost cleanups.
Docs pending: new battery widget options ( Checked: the v47 settings migration and its idempotence, JS helper/QML contracts, settings keys, untouched translation catalogs, the generated search index, wave timer gating, other |
The button group, detail chip and wavy ring and line now come from the shared widgets, which gained the parts the battery needed (width shares for the selected button, a chip icon slot, a charge limit with the part past it dimmed or hatched). The battery copies of them are gone. The popout defaults to a compact look: the level with the charging target beside it, the bar hatched past the charge limit, power profile and details grouped under one Battery label, and devices as filled bars that fade out and collapse when one disconnects. The Devices section shows once a peripheral has connected during the open popout. The previous card look stays reachable as the Line style. The Slider power style is redesigned with a sliding thumb and the profile as a chip. Fixes from review: compact device tiles no longer overflow with an odd count, a device hero no longer shows a clock icon, the ring layout's buttons no longer cover the first fact, a vertical Solid meter fits a horizontal bar, separated pills blur up to their rounded outer ends, the past-limit shade uses the theme scrim, and the Control Center no longer rebuilds its widget list on every peripheral update. While charging toward a charge limit the time remaining counts to the limit, everywhere it is shown. The bar and popout share one device icon and badge rule, every battery meter host passes its color mode, and the island offers the same color options as the bar. Power profile icons match between the popout and the Control Center tile.
…design # Conflicts: # dux-qml-common
Low and charging colors the laptop battery with the theme accent while it is plugged in but not charging, like the theme mode did before it was folded into Low and charging. The Control Center battery detail stops its wave and releases the battery data when the Control Center closes. The power saver icon stays outlined wherever a selected profile icon is filled. Housekeeping: the hero layouts share one column with their footer, the popout sizes live in the metrics file, the meter names its proportions, the bar color options come from one list, and a dead color property, a refactor-only test and a few comments are gone. Long button labels elide in the power profile buttons.
Claude reviewThe ten findings from the last review are fixed. Two new issues: a popout bug and a raw
Docs pending: new battery widget options ( Checked: the earlier findings against HEAD, the v47 migration and its idempotence, settings keys in the spec, data, profiles and UI, the JS helper and QML contracts, other |
The group's height read stats.visible, which is false while the group itself is hidden, so once the details list started empty (before the first battery reading, or with no power profile in the list) the group never came back. It now reads the entry count instead. The bars device list uses DListView like the other lists, with its own row fade off so it doesn't double up with the add and remove transitions.
Claude reviewNo issues found. Both findings from the last review are fixed: the details group now reads Checked: the hero layouts moved into one column with their footer (invisible footers add no gap), |
Dependency
duxlabs-dev/dux-qml-common#57 needs to be merged and qml-common bumped before this gets merged.
Description
Redesigns the battery bar widget and its popout, following the design discussion in the discord. I wanted the battery of my mouse and headset next to the laptop battery in the bar, and a popout that can be arranged like the rest of the shell.
Bar widget:
Popout:
Behavior changes:
Type of change
Related issues
Partially implements #3806: peripherals get the low look in the bar and popout, notifications are separate work.
Screenshots / video
Checklist
I18n.tr()with translator context, reusing existing terms where possiblemake fmt, added/updated tests,make testpasses, andgo mod tidyis cleanmake lint-qmlwith no new warnings