UI Copy
Plain language for users. No raw backend enums. No technical leakage. Errors land safely; system internals stay internal.
Binding markdown
Binding source: 01-STANDARDS/UI-Copy-Standard.md.
How user-facing copy is written
01
Plain language only
- No "extrinsic", "GraphQL", "OCW", "indexer"
- No "worker queue", "vault storage" in user UI
- Words a non-engineer can act on
02
userFacingReason only
- Failed terminals show only the safe string
- Raw
rejectionReasonis admin / ops only - Closed allowed-strings table
- Fallback when missing: "This deposit could not be verified."
03
No raw enums
DepositNotPending,TX_REUSEDnever reach the user- Mapper at the wrapper boundary
- Tests assert raw enum names absent from user copy
04
Action-oriented
- Tell the user what to do next
- Avoid passive "an error occurred"
- Recoverable errors get a clear next step
Closed user-facing reason set
The Failed terminal and mismatch surfaces draw from a closed list. New strings require a spec amendment + tests.
| Internal reason | User-facing string | Surface |
|---|---|---|
| TX_NOT_FOUND | Transaction not found on chain | Deposit failed |
| AMOUNT_MISMATCH | Transaction did not match your deposit | Deposit failed |
| TX_REUSED | This transaction has already been used | Deposit failed |
| (any, fallback) | This deposit could not be verified. | Deposit failed |
| DepositNotFound | Deposit not found. Please refresh and try again. | Tx-hash submit error |
| NoPermission | You do not have permission to submit a hash for this deposit. | Tx-hash submit error |
| DepositNotPending | This deposit is already confirmed. | Tx-hash submit success |
| TxHashAlreadySubmitted | A transaction hash has already been submitted for this deposit. | Tx-hash submit error |
How we keep it safe
- Unit tests assert that error mappers return only allowed strings.
- Source-scans on TSX + preview reject raw enum identifiers in user-facing components.
- Fallback is mandatory — every error path resolves to a known-safe string, never to
undefinedor an enum literal.