fix: multiple address input fixes (#20005)

fix: multiple address input fixes (#20005)
This commit is contained in:
Omar Basem 2024-05-20 14:53:15 +04:00 committed by GitHub
parent 3e4cbfeb69
commit 29b02a544c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 31 additions and 24 deletions

View File

@ -133,8 +133,7 @@
:on-focus on-focus
:on-blur on-blur
:on-change-text on-change}]
(when (or (= status :default)
(= status :active))
(when (empty? value)
[rn/view
{:style style/buttons-container
:accessibility-label :paste-scan-buttons-container}
@ -155,7 +154,9 @@
:inner-style (style/accessory-button blur? theme)
:on-press on-scan}
:main-icons/scan])])
(when (= status :typing)
(when (or (= status :typing)
(and (= status :active)
(not-empty value)))
[rn/view
{:style style/buttons-container
:accessibility-label :clear-button-container}
@ -168,7 +169,10 @@
{:style style/buttons-container
:accessibility-label :loading-button-container}
[loading-icon blur? theme]])
(when (and (= status :loading) valid-ens-or-address?)
(when (and (or (= status :loading)
(= status :default))
valid-ens-or-address?
(not-empty value))
[rn/view
{:style style/buttons-container
:accessibility-label :positive-button-container}

View File

@ -58,7 +58,7 @@
(defn view
[{:keys [header footer customization-color footer-container-padding header-container-style
gradient-cover?]
gradient-cover? keyboard-should-persist-taps]
:or {footer-container-padding (safe-area/get-top)}}
& children]
(reagent/with-let [scroll-view-ref (atom nil)
@ -108,7 +108,8 @@
:padding-bottom (when @keyboard-did-show?
@footer-container-height)}
:always-bounce-vertical @keyboard-did-show?
:shows-vertical-scroll-indicator false}
:shows-vertical-scroll-indicator false
:keyboard-should-persist-taps keyboard-should-persist-taps}
(into [rn/view {:on-layout set-content-container-height}]
children)]
[rn/keyboard-avoiding-view

View File

@ -157,6 +157,7 @@
color (rf/sub [:wallet/current-viewing-account-color])]
[floating-button-page/view
{:footer-container-padding 0
:keyboard-should-persist-taps true
:header [account-switcher/view
{:on-press on-close
:margin-top (safe-area/get-top)
@ -168,7 +169,8 @@
:disabled? (not valid-ens-or-address?)
:on-press #(rf/dispatch
[:wallet/select-send-address
{:address (or local-suggestion-address
{:address (or
local-suggestion-address
@input-value)
:stack-id
:screen/wallet.select-address}])