Skip to content

feat(home): show Wi-Fi and internet status on the home screen - #102

Merged
anned20 merged 1 commit into
mainfrom
feat/network-status
Oct 31, 2026
Merged

anned20 merged 1 commit into
mainfrom
feat/network-status

Conversation

@anned20

@anned20 anned20 commented Oct 31, 2026

Copy link
Copy Markdown
Owner

Summary

A network chip next to the Settings gear on the home screen: it shows the link type from webOS' connection manager, then probes a neutral host, because isInternetConnectionAvailable can report true with no uplink.

top chrome
├── #network-status   (home/network-status.ts)
│     start / stop / applyConfig / refresh
│     connection manager -> link type (wifi, ethernet, none)
│     probe -> internet (ok, none)     pause while inactive or saver
└── #app-settings-btn

Clicking the chip opens TV Settings on the network target, falling back to the plain launch that already existed. The chip is optional in Look → Clock & icons.

 config
+29: addNetworkStatus   # showNetworkStatus, defaults true

Call path added to the composition root:

 createApp
+  createNetworkStatus(el, {getConfig, isActive, onOpenNetworkSettings})
   createHomePaint
+  openTvSettings(target)
+    launchSystemApp(id, {target})

Focus changed only so UP from the input row still lands on Settings rather than the new chip; Left reaches the chip.

Evidence

  • Before: no network indicator; isInternetConnectionAvailable trusted blindly.
    After: chip driven by a probe with a 10 s confirmation and a 60 s re-check.
npm run typecheck   # clean
npm test            # 53 files, 431 tests passed
  home/network-status.test.ts   298 lines, new
  config.test.ts                +29 migration covered
  settings-panel.test.ts        toggle round-trip covered

No screenshot: the chip needs a running TV or Simulator.

Merge Danger

Door: two-way — reverting drops the chip and leaves the extra optional config key, which normalize ignores.

A config schema bump to 29; the migration only fills a missing showNetworkStatus with true, so settings and restored backups from 28 and older keep working.

Blast Radius: home chrome and the focus row — the widget can be switched off, but by default every home screen gains a chip, and a failed probe turns it to "no internet" until one succeeds.

A chip next to the Settings gear reports the link type from the connection manager and probes a neutral host for internet reachability, because LG's isInternetConnectionAvailable can stay true without an uplink. A failed probe is confirmed once after ten seconds; probing pauses while another app or the saver is in front.

Clicking the chip opens TV Settings, with an unverified network target and the existing launch as the fallback. The chip can be turned off in Look -> Clock & icons; the config schema moves to 29.

Closes #101
@anned20
anned20 merged commit 43fb329 into main Oct 31, 2026
2 checks passed
@anned20
anned20 deleted the feat/network-status branch October 31, 2026 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant