|
1 | 1 | (ns status-im.ui.screens.onboarding.intro.views
|
2 | 2 | (:require [quo.animated :as animated]
|
| 3 | + [quo.react-native :as rn] |
3 | 4 | [status-im.ui.screens.onboarding.intro.styles :as styles]
|
4 | 5 | [status-im.ui.components.react :as react]
|
5 | 6 | [reagent.core :as reagent]
|
|
133 | 134 | [dots-selector {:progress progress
|
134 | 135 | :n (count slides)}]])))
|
135 | 136 |
|
| 137 | +(defonce tos-accepted (reagent/atom false)) |
| 138 | + |
136 | 139 | (defn intro []
|
137 | 140 | [react/view {:style styles/intro-view}
|
138 | 141 | [carousel [{:image (resources/get-theme-image :chat)
|
|
145 | 148 | :title :intro-title3
|
146 | 149 | :text :intro-text3}]
|
147 | 150 | @(re-frame/subscribe [:dimensions/window-width])]
|
148 |
| - [react/view styles/buttons-container |
149 |
| - [react/view {:style (assoc styles/bottom-button :margin-bottom 16)} |
150 |
| - [quo/button {:on-press #(re-frame/dispatch [:init-root :onboarding])} |
| 151 | + [react/view {:style {:align-items :center}} |
| 152 | + [react/view {:flex-direction :row |
| 153 | + :justify-content :space-between |
| 154 | + :margin-top 36 |
| 155 | + :margin-bottom 24} |
| 156 | + [quo/checkbox {:value @tos-accepted |
| 157 | + :on-change #(swap! tos-accepted not)}] |
| 158 | + [rn/touchable-opacity {:on-press #(swap! tos-accepted not)} |
| 159 | + [react/nested-text {:style {:margin-left 12}} |
| 160 | + (i18n/label :t/accept-status-tos-prefix) |
| 161 | + [{:style {:color colors/blue} |
| 162 | + :on-press #(re-frame/dispatch [:open-modal :terms-of-service])} |
| 163 | + " " |
| 164 | + (i18n/label :t/terms-of-service)]]]] |
| 165 | + [react/view {:style {:margin-bottom 24}} |
| 166 | + [quo/button {:disabled (not @tos-accepted) |
| 167 | + :on-press #(re-frame/dispatch [:init-root :onboarding])} |
151 | 168 | (i18n/label :t/get-started)]]
|
152 |
| - [react/nested-text |
153 |
| - {:style styles/welcome-text-bottom-note} |
154 |
| - (i18n/label :t/intro-privacy-policy-note1) |
155 |
| - [{:style (assoc styles/welcome-text-bottom-note :color colors/blue) |
156 |
| - :on-press #(re-frame/dispatch [:open-modal :privacy-policy])} |
157 |
| - (i18n/label :t/intro-privacy-policy-note2)]]]]) |
| 169 | + [react/text |
| 170 | + {:style {:color colors/blue} |
| 171 | + :on-press #(re-frame/dispatch [:open-modal :privacy-policy])} |
| 172 | + (i18n/label :t/privacy-policy)]]]) |
0 commit comments