litehost 1.3.0
litehost: ^1.3.0 copied to clipboard
Use SetLiteWeb's phone features (location, QR scanner, Bluetooth, sign-in, profile, storage and more) from a LiteStore mini app, with typed Dart APIs and a mock host for development in a normal browser.
1.3.0 #
For SetLiteWeb 1.6.7+ (Android):
LiteHost.location.track()(featurelocation.background, asks): fixes keep coming in the background in a foreground service with a notification; each also goes to your https server (uploadUrl, with Authorization/X- headers), queued while offline. Cancel to stop.LiteHost.phone.call()(featurephone.call): SetLiteWeb confirms each call, then calls or opens the dialer.LiteHost.sms.otp()(featuresms.otp): the next code SMS, after Google's consent prompt; no SMS permission.LiteHost.screen.capture()(featurescreen.capture): your app's screen as PNG.LiteHost.pip.enter()/auto()(featurepip): picture-in-picture.
1.2.0 #
For SetLiteWeb 1.6.6+ (Android):
LiteHost.bluetooth.enable(): Android's "turn on Bluetooth?" dialog.LiteHost.wifi.enable()(featurewifi.enable): the Wi-Fi panel for the user to switch Wi-Fi on (Android 10+), directly on older phones.LiteHost.torch.set()/isOn()(featuretorch): off by itself when the app leaves the screen.LiteHost.nfc.read()(featurenfc): the host's "hold a tag" sheet; tag id, techs and NDEF records (text, links, contact cards). No commands go to cards, so bank cards give only a random id.LiteHost.sensors.list()/watch()(featuresensors): motion, compass, light, pressure, proximity, temperature, humidity, steps; up to 50 Hz, 4 at once.LiteHost.gestures.watch()(featuregestures): shake, face down/up, tilt left/right, wave.LiteHost.device.battery(): level, charging and battery temperature.- MockHost answers all of them;
litehost:checkknows them.
1.1.2 #
- The example is now Feature Lab: one card per feature (every litehost API, including wifi.signal, notifications, biometric, contacts, browser sign-in, camera and microphone streams), with results, error codes explained, timings, an event log and "Run safe tests". No API changes.
1.1.1 #
- Works with
archive3 as well as 4 (only the build tool uses it), so mini apps on Flame's tiled maps, still on archive 3, can depend on litehost.
1.1.0 #
LiteHost.wifi.signal()(featurewifi.signal, SetLiteWeb 1.6.4+, Android): signal strength in dBm, Wi-Fi link speed and band, withpercentandqualityhelpers. No network name, so no consent sheet.MockHostdrifts it like a walk, or fixes it withmockRssi.litehost:checkalso reads JavaScript and HTML inweb/, for mini apps that callwindow.LiteHostdirectly, and tellswifi.getfromwifi.signal.litehost:build:--target <file>for apps whose entry point isn't lib/main.dart; no offline service worker (SetLiteWeb keeps the bundle); leaves out Flutter engine files a WebView never loads (skwasm, other renderers,.symbols, version.json), several MB per app.--no-trimkeeps them;--wasmbuilds keep them too.
1.0.0 #
- First release, for SetLiteWeb bridge version 1: location, camera, microphone, Bluetooth LE, Wi-Fi, clipboard, profile, sign-in (SetLiteWeb token and browser OAuth), QR scanner, photo picker, share, open links, haptics, keep screen on, per-app storage, device info, shareable links, notifications (now or scheduled, opening the app on tap), biometric confirm, contact picker, and pause/resume/link events.
MockHostfor development in a normal browser and for tests.litestore.yamlmanifest,dart run litehost:checkanddart run litehost:build.