tvl-depot/website/sandbox
William Carroll 2fe6d7a10c Responsively size UI
TL;DR: scale down UI for non-mobile devices.

I pulled the screen resolution for my phone, the Google Pixel 4, off of the
internet. I created a device profile in Chrome to develop this application
specifically for my phone. To my surprise, when I opened the app on my phone,
many of elements that looked good in Google Chrome, looked askew on my phone. I
needed to troubleshoot.

Here's how I did that:
I used Tailwind to responsively color the bg for each breakpoint to see if my
device was sm, md, lg, xl (according to Tailwind's breakpoint
terminology). After reading Tailwind's documentation and comparing their
breakpoints with my Pixel 4's width (i.e. 1080px), I figured that my device
would be lg. It's not; it's md, which I confirmed by using ngrok to load
localhost:8000 on my phone and see that the background-color was
"md:bg-green-600".

I'm still unsure why my device is not lg, but knowing that my device was md
was enough to fix many of the styling issues. My current theory is that while
my screen's resolution is 1080 wide, the pixel density affects the media query
for the breakpoint.
2020-04-19 13:05:55 +01:00
..
contentful Run Prettier across projects 2020-03-27 10:59:50 +00:00
covid-uk Move sandbox into website 2020-03-20 00:52:05 +00:00
github-issues-service Create README for Github Issues Service 2020-04-10 13:40:04 +01:00
learnpianochords Responsively size UI 2020-04-19 13:05:55 +01:00
typo-po Add README for typo-po 2020-04-10 13:54:33 +01:00
default.nix Move sandbox into website 2020-03-20 00:52:05 +00:00
index.html Run Prettier across projects 2020-03-27 10:59:50 +00:00