Skip to content

Commit

Permalink
fix: report devicePixelRatio in diagnostics
Browse files Browse the repository at this point in the history
  • Loading branch information
mman committed Nov 8, 2024
1 parent 2f09cd8 commit c78e3dc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/app/Marine2/components/views/DiagnosticsView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,10 @@ const getDeviceDiagnostics = (windowSize: { width?: number; height?: number }) =
property: translate("diagnostics.device.viewportHeight"),
value: (windowSize.height ?? window.innerHeight) + "px",
},
{
property: translate("diagnostics.device.devicePixelRatio"),
value: (window.devicePixelRatio ?? 1) + "px/pt",
},
]
}

Expand Down
3 changes: 2 additions & 1 deletion src/app/locales/languages/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@
"device": "Device",
"userAgent": "User agent",
"viewportHeight": "Viewport height",
"viewportWidth": "Viewport width"
"viewportWidth": "Viewport width",
"devicePixelRatio": "Pixel Ratio"
},
"diagnostics": "Diagnostics"
},
Expand Down

0 comments on commit c78e3dc

Please sign in to comment.