make iphone xs max owners little bit happier

Signed-off-by: Andrey Shovkoplyas <motor4ik@gmail.com>
This commit is contained in:
Andrey Shovkoplyas 2018-10-08 16:40:40 +02:00
parent 84151ea996
commit b776af96c6
No known key found for this signature in database
GPG Key ID: EAAB7C8622D860A4
1 changed files with 2 additions and 2 deletions

View File

@ -12,14 +12,14 @@
:font-weight "bold"}}) :font-weight "bold"}})
;; iPhone X dimensions ;; iPhone X dimensions
(def x-width 375)
(def x-height 812) (def x-height 812)
(def xs-height 896)
(defn iphone-x-dimensions? [] (defn iphone-x-dimensions? []
(let [{:keys [width height]} (-> (.-Dimensions rn-dependencies/react-native) (let [{:keys [width height]} (-> (.-Dimensions rn-dependencies/react-native)
(.get "window") (.get "window")
(js->clj :keywordize-keys true))] (js->clj :keywordize-keys true))]
(and (= width x-width) (= height x-height)))) (or (= height x-height) (= height xs-height))))
(def platform-specific (def platform-specific
{:fonts fonts {:fonts fonts