Skip to content

Drop articles before renameable domain words#51

Merged
dadachi merged 1 commit into
mainfrom
apply-rename-safety-contract
May 8, 2026
Merged

Drop articles before renameable domain words#51
dadachi merged 1 commit into
mainfrom
apply-rename-safety-contract

Conversation

@dadachi
Copy link
Copy Markdown
Contributor

@dadachi dadachi commented May 8, 2026

Summary

  • Apply SUBSTRATE-CONTRACT.md rule 1: UI strings must not couple articles to renameable domain nouns (Shop, ItemTag, Shopkeeper), so the agent's rename pipeline produces grammatical output for any target word (e.g. "Swipe an item tag…""Swipe an patient…" after ItemTag → Patient).
  • Mirrors nativeapptemplate/NativeAppTemplate-iOS#77. Of the 7 iOS UI string changes, 3 have Android equivalents in app/src/main/res/values/strings.xml; the other 4 are toast/error strings (shopDeletedError, itemTagDeletedError, itemTagCompletedError, itemTagIdledError) that don't exist on Android, so they're skipped.
  • The 1 iOS test-fixture change (ShopAdapterTest.swift) maps to the seed JSON in app/src/main/assets/{shop,shops}.json plus the matching DemoShopRepositoryTest assertions — all four "This is a Shop1"-style strings updated to "This is Shop1" so demo deserialization tests stay green.
  • One change matches the contract's "Also good" example verbatim: shop_detail_instruction becomes "Swipe to change item tag status."

Test plan

  • ./gradlew testDebugUnitTest --tests "com.nativeapptemplate.nativeapptemplatefree.demo.shop.DemoShopRepositoryTest" — passes
  • ./gradlew spotlessCheck lintDebug — clean
  • Spot-check the affected UI strings render correctly: shop list empty state ("Tap shop below"), item-tag list empty state ("Add a new item tag and start changing item tag status."), shop detail instruction ("Swipe to change item tag status.")

🤖 Generated with Claude Code

Apply SUBSTRATE-CONTRACT.md rule 1: UI strings and seed data must not
couple articles to renameable domain nouns (Shop, ItemTag, Shopkeeper),
so the agent's rename pipeline produces grammatical output for any
target word.

Mirrors nativeapptemplate/NativeAppTemplate-iOS#77. Of the 7 iOS UI
string changes, 3 have Android equivalents in strings.xml; the other
4 are toast/error strings that don't exist on Android. The seed
description fixtures (shop.json, shops.json) and the demo test that
mirrors them are updated to match.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@dadachi dadachi merged commit d986a81 into main May 8, 2026
1 check passed
@dadachi dadachi deleted the apply-rename-safety-contract branch May 8, 2026 07:20
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