Compare commits

...
Author SHA1 Message Date
Omar Basem 6221b42f2a fix: android bottom padding 2023-05-16 10:44:03 +04:00
4 changed files with 11 additions and 3 deletions
@@ -31,4 +31,4 @@
:left -20 :left -20
:right -20 :right -20
:bottom 0 :bottom 0
:height constants/composer-default-height}) :height (- constants/composer-default-height constants/bottom-padding)})
@@ -9,7 +9,9 @@
(def ^:const actions-container-height 56) (def ^:const actions-container-height 56)
(def ^:const composer-default-height (+ bar-container-height input-height actions-container-height)) (def ^:const bottom-padding (if platform/android? 15 0))
(def ^:const composer-default-height (+ bar-container-height input-height actions-container-height bottom-padding))
(def ^:const line-height (:line-height typography/paragraph-1)) (def ^:const line-height (:line-height typography/paragraph-1))
@@ -118,6 +118,7 @@
neg-y (if @maximized? -50 0)] neg-y (if @maximized? -50 0)]
(- (+ constants/bar-container-height (- (+ constants/bar-container-height
constants/actions-container-height constants/actions-container-height
constants/bottom-padding
(:bottom insets) (:bottom insets)
padding padding
extra-height extra-height
@@ -4,6 +4,7 @@
[react-native.core :as rn] [react-native.core :as rn]
[react-native.gesture :as gesture] [react-native.gesture :as gesture]
[react-native.hooks :as hooks] [react-native.hooks :as hooks]
[react-native.platform :as platform]
[react-native.reanimated :as reanimated] [react-native.reanimated :as reanimated]
[reagent.core :as reagent] [reagent.core :as reagent]
[utils.i18n :as i18n] [utils.i18n :as i18n]
@@ -105,7 +106,11 @@
:accessibility-label :chat-message-input}]] :accessibility-label :chat-message-input}]]
[gradients/view props state animations show-bottom-gradient?]] [gradients/view props state animations show-bottom-gradient?]]
[images/images-list] [images/images-list]
[actions/view props state animations window-height insets subs]]]])) [actions/view props state animations window-height insets subs]
(when (and platform/android? (not @(:focused? state)))
[rn/view {:style {:height constants/bottom-padding
:background-color :transparent}}])
]]]))
(defn composer (defn composer
[insets] [insets]