chore(wallet/shell): minor fixes from design review (#20494)
* chore(wallet): make recent tab fullscreen for empty view * chore(wallet): hide advanced button on send page * chore(wallet): hide estimated fees when no routes found * chore(wallet): update emoji icon to edit * chore(wallet): update key pair placeholder to use keypair example * chore(shell): feature flag saved address option in scanner
This commit is contained in:
parent
136c3c0032
commit
6931fd0052
|
@ -58,7 +58,7 @@
|
|||
|
||||
(defn view
|
||||
[{:keys [header footer customization-color footer-container-padding header-container-style
|
||||
gradient-cover? keyboard-should-persist-taps]
|
||||
content-container-style gradient-cover? keyboard-should-persist-taps]
|
||||
:or {footer-container-padding (safe-area/get-top)}}
|
||||
& children]
|
||||
(reagent/with-let [scroll-view-ref (atom nil)
|
||||
|
@ -110,7 +110,9 @@
|
|||
:always-bounce-vertical @keyboard-did-show?
|
||||
:shows-vertical-scroll-indicator false
|
||||
:keyboard-should-persist-taps keyboard-should-persist-taps}
|
||||
(into [rn/view {:on-layout set-content-container-height}]
|
||||
(into [rn/view
|
||||
{:style content-container-style
|
||||
:on-layout set-content-container-height}]
|
||||
children)]
|
||||
[rn/keyboard-avoiding-view
|
||||
{:style style/keyboard-avoiding-view
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
(ns status-im.contexts.shell.qr-reader.sheets.scanned-wallet-address
|
||||
(:require
|
||||
[quo.core :as quo]
|
||||
[status-im.feature-flags :as ff]
|
||||
[utils.i18n :as i18n]
|
||||
[utils.re-frame :as rf]))
|
||||
|
||||
|
@ -20,7 +21,8 @@
|
|||
:recipient address
|
||||
:stack-id :wallet-select-address
|
||||
:start-flow? true}]))}
|
||||
{:icon :i/save
|
||||
:accessibility-label :save-address
|
||||
:label (i18n/label :t/save-address)
|
||||
:on-press #(js/alert "feature not implemented")}]]]])
|
||||
(when (ff/enabled? :ff/wallet.saved-addresses)
|
||||
{:icon :i/save
|
||||
:accessibility-label :save-address
|
||||
:label (i18n/label :t/save-address)
|
||||
:on-press #(js/alert "feature not implemented")})]]]])
|
||||
|
|
|
@ -70,7 +70,7 @@
|
|||
:icon-only? true
|
||||
:on-press #(rf/dispatch [:emoji-picker/open {:on-select on-select-emoji}])
|
||||
:container-style style/reaction-button-container}
|
||||
:i/reaction]])
|
||||
:i/edit]])
|
||||
|
||||
(defn- input
|
||||
[_]
|
||||
|
|
|
@ -49,7 +49,7 @@
|
|||
:icon-only? true
|
||||
:on-press #(rf/dispatch [:emoji-picker/open {:on-select on-change-emoji}])
|
||||
:container-style style/reaction-button-container}
|
||||
:i/reaction]]
|
||||
:i/edit]]
|
||||
|
||||
[rn/view
|
||||
[quo/title-input
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
[status-im.contexts.wallet.send.routes.view :as routes]
|
||||
[status-im.contexts.wallet.sheets.buy-token.view :as buy-token]
|
||||
[status-im.contexts.wallet.sheets.unpreferred-networks-alert.view :as unpreferred-networks-alert]
|
||||
[status-im.feature-flags :as ff]
|
||||
[utils.debounce :as debounce]
|
||||
[utils.i18n :as i18n]
|
||||
[utils.money :as money]
|
||||
|
@ -24,16 +25,17 @@
|
|||
(defn- estimated-fees
|
||||
[{:keys [loading-routes? fees amount]}]
|
||||
[rn/view {:style style/estimated-fees-container}
|
||||
[rn/view {:style style/estimated-fees-content-container}
|
||||
[quo/button
|
||||
{:icon-only? true
|
||||
:type :outline
|
||||
:size 32
|
||||
:inner-style {:opacity 1}
|
||||
:accessibility-label :advanced-button
|
||||
:disabled? loading-routes?
|
||||
:on-press #(js/alert "Not implemented yet")}
|
||||
:i/advanced]]
|
||||
(when (ff/enabled? ::ff/wallet.advanced-sending)
|
||||
[rn/view {:style style/estimated-fees-content-container}
|
||||
[quo/button
|
||||
{:icon-only? true
|
||||
:type :outline
|
||||
:size 32
|
||||
:inner-style {:opacity 1}
|
||||
:accessibility-label :advanced-button
|
||||
:disabled? loading-routes?
|
||||
:on-press #(js/alert "Not implemented yet")}
|
||||
:i/advanced]])
|
||||
[quo/data-item
|
||||
{:container-style style/fees-data-item
|
||||
:status (if loading-routes? :loading :default)
|
||||
|
@ -376,7 +378,7 @@
|
|||
sender-network-values
|
||||
token-not-supported-in-receiver-networks?)
|
||||
[token-not-available token-symbol receiver-networks token-networks])
|
||||
(when (or loading-routes? route)
|
||||
(when (and (not no-routes-found?) (or loading-routes? route))
|
||||
[estimated-fees
|
||||
{:loading-routes? loading-routes?
|
||||
:fees fee-formatted
|
||||
|
|
|
@ -82,11 +82,12 @@
|
|||
empty-state-component (rn/use-memo
|
||||
(fn []
|
||||
[quo/empty-state
|
||||
{:title (i18n/label :t/no-saved-addresses)
|
||||
:description (i18n/label
|
||||
:t/you-like-to-type-43-characters)
|
||||
:image (resources/get-themed-image :sweating-man
|
||||
theme)}])
|
||||
{:title (i18n/label :t/no-saved-addresses)
|
||||
:description (i18n/label
|
||||
:t/you-like-to-type-43-characters)
|
||||
:container-style style/empty-container-style
|
||||
:image (resources/get-themed-image :sweating-man
|
||||
theme)}])
|
||||
[theme])]
|
||||
[rn/section-list
|
||||
{:key-fn :title
|
||||
|
@ -94,6 +95,7 @@
|
|||
:render-section-header-fn section-header
|
||||
:sections group-saved-addresses
|
||||
:render-fn saved-address
|
||||
:content-container-style {:flex 1}
|
||||
:empty-component empty-state-component}]))
|
||||
|
||||
(defn view
|
||||
|
|
|
@ -136,7 +136,7 @@
|
|||
:keyboard-should-persist-taps :handled
|
||||
:render-fn suggestion-component}]]))
|
||||
|
||||
(defn- f-view
|
||||
(defn view
|
||||
[]
|
||||
(let [on-close (fn []
|
||||
(rf/dispatch [:wallet/clean-scanned-address])
|
||||
|
@ -155,7 +155,8 @@
|
|||
local-suggestion-address (rf/sub [:wallet/local-suggestions->full-address])
|
||||
color (rf/sub [:wallet/current-viewing-account-color])]
|
||||
[floating-button-page/view
|
||||
{:footer-container-padding 0
|
||||
{:content-container-style {:flex 1}
|
||||
:footer-container-padding 0
|
||||
:keyboard-should-persist-taps true
|
||||
:header [account-switcher/view
|
||||
{:on-press on-close
|
||||
|
@ -205,7 +206,3 @@
|
|||
:scrollable? true
|
||||
:on-change on-change-tab}]
|
||||
[tabs/view {:selected-tab selected-tab}]])]))))
|
||||
|
||||
(defn view
|
||||
[]
|
||||
[:f> f-view])
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
::settings.saved-addresses (enabled-in-env?
|
||||
:FLAG_WALLET_SETTINGS_SAVED_ADDRESSES_ENABLED)
|
||||
::shell.jump-to (enabled-in-env? :ENABLE_JUMP_TO)
|
||||
::wallet.advanced-sending (enabled-in-env? :FLAG_ADVANCED_SENDING)
|
||||
::wallet.assets-modal-hide (enabled-in-env? :FLAG_ASSETS_MODAL_HIDE)
|
||||
::wallet.assets-modal-manage-tokens (enabled-in-env? :FLAG_ASSETS_MODAL_MANAGE_TOKENS)
|
||||
::wallet.bridge-token (enabled-in-env? :FLAG_BRIDGE_TOKEN_ENABLED)
|
||||
|
@ -24,6 +25,7 @@
|
|||
::wallet.graph (enabled-in-env? :FLAG_GRAPH_ENABLED)
|
||||
::wallet.import-private-key (enabled-in-env? :FLAG_IMPORT_PRIVATE_KEY_ENABLED)
|
||||
::wallet.long-press-watch-only-asset (enabled-in-env? :FLAG_LONG_PRESS_WATCH_ONLY_ASSET_ENABLED)
|
||||
::wallet.saved-addresses (enabled-in-env? :WALLET_SAVED_ADDRESSES)
|
||||
::wallet.swap (enabled-in-env? :FLAG_SWAP_ENABLED)
|
||||
::wallet.wallet-connect (enabled-in-env? :FLAG_WALLET_CONNECT_ENABLED)})
|
||||
|
||||
|
|
|
@ -2612,7 +2612,7 @@
|
|||
"generating-keypair": "Generating key pair...",
|
||||
"keypair-name": "Key pair name",
|
||||
"keypair-name-description": "Name key pair for your own personal reference",
|
||||
"keypair-name-input-placeholder": "Collectibles account, Old vault....",
|
||||
"keypair-name-input-placeholder": "Collectibles key pair, Old vault....",
|
||||
"key-pair-name-updated": "Key pair name updated",
|
||||
"key-pair-removed": "Key pair and derived accounts has been removed",
|
||||
"goerli-testnet-toggle-confirmation": "Are you sure you want to toggle Goerli? This will log you out and you will have to login again.",
|
||||
|
|
Loading…
Reference in New Issue