Former-commit-id: 11d68436b5
This commit is contained in:
Roman Volosovskyi 2016-09-20 12:54:21 +03:00
parent 5287f17afc
commit d1dfce60d5
1 changed files with 1 additions and 5 deletions

View File

@ -22,10 +22,6 @@
(def response-height (+ input-height response-height-normal)) (def response-height (+ input-height response-height-normal))
(defn update-response-height
[{:keys [current-chat-id] :as db}]
(assoc-in db [:animations :to-response-height current-chat-id] response-height))
(register-handler :animate-command-suggestions (register-handler :animate-command-suggestions
(fn [{chat-id :current-chat-id :as db} _] (fn [{chat-id :current-chat-id :as db} _]
(let [suggestions? (seq (get-in db [:command-suggestions chat-id])) (let [suggestions? (seq (get-in db [:command-suggestions chat-id]))
@ -47,7 +43,7 @@
suggestion? (get-in db [:has-suggestions? current-chat-id]) suggestion? (get-in db [:has-suggestions? current-chat-id])
custom-errors (get-in db [:custom-validation-errors current-chat-id]) custom-errors (get-in db [:custom-validation-errors current-chat-id])
validation-height (if (or (seq errors) (seq custom-errors)) validation-height (if (or (seq errors) (seq custom-errors))
(+ suggestions-header-height request-info-height) request-info-height
0)] 0)]
(+ validation-height (+ validation-height
(if (= :response type) (if (= :response type)