A Christmas tree in the packages page gift box
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012vLHzh5qUhFtmJhzkcTbXL
This commit is contained in:
@@ -6,6 +6,7 @@ import { PackageCards } from "@/components/PackageCards";
|
|||||||
import { RedeemCode } from "@/components/RedeemCode";
|
import { RedeemCode } from "@/components/RedeemCode";
|
||||||
import { payMethod } from "@/lib/payments";
|
import { payMethod } from "@/lib/payments";
|
||||||
import { isChristmasTime } from "@/lib/season";
|
import { isChristmasTime } from "@/lib/season";
|
||||||
|
import { ChristmasTree } from "@/components/ChristmasTree";
|
||||||
import { backendGet, requireMe } from "@/lib/server";
|
import { backendGet, requireMe } from "@/lib/server";
|
||||||
import type { Package, PublicConfig } from "@/lib/types";
|
import type { Package, PublicConfig } from "@/lib/types";
|
||||||
|
|
||||||
@@ -101,7 +102,8 @@ export default async function PackagesPage() {
|
|||||||
<PackageCards packages={packages} canPay={canPay} giftLinks />
|
<PackageCards packages={packages} canPay={canPay} giftLinks />
|
||||||
|
|
||||||
<section className="card gift-banner" aria-labelledby="gift-title">
|
<section className="card gift-banner" aria-labelledby="gift-title">
|
||||||
<div>
|
{xmas && <ChristmasTree />}
|
||||||
|
<div className="gift-banner-text">
|
||||||
<h2 id="gift-title">{xmas ? "Karácsonyi ajándék a csillagokból" : "Ajándékba is adhatod"}</h2>
|
<h2 id="gift-title">{xmas ? "Karácsonyi ajándék a csillagokból" : "Ajándékba is adhatod"}</h2>
|
||||||
<p className="muted">
|
<p className="muted">
|
||||||
A három fő csomag bármelyikét megveheted másnak: e-mailben elküldjük neki egy nyomtatható utalvánnyal, vagy
|
A három fő csomag bármelyikét megveheted másnak: e-mailben elküldjük neki egy nyomtatható utalvánnyal, vagy
|
||||||
|
|||||||
@@ -1534,6 +1534,8 @@ span.tarot-fan-card { cursor: default; }
|
|||||||
.gift-banner h2 { font-size: 24px; }
|
.gift-banner h2 { font-size: 24px; }
|
||||||
.gift-banner p { margin: 6px 0 0; }
|
.gift-banner p { margin: 6px 0 0; }
|
||||||
.gift-banner .btn { flex: none; }
|
.gift-banner .btn { flex: none; }
|
||||||
|
.gift-banner-text { flex: 1; }
|
||||||
|
.gift-banner .xmas-tree { flex: none; filter: drop-shadow(0 0 10px rgba(217, 180, 106, 0.25)); }
|
||||||
.gift-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; }
|
.gift-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; }
|
||||||
.gift-aside { display: flex; flex-direction: column; gap: 16px; }
|
.gift-aside { display: flex; flex-direction: column; gap: 16px; }
|
||||||
.gift-sample { margin: 0; display: flex; flex-direction: column; gap: 8px; align-items: center; }
|
.gift-sample { margin: 0; display: flex; flex-direction: column; gap: 8px; align-items: center; }
|
||||||
@@ -1586,6 +1588,7 @@ span.tarot-fan-card { cursor: default; }
|
|||||||
}
|
}
|
||||||
@media (max-width: 640px) {
|
@media (max-width: 640px) {
|
||||||
.gift-banner { flex-direction: column; align-items: stretch; }
|
.gift-banner { flex-direction: column; align-items: stretch; }
|
||||||
|
.gift-banner .xmas-tree { align-self: center; }
|
||||||
.gift-packages, .gift-ways { grid-template-columns: 1fr; }
|
.gift-packages, .gift-ways { grid-template-columns: 1fr; }
|
||||||
.gift-packages .gift-option-head { flex-direction: row; align-items: baseline; justify-content: space-between; }
|
.gift-packages .gift-option-head { flex-direction: row; align-items: baseline; justify-content: space-between; }
|
||||||
.gift-aside { flex-direction: column; }
|
.gift-aside { flex-direction: column; }
|
||||||
|
|||||||
@@ -0,0 +1,44 @@
|
|||||||
|
/** A Christmas tree in the site's gold line style, with a star on top. */
|
||||||
|
export function ChristmasTree({ size = 64 }: { size?: number }) {
|
||||||
|
return (
|
||||||
|
<svg
|
||||||
|
className="xmas-tree"
|
||||||
|
width={size}
|
||||||
|
height={size * 1.25}
|
||||||
|
viewBox="0 0 64 80"
|
||||||
|
aria-hidden="true"
|
||||||
|
fill="none"
|
||||||
|
stroke="#d9b46a"
|
||||||
|
strokeWidth="2"
|
||||||
|
strokeLinejoin="round"
|
||||||
|
strokeLinecap="round"
|
||||||
|
>
|
||||||
|
{/* The star */}
|
||||||
|
<path
|
||||||
|
d="M32 2 L34.4 8 L40.6 8.6 L35.9 12.7 L37.3 18.8 L32 15.6 L26.7 18.8 L28.1 12.7 L23.4 8.6 L29.6 8 Z"
|
||||||
|
fill="#d9b46a"
|
||||||
|
/>
|
||||||
|
{/* Three tiers */}
|
||||||
|
<path
|
||||||
|
d="M32 20 L44 34 L38 34 L50 49 L42 49 L56 65 L8 65 L22 49 L14 49 L26 34 L20 34 Z"
|
||||||
|
fill="rgba(217,180,106,0.08)"
|
||||||
|
/>
|
||||||
|
{/* Garland */}
|
||||||
|
<path
|
||||||
|
d="M23 41 Q33 45 42 39 M17 56 Q31 61 47 54"
|
||||||
|
strokeWidth="1.2"
|
||||||
|
opacity="0.7"
|
||||||
|
/>
|
||||||
|
{/* Baubles */}
|
||||||
|
<g stroke="none">
|
||||||
|
<circle cx="29" cy="30" r="1.8" fill="#ece6d8" />
|
||||||
|
<circle cx="36" cy="44" r="2" fill="#d9b46a" />
|
||||||
|
<circle cx="25" cy="50" r="1.8" fill="#ece6d8" />
|
||||||
|
<circle cx="41" cy="59" r="2" fill="#ece6d8" />
|
||||||
|
<circle cx="20" cy="61" r="1.8" fill="#d9b46a" />
|
||||||
|
</g>
|
||||||
|
{/* Trunk */}
|
||||||
|
<path d="M28 65 L28 74 L36 74 L36 65" />
|
||||||
|
</svg>
|
||||||
|
);
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user