File tree 1 file changed +9
-8
lines changed
src/status_im2/contexts/chat/composer
1 file changed +9
-8
lines changed Original file line number Diff line number Diff line change 28
28
changes to make it appear seamless during transitions between keyboard types when maximized."
29
29
[event
30
30
{:keys [emoji-kb-extra-height]}
31
- {:keys [text-value]}
31
+ {:keys [text-value kb-height ]}
32
32
{:keys [height saved-height]}
33
33
{:keys [max-height]}]
34
- (let [start-h (oops/oget event " startCoordinates.height" )
35
- end-h (oops/oget event " endCoordinates.height" )
36
- diff (- end-h start-h)
37
- max-height-diff (- max-height diff)
38
- curr-text @text-value
39
- almost-expanded? (> (reanimated/get-shared-value height) max-height-diff)]
40
- (if (and almost-expanded? (pos? diff))
34
+ (let [start-h (oops/oget event " startCoordinates.height" )
35
+ end-h (oops/oget event " endCoordinates.height" )
36
+ diff (- end-h start-h)
37
+ max-height-diff (- max-height diff)
38
+ curr-text @text-value
39
+ bigger-than-default-kb? (> end-h @kb-height)
40
+ almost-expanded? (> (reanimated/get-shared-value height) max-height-diff)]
41
+ (if (and almost-expanded? bigger-than-default-kb? (pos? diff))
41
42
(do
42
43
(reanimated/set-shared-value height (- (reanimated/get-shared-value height) diff))
43
44
(reanimated/set-shared-value saved-height (- (reanimated/get-shared-value saved-height) diff))
You can’t perform that action at this time.
0 commit comments