|
57 | 57 | bottom (safe-area/get-bottom)
|
58 | 58 | account-color (reagent/atom (rand-nth colors/account-colors))
|
59 | 59 | emoji (reagent/atom (emoji-picker.utils/random-emoji))
|
60 |
| - number-of-accounts (count (rf/sub [:wallet/accounts])) |
61 |
| - account-name (reagent/atom (i18n/label :t/default-account-name |
62 |
| - {:number (inc number-of-accounts)})) |
| 60 | + number-of-accounts (count (rf/sub [:wallet/accounts-without-watched-accounts])) |
| 61 | + account-name (reagent/atom "") |
| 62 | + placeholder (i18n/label :t/default-account-placeholder |
| 63 | + {:number (inc number-of-accounts)}) |
63 | 64 | derivation-path (reagent/atom (utils/get-derivation-path number-of-accounts))
|
64 | 65 | {:keys [public-key]} (rf/sub [:profile/profile])
|
65 | 66 | on-change-text #(reset! account-name %)
|
|
96 | 97 | :container-style style/reaction-button-container} :i/reaction]]
|
97 | 98 | [quo/title-input
|
98 | 99 | {:customization-color @account-color
|
99 |
| - :placeholder "Type something here" |
| 100 | + :placeholder placeholder |
100 | 101 | :on-change-text on-change-text
|
101 | 102 | :max-length constants/wallet-account-name-max-length
|
102 | 103 | :blur? true
|
103 | 104 | :disabled? false
|
| 105 | + :auto-focus true |
104 | 106 | :default-value @account-name
|
105 | 107 | :container-style style/title-input-container}]
|
106 | 108 | [quo/divider-line]
|
|
133 | 135 | :path @derivation-path
|
134 | 136 | :account-name @account-name}]))
|
135 | 137 | :auth-button-label (i18n/label :t/confirm)
|
| 138 | + ;; TODO (@rende11) Add this property when sliding button issue will fixed |
| 139 | + ;; https://github.com/status-im/status-mobile/pull/18683#issuecomment-1941564785 |
| 140 | + ;; :disabled? (empty? @account-name) |
136 | 141 | :container-style (style/slide-button-container bottom)}]])))
|
137 | 142 |
|
138 | 143 | (def view (quo.theme/with-theme view-internal))
|
0 commit comments