Skip to content

Commit

Permalink
Ignore dynamic type when changing zoom level
Browse files Browse the repository at this point in the history
  • Loading branch information
quanganhdo committed Nov 28, 2024
1 parent f838e4d commit 04dffd3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions DuckDuckGo/TextZoomCoordinator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,7 @@ final class TextZoomCoordinator: TextZoomCoordinating {
private func applyTextZoom(_ webView: WKWebView) {
guard isEnabled else { return }
let level = textZoomLevel(forHost: webView.url?.host)
let dynamicTypeScalePercentage = UIFontMetrics.default.scaledValue(for: 1.0)
let viewScale = CGFloat(level.rawValue) / 100 * dynamicTypeScalePercentage
let viewScale = CGFloat(level.rawValue) / 100
webView.applyViewScale(viewScale)
}

Expand Down

0 comments on commit 04dffd3

Please sign in to comment.