Mobile/PWA spacing fixes (#11403)

* spacing on mobile landscape

* better icon placement when running as pwa

* better icon placement when running as pwa

* portrait padding only
This commit is contained in:
Josh Hawkins
2024-05-16 17:00:14 -05:00
committed by GitHub
parent 76f822630d
commit ba03d3b3e4
5 changed files with 20 additions and 7 deletions

View File

@@ -16,6 +16,7 @@ import {
import { Link } from "react-router-dom";
import { cn } from "@/lib/utils";
import { isMobile } from "react-device-detect";
import { isPWA } from "@/utils/isPWA";
function Bottombar() {
const navItems = useNavigation("secondary");
@@ -23,8 +24,11 @@ function Bottombar() {
return (
<div
className={cn(
"absolute inset-x-4 bottom-0 flex flex-row items-center justify-between",
isMobile ? "h-12 landscape:md:h-16" : "h-16",
"absolute inset-x-4 bottom-0 flex h-16 flex-row justify-between",
isPWA
? "portrait:items-start portrait:pt-1 landscape:items-center"
: "items-center",
isMobile && !isPWA && "h-12 landscape:md:h-16",
)}
>
{navItems.map((item) => (