ReviewOS

also looking at this

craft-native/craft

feat: finish native customization and platform seams

#401
Merged glennmichael123 wants to merge codex/issues-388-400-344 into main
21 files +707 -17
packages/android/README.mdmodified+23-0
Changes to packages/android/README.md
@@ -484,6 +484,29 @@ changes; the other two values pin the generated host. If it is omitted,
484484`darkMode` remains the compatibility switch (`false` pins light, `true` pins
485485dark).
486486
487Native tab-bar selection styling is opt-in and lives in the generated config,
488so the generated Kotlin never needs to be patched:
489
490```json
491{
492 "tabBar": {
493 "selection": { "cornerRadius": 8, "color": "#123456" }
494 },
495 "postGenerate": {
496 "command": "bun",
497 "args": ["run", "scripts/customize-native.ts"]
498 }
499}
500```
501
502`cornerRadius` is measured in dp and `color` is `#RRGGBB`; omit either to keep
503its host default. `postGenerate` runs from the generated project root during
504`craft android build`, before Gradle compiles the app. Craft passes
505`command` and `args` directly without a shell, and supplies
506`CRAFT_PROJECT_ROOT`, `CRAFT_PLATFORM=android`, and
507`CRAFT_GENERATE_PHASE=build`. An invalid command or non-zero exit fails the
508build and includes the hook's stderr in the diagnostic.
509
487510Remote app and trusted-origin URLs must use HTTPS. Local development may use
488511HTTP with `localhost`, `127.0.0.1`, or the Android emulator host `10.0.2.2`.
489512Origins are normalized before they are stored, and a configured development