x07 Field Notes Build Notes
This showcase now ships a real x07 Field Notes reducer and validates the same reducer across web-ui, desktop device-host smoke, and mobile packaging.
What The App Does
- Local notes app with three persistent note slots
- Search over note title, body, and attachment URL
- Note editor with title, body, up to two checklist items, and one attachment URL
- Settings screen with
sync_path, optional API token, and manual sync - Local persistence under the storage key
field_notes.state.v1
The reducer stores the local document as a serialized JSON string in storage. On reload it accepts the stored string form and rehydrates the working state document.
One Command Validation
From the repo root:
bash scripts/ci/check_showcase_mobile.sh
That script runs:
x07 check --project frontend/x07.jsonx07 test --manifest frontend/tests/tests.jsonx07-wasm web-ui profile validatex07-wasm web-ui buildx07-wasm web-ui testfor:tests/web_ui/notes_edit.trace.jsontests/web_ui/storage_reload.trace.jsontests/web_ui/sync_success.trace.jsontests/web_ui/sync_error.trace.json
x07-wasm device build|verify|runfordevice_desktop_devx07-wasm device build|verify|packagefordevice_ios_devx07-wasm device build|verify|packagefordevice_android_dev
Generated Outputs
The validation flow produces:
dist/showcase_mobile/web_ui_debugdist/showcase_mobile/device_desktop_dev_bundledist/showcase_mobile/device_ios_dev_bundledist/showcase_mobile/device_ios_dev_package/ios_projectdist/showcase_mobile/device_android_dev_bundledist/showcase_mobile/device_android_dev_package/android_project
Each packaged mobile project embeds:
bundle.manifest.jsonui/reducer.wasm- local host assets:
index.html,bootstrap.js,main.mjs,app-host.mjs
No runtime WASM download is required.
Sync Contract
The settings screen stores a relative sync_path, not a full backend URL.
The actual network destination comes from the device profile:
arch/device/profiles/device_desktop_dev.jsonarch/device/profiles/device_ios_dev.jsonarch/device/profiles/device_android_dev.json
Those profiles currently point at the placeholder backend https://example.invalid and keep the packaged showcase in a safe non-production state.
Before pointing the app at a real backend:
- Edit the relevant device profile.
- Set
backend.base_urlto the real host. - Keep
backend.allowed_hostsaligned with that host. - Keep
capabilities.network.allow_hostsaligned with the same host policy. - Re-run
bash scripts/ci/check_showcase_mobile.sh. - Enter the matching
sync_pathand optional token in the app settings screen.
If the device profile and the in-app sync_path do not match, sync will fail by design.
Manual Native Build
For iOS:
- Run
bash scripts/ci/check_showcase_mobile.sh. - Open
dist/showcase_mobile/device_ios_dev_package/ios_project/X07DeviceApp.xcodeproj. - Set signing and team information.
- Build for a simulator or device.
For Android:
- Run
bash scripts/ci/check_showcase_mobile.sh. - Open
dist/showcase_mobile/device_android_dev_package/android_project. - Let Gradle sync.
- Configure signing if needed.
- Build for an emulator or device.
Policy Constraint
The packaged app must continue to ship ui/reducer.wasm as an embedded asset. Shipping updated behavior requires rebuilding and redistributing the app bundle, not downloading replacement WASM at runtime.