fix: profile input - input field position - Android (#17210)

This commit is contained in:
Ajay Sivan 2023-09-07 03:53:40 -07:00 committed by GitHub
parent bd8e332c68
commit b645686684
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 16 additions and 18 deletions

View File

@ -9,5 +9,4 @@
{:placeholder "Your Name" {:placeholder "Your Name"
:on-press event}]) :on-press event}])
(h/fire-event :press (h/get-by-label-text :select-profile-picture-button)) (h/fire-event :press (h/get-by-label-text :select-profile-picture-button))
(-> (js/expect event) (h/was-called-times event 1))))
(.toHaveBeenCalledTimes 1)))))

View File

@ -1,13 +1,12 @@
(ns quo2.components.inputs.profile-input.style (ns quo2.components.inputs.profile-input.style
(:require [react-native.platform :as platform] (:require [quo2.foundations.colors :as colors]))
[quo2.foundations.colors :as colors]))
(defn container (defn container
[customization-color] [customization-color]
{:background-color (colors/custom-color customization-color 50 40) {:background-color (colors/custom-color customization-color 50 40)
:padding-horizontal 12 :padding-horizontal 12
:padding-top 12 :padding-top 12
:padding-bottom (if platform/ios? 10 0) :padding-bottom 10
:border-radius 16 :border-radius 16
:flex 1}) :flex 1})

View File

@ -31,10 +31,11 @@
:borderRadius 12}]} :borderRadius 12}]}
[user-avatar/user-avatar [user-avatar/user-avatar
(assoc image-picker-props (assoc image-picker-props
:static? true :customization-color customization-color
:status-indicator? false :static? true
:full-name (if (seq full-name) full-name placeholder) :status-indicator? false
:size :medium)]] :full-name (if (seq full-name) full-name placeholder)
:size :medium)]]
[buttons/button [buttons/button
{:accessibility-label :select-profile-picture-button {:accessibility-label :select-profile-picture-button
:type :grey :type :grey

View File

@ -1,10 +1,9 @@
(ns status-im2.contexts.quo-preview.inputs.profile-input (ns status-im2.contexts.quo-preview.inputs.profile-input
(:require [quo2.core :as quo] (:require [quo2.core :as quo]
[quo2.foundations.colors :as colors]
[react-native.blur :as blur]
[reagent.core :as reagent] [reagent.core :as reagent]
[status-im2.common.resources :as resources] [status-im2.common.resources :as resources]
[status-im2.contexts.quo-preview.preview :as preview])) [status-im2.contexts.quo-preview.preview :as preview]
[quo.react-native :as rn]))
(def descriptor (def descriptor
[{:key :disabled? [{:key :disabled?
@ -22,12 +21,12 @@
value (reagent/atom "") value (reagent/atom "")
on-change-text #(reset! value %)] on-change-text #(reset! value %)]
(fn [] (fn []
[preview/preview-container {:state state :descriptor descriptor} [preview/preview-container
[blur/view {:state state
{:background-color colors/neutral-80-opa-80 :descriptor descriptor
:flex-direction :row :blur? true
:margin-horizontal 20 :show-blur-background? true}
:justify-content :center} [rn/view
[quo/profile-input [quo/profile-input
{:default-value "" {:default-value ""
:on-change-text on-change-text :on-change-text on-change-text