Skip to content

Improve model viewer on mobile scaling#2

Open
RealThe3D wants to merge 2 commits into
AppliedEnergistics:mainfrom
RealThe3D:mobile-ux-fix
Open

Improve model viewer on mobile scaling#2
RealThe3D wants to merge 2 commits into
AppliedEnergistics:mainfrom
RealThe3D:mobile-ux-fix

Conversation

@RealThe3D

Copy link
Copy Markdown

The model viewer is currently scaled too high for those on mobile devices. This PR attempts to make the width of the model viewer fit within the dimensions of a mobile device (mostly smartphones in portrait mode).

Before:
Screenshot 2026-07-06 122813

After:
Screenshot 2026-07-06 123128

This PR additionally gets rid of the X-axis overflow of the article guides on Desktop screens since the widths are adjusted accordingly.

@shartte

shartte commented Jul 7, 2026

Copy link
Copy Markdown
Member

Odd, I wonder what I fucked up during copying. The "old" style of guide publishing used by AE2 had this correct I think (at least I did test it on mobile)

Not super happy about the device pixel ratio clamping to 2 though 😓 No one's gonna understand those magic numbers going forward.

@RealThe3D

Copy link
Copy Markdown
Author

Fair point, I assumed that window.devicePixelRatio was an integer value. I reread MDN docs to find out that it can be a floating-point number as well. My latest commit reverts those changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants