Skip to content

Dashboard: Show the adapter's standing capability note on supported devices - #58

Merged
d4rken merged 1 commit into
mainfrom
feat/adapter-ready-hint
Aug 14, 2026
Merged

Dashboard: Show the adapter's standing capability note on supported devices#58
d4rken merged 1 commit into
mainfrom
feat/adapter-ready-hint

Conversation

@d4rken

@d4rken d4rken commented Aug 13, 2026

Copy link
Copy Markdown
Member

What changed

Supported devices now show a short standing note under the policy card's provenance section describing how this device applies charging changes — "changes take about 15 seconds to reach the hardware" on Pixel, "changes apply immediately" on Samsung/Xiaomi, the Shizuku requirement on ColorOS/LineageOS, and the reconnect-to-apply behavior on GrapheneOS. Previously this copy existed but was unreachable: it only ever rendered on unsupported devices.

Technical Context

  • The adapter_detail_*_ready strings were dead copy — AdapterSupport.detail only reached the UI through the Unsupported/NeedsSetup observation. The new ChargingState.adapterDetail field is populated only while control is enabled, which every probe's when-cascade construction makes exactly the case where detail holds the ready string — verified per adapter, so a gate-failure reason can never render twice.
  • The six strings are reworded from probe-log phrasing ("…detected; …") to standing facts, which is free: they had no other reachable call site.
  • The note is suppressed while a replug is pending on plug-latched adapters (the transient hint states the same fact as an instruction), and cleared when an apply-time gate failure publishes an Unsupported state — the two spots close review found.

…evices

The adapter_detail_*_ready strings were dead copy: AdapterSupport.detail
only ever reached the UI through the Unsupported/NeedsSetup observation,
so a healthy device had no per-adapter hint surface at all. ChargingState
now carries the detail as adapterDetail - populated only while control is
enabled, which by every probe's when-cascade construction is exactly when
detail holds the ready string, so a gate-failure reason can never print
twice - and the dashboard's provenance block renders it between the
readback line and the device line. The six strings are reworded from
probe-log phrasing ("...detected; ...") into standing facts (write
latency on Pixel, immediate application on Samsung/Xiaomi, the Shizuku
requirement on Oplus/LineageOS, replug semantics on GrapheneOS).
@github-actions github-actions Bot added the enhancement New feature or request label Aug 13, 2026
@d4rken
d4rken merged commit fabd764 into main Aug 14, 2026
12 checks passed
@d4rken
d4rken deleted the feat/adapter-ready-hint branch August 14, 2026 04:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant