From 24a777357d822551eb6f81e1347632cf4506f3d0 Mon Sep 17 00:00:00 2001 From: Nguyen Anh Tu Date: Tue, 24 Sep 2024 19:34:46 +0700 Subject: [PATCH 1/2] feat(view): demo - add use aa with external wallet toggle --- demo/vue-app-new/src/MainView.vue | 2 +- demo/vue-app-new/src/components/AppSettings.vue | 11 +++++++++++ demo/vue-app-new/src/config.ts | 1 + demo/vue-app-new/src/store/form.ts | 1 + demo/vue-app-new/src/translations/en.json | 3 ++- 5 files changed, 16 insertions(+), 2 deletions(-) diff --git a/demo/vue-app-new/src/MainView.vue b/demo/vue-app-new/src/MainView.vue index 204330ed1..462b35c5e 100644 --- a/demo/vue-app-new/src/MainView.vue +++ b/demo/vue-app-new/src/MainView.vue @@ -131,7 +131,7 @@ const options = computed((): Web3AuthOptions => { web3AuthNetwork: formData.network, uiConfig: enabledWhiteLabel ? { ...whiteLabel } : undefined, accountAbstractionProvider: accountAbstractionProvider.value, - useAAWithExternalWallet: true, + useAAWithExternalWallet: formData.useAAWithExternalWallet, // TODO: Add more options // chainConfig?: CustomChainConfig; // enableLogging?: boolean; diff --git a/demo/vue-app-new/src/components/AppSettings.vue b/demo/vue-app-new/src/components/AppSettings.vue index 9322c9409..7861a8b2e 100644 --- a/demo/vue-app-new/src/components/AppSettings.vue +++ b/demo/vue-app-new/src/components/AppSettings.vue @@ -52,6 +52,7 @@ const isDisabled = (name: string): boolean => { case "smartAccountType": case "bundlerUrl": case "paymasterUrl": + case "useAAWithExternalWallet": return !formData.useAccountAbstractionProvider; default: { @@ -337,6 +338,16 @@ const isActiveTab = (index: number) => activeTab.value === index; :label-enabled="$t('app.accountAbstractionProvider.title')" class="my-2" /> +