You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 12, 2022. It is now read-only.
@@ -218,51 +220,66 @@ class DocumentWebView: UIView, Loggable {
218
220
/// - Parameter body: Unused.
219
221
privatefunc documentDidLoad(body:Any){
220
222
documentLoaded =true
221
-
223
+
224
+
applyUserSettingsStyle()
225
+
222
226
// FIXME: We need to give the CSS and webview time to layout correctly. 0.2 seconds seems like a good value for it to work on an iPhone 5s. Look into solving this better
log(.warning,"Scrolling to invalid position \(position)")
241
+
completion()
242
+
return
243
+
}
244
+
245
+
// Note: The JS layer does not take into account the scroll view's content inset. So it can't be used to reliably scroll to the top or the bottom of the page in scroll mode.
letpropertiesScript=properties.reduce(""){ script, property in
68
68
letvalue:String={
69
69
// Scroll mode depends both on the user settings, and on the fact that VoiceOver is activated or not, so we need to generate the value dynamically.
70
70
// FIXME: This would be handled in a better way by decoupling the user settings from the actual ReadiumCSS properties sent to the WebView, which should be private details of the EPUBNavigator implementation and not shared with the host app.
0 commit comments