File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,10 +4,10 @@ import WebKit
44enum WebInjection {
55 static let css = """
66 :root {
7- --nwZoom: 1.18 ;
8- --nwBezelYOffset: 2 .1%;
9- --nwScreenZoom: 1.04 ;
10- --nwGlobalYOffset: 3.6 %;
7+ --nwZoom: 1.17 ;
8+ --nwBezelYOffset: 1 .1%;
9+ --nwScreenZoom: 0.992 ;
10+ --nwGlobalYOffset: 5.975 %;
1111 }
1212 html, body {
1313 margin: 0 !important;
@@ -53,6 +53,11 @@ enum WebInjection {
5353 backface-visibility: hidden !important;
5454 will-change: transform !important;
5555 transform: translate3d(0, var(--nwBezelYOffset), 0) !important;
56+
57+ /* Hide the simulator-rendered calculator image, but keep its layout
58+ so button hitboxes and screen geometry remain unchanged. */
59+ opacity: 0 !important;
60+ pointer-events: none !important;
5661 }
5762
5863 .calculator canvas {
Original file line number Diff line number Diff line change @@ -9,6 +9,11 @@ struct CalculatorView: View {
99
1010 var body : some View {
1111 ZStack ( alignment: . topTrailing) {
12+ Image ( " CalculatorImage " )
13+ . resizable ( )
14+ . scaledToFit ( )
15+ . frame ( maxWidth: . infinity, maxHeight: . infinity)
16+
1217 if OnLaunch . hasInstalledSimulator ( ) {
1318 CalculatorWebView (
1419 onReady: {
You can’t perform that action at this time.
0 commit comments