Skip to content

Commit d1d7cfd

Browse files
committed
fix: improve mobile responsiveness
1 parent fd0f076 commit d1d7cfd

File tree

4 files changed

+8
-10
lines changed

4 files changed

+8
-10
lines changed

apps/web/app/page.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,20 @@
1-
import Image from "next/image";
21
import { QRCodeUrl } from "@/components/QRCodeUrl";
32
import { QRCodeCard } from "@/components/QRCodeCard";
4-
import Link from "next/link";
53

64
export default function Home() {
75
return (
8-
<div className="grid grid-rows-[20px_1fr_20px] items-center justify-items-center min-h-[100dvh] p-8 pb-20 gap-16 sm:p-20">
6+
<div className="grid grid-rows-[20px_1fr_20px] items-center justify-items-center min-h-[100dvh] p-4 sm:p-8 pb-20 gap-16 ">
97
<main className="flex flex-col gap-8 row-start-2 items-center">
108
{/* Title and description */}
119
<div className="flex flex-col gap-2 items-center max-w-xl text-center">
1210
<h1 className="text-5xl font-semibold">QR Code API</h1>
13-
<p className="text-lg text-black/60">
11+
<p className="sm:text-lg text-black/60">
1412
A free, simple and fast QR Code API for developers. Generate
1513
unlimited QR codes programmatically.
1614
</p>
1715
</div>
1816

19-
<div className="flex flex-col gap-4">
17+
<div className="flex flex-col gap-4 max-w-xl w-full">
2018
<QRCodeCard />
2119
<QRCodeUrl />
2220
</div>

apps/web/components/QRCodeCard.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ import { QRCodePreview } from "./QRCodePreview";
55

66
export function QRCodeCard() {
77
return (
8-
<div className="flex flex-col gap-4 items-center max-w-xl w-full bg-muted/50 rounded-xl p-3 border">
8+
<div className="flex flex-col gap-4 items-center w-full bg-muted/50 rounded-xl p-3 border">
99
{/* Data Input */}
1010
<DataInput />
1111

1212
{/* QR Code Preview */}
1313
<QRCodePreview />
1414

1515
{/* QR Code Settings */}
16-
<div className="flex flex-row gap-2 w-full h-full">
16+
<div className="flex flex-col-reverse sm:flex-row gap-2 w-full h-full">
1717
{/* Logo */}
1818
<div className="flex flex-col gap-1 w-full">
1919
<LogoInput />

apps/web/components/QRCodeUrl.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,15 @@ export function QRCodeUrl() {
1919

2020
return (
2121
<div
22-
className="flex flex-row gap-2 max-w-xl bg-muted/50 items-center justify-between rounded-xl pl-3.5 p-2 border text-sm group hover:cursor-copy"
22+
className="flex flex-row gap-2 min-w-0 w-full bg-muted/50 items-center justify-between rounded-xl pl-3.5 p-2 border text-sm group hover:cursor-copy"
2323
onClick={handleCopy}
2424
onKeyDown={(e) => {
2525
if (e.key === "Enter" || e.key === " ") {
2626
handleCopy();
2727
}
2828
}}
2929
>
30-
<span className="text-muted-foreground truncate select-none">
30+
<span className="text-muted-foreground w-full line-clamp-1 select-none break-words break-all overflow-hidden">
3131
{decodeURIComponent(qrUrl || "")}
3232
</span>
3333

packages/tinyqrc/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "tinyqrc",
33
"description": "A tiny QR code generator, written in TypeScript.",
4-
"version": "0.0.1",
4+
"version": "0.0.2",
55
"author": "Christo Todorov <[email protected]>",
66
"repository": "https://github.com/chroxify/tinyqrc",
77
"keywords": [

0 commit comments

Comments
 (0)