mirror of
https://github.com/penpot/penpot.git
synced 2025-05-20 02:36:11 +02:00
🐛 Fix crash on iOS when displaying viewer
This commit is contained in:
parent
b4a997cde9
commit
1cac7d55d0
4 changed files with 28 additions and 15 deletions
|
@ -1,5 +1,11 @@
|
||||||
# CHANGELOG
|
# CHANGELOG
|
||||||
|
|
||||||
|
## 1.12.4-beta
|
||||||
|
|
||||||
|
### :bug: Bugs fixed
|
||||||
|
|
||||||
|
- Fix crash on iOS when displaying viewer [#1522](https://github.com/penpot/penpot/issues/1522)
|
||||||
|
|
||||||
## 1.12.3-beta
|
## 1.12.3-beta
|
||||||
|
|
||||||
### :bug: Bugs fixed
|
### :bug: Bugs fixed
|
||||||
|
|
|
@ -6,14 +6,16 @@
|
||||||
|
|
||||||
(ns app.util.dom
|
(ns app.util.dom
|
||||||
(:require
|
(:require
|
||||||
[app.common.exceptions :as ex]
|
|
||||||
[app.common.geom.point :as gpt]
|
[app.common.geom.point :as gpt]
|
||||||
|
[app.common.logging :as log]
|
||||||
[app.util.globals :as globals]
|
[app.util.globals :as globals]
|
||||||
[app.util.object :as obj]
|
[app.util.object :as obj]
|
||||||
[cuerdas.core :as str]
|
[cuerdas.core :as str]
|
||||||
[goog.dom :as dom]
|
[goog.dom :as dom]
|
||||||
[promesa.core :as p]))
|
[promesa.core :as p]))
|
||||||
|
|
||||||
|
(log/set-level! :warn)
|
||||||
|
|
||||||
;; --- Deprecated methods
|
;; --- Deprecated methods
|
||||||
|
|
||||||
(defn event->inner-text
|
(defn event->inner-text
|
||||||
|
@ -289,8 +291,9 @@
|
||||||
(boolean (.-fullscreenElement globals/document))
|
(boolean (.-fullscreenElement globals/document))
|
||||||
|
|
||||||
:else
|
:else
|
||||||
(ex/raise :type :not-supported
|
(do
|
||||||
:hint "seems like the current browser does not support fullscreen api.")))
|
(log/error :msg "Seems like the current browser does not support fullscreen api.")
|
||||||
|
false)))
|
||||||
|
|
||||||
(defn ^boolean blob?
|
(defn ^boolean blob?
|
||||||
[^js v]
|
[^js v]
|
||||||
|
|
|
@ -8,11 +8,13 @@
|
||||||
"HTML5 web api helpers."
|
"HTML5 web api helpers."
|
||||||
(:require
|
(:require
|
||||||
[app.common.data :as d]
|
[app.common.data :as d]
|
||||||
[app.common.exceptions :as ex]
|
[app.common.logging :as log]
|
||||||
[app.util.object :as obj]
|
[app.util.object :as obj]
|
||||||
[beicon.core :as rx]
|
[beicon.core :as rx]
|
||||||
[cuerdas.core :as str]))
|
[cuerdas.core :as str]))
|
||||||
|
|
||||||
|
(log/set-level! :warn)
|
||||||
|
|
||||||
(defn- file-reader
|
(defn- file-reader
|
||||||
[f]
|
[f]
|
||||||
(rx/create
|
(rx/create
|
||||||
|
@ -114,8 +116,9 @@
|
||||||
(.webkitRequestFullscreen el)
|
(.webkitRequestFullscreen el)
|
||||||
|
|
||||||
:else
|
:else
|
||||||
(ex/raise :type :not-supported
|
(do
|
||||||
:hint "seems like the current browser does not support fullscreen api.")))
|
(log/error :msg "Seems like the current browser does not support fullscreen api.")
|
||||||
|
false)))
|
||||||
|
|
||||||
(defn exit-fullscreen
|
(defn exit-fullscreen
|
||||||
[]
|
[]
|
||||||
|
@ -127,8 +130,9 @@
|
||||||
(.webkitExitFullscreen js/document)
|
(.webkitExitFullscreen js/document)
|
||||||
|
|
||||||
:else
|
:else
|
||||||
(ex/raise :type :not-supported
|
(do
|
||||||
:hint "seems like the current browser does not support fullscreen api.")))
|
(log/error :msg "Seems like the current browser does not support fullscreen api.")
|
||||||
|
false)))
|
||||||
|
|
||||||
(defn observe-resize
|
(defn observe-resize
|
||||||
[node]
|
[node]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue