Hide option to increase gas on keycard
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
This commit is contained in:
parent
33e58dbca9
commit
37ccc6f825
|
@ -605,6 +605,7 @@
|
||||||
(fn [multiaccounts]
|
(fn [multiaccounts]
|
||||||
(> (count multiaccounts) 1)))
|
(> (count multiaccounts) 1)))
|
||||||
|
|
||||||
|
;; NOTE: this subscription only works on login
|
||||||
(re-frame/reg-sub
|
(re-frame/reg-sub
|
||||||
:multiaccounts.login/keycard-account?
|
:multiaccounts.login/keycard-account?
|
||||||
:<- [:multiaccounts/multiaccounts]
|
:<- [:multiaccounts/multiaccounts]
|
||||||
|
@ -612,6 +613,12 @@
|
||||||
(fn [[multiaccounts {:keys [key-uid]}]]
|
(fn [[multiaccounts {:keys [key-uid]}]]
|
||||||
(get-in multiaccounts [key-uid :keycard-pairing])))
|
(get-in multiaccounts [key-uid :keycard-pairing])))
|
||||||
|
|
||||||
|
(re-frame/reg-sub
|
||||||
|
:multiaccounts/keycard-account?
|
||||||
|
:<- [:multiaccount]
|
||||||
|
(fn [multiaccount]
|
||||||
|
(:keycard-pairing multiaccount)))
|
||||||
|
|
||||||
(re-frame/reg-sub
|
(re-frame/reg-sub
|
||||||
:accounts-without-watch-only
|
:accounts-without-watch-only
|
||||||
:<- [:multiaccount/accounts]
|
:<- [:multiaccount/accounts]
|
||||||
|
|
|
@ -38,7 +38,8 @@
|
||||||
(defn render-transaction
|
(defn render-transaction
|
||||||
[{:keys [label contact address contact-accessibility-label
|
[{:keys [label contact address contact-accessibility-label
|
||||||
address-accessibility-label currency-text amount-text
|
address-accessibility-label currency-text amount-text
|
||||||
time-formatted on-touch-fn type hash]}]
|
time-formatted on-touch-fn type hash]}
|
||||||
|
_ _ {:keys [keycard-account?]}]
|
||||||
[react/view
|
[react/view
|
||||||
[list/touchable-item on-touch-fn
|
[list/touchable-item on-touch-fn
|
||||||
[react/view {:accessibility-label :transaction-item}
|
[react/view {:accessibility-label :transaction-item}
|
||||||
|
@ -75,7 +76,8 @@
|
||||||
:style {:margin-top 10}
|
:style {:margin-top 10}
|
||||||
:icon-opts (merge styles/forward
|
:icon-opts (merge styles/forward
|
||||||
{:accessibility-label :show-transaction-button})}]]]]
|
{:accessibility-label :show-transaction-button})}]]]]
|
||||||
(when (= type :pending)
|
(when (and (not keycard-account?)
|
||||||
|
(= type :pending))
|
||||||
[react/view {:flex-direction :row :padding 16 :justify-content :space-between}
|
[react/view {:flex-direction :row :padding 16 :justify-content :space-between}
|
||||||
[quo/button
|
[quo/button
|
||||||
{:on-press #(re-frame/dispatch [:signing.ui/increase-gas-pressed hash])}
|
{:on-press #(re-frame/dispatch [:signing.ui/increase-gas-pressed hash])}
|
||||||
|
@ -108,6 +110,8 @@
|
||||||
[transactions-history-sections address]
|
[transactions-history-sections address]
|
||||||
(let [fetching-recent-history? @(re-frame/subscribe [:wallet/fetching-recent-tx-history? address])
|
(let [fetching-recent-history? @(re-frame/subscribe [:wallet/fetching-recent-tx-history? address])
|
||||||
fetching-more-history? @(re-frame/subscribe [:wallet/fetching-tx-history? address])
|
fetching-more-history? @(re-frame/subscribe [:wallet/fetching-tx-history? address])
|
||||||
|
keycard-account? @(re-frame/subscribe [:multiaccounts/keycard-account?])
|
||||||
|
|
||||||
all-fetched? @(re-frame/subscribe [:wallet/tx-history-fetched? address])]
|
all-fetched? @(re-frame/subscribe [:wallet/tx-history-fetched? address])]
|
||||||
[react/view components.styles/flex
|
[react/view components.styles/flex
|
||||||
[etherscan-link address]
|
[etherscan-link address]
|
||||||
|
@ -121,6 +125,7 @@
|
||||||
[list/section-list
|
[list/section-list
|
||||||
{:sections transactions-history-sections
|
{:sections transactions-history-sections
|
||||||
:key-fn :hash
|
:key-fn :hash
|
||||||
|
:render-data {:keycard-account? keycard-account?}
|
||||||
:render-fn render-transaction
|
:render-fn render-transaction
|
||||||
:empty-component
|
:empty-component
|
||||||
[react/i18n-text {:style styles/empty-text
|
[react/i18n-text {:style styles/empty-text
|
||||||
|
|
Loading…
Reference in New Issue