|
11 | 11 | [quo.foundations.colors :as colors]
|
12 | 12 | [quo.theme :as quo.theme]
|
13 | 13 | [react-native.core :as rn]
|
| 14 | + [react-native.platform :as platform] |
14 | 15 | [reagent.core :as reagent]
|
15 | 16 | [utils.i18n :as i18n]))
|
16 | 17 |
|
|
19 | 20 | (let [first-name (first (string/split full-name #" "))]
|
20 | 21 | (i18n/label :t/keypair-title {:name first-name})))
|
21 | 22 |
|
22 |
| -(defn details-string |
23 |
| - [address stored] |
24 |
| - (str (when address (str address " ∙ ")) |
25 |
| - (if (= stored :on-device) (i18n/label :t/on-device) (i18n/label :t/on-keycard)))) |
26 |
| - |
27 | 23 | (defn avatar
|
28 | 24 | [{{:keys [full-name]} :details
|
29 | 25 | avatar-type :type
|
|
67 | 63 | [{:keys [details stored blur? theme]}]
|
68 | 64 | (let [{:keys [address]} details]
|
69 | 65 | [rn/view
|
70 |
| - {:style {:flex-direction :row |
71 |
| - :align-items :center}} |
| 66 | + {:style {:flex-direction :row |
| 67 | + :align-items :center} |
| 68 | + :accessibility-label :details} |
| 69 | + [text/text |
| 70 | + {:size :paragraph-2 |
| 71 | + :style (style/subtitle blur? theme)} |
| 72 | + address] |
| 73 | + [text/text |
| 74 | + {:size :paragraph-2 |
| 75 | + :style (merge (style/subtitle blur? theme) {:bottom (if platform/ios? 2 -2)})} |
| 76 | + " ∙ "] |
72 | 77 | [text/text
|
73 |
| - {:size :paragraph-2 |
74 |
| - :accessibility-label :details |
75 |
| - :style {:color (if blur? |
76 |
| - colors/white-opa-40 |
77 |
| - (colors/theme-colors colors/neutral-50 colors/neutral-40 theme))}} |
78 |
| - (details-string address stored)] |
| 78 | + {:size :paragraph-2 |
| 79 | + :style (style/subtitle blur? theme)} |
| 80 | + (if (= stored :on-device) (i18n/label :t/on-device) (i18n/label :t/on-keycard))] |
79 | 81 | (when (= stored :on-keycard)
|
80 | 82 | [rn/view {:style {:margin-left 4}}
|
81 | 83 | [icon/icon :i/keycard-card
|
|
0 commit comments