id: NL-SPEC-C24FF4FA
type: spec
title: Power popup
Power popup
Power state
A main battery hero appears only for a real laptop or display battery.
The hero shows circular percentage, lowercase state, time estimate, health when available, and the existing charge role.
Desktops never show a fake battery.
External battery devices appear as compact chips below the hero.
Without battery data, session actions become the first content.
Global low-power mode continues to reflect discharge state for animation throttling.
Session actions
lock is the primary safe action.
suspend, monitor-off, and monitor-on are secondary one-click actions.
logout, reboot, and poweroff occupy a separate danger region.
Destructive actions require two steps.
While confirmation is pending, the danger region becomes a focused card with the lowercase action name, confirm, and cancel.
Enter confirms and Escape cancels without on-screen keyboard instructions.
Existing real session effects remain unchanged.
No fake power-profile selector appears without a working profile service.
Safety and interface constraints
Session commands use fixed discrete argument vectors without shell interpolation or sudo.
Verification never executes logout, reboot, or poweroff; it covers their confirmation gate and route only.
Existing power, confirmation, low-power, and self-test IPC remains available.
State retains battery status, external devices, actions, compact state, pending confirmation, and last action.
State excludes backend narration and fake profile state.
Acceptance
Pure tests cover battery normalization, time and state labels, roles, battery detection, low-power detection, confirmation, and every route.
Runtime self-test passes without executing destructive actions.
A live visual check confirms battery-present and battery-absent layouts, external chips, safe and danger grouping, and in-place confirmation.
All UI labels are lowercase.
---
id: NL-SPEC-C24FF4FA
type: spec
title: Power popup
---
# Power popup
## Power state
- A main battery hero appears only for a real laptop or display battery.
- The hero shows circular percentage, lowercase state, time estimate, health when available, and the existing charge role.
- Desktops never show a fake battery.
- External battery devices appear as compact chips below the hero.
- Without battery data, session actions become the first content.
- Global low-power mode continues to reflect discharge state for animation throttling.
## Session actions
- `lock` is the primary safe action.
- `suspend`, `monitor-off`, and `monitor-on` are secondary one-click actions.
- `logout`, `reboot`, and `poweroff` occupy a separate danger region.
- Destructive actions require two steps.
- While confirmation is pending, the danger region becomes a focused card with the lowercase action name, `confirm`, and `cancel`.
- Enter confirms and Escape cancels without on-screen keyboard instructions.
- Existing real session effects remain unchanged.
- No fake power-profile selector appears without a working profile service.
## Safety and interface constraints
- Session commands use fixed discrete argument vectors without shell interpolation or sudo.
- Verification never executes logout, reboot, or poweroff; it covers their confirmation gate and route only.
- Existing power, confirmation, low-power, and self-test IPC remains available.
- State retains battery status, external devices, actions, compact state, pending confirmation, and last action.
- State excludes backend narration and fake profile state.
## Acceptance
- Pure tests cover battery normalization, time and state labels, roles, battery detection, low-power detection, confirmation, and every route.
- Runtime self-test passes without executing destructive actions.
- A live visual check confirms battery-present and battery-absent layouts, external chips, safe and danger grouping, and in-place confirmation.
- All UI labels are lowercase.