Skip to content

Commit 33e0e8b

Browse files
committed
ui: make nft drops larger with mint button
1 parent b3d5ca0 commit 33e0e8b

2 files changed

Lines changed: 100 additions & 17 deletions

File tree

app/ClientPage.tsx

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1356,38 +1356,38 @@ export default function ClientPage() {
13561356
<span className={styles.pill}>Owned</span>
13571357
</div>
13581358
<div className={styles.stack}>
1359-
<div className={styles.dropCard}>
1360-
<div className={styles.dropLeft}>
1361-
<div className={styles.dropThumb}>
1359+
<div className={styles.dropGrid}>
1360+
<div className={styles.dropTile}>
1361+
<div className={styles.dropTileThumb}>
13621362
<Image
13631363
src={INFERNO_PULSE.localImagePath}
13641364
alt={INFERNO_PULSE.name}
1365-
width={96}
1366-
height={96}
1365+
width={520}
1366+
height={520}
13671367
unoptimized
1368-
style={{ width: "100%", height: "100%", objectFit: "contain" }}
1368+
style={{
1369+
width: "100%",
1370+
height: "100%",
1371+
objectFit: "contain",
1372+
}}
13691373
/>
13701374
</div>
1371-
<div className={styles.dropMeta}>
1372-
<div className={styles.dropTitle}>{INFERNO_PULSE.name}</div>
1373-
<div className={styles.dropLine}>
1375+
<div className={styles.dropTileBody}>
1376+
<div className={styles.dropTileTitle}>{INFERNO_PULSE.name}</div>
1377+
<div className={styles.dropTileLine}>
13741378
Kind <code>u{INFERNO_PULSE.kind}</code>
13751379
{" · "}
13761380
{infernoFeeUstx === null
13771381
? "Price: —"
13781382
: `Price: ${(infernoFeeUstx / 1_000_000).toFixed(2)} STX`}
13791383
</div>
1380-
<div className={styles.dropLine}>
1384+
<div className={styles.dropTileLine}>
13811385
Metadata:{" "}
1382-
<span>
1383-
{infernoUri ? "Configured" : "Not configured"}
1384-
</span>
1386+
<span>{infernoUri ? "Configured" : "Not configured"}</span>
13851387
</div>
13861388
</div>
1387-
</div>
1388-
<div className={styles.dropRight}>
13891389
<button
1390-
className={styles.button}
1390+
className={`${styles.button} ${styles.dropTileButton}`}
13911391
onClick={mintInfernoPulse}
13921392
disabled={!address || !infernoUri}
13931393
type="button"

app/page.module.css

Lines changed: 84 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@
145145

146146
.panelGrid {
147147
display: grid;
148-
grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
148+
grid-template-columns: 1fr;
149149
gap: 24px;
150150
}
151151

@@ -408,6 +408,81 @@
408408
background: rgba(0, 0, 0, 0.02);
409409
}
410410

411+
.dropGrid {
412+
display: grid;
413+
grid-template-columns: repeat(2, minmax(0, 1fr));
414+
gap: 14px;
415+
}
416+
417+
.dropTile {
418+
padding: 14px;
419+
border-radius: 20px;
420+
border: 1px solid rgba(255, 255, 255, 0.12);
421+
background: rgba(255, 255, 255, 0.06);
422+
display: flex;
423+
flex-direction: column;
424+
gap: 12px;
425+
min-width: 0;
426+
}
427+
428+
[data-theme="light"] .dropTile {
429+
border-color: rgba(0, 0, 0, 0.12);
430+
background: rgba(0, 0, 0, 0.02);
431+
}
432+
433+
.dropTileThumb {
434+
width: 100%;
435+
aspect-ratio: 1 / 1;
436+
border-radius: 18px;
437+
border: 1px solid rgba(255, 255, 255, 0.14);
438+
background: rgba(255, 255, 255, 0.06);
439+
overflow: hidden;
440+
display: grid;
441+
place-items: center;
442+
}
443+
444+
[data-theme="light"] .dropTileThumb {
445+
border-color: rgba(0, 0, 0, 0.12);
446+
background: rgba(0, 0, 0, 0.03);
447+
}
448+
449+
.dropTileBody {
450+
display: flex;
451+
flex-direction: column;
452+
gap: 6px;
453+
min-width: 0;
454+
}
455+
456+
.dropTileTitle {
457+
font-size: 14px;
458+
font-weight: 900;
459+
color: var(--text);
460+
}
461+
462+
.dropTileLine {
463+
font-size: 12px;
464+
color: var(--muted);
465+
line-height: 1.4;
466+
}
467+
468+
.dropTileLine span {
469+
color: var(--text);
470+
font-weight: 600;
471+
}
472+
473+
.dropTileLine code {
474+
white-space: nowrap;
475+
overflow: hidden;
476+
text-overflow: ellipsis;
477+
max-width: 100%;
478+
display: inline-block;
479+
vertical-align: bottom;
480+
}
481+
482+
.dropTileButton {
483+
width: 100%;
484+
}
485+
411486
.dropLeft {
412487
display: flex;
413488
gap: 12px;
@@ -765,6 +840,14 @@
765840
grid-template-columns: 1fr;
766841
}
767842

843+
.nftGrid {
844+
grid-template-columns: 1fr;
845+
}
846+
847+
.dropGrid {
848+
grid-template-columns: 1fr;
849+
}
850+
768851
.statChip {
769852
min-width: 0;
770853
flex: 1 1 140px;

0 commit comments

Comments
 (0)