feat(settings): redesign encrypt & change-passphrase modals onto reference design

Migrate the Encrypt Wallet (3-phase) and Change Passphrase dialogs in
renderEncryptWalletDialog onto the settings-modal reference design —
presentation-only, no change to the crypto/state-machine/secret-wipe logic:

- struct-form BeginOverlayDialog(OverlayDialogSpec{BlurFloat, cardWidth, idSuffix})
  replacing the legacy positional overload (same visual style, dp-scaled width)
- amber TextWrapped warning -> material::DialogWarningHeader(wiz_encrypt_warning)
- drop redundant Separator dividers
- every hardcoded English string -> TR() (13 new enc_*/change_pass_* keys added to
  the English source + all 8 res/lang/*.json additively; CJK subset rebuilt)

The strength-meter math, 3-phase transitions, "cannot close while encrypting"
guard, memset/SecureVault buffer wipes, and the encrypt/changePassphrase/vault
async paths are byte-for-byte unchanged. Verified: build + ctest + hygiene clean,
wiz_strength %s format-string safe across all languages, and a 3-lens adversarial
review (secret-hygiene / presentation-only / ui-i18n) returned zero findings.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-14 11:13:44 -05:00
parent 5dd68dc9bd
commit 625df8abe6
11 changed files with 157 additions and 41 deletions

View File

@@ -116,6 +116,10 @@
"bootstrap_wallet_protected": "(wallet.dat 已受保护)",
"bootstrap_warning": "现有区块数据blocks、chainstate、notarizations将被删除并替换。您的 wallet.dat 不会被修改或删除。",
"cancel": "取消",
"change_pass_confirm": "确认新密码:",
"change_pass_current": "当前密码短语:",
"change_pass_new": "新密码短语:",
"change_pass_title": "更改密码短语",
"characters": "字符",
"chat": "聊天",
"chat_cancel": "取消",
@@ -341,6 +345,15 @@
"download_bootstrap": "下载引导程序",
"dragonx_green": "DragonX绿色",
"edit": "编辑",
"enc_confirm": "确认:",
"enc_desc": "加密钱包会用密码短语保护您的私钥。加密后,守护进程将重新启动。",
"enc_encrypting": "正在加密钱包...",
"enc_pin_desc": "4-8 位 PIN 码可让您无需每次输入完整密码短语即可解锁钱包。",
"enc_pin_set_ok": "PIN 码设置成功",
"enc_pin_skipped": "已跳过 PIN。您可以稍后在设置中设置。",
"enc_pin_vault_fail": "无法创建 PIN 保险库",
"enc_success": "钱包加密成功!",
"enc_wait": "请稍候,不要关闭应用程序。",
"error": "错误",
"error_format": "错误:%s",
"est_time_to_block": "预计出块时间",