do not scroll input
Signed-off-by: Andrey Shovkoplyas <motor4ik@gmail.com>
This commit is contained in:
parent
fcf1a91507
commit
5dc6b77ee8
|
@ -1,10 +1,8 @@
|
||||||
(ns status-im.ui.screens.chat.styles.input.input
|
(ns status-im.ui.screens.chat.styles.input.input
|
||||||
(:require [status-im.ui.components.colors :as colors]
|
(:require [status-im.ui.components.colors :as colors]
|
||||||
[status-im.ui.screens.chat.styles.message.message :refer [message-author-name]]
|
[status-im.ui.screens.chat.styles.message.message :refer [message-author-name]]))
|
||||||
[status-im.utils.styles :as styles]))
|
|
||||||
|
|
||||||
(def min-input-height 36)
|
(def min-input-height 36)
|
||||||
(def padding-vertical 8)
|
|
||||||
(def border-height 1)
|
(def border-height 1)
|
||||||
(def max-input-height (* 5 min-input-height))
|
(def max-input-height (* 5 min-input-height))
|
||||||
|
|
||||||
|
@ -40,9 +38,6 @@
|
||||||
:height 18
|
:height 18
|
||||||
:include-font-padding false))
|
:include-font-padding false))
|
||||||
|
|
||||||
(def reply-message-container
|
|
||||||
{:flex-direction :column-reverse})
|
|
||||||
|
|
||||||
(def reply-message-to-container
|
(def reply-message-to-container
|
||||||
{:flex-direction :row
|
{:flex-direction :row
|
||||||
:height 18
|
:height 18
|
||||||
|
@ -51,12 +46,6 @@
|
||||||
:padding-right 8
|
:padding-right 8
|
||||||
:justify-content :flex-start})
|
:justify-content :flex-start})
|
||||||
|
|
||||||
(def reply-icon
|
|
||||||
{:width 20
|
|
||||||
:margin-top 1
|
|
||||||
:margin-bottom 1
|
|
||||||
:margin-right 0})
|
|
||||||
|
|
||||||
(def cancel-reply-highlight
|
(def cancel-reply-highlight
|
||||||
{:align-self :flex-start
|
{:align-self :flex-start
|
||||||
:width 19
|
:width 19
|
||||||
|
@ -79,71 +68,9 @@
|
||||||
{:flex-direction :row
|
{:flex-direction :row
|
||||||
:align-items :flex-end})
|
:align-items :flex-end})
|
||||||
|
|
||||||
(def input-animated
|
|
||||||
{:align-items :flex-start
|
|
||||||
:flex-direction :row
|
|
||||||
:flex-grow 1
|
|
||||||
:min-height min-input-height
|
|
||||||
:max-height max-input-height})
|
|
||||||
|
|
||||||
(def input-view
|
(def input-view
|
||||||
{:flex 1
|
{:flex 1
|
||||||
:padding-top 12
|
:padding-top 12
|
||||||
:padding-bottom 15
|
:padding-bottom 15
|
||||||
:padding-horizontal 12
|
:padding-horizontal 12
|
||||||
:min-height min-input-height
|
|
||||||
:max-height max-input-height})
|
:max-height max-input-height})
|
||||||
|
|
||||||
(def invisible-input-text
|
|
||||||
{:position :absolute
|
|
||||||
:left 0
|
|
||||||
:background-color :transparent
|
|
||||||
:color :transparent})
|
|
||||||
|
|
||||||
(styles/defn invisible-input-text-height [container-width]
|
|
||||||
{:width container-width
|
|
||||||
:flex 1
|
|
||||||
:padding-top 5
|
|
||||||
:padding-bottom 5
|
|
||||||
:android {:padding-top 3}
|
|
||||||
:position :absolute
|
|
||||||
:left 0
|
|
||||||
:background-color :transparent
|
|
||||||
:color :transparent})
|
|
||||||
|
|
||||||
(styles/defn input-helper-view [left opacity]
|
|
||||||
{:opacity opacity
|
|
||||||
:position :absolute
|
|
||||||
:height min-input-height
|
|
||||||
:android {:left (+ 4 left)}
|
|
||||||
:ios {:left left}
|
|
||||||
:desktop {:left left}})
|
|
||||||
|
|
||||||
(styles/defn input-helper-text [left]
|
|
||||||
{:color colors/gray
|
|
||||||
:text-align-vertical :center
|
|
||||||
:flex 1
|
|
||||||
:android {:top -1}
|
|
||||||
:ios {:line-height min-input-height}
|
|
||||||
:desktop {:line-height min-input-height}})
|
|
||||||
|
|
||||||
(styles/defn seq-input-text [left container-width]
|
|
||||||
{:min-width (- container-width left)
|
|
||||||
:position :absolute
|
|
||||||
:text-align-vertical :center
|
|
||||||
:align-items :center
|
|
||||||
:android {:left (+ 2 left)
|
|
||||||
:height (+ 2 min-input-height)
|
|
||||||
:top 0.5}
|
|
||||||
:ios {:line-height min-input-height
|
|
||||||
:height min-input-height
|
|
||||||
:left left}
|
|
||||||
:desktop {:line-height min-input-height
|
|
||||||
:height min-input-height
|
|
||||||
:left left}})
|
|
||||||
|
|
||||||
(def input-clear-container
|
|
||||||
{:width 24
|
|
||||||
:height 24
|
|
||||||
:margin-top 7
|
|
||||||
:align-items :center})
|
|
||||||
|
|
Loading…
Reference in New Issue