diff --git a/docs/DEPLOY_CHECKLIST.md b/docs/DEPLOY_CHECKLIST.md index 584c3babf..93e6401ab 100644 --- a/docs/DEPLOY_CHECKLIST.md +++ b/docs/DEPLOY_CHECKLIST.md @@ -1068,10 +1068,13 @@ claim が漏れ ありと判明、6 箇所に拡張): ### 9.6 MAv2 + Kaia defensive UI (実装済) -MAv2 経路は Pimlico Kaia 非対応で早期 throw され、`errorMav2KaiaPolygon` i18n -message で「Polygon / Base / Arbitrum / Optimism 等の他チェーン版をご利用くだ -さい」と案内する (commit `7ee8bc4`、Payment/Tip/Checkout 3 form × ja/en 全カ -バー)。 +MAv2 経路は Pimlico Kaia 非対応で早期 throw される (`IncompatibleSmartAccountError`・ +i18nKey `errorMav2KaiaPolygon`・commit `7ee8bc4`)。画面は Payment/Tip/Checkout の 3 form とも +`SmartAccountFallback` の banner を出す (/pay・/checkout は「通常決済に切替」・/tip は +「このウォレットではチップを送れません」)。`errorMav2KaiaPolygon` の名前の文 (「Polygon / Base / +Arbitrum / Optimism 等の他チェーン版をご利用ください」) は 3 form の namespace にあったが、画面に +描かれていなかったので消した (2026-11 第 10 回レビュー PR-28a)。i18nKey は error の種類の名前として +コードに残る。 **注意**: HashPort wallet は Kaia 非対応 (Ethereum/Polygon/Base/BNB/Avalanche/ Arbitrum/Aptos のみ) のため、本ガードは現時点で実発火しない defensive 実装。 @@ -1081,8 +1084,10 @@ Arbitrum/Aptos のみ) のため、本ガードは現時点で実発火しない - [x] `lib/smartAccount/mav2.ts` chainId 8217/1001 で `errorMav2KaiaPolygon` i18nKey throw - [x] i18n message を `messages/{ja,en}.json` の Payment/Tip/Checkout 3 - namespace に追加 -- [x] `tests/lib/i18nKeys.test.ts` で 6 件全て存在を fence + namespace に追加 → 描かれていなかったので PR-28a で削除 (画面の文は + `SmartAccountFallback` namespace) +- [x] `tests/lib/i18nKeys.test.ts` で 6 件全て存在を fence → PR-28a で + 「smart account の error の 7 つの名前の文が messages に無い」の fence に替えた - [ ] **将来 MAv2+Kaia wallet 出現時**: Sentry `smart_account.mav2_kaia_rejected` の実発火を観測したら、当該 wallet で 実機 QA + 文言再確認 diff --git a/docs/plans/tip-widget-parity-plan.md b/docs/plans/tip-widget-parity-plan.md index 10582ebd4..f9c869f7b 100644 --- a/docs/plans/tip-widget-parity-plan.md +++ b/docs/plans/tip-widget-parity-plan.md @@ -418,7 +418,7 @@ Tip widget の `params.to` (creator address) は EOA 想定。Kaia chain で USD - creator が「Kaia で JPYC tip だけ受けたい」というユースケースは現実にあるか? それとも社内 demo only か? - もし demo only なら chain chooser に注意書きを追加するか -- **推奨**: 注意書き不要 (PaymentForm 側でも Kaia 注意書きはない、`messages/ja.json:235-237` の `errorMav2KaiaPolygon` で UI fallback 済) +- **推奨**: 注意書き不要 (PaymentForm 側でも Kaia 注意書きはない、`messages/ja.json:235-237` の `errorMav2KaiaPolygon` で UI fallback 済 — 追記 2026-11: この文は画面に描かれておらず、第 10 回レビュー PR-28a で消した。画面が出すのは `SmartAccountFallback` の banner) ### Q4. cross-chain crossChain toggle の default ✅ 決定: default true diff --git a/lib/accountDetection.ts b/lib/accountDetection.ts index caf726f7a..c7f7e6cd9 100644 --- a/lib/accountDetection.ts +++ b/lib/accountDetection.ts @@ -72,6 +72,9 @@ export async function detectAccountKind( return { kind: 'unknown', delegateAddress: target }; } +// 名前は i18nKey だが、messages に同じ名前の文は無い (描かれていなかったので 2026-11 の第 10 回レビュー PR-28a で消した)。 +// error の種類の名前として使う: 3 フォームは 'errorPristineNoBootstrap' かどうかだけを見て、文は SmartAccountFallback の +// namespace から出す (components/SmartAccountFallbackBanner.tsx)。 export type IncompatibleSmartAccountI18nKey = | 'errorIncompatibleSmartAccount' | 'errorMav2Disabled' diff --git a/messages/en.json b/messages/en.json index 604bd3122..6fd67ca5c 100644 --- a/messages/en.json +++ b/messages/en.json @@ -719,13 +719,6 @@ "errorGasCongested": "The network is congested and gas prices are too high. Please try again later.", "errorGasQuote": "Failed to fetch the gas estimate. Check your network connection and try again.", "errorMerchantUnderflow": "After deducting gas the merchant would receive 0. Minimum {min} required.", - "errorIncompatibleSmartAccount": "Your wallet is delegated to a Smart Account implementation that OpenPay does not support yet (delegate: {address}). If you are using MetaMask, toggle off \"Smart account\" in Account details to revert to a plain EOA. Or try a different wallet (Rabby / Frame, etc.).", - "errorMav2Disabled": "Payments from wallets backed by Alchemy Modular Account v2 (such as HashPort) are being rolled out gradually. Please try again later.", - "errorMav2KaiaPolygon": "Payments on Kaia are not supported for wallets delegated to Alchemy Modular Account v2. Please use a Polygon / Base / Arbitrum / Optimism payment QR, or try a different wallet.", - "errorMetaMaskKaia": "MetaMask Smart Account is not supported on Kaia yet (MetaMask has not deployed its delegator on Kaia). Toggle off \"Smart account\" in MetaMask Account details to revert to a plain EOA, or try a different wallet.", - "errorPristineNoBootstrap": "This wallet isn't set up for gasless payments yet. You can pay now in standard mode (you pay network gas).", - "errorChainNo7702": "Gasless USDC payments aren't available on this chain yet (its EIP-7702 implementation differs from the standard). You can pay now in standard mode (you pay network gas).", - "errorMetaMaskGaslessUnavailable": "Gasless payments via MetaMask Smart Account are temporarily unavailable (a wallet-side compatibility issue). You can pay now in standard mode (you pay network gas).", "successTitle": "Payment complete", "foreignSettlementTitle": "A previous pending payment has completed. This is not the payment on this screen.", "foreignSettlementBody": "To continue with the payment on this screen, reload the page.", @@ -893,8 +886,6 @@ "errorTitle": "Error", "errorGasCongested": "The network is congested and gas prices are too high. Please try again later.", "errorGasQuote": "Failed to fetch the gas estimate. Check your network connection and try again.", - "errorIncompatibleSmartAccount": "Your wallet is delegated to a Smart Account implementation that OpenPay does not support yet (delegate: {address}). If you are using MetaMask, toggle off \"Smart account\" in Account details to revert to a plain EOA. Or try a different wallet (Rabby / Frame, etc.).", - "errorMav2Disabled": "Tip sending from wallets backed by Alchemy Modular Account v2 (such as HashPort) is being rolled out gradually. Please try again later.", "errorAmountPrecision": "Amount can have at most {decimals} decimal places. Trim the digits so the displayed amount matches what is actually sent.", "errorReverted": "The tip failed on-chain (it was reverted). Check your balance and network, then try again.", "errorRelayRateLimited": "Too many payments in a short period. Please wait a moment and try again.", @@ -903,11 +894,6 @@ "errorRelayGeneric": "Could not complete the gasless transfer. Please try again later.", "errorRelayFeePaused": "Gasless tips to this creator are currently paused. Please check with the creator.", "errorRelayStorageUnavailable": "We can't save a payment record on this device, so gasless transfer isn't available (your JPYC didn't move). Check your browser's site data settings, or try another browser.", - "errorMav2KaiaPolygon": "Sending tips on Kaia is not supported for wallets delegated to Alchemy Modular Account v2. Please use a Polygon / Base / Arbitrum / Optimism Tip link, or try a different wallet.", - "errorMetaMaskKaia": "MetaMask Smart Account is not supported on Kaia yet. Toggle off \"Smart account\" in MetaMask Account details, or try a different wallet.", - "errorPristineNoBootstrap": "This wallet isn't set up for gasless payments yet, and tips require gasless mode. Please try a wallet that's already set up for gasless.", - "errorChainNo7702": "Gasless isn't available on this chain yet (its EIP-7702 implementation differs from the standard), and tips require gasless mode. Please use another chain such as Polygon / Base / Arbitrum / Optimism.", - "errorMetaMaskGaslessUnavailable": "Gasless payments via MetaMask Smart Account are temporarily unavailable (a wallet-side compatibility issue). Tips require gasless mode — please try a different wallet that's already set up for gasless.", "ipRateLimitedTitle": "Temporarily busy", "ipRateLimitedBody": "Please wait a moment, then retry with the same details. You do not need to sign again.", "ipRateLimitedBodyWithRetryAfter": "Please wait about {seconds} seconds, then retry with the same details. You do not need to sign again.", @@ -1662,14 +1648,7 @@ "errorGasQuote": "Failed to fetch the gas estimate. Check your network connection and try again.", "errorMerchantUnderflow": "After deducting gas the merchant would receive 0. Minimum {min} required.", "errorOrderMerchantBelowFloor": "This order can't be paid because the shop would receive less than 1 JPYC.", - "errorIncompatibleSmartAccount": "Your wallet is delegated to a Smart Account implementation that OpenPay does not support yet (delegate: {address}). If you are using MetaMask, toggle off \"Smart account\" in Account details to revert to a plain EOA. Or try a different wallet (Rabby / Frame, etc.).", - "errorMav2Disabled": "Payments from wallets backed by Alchemy Modular Account v2 (such as HashPort) are being rolled out gradually. Please try again later.", - "errorMav2KaiaPolygon": "Checkout on Kaia is not supported for wallets delegated to Alchemy Modular Account v2. Please use a Polygon / Base / Arbitrum / Optimism checkout URL, or try a different wallet.", "errorReverted": "The payment failed on-chain (it was reverted). Check your balance and network, then try again.", - "errorMetaMaskKaia": "MetaMask Smart Account is not supported on Kaia yet. Toggle off \"Smart account\" in MetaMask Account details, or try a different wallet.", - "errorPristineNoBootstrap": "This wallet isn't set up for gasless payments yet. You can pay now in standard mode (you pay network gas).", - "errorChainNo7702": "Gasless USDC payments aren't available on this chain yet (its EIP-7702 implementation differs from the standard). You can pay now in standard mode (you pay network gas).", - "errorMetaMaskGaslessUnavailable": "Gasless payments via MetaMask Smart Account are temporarily unavailable (a wallet-side compatibility issue). You can pay now in standard mode (you pay network gas).", "successTitle": "Payment complete", "successBody": "Thanks for your purchase. The transaction is confirmed on-chain.", "foreignSettlementTitle": "A previous pending payment has completed. This is not the payment on this screen.", diff --git a/messages/ja.json b/messages/ja.json index 5cca2f7e0..be47cb22f 100644 --- a/messages/ja.json +++ b/messages/ja.json @@ -719,13 +719,6 @@ "errorGasCongested": "ネットワークが混雑しています。ガス代が高騰しているため、しばらく経ってから再度お試しください。", "errorGasQuote": "ガス代見積の取得に失敗しました。ネットワーク接続を確認してから再度お試しください。", "errorMerchantUnderflow": "この金額では gas を引くと店主受取が 0 になります。最低 {min} 必要です。", - "errorIncompatibleSmartAccount": "お使いのウォレットは OpenPay 未対応の Smart Account 実装に委任されています (delegate: {address})。MetaMask の場合は「アカウント詳細 → Smart account」をオフにすると元の EOA に戻せます。または別のウォレット (Rabby / Frame 等) でお試しください。", - "errorMav2Disabled": "現在 HashPort 等の一部ウォレット (Alchemy Modular Account v2) での決済は段階公開中です。少々お待ちください。", - "errorMav2KaiaPolygon": "Kaia チェーン上では Alchemy Modular Account v2 に委任されたウォレットでは決済できません。お手数ですが Polygon / Base / Arbitrum / Optimism 等の他チェーン版 QR をご利用いただくか、別のウォレットでお試しください。", - "errorMetaMaskKaia": "Kaia チェーン上では MetaMask Smart Account には現在対応していません (MetaMask は Kaia への delegator を未 deploy)。MetaMask の場合は「アカウント詳細 → Smart account」をオフにして元の EOA に戻すか、別のウォレットでお試しください。", - "errorPristineNoBootstrap": "このウォレットはまだガスレス決済の準備ができていません。通常決済 (ガス代自己負担) で今すぐ支払えます。", - "errorChainNo7702": "このチェーンでは現在 USDC ガスレス決済に対応していません (このチェーンの EIP-7702 実装が標準と異なるため)。通常決済 (ガス代自己負担) で今すぐ支払えます。", - "errorMetaMaskGaslessUnavailable": "MetaMask Smart Account でのガスレス決済は現在ご利用いただけません (ウォレット側の互換性問題のため一時停止中)。通常決済 (ガス代自己負担) で今すぐ支払えます。", "successTitle": "決済が完了しました", "foreignSettlementTitle": "前に確認中だった支払いが完了しました。この画面の支払いではありません。", "foreignSettlementBody": "この画面の支払いを続けるには、読み込み直してください。", @@ -893,8 +886,6 @@ "errorTitle": "エラー", "errorGasCongested": "ネットワークが混雑しています。ガス代が高騰しているため、しばらく経ってから再度お試しください。", "errorGasQuote": "ガス代見積の取得に失敗しました。ネットワーク接続を確認してから再度お試しください。", - "errorIncompatibleSmartAccount": "お使いのウォレットは OpenPay 未対応の Smart Account 実装に委任されています (delegate: {address})。MetaMask の場合は「アカウント詳細 → Smart account」をオフにすると元の EOA に戻せます。または別のウォレット (Rabby / Frame 等) でお試しください。", - "errorMav2Disabled": "現在 HashPort 等の一部ウォレット (Alchemy Modular Account v2) でのチップ送信は段階公開中です。少々お待ちください。", "errorAmountPrecision": "金額の小数点以下は最大 {decimals} 桁までです。表示額と実際の送金額がずれないよう、桁を減らしてください。", "errorReverted": "チップの送信がネットワーク上で失敗しました (処理が取り消されました)。残高やネットワーク状況を確認のうえ、再度お試しください。", "errorRelayRateLimited": "短時間に送金が集中しています。少し時間をおいてから、再度お試しください。", @@ -903,11 +894,6 @@ "errorRelayGeneric": "ガスレス送金を完了できませんでした。時間をおいて再度お試しください。", "errorRelayFeePaused": "クリエイターへのガスレス送金は現在停止しています。クリエイターの方にご確認ください。", "errorRelayStorageUnavailable": "この端末では支払い記録を保存できないため、ガスレス送金は使えません (JPYC は動いていません)。ブラウザの設定 (サイトのデータの保存) を確かめるか、別のブラウザでお試しください。", - "errorMav2KaiaPolygon": "Kaia チェーン上では Alchemy Modular Account v2 に委任されたウォレットからチップを送れません。お手数ですが Polygon / Base / Arbitrum / Optimism 等の他チェーン版 Tip リンクをご利用いただくか、別のウォレットでお試しください。", - "errorMetaMaskKaia": "Kaia チェーン上では MetaMask Smart Account には現在対応していません。MetaMask の「アカウント詳細 → Smart account」をオフにするか、別のウォレットでお試しください。", - "errorPristineNoBootstrap": "このウォレットはまだガスレス決済の準備ができていません。チップにはガスレスモードが必要です。ガスレス対応済みのウォレットでお試しください。", - "errorChainNo7702": "このチェーンでは現在 USDC ガスレスに対応していないため、チップを送れません (このチェーンの EIP-7702 実装が標準と異なるため)。Polygon / Base / Arbitrum / Optimism 等の他チェーンをご利用ください。", - "errorMetaMaskGaslessUnavailable": "MetaMask Smart Account でのガスレス決済は現在ご利用いただけません (ウォレット側の互換性問題のため一時停止中)。チップにはガスレスが必要なため、ガスレス対応済みの別ウォレットでお試しください。", "ipRateLimitedTitle": "混雑しています", "ipRateLimitedBody": "しばらくしてから、同じ内容でもう一度お試しください(再署名は不要です)。", "ipRateLimitedBodyWithRetryAfter": "{seconds}秒ほど待ってから、同じ内容でもう一度お試しください(再署名は不要です)。", @@ -1662,14 +1648,7 @@ "errorGasQuote": "ガス代見積の取得に失敗しました。ネットワーク接続を確認してから再度お試しください。", "errorMerchantUnderflow": "この金額では gas を引くと店主受取が 0 になります。最低 {min} 必要です。", "errorOrderMerchantBelowFloor": "この注文はお店に届く額が 1 JPYC 未満のため、お支払いできません", - "errorIncompatibleSmartAccount": "お使いのウォレットは OpenPay 未対応の Smart Account 実装に委任されています (delegate: {address})。MetaMask の場合は「アカウント詳細 → Smart account」をオフにすると元の EOA に戻せます。または別のウォレット (Rabby / Frame 等) でお試しください。", - "errorMav2Disabled": "現在 HashPort 等の一部ウォレット (Alchemy Modular Account v2) での決済は段階公開中です。少々お待ちください。", - "errorMav2KaiaPolygon": "Kaia チェーン上では Alchemy Modular Account v2 に委任されたウォレットでチェックアウトできません。お手数ですが Polygon / Base / Arbitrum / Optimism 等の他チェーン版のチェックアウト URL をご利用いただくか、別のウォレットでお試しください。", "errorReverted": "送金がネットワーク上で失敗しました (処理が取り消されました)。残高やネットワーク状況を確認のうえ、再度お試しください。", - "errorMetaMaskKaia": "Kaia チェーン上では MetaMask Smart Account には現在対応していません。MetaMask の「アカウント詳細 → Smart account」をオフにするか、別のウォレットでお試しください。", - "errorPristineNoBootstrap": "このウォレットはまだガスレス決済の準備ができていません。通常決済 (ガス代自己負担) で今すぐ支払えます。", - "errorChainNo7702": "このチェーンでは現在 USDC ガスレス決済に対応していません (このチェーンの EIP-7702 実装が標準と異なるため)。通常決済 (ガス代自己負担) で今すぐ支払えます。", - "errorMetaMaskGaslessUnavailable": "MetaMask Smart Account でのガスレス決済は現在ご利用いただけません (ウォレット側の互換性問題のため一時停止中)。通常決済 (ガス代自己負担) で今すぐ支払えます。", "successTitle": "お支払いが完了しました", "successBody": "ご注文ありがとうございます。決済はオンチェーンで確定しました。", "foreignSettlementTitle": "前に確認中だった支払いが完了しました。この画面の支払いではありません。", diff --git a/tests/lib/i18nKeys.test.ts b/tests/lib/i18nKeys.test.ts index 5b0e47fab..cc515bbf2 100644 --- a/tests/lib/i18nKeys.test.ts +++ b/tests/lib/i18nKeys.test.ts @@ -112,39 +112,29 @@ describe('i18n: Tokutei の ja/en parity', () => { }); }); -describe('i18n: smart account 互換性エラー (3 form 名前空間 × ja/en)', () => { - // useSmartAccount の router が IncompatibleSmartAccountError を投げる時の - // i18n key 2 種。HashPort などの MAv2 委任 EOA 対策で導入。 - const SA_KEYS = [ +// smart account の互換性 error (lib/accountDetection.ts の IncompatibleSmartAccountError) の i18nKey の 7 つの名前は、 +// 3 フォームの namespace に同じ名前の文を持っていたが、どの画面も描いていなかった (3 フォームは i18nKey を +// 'errorPristineNoBootstrap' かどうかの判定にだけ使い、文は SmartAccountFallback の namespace から出す = +// components/SmartAccountFallbackBanner.tsx)。第 10 回レビュー PR-28a で messages から消した (user 裁定 2026-11-12)。 +// i18nKey の名前はコードに残るので、下の「使われていないキーが無い」の検査 (leaf 名がソースに出れば使用中とみなす) は +// 文が戻っても落ちない。描かれない文が戻らないよう、ここで名前ごとに縛る。 +describe('i18n: smart account 互換性 error の文は messages に無い (描くのは SmartAccountFallback)', () => { + const REMOVED_SA_KEYS = [ 'errorIncompatibleSmartAccount', 'errorMav2Disabled', - // Kaia + MAv2 (HashPort 等) 専用、Polygon フォールバック案内 - // (memory:project_kaia_evaluation、mav2.ts の Kaia chainId 早期 throw 経路) 'errorMav2KaiaPolygon', - // pristine EOA (未委任) は injected wallet で初回ガスレス委任不可 - // (useSmartAccount が standard mode 案内に倒す) + 'errorMetaMaskKaia', 'errorPristineNoBootstrap', - // canonical EIP-7702 非対応 chain (Avalanche = ACP-209「7702 style」AA) で - // 委任済み EOA を standard mode に倒す (chainSupportsCanonical7702 ガード) 'errorChainNo7702', - // MetaMask Smart Account ガスレスが viem 2.50 ERC-7739 非互換で一時無効 - // (standard mode 案内に倒す・useSmartAccount の metamask-7702 ガード) 'errorMetaMaskGaslessUnavailable', ] as const; - for (const ns of FORM_NAMESPACES) { - for (const key of SA_KEYS) { - it(`ja.${ns}.${key} は非空文字列`, () => { - const v = (ja[ns] as Record)[key]; - expect(typeof v).toBe('string'); - expect(v).not.toBe(''); - }); - it(`en.${ns}.${key} は非空文字列`, () => { - const v = (en[ns] as Record)[key]; - expect(typeof v).toBe('string'); - expect(v).not.toBe(''); - }); - } - } + it.each(['ja', 'en'] as const)('%s: 7 つの名前の文が、どの namespace にも無い', (locale) => { + const messages = { ja, en }[locale]; + const holders = messageLeafPaths(messages).filter((leafPath) => + REMOVED_SA_KEYS.some((key) => leafPath.split('.').includes(key)), + ); + expect(holders).toEqual([]); + }); }); // 確認中の支払いを送り直す前に端末へ保存できないときの本文 (user 承認済みの文・2026-11-11)。3 フォームの @@ -177,28 +167,6 @@ describe('i18n: pendingStoreUnavailableResendBody (3 form 名前空間 × ja/en) }); }); -// errorMetaMaskKaia は Kaia で MetaMask Smart Account を断るときの文。MetaMask Smart Account のガスレスは -// 止めている (NEXT_PUBLIC_ENABLE_METAMASK_SMART_ACCOUNT は既定 OFF・同じ namespace の -// errorMetaMaskGaslessUnavailable が「現在ご利用いただけません」と書く) ので、ほかのチェーンで使えるとは書かない。 -// 同名の key が 3 フォームの namespace にあるので、namespace ごとに確かめる。 -describe('i18n: errorMetaMaskKaia (3 form 名前空間 × ja/en)', () => { - const KEY = 'errorMetaMaskKaia'; - it.each(['ja', 'en'] as const)('%s: 3 フォームの namespace だけにあり、Kaia のほかのチェーンの名前を出さない', (locale) => { - const messages = { ja, en }[locale] as Record; - const holders = Object.entries(messages) - .filter(([, value]) => typeof value === 'object' && value !== null && KEY in value) - .map(([ns]) => ns); - expect(holders.sort()).toEqual([...FORM_NAMESPACES].sort()); - for (const ns of FORM_NAMESPACES) { - const text = (messages[ns] as Record)[KEY]; - expect(typeof text).toBe('string'); - expect(text).toContain('Kaia'); - expect(text).not.toMatch(/\b(Polygon|Base|Arbitrum|Optimism|Ethereum|Avalanche|Arc)\b/); - expect(text).not.toMatch(/gasless|ガスレス/i); - } - }); -}); - describe('i18n: onramp keys (3 form 名前空間 × ja/en)', () => { for (const ns of FORM_NAMESPACES) { for (const key of ONRAMP_KEYS) { diff --git a/tests/lib/smartAccount/mav2.test.ts b/tests/lib/smartAccount/mav2.test.ts index 56848c264..bbcbe3ed1 100644 --- a/tests/lib/smartAccount/mav2.test.ts +++ b/tests/lib/smartAccount/mav2.test.ts @@ -202,8 +202,8 @@ describe('buildMav2SmartAccountClient', () => { // Pimlico Kaia 対応 Smart Account は Safe / Simple Account / Thirdweb のみ。 // MAv2 wallet で Kaia 対応のものは 2026-05 時点で確認されていない (HashPort // wallet は Kaia 非対応) が、defensive guard として将来の MAv2 + Kaia 遭遇 - // に対し errorMav2KaiaPolygon で他 chain (Polygon/Base/Arbitrum/Optimism) - // フォールバックを案内する。 + // に対し専用の i18nKey (errorMav2KaiaPolygon) で止める。画面は SmartAccountFallback の banner を出す + // (他 chain を案内する同名の文は描かれていなかったので、第 10 回レビュー PR-28a で messages から消した)。 const consoleWarn = vi.spyOn(console, 'warn').mockImplementation(() => undefined); const jpycKaia: TokenDeployment = { ...jpycSponsorship, @@ -220,7 +220,7 @@ describe('buildMav2SmartAccountClient', () => { captured = e; }); expect(captured).toBeInstanceOf(IncompatibleSmartAccountError); - // Polygon フォールバック専用の i18nKey に routing (generic errorIncompatible… + // MAv2 + Kaia 専用の i18nKey に routing (generic errorIncompatible… // ではなく specific errorMav2KaiaPolygon) expect(captured?.i18nKey).toBe('errorMav2KaiaPolygon'); expect(captured?.delegateAddress).toBeNull();