feat(site): redesign promotion experience
This commit is contained in:
parent
6930906583
commit
13dd160c16
39 changed files with 5764 additions and 5738 deletions
|
|
@ -1,138 +0,0 @@
|
|||
---
|
||||
import { Image } from "astro:assets";
|
||||
import refraction from "../assets/bg/bg-refraction.webp";
|
||||
import paper from "../assets/bg/bg-paper.webp";
|
||||
import split from "../assets/bg/bg-split.webp";
|
||||
import align from "../assets/bg/bg-align.webp";
|
||||
|
||||
/**
|
||||
* 배경은 섹션마다 다른 말을 해야 한다. 같은 그림을 전부에 깔면 그건 벽지다.
|
||||
* 넷 다 gpt-image-2 로 만들었고, 프롬프트에 이 페이지의 토큰 값을 그대로 넣었다.
|
||||
*/
|
||||
const SOURCES = { refraction, paper, split, align } as const;
|
||||
|
||||
interface Props {
|
||||
variant?: keyof typeof SOURCES;
|
||||
/**
|
||||
* `fixed` — 뷰포트에 고정. 콘텐츠만 그 위를 지나간다. 무한히 먼 원경.
|
||||
* `drift` — 스크롤보다 느리게 따라온다. 중경. 종이처럼 가까운 재질에 쓴다.
|
||||
*/
|
||||
mode?: "fixed" | "drift";
|
||||
/** drift 전용. 이미지를 컨테이너보다 이 비율만큼 키우고 그 초과분 전체를 움직인다 */
|
||||
depth?: number;
|
||||
opacity?: number;
|
||||
flip?: boolean;
|
||||
}
|
||||
const {
|
||||
variant = "refraction",
|
||||
mode = "fixed",
|
||||
depth = 0.35,
|
||||
opacity = 0.9,
|
||||
flip = false,
|
||||
} = Astro.props;
|
||||
const src = SOURCES[variant];
|
||||
|
||||
// 밝은 종이만 그대로 얹고, 어두운 광원 사진은 더하기 합성한다.
|
||||
const additive = variant !== "paper";
|
||||
|
||||
const scale = 1 + depth;
|
||||
const shift = -(depth / scale) * 100;
|
||||
---
|
||||
|
||||
{/*
|
||||
패럴랙스의 원형은 "배경이 고정되어 원경처럼 보이는 것"이다.
|
||||
느리게 같이 움직이는 것으로는 그 인상이 안 나온다 — 속도만 다를 뿐 같은 방향이다.
|
||||
|
||||
`background-attachment: fixed` 는 쓰지 않는다. iOS Safari 가 GPU 메모리 때문에
|
||||
그것을 throttle 해서 스크롤 중 배경이 튀거나 리셋된다.
|
||||
대신 부모에 `clip-path: inset(0)` 을 걸어 **fixed 의 컨테이닝 블록**으로 만든다.
|
||||
그러면 배경은 뷰포트에 고정되면서 그 섹션 영역에서만 보인다.
|
||||
|
||||
주의: 조상에 `transform`·`filter`·`mask` 가 있으면 그게 컨테이닝 블록이 되어
|
||||
이 기법이 통째로 깨진다. 그래서 위아래 페이드 마스크를 포기했다 —
|
||||
마스크를 걸면 고정이 사라진다. 경계는 clip 으로 딱 자른다.
|
||||
*/}
|
||||
<div
|
||||
class="bg-photo"
|
||||
class:list={[mode, { flip, additive }]}
|
||||
aria-hidden="true"
|
||||
style={`--bg-opacity:${opacity}; --bg-h:${scale * 100}%; --bg-shift:${shift.toFixed(2)}%`}
|
||||
>
|
||||
<Image src={src} alt="" widths={[860, 1400, 1920]} sizes="100vw" loading="lazy" decoding="async" />
|
||||
</div>
|
||||
|
||||
<style>
|
||||
.bg-photo {
|
||||
z-index: -1;
|
||||
pointer-events: none;
|
||||
grid-column: full;
|
||||
}
|
||||
|
||||
/* ---- 원경: 뷰포트에 고정 ---------------------------------- */
|
||||
.fixed {
|
||||
position: fixed;
|
||||
inset: 0;
|
||||
}
|
||||
.fixed :global(img) {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
display: block;
|
||||
opacity: var(--bg-opacity);
|
||||
}
|
||||
|
||||
/* ---- 중경: 스크롤보다 느리게 ------------------------------ */
|
||||
.drift {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
}
|
||||
.drift :global(img) {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
/* 컨테이너보다 크다. 이 초과분이 곧 움직일 수 있는 거리다 */
|
||||
height: var(--bg-h);
|
||||
object-fit: cover;
|
||||
display: block;
|
||||
opacity: var(--bg-opacity);
|
||||
}
|
||||
|
||||
/*
|
||||
어두운 배경 위의 광원 사진은 opacity 로 누르면 안 된다 — 빛까지 같이 죽는다.
|
||||
screen 은 검정을 투명하게 만들고 밝은 곳만 더한다.
|
||||
*/
|
||||
.additive :global(img) { mix-blend-mode: screen; }
|
||||
.flip :global(img) { transform: scaleX(-1); }
|
||||
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
@supports (animation-timeline: view()) {
|
||||
/* drift 만 움직인다. fixed 는 애초에 안 움직이는 것이 효과다 */
|
||||
.drift :global(img) {
|
||||
animation: bg-parallax linear both;
|
||||
animation-timeline: view();
|
||||
animation-range: cover 0% cover 100%;
|
||||
}
|
||||
.drift.flip :global(img) { animation-name: bg-parallax-flip; }
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes bg-parallax {
|
||||
from { transform: translateY(0); }
|
||||
to { transform: translateY(var(--bg-shift)); }
|
||||
}
|
||||
@keyframes bg-parallax-flip {
|
||||
from { transform: translateY(0) scaleX(-1); }
|
||||
to { transform: translateY(var(--bg-shift)) scaleX(-1); }
|
||||
}
|
||||
|
||||
/* 모션을 줄이는 설정에서는 고정 배경도 부담이 될 수 있다. 흐름에 되돌린다 */
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.fixed { position: absolute; }
|
||||
}
|
||||
|
||||
@media (prefers-reduced-transparency: reduce) {
|
||||
.additive :global(img) { opacity: calc(var(--bg-opacity) * 0.9); }
|
||||
.bg-photo:not(.additive) :global(img) { opacity: calc(var(--bg-opacity) * 0.7); }
|
||||
}
|
||||
</style>
|
||||
|
|
@ -5,99 +5,133 @@ interface Props {
|
|||
copiedLabel: string;
|
||||
note?: string;
|
||||
}
|
||||
|
||||
const { command, copyLabel, copiedLabel, note } = Astro.props;
|
||||
---
|
||||
|
||||
{/* 명령어를 담는 액자. 유리를 쓰는 세 자리 중 하나다 */}
|
||||
<div class="cmd-shell frame">
|
||||
<div class="cmd-shell">
|
||||
<div class="cmd">
|
||||
<code class="cmd-text">{command}</code>
|
||||
<button type="button" class="btn btn-solid cmd-copy" data-copy={command} data-copied={copiedLabel}>
|
||||
<code class="cmd-text" translate="no"><span aria-hidden="true">$ </span>{command}</code>
|
||||
<button type="button" class="btn btn-primary cmd-copy" data-copy={command} data-copied={copiedLabel}>
|
||||
<span class="cmd-copy-label">{copyLabel}</span>
|
||||
<span class="cmd-copy-icon" aria-hidden="true">
|
||||
<svg viewBox="0 0 16 16" width="12" height="12" fill="none">
|
||||
<path d="M5.5 10.5L10.5 5.5M10.5 5.5H6.5M10.5 5.5V9.5"
|
||||
stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
</span>
|
||||
<svg viewBox="0 0 16 16" width="15" height="15" aria-hidden="true">
|
||||
<path d="M5.5 10.5 10.5 5.5M6.5 5.5h4v4" />
|
||||
</svg>
|
||||
</button>
|
||||
</div>
|
||||
<span class="copy-status sr-only" aria-live="polite"></span>
|
||||
</div>
|
||||
{note && <p class="cmd-note muted">{note}</p>}
|
||||
|
||||
<style>
|
||||
.cmd-shell { max-width: 30em; min-width: 0; }
|
||||
.cmd {
|
||||
display: flex;
|
||||
.cmd-shell {
|
||||
min-width: 0;
|
||||
max-width: 32rem;
|
||||
border: var(--line-width) solid var(--line-strong);
|
||||
border-radius: var(--radius-sm);
|
||||
background: var(--surface-raised);
|
||||
}
|
||||
|
||||
.cmd {
|
||||
min-width: 0;
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) auto;
|
||||
align-items: center;
|
||||
gap: var(--space-2);
|
||||
padding: var(--space-2) var(--space-2) var(--space-2) var(--space-3);
|
||||
padding: var(--space-2);
|
||||
}
|
||||
|
||||
.cmd-text {
|
||||
flex: 1 1 0;
|
||||
min-width: 0;
|
||||
overflow-x: auto;
|
||||
white-space: nowrap;
|
||||
padding-inline: var(--space-2);
|
||||
color: var(--ink);
|
||||
}
|
||||
.cmd-text::before {
|
||||
content: "$ ";
|
||||
color: var(--ink-muted);
|
||||
line-height: var(--control-h);
|
||||
white-space: nowrap;
|
||||
scrollbar-width: thin;
|
||||
}
|
||||
|
||||
/* 높이·패딩·웨이트·전환은 .btn 이 정한다. 여기서는 이 자리에만
|
||||
필요한 것만 더한다 — 아이콘이 오른쪽 안쪽에 붙어야 해서 그쪽만 좁다 */
|
||||
.cmd-copy {
|
||||
flex: 0 0 auto;
|
||||
padding-right: var(--space-2);
|
||||
font-family: inherit;
|
||||
}
|
||||
|
||||
.cmd-copy-icon {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 26px;
|
||||
height: 26px;
|
||||
border-radius: var(--radius-sm);
|
||||
background: color-mix(in oklab, var(--accent-ink) 18%, transparent);
|
||||
.cmd-text span { color: var(--ink-muted); }
|
||||
.cmd-copy { white-space: nowrap; }
|
||||
.cmd-copy svg {
|
||||
fill: none;
|
||||
stroke: currentColor;
|
||||
stroke-width: 1.5;
|
||||
stroke-linecap: round;
|
||||
stroke-linejoin: round;
|
||||
transition: transform var(--dur-quick) var(--ease-out);
|
||||
}
|
||||
.cmd-copy:hover .cmd-copy-icon { transform: translate(2px, -2px); }
|
||||
.cmd-copy:hover svg,
|
||||
.cmd-copy:focus-visible svg { transform: translate(2px, -2px); }
|
||||
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.cmd-copy svg {
|
||||
transition: none;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
.cmd-copy:hover svg,
|
||||
.cmd-copy:focus-visible svg { transform: none; }
|
||||
}
|
||||
|
||||
.cmd-note {
|
||||
max-width: 32rem;
|
||||
margin-top: var(--space-2);
|
||||
font-size: var(--step-0);
|
||||
font-size: var(--step--1);
|
||||
}
|
||||
|
||||
@media (max-width: 26rem) {
|
||||
.cmd { grid-template-columns: minmax(0, 1fr); }
|
||||
.cmd-copy { width: 100%; }
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
// 이 페이지의 유일한 상호작용이다. 라이브러리를 쓰지 않는다.
|
||||
document.querySelectorAll<HTMLButtonElement>(".cmd-copy").forEach((btn) => {
|
||||
const label = btn.querySelector<HTMLSpanElement>(".cmd-copy-label");
|
||||
if (!label) return;
|
||||
btn.addEventListener("click", async () => {
|
||||
const text = btn.dataset["copy"] ?? "";
|
||||
const done = btn.dataset["copied"] ?? "OK";
|
||||
const original = label.textContent;
|
||||
document.querySelectorAll<HTMLButtonElement>(".cmd-copy").forEach((button) => {
|
||||
if (button.dataset["copyReady"] === "true") return;
|
||||
button.dataset["copyReady"] = "true";
|
||||
const label = button.querySelector<HTMLSpanElement>(".cmd-copy-label");
|
||||
const shell = button.closest<HTMLElement>(".cmd-shell");
|
||||
const status = shell?.querySelector<HTMLElement>(".copy-status");
|
||||
const code = shell?.querySelector<HTMLElement>(".cmd-text");
|
||||
if (!label || !status || !code) return;
|
||||
const original = label.textContent ?? "";
|
||||
let resetTimer: number | undefined;
|
||||
let announceTimer: number | undefined;
|
||||
|
||||
const announce = (message: string) => {
|
||||
window.clearTimeout(announceTimer);
|
||||
status.textContent = "";
|
||||
announceTimer = window.setTimeout(() => {
|
||||
status.textContent = message;
|
||||
}, 20);
|
||||
};
|
||||
|
||||
button.addEventListener("click", async () => {
|
||||
const command = button.dataset["copy"] ?? "";
|
||||
const copied = button.dataset["copied"] ?? "Copied";
|
||||
window.clearTimeout(resetTimer);
|
||||
|
||||
try {
|
||||
await navigator.clipboard.writeText(text);
|
||||
await navigator.clipboard.writeText(command);
|
||||
label.textContent = copied;
|
||||
announce(document.documentElement.lang === "ko"
|
||||
? "설치 명령을 클립보드에 복사했어요."
|
||||
: "Install command copied to the clipboard.");
|
||||
} catch {
|
||||
// 클립보드 권한이 없으면 선택 상태로 만들어 사용자가 직접 복사하게 둔다
|
||||
const code = btn.parentElement?.querySelector(".cmd-text");
|
||||
if (code) {
|
||||
const range = document.createRange();
|
||||
range.selectNodeContents(code);
|
||||
const sel = getSelection();
|
||||
sel?.removeAllRanges();
|
||||
sel?.addRange(range);
|
||||
}
|
||||
return;
|
||||
const range = document.createRange();
|
||||
range.selectNodeContents(code);
|
||||
const selection = getSelection();
|
||||
selection?.removeAllRanges();
|
||||
selection?.addRange(range);
|
||||
announce(document.documentElement.lang === "ko"
|
||||
? "설치 명령을 선택했어요. 복사 단축키를 눌러주세요."
|
||||
: "The install command is selected. Use your copy shortcut.");
|
||||
}
|
||||
label.textContent = done;
|
||||
label.setAttribute("aria-live", "polite");
|
||||
setTimeout(() => { label.textContent = original; }, 1600);
|
||||
|
||||
resetTimer = window.setTimeout(() => {
|
||||
label.textContent = original;
|
||||
}, 1600);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
|
|
|||
|
|
@ -1,185 +0,0 @@
|
|||
---
|
||||
import { Image } from "astro:assets";
|
||||
import paper from "../assets/bg/bg-paper.webp";
|
||||
import split from "../assets/bg/bg-split.webp";
|
||||
|
||||
/**
|
||||
* 필터 데모의 소재. 같은 소재를 두 번 그리고 한쪽에만 필터를 건다.
|
||||
* 변수를 하나만 바꿔야 데모가 무언가를 증명한다 — 소재가 다르면
|
||||
* 보이는 차이가 필터 때문인지 소재 때문인지 알 수 없다.
|
||||
*/
|
||||
interface Props {
|
||||
kind: "scrim" | "cvd" | "goo" | "glass";
|
||||
on: boolean;
|
||||
}
|
||||
const { kind, on } = Astro.props;
|
||||
|
||||
|
||||
---
|
||||
|
||||
{
|
||||
kind === "scrim" && (
|
||||
<div class="art art-photo">
|
||||
<Image src={paper} alt="" widths={[300, 600]} sizes="300px" loading="lazy" />
|
||||
<span class:list={["cap", { on }]}>산미 8.5 · 로스팅 2일차</span>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
{
|
||||
kind === "cvd" && (
|
||||
<div class:list={["art art-badges", { on }]}>
|
||||
<span class="badge b-ok">통과</span>
|
||||
<span class="badge b-warn">주의</span>
|
||||
<span class="badge b-bad">실패</span>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
{
|
||||
kind === "goo" && (
|
||||
<div class="art art-goo">
|
||||
{/* 같은 간격으로 놓인 세 덩어리. 왼쪽은 셋으로 보이고 오른쪽은 하나로 보인다.
|
||||
움직임으로 증명하려다 실패했다 — 지나가는 프레임은 방문자도 놓치고
|
||||
측정도 매번 다른 값을 준다. 정지된 두 장이 더 정확하게 말한다. */}
|
||||
<div class:list={["goo-track", { on }]}>
|
||||
<span class="goo-blob" /><span class="goo-blob" /><span class="goo-blob" />
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
{
|
||||
kind === "glass" && (
|
||||
<div class="art art-glass">
|
||||
<Image src={split} alt="" widths={[300, 600]} sizes="300px" loading="lazy" />
|
||||
{/* 격자를 함께 깐다. 굴절은 직선이 휘어야 보인다 —
|
||||
사진만 놓으면 무엇이 어떻게 밀렸는지 알 수 없다 */}
|
||||
<span class="glass-grid" />
|
||||
<span class:list={["glass-panel", { on }]}>산미 8.5</span>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
<style>
|
||||
.art {
|
||||
height: var(--art-h, 118px);
|
||||
border-radius: var(--radius-sm);
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
background: var(--surface-2);
|
||||
}
|
||||
|
||||
/* ---- 스크림 ------------------------------------------------
|
||||
밝은 종이 사진 위의 흰 캡션. 필터가 없으면 대비가 무너진다 */
|
||||
.art-photo :global(img) {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
}
|
||||
.cap {
|
||||
position: absolute;
|
||||
left: var(--space-3);
|
||||
bottom: var(--space-3);
|
||||
right: var(--space-3);
|
||||
color: #fff;
|
||||
font-weight: var(--weight-medium);
|
||||
font-size: var(--step-0);
|
||||
line-height: 1.3;
|
||||
}
|
||||
.cap.on { filter: url(#f-scrim); }
|
||||
|
||||
/* ---- 색각 --------------------------------------------------
|
||||
상태를 색으로만 구분한 흔한 배지 묶음. 사이트 팔레트가 아니라
|
||||
"현장에서 그렇게 오는" 색이다 — 그게 이 데모의 소재다 */
|
||||
.art-badges {
|
||||
--art-h: 84px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: var(--space-2);
|
||||
padding: var(--space-3);
|
||||
}
|
||||
.art-badges.on { filter: url(#f-deuter); }
|
||||
.badge {
|
||||
padding: 0.4em 0.95em;
|
||||
border-radius: var(--radius-sm);
|
||||
font-size: var(--step--1);
|
||||
font-weight: var(--weight-medium);
|
||||
color: #08110f;
|
||||
}
|
||||
/* 적록색약에서 서로 무너지는 조합을 일부러 골랐다.
|
||||
현장에서 상태 배지가 실제로 이렇게 온다 */
|
||||
.b-ok { background: #3fb950; }
|
||||
.b-warn { background: #d29922; }
|
||||
.b-bad { background: #e5534b; }
|
||||
|
||||
/* ---- 구이 ---------------------------------------------------
|
||||
필터는 트랙에만 건다. 라벨까지 걸면 글자가 녹는다 */
|
||||
.art-goo {
|
||||
--art-h: 96px;
|
||||
display: grid;
|
||||
align-content: center;
|
||||
gap: var(--space-2);
|
||||
}
|
||||
/* 간격이 이 데모의 유일한 변수다.
|
||||
붙는 조건은 눈대중이 아니라 산수다 — 두 원 사이 중간점의 블러 알파가
|
||||
alpha 램프의 문턱(offset/slope = 7/18 ≒ 0.39)을 넘어야 한다.
|
||||
간격 18px 에 stdDeviation 7 로는 중간점 알파가 0.2 근처라 못 넘었다.
|
||||
실측에서 필터를 켜고도 덩어리가 3개 그대로였다. 간격을 좁힌다. */
|
||||
.goo-track {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
gap: 12px;
|
||||
}
|
||||
.goo-track.on { filter: url(#f-goo); }
|
||||
.goo-blob {
|
||||
width: 46px;
|
||||
height: 46px;
|
||||
border-radius: 23px;
|
||||
background: var(--accent);
|
||||
}
|
||||
|
||||
|
||||
/* ---- 유리 ----------------------------------------------------
|
||||
feImage 는 요소 크기에 맞춰 자동 조정되지 않는다.
|
||||
그래서 패널 크기를 필터의 지도 크기(216×72)와 똑같이 고정한다 */
|
||||
.art-glass :global(img) {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
}
|
||||
.glass-grid {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
background:
|
||||
repeating-linear-gradient(90deg, rgb(255 255 255 / 0.5) 0 1px, transparent 1px 20px),
|
||||
repeating-linear-gradient(0deg, rgb(255 255 255 / 0.5) 0 1px, transparent 1px 20px);
|
||||
}
|
||||
.glass-panel {
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
width: 216px;
|
||||
height: 72px;
|
||||
margin: -36px 0 0 -108px;
|
||||
display: grid;
|
||||
place-items: center;
|
||||
border-radius: var(--radius-md);
|
||||
border: 1px solid rgb(255 255 255 / 0.28);
|
||||
background: rgb(255 255 255 / 0.05);
|
||||
color: #fff;
|
||||
font-weight: var(--weight-medium);
|
||||
/* 굴절을 못 읽는 엔진은 여기서 멈춘다 */
|
||||
backdrop-filter: blur(1px);
|
||||
}
|
||||
.glass-panel.on { backdrop-filter: blur(1px) url(#f-lens); }
|
||||
|
||||
@media (prefers-reduced-transparency: reduce) {
|
||||
.cap { text-shadow: 0 1px 3px rgb(0 0 0 / 0.9); }
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,246 +0,0 @@
|
|||
---
|
||||
import CopyCommand from "./CopyCommand.astro";
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props {
|
||||
c: Content["hero"];
|
||||
ui: Content["ui"];
|
||||
}
|
||||
const { c, ui } = Astro.props;
|
||||
---
|
||||
|
||||
{/*
|
||||
3D 는 배경이다. 액자에 가두지 않는다.
|
||||
|
||||
한 번 액자 안에 넣었다가 되돌렸다. lusion.co 에서 가져온 "3D 는 액자 안,
|
||||
텍스트는 액자 밖"은 3D 자체가 상품일 때의 규칙이다. 그 스튜디오는 3D 를
|
||||
팔기 때문에 액자가 쇼케이스 프레임으로 정당하다.
|
||||
배경으로 쓸 때는 규칙이 다르다 — 주인공이 아니라 공간을 만드는 재질이고,
|
||||
그래서 대비를 낮추고 글자에 자리를 내준다.
|
||||
|
||||
처음 배경으로 깔았을 때 실패한 이유는 배치가 아니라 둘이었다.
|
||||
판이 정면이라 프레넬이 0 이어서 아무것도 안 보였고(three.md §2),
|
||||
헤드라인이 112px 이라 그나마 보이는 것과도 싸웠다. 둘 다 고쳤다.
|
||||
*/}
|
||||
<section class="full hero">
|
||||
<div class="hero-bg" aria-hidden="true">
|
||||
{/* WebGL 이 없으면 이 그라디언트가 폴백이 아니라 결과물이다 */}
|
||||
<div class="hero-fallback"></div>
|
||||
<canvas id="hero-canvas" class="hero-canvas"></canvas>
|
||||
{/* 글자가 앉는 자리만 눌러준다. 배경이 균일하게 밝으면 본문 대비가 무너진다 */}
|
||||
<div class="hero-scrim"></div>
|
||||
</div>
|
||||
|
||||
<div class="hero-grid">
|
||||
<h1 class="hero-title">{c.h1}</h1>
|
||||
|
||||
<div class="hero-aside">
|
||||
<p class="lead hero-lead">{c.lead}</p>
|
||||
<CopyCommand
|
||||
command={c.install}
|
||||
copyLabel={ui.copy}
|
||||
copiedLabel={ui.copied}
|
||||
note={c.installNote}
|
||||
/>
|
||||
<p class="hero-links">
|
||||
{c.links.map((l) => <a class="link-grow" href={l.href}>{l.label}</a>)}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
.hero {
|
||||
grid-column: full;
|
||||
position: relative;
|
||||
isolation: isolate;
|
||||
overflow: clip;
|
||||
/* 72dvh 는 0.7 화면이었다. 페이지에서 가장 짧은 섹션이 첫인상이라
|
||||
분량 배분이 중요도와 반대였다. 100dvh 로 채우지는 않는다 —
|
||||
다음 섹션의 머리가 조금 보여야 스크롤할 것이 있다는 단서가 된다. */
|
||||
min-height: min(88dvh, 52rem);
|
||||
display: grid;
|
||||
align-content: center;
|
||||
padding-block: calc(var(--header-h) + var(--space-6)) var(--space-6);
|
||||
}
|
||||
|
||||
/* ---- 배경 ------------------------------------------------ */
|
||||
.hero-bg {
|
||||
position: absolute;
|
||||
/* 패럴랙스로 내려가는 만큼 위아래에 여유를 둔다.
|
||||
inset: 0 이면 배경이 내려간 자리에 검은 띠가 생긴다 */
|
||||
inset: -4rem 0;
|
||||
z-index: -1;
|
||||
pointer-events: none;
|
||||
/* 아래로 갈수록 지운다. black 은 색이 아니라 마스크 알파다.
|
||||
없으면 히어로 하단에서 배경이 가로선으로
|
||||
뚝 끊겨 다음 섹션과 두 장의 종이처럼 보인다. */
|
||||
-webkit-mask-image: linear-gradient(to bottom, black 0%, black 97%, transparent 100%);
|
||||
mask-image: linear-gradient(to bottom, black 0%, black 97%, transparent 100%);
|
||||
}
|
||||
.hero-fallback,
|
||||
.hero-canvas,
|
||||
.hero-scrim {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: block;
|
||||
}
|
||||
.hero-fallback {
|
||||
background:
|
||||
radial-gradient(52% 62% at 24% 26%,
|
||||
color-mix(in oklab, var(--accent) 30%, transparent), transparent 68%),
|
||||
radial-gradient(46% 58% at 82% 62%,
|
||||
color-mix(in oklab, var(--glow-2) 26%, transparent), transparent 66%);
|
||||
}
|
||||
.hero-canvas { opacity: 0; transition: opacity 1.2s var(--ease-soft); }
|
||||
.hero-canvas.is-live { opacity: 1; }
|
||||
|
||||
/* 왼쪽 위(글자가 앉는 쪽)를 눌러 대비를 만든다. 오른쪽 아래는 열어둔다 */
|
||||
.hero-scrim {
|
||||
background:
|
||||
linear-gradient(100deg,
|
||||
color-mix(in oklab, var(--surface) 88%, transparent) 0%,
|
||||
color-mix(in oklab, var(--surface) 62%, transparent) 42%,
|
||||
transparent 78%),
|
||||
linear-gradient(to bottom,
|
||||
color-mix(in oklab, var(--surface) 72%, transparent) 0%,
|
||||
transparent 28%);
|
||||
}
|
||||
|
||||
/* ---- 글자 ------------------------------------------------ */
|
||||
.hero-grid {
|
||||
max-width: 1180px;
|
||||
width: 100%;
|
||||
margin-inline: auto;
|
||||
padding-inline: var(--gutter);
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
|
||||
gap: var(--space-5) var(--space-6);
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.hero-title {
|
||||
/* step-4(41.5px)는 h2(33px)보다 8px 클 뿐이라 위계가 서지 않았다.
|
||||
한때 --display(112px)를 썼다가 배경과 싸워서 줄였는데, 줄이다가
|
||||
h2 와 구별이 안 되는 데까지 왔다. 그 사이 값이 필요하다.
|
||||
|
||||
하한이 중요하다. h1 만 vw 에 비례해 줄고 h2 는 고정이라,
|
||||
하한을 2.2rem 으로 두면 390px 화면에서 35.2px 대 33.2px —
|
||||
1.06 배로 사실상 같은 크기가 된다. 하한은 h2 기준으로 정한다.
|
||||
3rem 하한에서는 320px 에서 한 줄에 글자 5개가 안 들어가 4줄로
|
||||
꺾였다. 2.6rem(41.6px)은 h2 의 1.25 배를 유지하면서 3줄에 끊긴다. */
|
||||
font-size: clamp(2.6rem, 1.9rem + 3.1vw, 4.4rem);
|
||||
line-height: 1.08;
|
||||
letter-spacing: var(--tracking-display);
|
||||
max-width: 15ch;
|
||||
/* 좁은 화면에서 왼쪽으로 몰려 4줄로 꺾이던 것을 어절 단위로 균형 있게.
|
||||
2줄(넓은 화면)·3줄(320px) 모두 의도한 끊김으로 바뀐다 */
|
||||
text-wrap: balance;
|
||||
margin: 0;
|
||||
}
|
||||
[lang="en"] .hero-title { max-width: 18ch; line-height: 1.04; }
|
||||
|
||||
.hero-aside { display: grid; gap: var(--space-3); align-content: center; }
|
||||
.hero-lead {
|
||||
margin: 0;
|
||||
max-width: 30em;
|
||||
color: var(--ink);
|
||||
opacity: 0.86;
|
||||
}
|
||||
.hero-links {
|
||||
display: flex;
|
||||
gap: var(--space-4);
|
||||
margin: 0;
|
||||
font-size: var(--step-0);
|
||||
color: var(--ink-muted);
|
||||
}
|
||||
|
||||
@media (max-width: 900px) {
|
||||
/* min-height 를 걸지 않는다. 콘텐츠가 390px 인데 736px 을 씌우면
|
||||
여백이 화면의 41% 를 먹고, 다음 섹션이 화면 밖으로 밀려나
|
||||
스크롤할 것이 있다는 단서까지 사라진다. */
|
||||
.hero { min-height: 0; }
|
||||
.hero-grid { grid-template-columns: 1fr; gap: var(--space-5); }
|
||||
.hero-title { max-width: 100%; }
|
||||
/* 세로 화면에서는 글자가 위쪽 절반을 다 쓴다. 가로 방향 스크림으로는
|
||||
덮이지 않으므로 위에서 아래로 누른다 */
|
||||
.hero-scrim {
|
||||
background: linear-gradient(to bottom,
|
||||
color-mix(in oklab, var(--surface) 86%, transparent) 0%,
|
||||
color-mix(in oklab, var(--surface) 58%, transparent) 52%,
|
||||
transparent 86%);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
<script>
|
||||
/*
|
||||
히어로 배경은 셰이더 플레인 하나다. 무거운 씬을 임포트하지 않는다 —
|
||||
references/three.md §0 이 권하는 그 구조다.
|
||||
|
||||
한때 여기에도 게이트 씬(유리판 여섯 장)을 깔았는데, 그러면 같은 그림이
|
||||
파이프라인 섹션과 페이지에 두 번 나온다. 게이트 은유는 옆에 여섯 단계가
|
||||
적힌 그 섹션의 것이고, 여기는 공간을 만드는 재질이면 된다.
|
||||
*/
|
||||
import { mountShaderPlane } from "../lib/shader-plane";
|
||||
|
||||
const canvas = document.getElementById("hero-canvas") as HTMLCanvasElement | null;
|
||||
|
||||
if (canvas) {
|
||||
mountShaderPlane({
|
||||
canvas,
|
||||
pointer: true,
|
||||
speed: 0.5,
|
||||
colors: { uA: "--accent", uB: "--glow-2" },
|
||||
fragment: `
|
||||
precision mediump float;
|
||||
varying vec2 vUv;
|
||||
uniform float uTime; uniform float uAspect;
|
||||
uniform vec2 uPointer;
|
||||
uniform vec3 uA; uniform vec3 uB;
|
||||
|
||||
float hash(vec2 p) { return fract(sin(dot(p, vec2(127.1, 311.7))) * 43758.5453); }
|
||||
float noise(vec2 p) {
|
||||
vec2 i = floor(p), f = fract(p);
|
||||
vec2 u = f * f * (3.0 - 2.0 * f);
|
||||
return mix(mix(hash(i), hash(i + vec2(1, 0)), u.x),
|
||||
mix(hash(i + vec2(0, 1)), hash(i + vec2(1, 1)), u.x), u.y);
|
||||
}
|
||||
float fbm(vec2 p) {
|
||||
float v = 0.0, a = 0.5;
|
||||
for (int i = 0; i < 5; i++) { v += a * noise(p); p *= 2.03; a *= 0.5; }
|
||||
return v;
|
||||
}
|
||||
|
||||
void main() {
|
||||
vec2 p = vUv; p.x *= uAspect;
|
||||
float t = uTime * 0.06;
|
||||
vec2 m = uPointer; m.x *= uAspect;
|
||||
|
||||
// 흐름 필드. 두 번 접어서 빛이 유리를 지난 것처럼 늘어지게 만든다.
|
||||
vec2 q = vec2(fbm(p * 1.5 + t), fbm(p * 1.5 - t * 0.8 + 4.2));
|
||||
vec2 r = vec2(fbm(p * 2.1 + q * 1.6 + t * 0.5),
|
||||
fbm(p * 2.1 + q * 1.6 - t * 0.4 + 1.7));
|
||||
float f = fbm(p * 1.2 + r * 1.9);
|
||||
|
||||
// 광원 둘. 포인터를 아주 조금만 따라간다.
|
||||
vec2 c1 = mix(vec2(0.30 * uAspect, 0.58), m, 0.14);
|
||||
vec2 c2 = vec2(0.80 * uAspect, 0.34);
|
||||
|
||||
float a = smoothstep(1.00, 0.06, distance(p, c1) + f * 0.42);
|
||||
float b = smoothstep(0.92, 0.05, distance(p, c2) + r.y * 0.38);
|
||||
|
||||
// 결이 지나간 자리에 얇은 선이 선다. 유리 가장자리의 굴절 대신이다.
|
||||
float streak = smoothstep(0.48, 0.52, f) - smoothstep(0.52, 0.58, f);
|
||||
|
||||
vec3 col = uA * a + uB * b * 0.9 + (uA + uB) * 0.5 * streak * 0.16;
|
||||
float alpha = clamp(a * 1.05 + b * 0.95 + streak * 0.2, 0.0, 1.0) * 0.8;
|
||||
gl_FragColor = vec4(col, alpha);
|
||||
}
|
||||
`,
|
||||
});
|
||||
}
|
||||
</script>
|
||||
454
apps/site/src/components/HeroSystemGraphic.astro
Normal file
454
apps/site/src/components/HeroSystemGraphic.astro
Normal file
|
|
@ -0,0 +1,454 @@
|
|||
---
|
||||
interface Props {
|
||||
lang?: "ko" | "en";
|
||||
}
|
||||
|
||||
const { lang = "ko" } = Astro.props;
|
||||
const suffix = lang === "en" ? "en" : "ko";
|
||||
const title = lang === "en"
|
||||
? "The designpaca process, assembled as a seven-stage design compiler"
|
||||
: "디자인파카의 7단계 과정을 공간형 디자인 컴파일러로 표현한 그림";
|
||||
const description = lang === "en"
|
||||
? "Seven aligned plates turn a brief into references, direction, tokens, implementation, preflight checks, and a verified result."
|
||||
: "브리프가 레퍼런스, 방향, 토큰, 구현, 프리플라이트를 거쳐 검증된 결과로 조립되는 일곱 개의 층을 보여 줍니다.";
|
||||
const caption = lang === "en"
|
||||
? "Brief · References · Direction · Tokens · Build · Preflight · Proof"
|
||||
: "브리프 · 레퍼런스 · 방향 · 토큰 · 구현 · 프리플라이트 · 결과";
|
||||
---
|
||||
|
||||
<figure class="system-graphic">
|
||||
<svg
|
||||
viewBox="0 0 650 560"
|
||||
role="img"
|
||||
aria-labelledby={`system-title-${suffix} system-desc-${suffix}`}
|
||||
preserveAspectRatio="xMidYMid meet"
|
||||
>
|
||||
<title id={`system-title-${suffix}`}>{title}</title>
|
||||
<desc id={`system-desc-${suffix}`}>{description}</desc>
|
||||
|
||||
<defs>
|
||||
<pattern id={`system-grid-${suffix}`} width="24" height="24" patternUnits="userSpaceOnUse">
|
||||
<path d="M24 0H0V24" class="field-grid" />
|
||||
</pattern>
|
||||
|
||||
<filter id={`system-field-${suffix}`} x="-8%" y="-8%" width="116%" height="116%" color-interpolation-filters="sRGB">
|
||||
<feTurbulence type="fractalNoise" baseFrequency="0.012 0.026" numOctaves="2" seed="7" result="field" />
|
||||
<feDisplacementMap in="SourceGraphic" in2="field" scale="3.5" xChannelSelector="R" yChannelSelector="G" />
|
||||
</filter>
|
||||
|
||||
<filter id={`system-grain-${suffix}`} x="0" y="0" width="100%" height="100%" color-interpolation-filters="sRGB">
|
||||
<feTurbulence type="fractalNoise" baseFrequency="0.72" numOctaves="2" seed="19" />
|
||||
<feColorMatrix type="matrix" values="
|
||||
0 0 0 0 0.09
|
||||
0 0 0 0 0.11
|
||||
0 0 0 0 0.10
|
||||
0 0 0 0.16 0
|
||||
" />
|
||||
</filter>
|
||||
</defs>
|
||||
|
||||
<g aria-hidden="true">
|
||||
<rect x="29" y="29" width="592" height="502" class="field" />
|
||||
<rect x="29" y="29" width="592" height="502" fill={`url(#system-grid-${suffix})`} />
|
||||
<rect x="29" y="29" width="592" height="502" class="field-grain" filter={`url(#system-grain-${suffix})`} />
|
||||
|
||||
<g class="crop-marks">
|
||||
<path d="M29 61V29h32M589 29h32v32M621 499v32h-32M61 531H29v-32" />
|
||||
<path d="M313 29h24M313 531h24M29 268v24M621 268v24" />
|
||||
</g>
|
||||
|
||||
<g class="contours" filter={`url(#system-field-${suffix})`}>
|
||||
<path d="M69 442c59-47 90-32 131-73 41-42 28-91 79-119 47-25 91-4 136-45 38-34 60-66 130-84" />
|
||||
<path d="M82 470c64-37 102-24 147-67 44-42 36-89 82-113 51-27 97 1 147-38 34-27 54-60 111-75" />
|
||||
<path d="M95 496c72-31 112-16 163-60 47-41 44-83 88-105 49-24 94 10 148-27 27-19 47-43 74-53" />
|
||||
</g>
|
||||
|
||||
<g class="datum">
|
||||
<path d="M93 448 485 103" />
|
||||
<path d="m93 448 21-5-10-20" />
|
||||
<circle cx="93" cy="448" r="4" />
|
||||
</g>
|
||||
|
||||
<!-- Seven plates share one datum. The process is one system, not seven unrelated cards. -->
|
||||
<g class="compiler-stack">
|
||||
<g class="stage-layer stage-01">
|
||||
<polygon class="plate-edge" points="103,423 348,349 526,421 280,496 103,480" />
|
||||
<polygon class="plate plate-dark" points="103,408 348,334 526,405 280,480" />
|
||||
<path class="plate-rule inverse" d="m127 414 221-66 153 61-221 67Z" />
|
||||
<circle class="target inverse" cx="205" cy="417" r="19" />
|
||||
<path class="target inverse" d="M205 390v54M178 417h54" />
|
||||
<path class="micro inverse" d="m323 381 93-28M338 398l120-36M355 415l81-24" />
|
||||
<text class="index inverse" x="121" y="457">01</text>
|
||||
</g>
|
||||
|
||||
<g class="stage-layer stage-02">
|
||||
<polygon class="plate-edge" points="123,359 368,285 546,357 300,432 123,416" />
|
||||
<polygon class="plate" points="123,344 368,270 546,341 300,416" />
|
||||
<path class="plate-rule" d="m147 350 221-66 153 61-221 67Z" />
|
||||
<path class="sample" d="m183 351 75-22 48 19-75 23Zm91-27 75-22 48 19-75 23Z" />
|
||||
<path class="micro" d="m365 351 91-27M379 367l57-17" />
|
||||
<text class="index" x="141" y="393">02</text>
|
||||
</g>
|
||||
|
||||
<g class="stage-layer stage-03">
|
||||
<polygon class="plate-edge" points="143,295 388,221 566,293 320,368 143,352" />
|
||||
<polygon class="plate plate-soft" points="143,280 388,206 566,277 320,352" />
|
||||
<path class="plate-rule" d="m167 286 221-66 153 61-221 67Z" />
|
||||
<circle class="target" cx="258" cy="290" r="24" />
|
||||
<path class="decision" d="m258 290 93-28m-15-8 15 8-8 15" />
|
||||
<path class="micro" d="m390 278 87-26M405 295l52-16" />
|
||||
<text class="index" x="161" y="329">03</text>
|
||||
</g>
|
||||
|
||||
<g class="stage-layer stage-04">
|
||||
<polygon class="plate-edge" points="163,231 408,157 586,229 340,304 163,288" />
|
||||
<polygon class="plate" points="163,216 408,142 586,213 340,288" />
|
||||
<path class="plate-rule" d="m187 222 221-66 153 61-221 67Z" />
|
||||
<g class="token-set">
|
||||
<path d="m222 224 35-11 23 9-36 11Zm44-13 35-10 23 9-35 10Zm44-13 36-10 22 9-35 10Zm44-13 36-11 22 9-35 11Z" />
|
||||
<path d="m247 245 121-36M265 256l83-24" />
|
||||
</g>
|
||||
<text class="index" x="181" y="265">04</text>
|
||||
</g>
|
||||
|
||||
<g class="stage-layer stage-05">
|
||||
<polygon class="plate-edge" points="183,167 428,93 606,165 360,240 183,224" />
|
||||
<polygon class="plate plate-dark" points="183,152 428,78 606,149 360,224" />
|
||||
<path class="plate-rule inverse" d="m207 158 221-66 153 61-221 67Z" />
|
||||
<path class="wireframe inverse" d="m245 164 78-24 48 19-78 24Zm78-24 74-22 48 19-74 22Zm-30 43 78-24v35l-78 24Zm78-24 74-22v35l-74 22" />
|
||||
<path class="micro inverse" d="m466 139 69-21M481 156l35-11" />
|
||||
<text class="index inverse" x="201" y="201">05</text>
|
||||
</g>
|
||||
|
||||
<g class="stage-layer stage-06">
|
||||
<polygon class="plate-edge" points="203,103 448,29 626,101 380,176 203,160" />
|
||||
<polygon class="plate plate-soft" points="203,88 448,14 626,85 380,160" />
|
||||
<path class="plate-rule" d="m227 94 221-66 153 61-221 67Z" />
|
||||
<path class="scan" d="m278 102 160-48 102 41-160 48Z" />
|
||||
<path class="scan-line" d="m307 93 160-48" />
|
||||
<path class="check" d="m479 103 11 10 27-36" />
|
||||
<text class="index" x="221" y="137">06</text>
|
||||
</g>
|
||||
|
||||
<!-- The verified result exits the stack: the only red surface in the scene. -->
|
||||
<g class="stage-layer stage-07">
|
||||
<polygon class="output-shadow" points="362,66 495,26 607,70 473,111" />
|
||||
<polygon class="output" points="350,50 483,10 595,54 461,95" />
|
||||
<path class="output-rule" d="m374 54 109-32 87 35-109 33Z" />
|
||||
<circle class="proof-mark" cx="476" cy="54" r="19" />
|
||||
<path class="proof-mark" d="m466 54 7 7 14-19" />
|
||||
<text class="index output-index" x="371" y="73">07</text>
|
||||
</g>
|
||||
</g>
|
||||
|
||||
<g class="registration-pins">
|
||||
<g class="registration-pin pin-01">
|
||||
<path d="M280 496V480" />
|
||||
<circle cx="280" cy="496" r="3" />
|
||||
</g>
|
||||
<g class="registration-pin pin-02">
|
||||
<path d="M300 432v-16" />
|
||||
<circle cx="300" cy="432" r="3" />
|
||||
</g>
|
||||
<g class="registration-pin pin-03">
|
||||
<path d="M320 368v-16" />
|
||||
<circle cx="320" cy="368" r="3" />
|
||||
</g>
|
||||
<g class="registration-pin pin-04">
|
||||
<path d="M340 304v-16" />
|
||||
<circle cx="340" cy="304" r="3" />
|
||||
</g>
|
||||
<g class="registration-pin pin-05">
|
||||
<path d="M360 240v-16" />
|
||||
<circle cx="360" cy="240" r="3" />
|
||||
</g>
|
||||
<g class="registration-pin pin-06">
|
||||
<path d="M380 176v-16" />
|
||||
<circle cx="380" cy="176" r="3" />
|
||||
</g>
|
||||
</g>
|
||||
|
||||
<g class="signal-path signal-path-open">
|
||||
<path fill="none" d="M91 451 116 443 136 379 156 315 176 251 196 187 216 123 365 78" />
|
||||
<circle class="signal-node" cx="116" cy="443" r="4" />
|
||||
<circle class="signal-node" cx="136" cy="379" r="4" />
|
||||
<circle class="signal-node" cx="156" cy="315" r="4" />
|
||||
<circle class="signal-node" cx="176" cy="251" r="4" />
|
||||
<circle class="signal-node" cx="196" cy="187" r="4" />
|
||||
<circle class="signal-node" cx="216" cy="123" r="4" />
|
||||
</g>
|
||||
|
||||
<!-- The compact signal is a second exact path. Crossfading avoids an SVG d morph and keeps every node registered. -->
|
||||
<g class="signal-path signal-path-compact">
|
||||
<path fill="none" d="M126 310 151 302 157 288 163 274 169 260 175 246 181 232 278 207.5" />
|
||||
<circle class="signal-node" cx="151" cy="302" r="4" />
|
||||
<circle class="signal-node" cx="157" cy="288" r="4" />
|
||||
<circle class="signal-node" cx="163" cy="274" r="4" />
|
||||
<circle class="signal-node" cx="169" cy="260" r="4" />
|
||||
<circle class="signal-node" cx="175" cy="246" r="4" />
|
||||
<circle class="signal-node" cx="181" cy="232" r="4" />
|
||||
</g>
|
||||
|
||||
<g class="scale-marks">
|
||||
<path d="M558 478h38M558 466v24M575 471v14M593 466v24" />
|
||||
<path d="M67 94V66h28M67 66l10 10M67 66l-10 10" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
<figcaption>{caption}</figcaption>
|
||||
</figure>
|
||||
|
||||
<style>
|
||||
.system-graphic {
|
||||
width: 100%;
|
||||
max-width: 40.625rem;
|
||||
margin: 0;
|
||||
color: var(--ink);
|
||||
}
|
||||
|
||||
.system-graphic svg {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
aspect-ratio: 65 / 56;
|
||||
overflow: visible;
|
||||
}
|
||||
|
||||
.system-graphic figcaption {
|
||||
padding: var(--space-3) var(--space-4);
|
||||
border-top: var(--line-width) solid var(--line-strong);
|
||||
color: var(--ink-muted);
|
||||
font-family: var(--font-mono);
|
||||
font-size: var(--step--1);
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
.field {
|
||||
fill: var(--surface-raised);
|
||||
stroke: var(--line);
|
||||
}
|
||||
|
||||
.field-grid {
|
||||
fill: none;
|
||||
stroke: var(--line);
|
||||
stroke-width: 0.65;
|
||||
opacity: 0.38;
|
||||
}
|
||||
|
||||
.field-grain { opacity: 0.19; }
|
||||
|
||||
.crop-marks,
|
||||
.scale-marks {
|
||||
fill: none;
|
||||
stroke: var(--ink);
|
||||
stroke-width: 1.1;
|
||||
vector-effect: non-scaling-stroke;
|
||||
}
|
||||
|
||||
.contours {
|
||||
fill: none;
|
||||
stroke: var(--line-strong);
|
||||
stroke-width: 0.8;
|
||||
opacity: 0.42;
|
||||
vector-effect: non-scaling-stroke;
|
||||
}
|
||||
|
||||
.datum {
|
||||
fill: var(--surface-raised);
|
||||
stroke: var(--ink-muted);
|
||||
stroke-width: 1;
|
||||
stroke-dasharray: 3 6;
|
||||
opacity: 0.72;
|
||||
vector-effect: non-scaling-stroke;
|
||||
}
|
||||
|
||||
.plate-edge {
|
||||
fill: var(--line-strong);
|
||||
stroke: var(--ink);
|
||||
stroke-width: 1;
|
||||
}
|
||||
|
||||
.plate {
|
||||
fill: var(--surface-raised);
|
||||
stroke: var(--ink);
|
||||
stroke-width: 1.15;
|
||||
}
|
||||
|
||||
.plate-soft { fill: var(--surface-soft); }
|
||||
.plate-dark { fill: var(--surface-inverse); }
|
||||
|
||||
.plate-rule {
|
||||
fill: none;
|
||||
stroke: var(--ink-muted);
|
||||
stroke-width: 0.9;
|
||||
opacity: 0.62;
|
||||
}
|
||||
|
||||
.inverse { stroke: var(--ink-muted-inverse); }
|
||||
|
||||
.target,
|
||||
.decision,
|
||||
.sample,
|
||||
.token-set,
|
||||
.wireframe,
|
||||
.scan,
|
||||
.scan-line,
|
||||
.check {
|
||||
fill: none;
|
||||
stroke: var(--ink);
|
||||
stroke-width: 1.35;
|
||||
stroke-linecap: square;
|
||||
stroke-linejoin: miter;
|
||||
}
|
||||
|
||||
.sample,
|
||||
.token-set { fill: var(--surface-soft); }
|
||||
.wireframe.inverse { stroke: var(--ink-inverse); }
|
||||
.scan { stroke-dasharray: 3 4; }
|
||||
.scan-line { stroke: var(--accent); stroke-width: 2; }
|
||||
.check { stroke: var(--accent); stroke-width: 2.8; }
|
||||
|
||||
.micro {
|
||||
fill: none;
|
||||
stroke: var(--ink-muted);
|
||||
stroke-width: 1;
|
||||
}
|
||||
|
||||
.micro.inverse { stroke: var(--ink-muted-inverse); }
|
||||
|
||||
.index {
|
||||
fill: var(--ink-muted);
|
||||
font-family: var(--font-mono);
|
||||
font-size: 11px;
|
||||
font-weight: var(--weight-medium);
|
||||
letter-spacing: 0.04em;
|
||||
}
|
||||
|
||||
.index.inverse { fill: var(--ink-muted-inverse); }
|
||||
|
||||
.output-shadow { fill: var(--ink); opacity: 0.16; }
|
||||
.output {
|
||||
fill: var(--accent);
|
||||
stroke: var(--ink);
|
||||
stroke-width: 1.15;
|
||||
}
|
||||
|
||||
.output-rule {
|
||||
fill: none;
|
||||
stroke: var(--accent-ink);
|
||||
stroke-width: 0.85;
|
||||
opacity: 0.58;
|
||||
}
|
||||
|
||||
.proof-mark {
|
||||
fill: none;
|
||||
stroke: var(--accent-ink);
|
||||
stroke-width: 2;
|
||||
stroke-linecap: square;
|
||||
stroke-linejoin: miter;
|
||||
}
|
||||
|
||||
.output-index { fill: var(--accent-ink); }
|
||||
|
||||
.registration-pins {
|
||||
fill: var(--surface-raised);
|
||||
stroke: var(--ink);
|
||||
stroke-width: 1;
|
||||
}
|
||||
|
||||
.signal-path {
|
||||
fill: none;
|
||||
stroke: var(--accent);
|
||||
stroke-width: 1.8;
|
||||
stroke-linecap: square;
|
||||
stroke-linejoin: miter;
|
||||
}
|
||||
|
||||
.signal-node { fill: var(--accent); }
|
||||
|
||||
.stage-layer,
|
||||
.registration-pin {
|
||||
--stack-x: 0px;
|
||||
--stack-y: 0px;
|
||||
transform: translate(var(--stack-x), var(--stack-y));
|
||||
transform-box: fill-box;
|
||||
transform-origin: center;
|
||||
}
|
||||
|
||||
.stage-01,
|
||||
.pin-01 { --stack-x: 35px; --stack-y: -141px; }
|
||||
.stage-02,
|
||||
.pin-02 { --stack-x: 21px; --stack-y: -91px; }
|
||||
.stage-03,
|
||||
.pin-03 { --stack-x: 7px; --stack-y: -41px; }
|
||||
.stage-04,
|
||||
.pin-04 { --stack-x: -7px; --stack-y: 9px; }
|
||||
.stage-05,
|
||||
.pin-05 { --stack-x: -21px; --stack-y: 59px; }
|
||||
.stage-06,
|
||||
.pin-06 { --stack-x: -35px; --stack-y: 109px; }
|
||||
.stage-07 { --stack-x: -87px; --stack-y: 129.5px; }
|
||||
|
||||
.signal-path-open { opacity: 0; }
|
||||
.signal-path-compact { opacity: 1; }
|
||||
|
||||
@supports (animation-timeline: scroll()) {
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.stage-layer,
|
||||
.registration-pin {
|
||||
animation: system-stack-scroll linear both;
|
||||
animation-timeline: scroll(root block);
|
||||
animation-range: 0 18vh;
|
||||
}
|
||||
|
||||
.signal-path-open { animation: system-signal-open linear both; }
|
||||
.signal-path-compact { animation: system-signal-compact linear both; }
|
||||
|
||||
.signal-path-open,
|
||||
.signal-path-compact {
|
||||
animation-timeline: scroll(root block);
|
||||
animation-range: 0 18vh;
|
||||
}
|
||||
|
||||
@media (max-width: 68rem) {
|
||||
.stage-layer,
|
||||
.registration-pin,
|
||||
.signal-path-open,
|
||||
.signal-path-compact { animation-range: 0 58vh; }
|
||||
}
|
||||
|
||||
@keyframes system-stack-scroll {
|
||||
from { transform: translate(0, 0); }
|
||||
to { transform: translate(var(--stack-x), var(--stack-y)); }
|
||||
}
|
||||
|
||||
@keyframes system-signal-open {
|
||||
0%, 10% { opacity: 1; }
|
||||
14%, 100% { opacity: 0; }
|
||||
}
|
||||
|
||||
@keyframes system-signal-compact {
|
||||
0%, 86% { opacity: 0; }
|
||||
90%, 100% { opacity: 1; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 34rem) {
|
||||
.system-graphic {
|
||||
width: calc(100% + var(--space-2));
|
||||
margin-inline: calc(var(--space-1) * -1);
|
||||
}
|
||||
|
||||
.contours,
|
||||
.scale-marks { opacity: 0.62; }
|
||||
|
||||
.index { font-size: 13px; }
|
||||
}
|
||||
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.stage-layer,
|
||||
.registration-pin,
|
||||
.signal-path { animation: none; }
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,91 +0,0 @@
|
|||
---
|
||||
import CopyCommand from "./CopyCommand.astro";
|
||||
import BgPhoto from "./BgPhoto.astro";
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props { c: Content["install"]; ui: Content["ui"]; }
|
||||
const { c, ui } = Astro.props;
|
||||
---
|
||||
|
||||
|
||||
<section id="install" class="full install has-bg" aria-labelledby="install-h">
|
||||
<BgPhoto variant="refraction" mode="fixed" opacity={0.85} flip />
|
||||
<div class="install-grid">
|
||||
<div class="install-head">
|
||||
<h2 id="install-h">{c.h2}</h2>
|
||||
<p class="lead install-lead">{c.lead}</p>
|
||||
<CopyCommand command={c.command} copyLabel={ui.copy} copiedLabel={ui.copied} />
|
||||
</div>
|
||||
|
||||
<div class="install-body">
|
||||
<ul class="targets">
|
||||
{
|
||||
c.targets.map((t) => (
|
||||
<li>
|
||||
<span class="t-name">{t.name}</span>
|
||||
<span class="t-path mono muted">{t.path}</span>
|
||||
</li>
|
||||
))
|
||||
}
|
||||
</ul>
|
||||
|
||||
<dl class="cmds">
|
||||
{
|
||||
c.commands.map((x) => (
|
||||
<div class="cmd-row">
|
||||
<dt class="mono">{x.cmd}</dt>
|
||||
<dd class="muted">{x.what}</dd>
|
||||
</div>
|
||||
))
|
||||
}
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
.install { padding-block: var(--space-8); }
|
||||
.install-grid {
|
||||
max-width: 1180px;
|
||||
margin-inline: auto;
|
||||
padding-inline: var(--gutter);
|
||||
display: grid;
|
||||
gap: var(--space-6);
|
||||
grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
|
||||
align-items: start;
|
||||
}
|
||||
.install-lead { margin-block: var(--space-3) var(--space-5); max-width: 26em; }
|
||||
|
||||
.targets { list-style: none; margin: 0 0 var(--space-5); padding: 0; }
|
||||
.targets li {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: var(--space-2) var(--space-3);
|
||||
justify-content: space-between;
|
||||
padding-block: var(--space-2);
|
||||
border-bottom: 1px solid var(--line);
|
||||
}
|
||||
.t-name { font-weight: var(--weight-medium); }
|
||||
.t-path {
|
||||
font-size: var(--mono-size);
|
||||
/* 경로는 공백이 없어 min-content 가 363px 다 — anywhere 로 접게 한다 */
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
.cmds { margin: 0; display: grid; gap: var(--space-3); }
|
||||
.cmd-row {
|
||||
display: grid;
|
||||
gap: var(--space-1);
|
||||
padding-block: var(--space-3);
|
||||
border-top: 1px solid var(--line);
|
||||
}
|
||||
.cmd-row:last-child { border-bottom: 1px solid var(--line); }
|
||||
dt { color: var(--accent); }
|
||||
dd { margin: 0; font-size: var(--step-0); }
|
||||
|
||||
@media (max-width: 820px) {
|
||||
/* 순수 1fr 은 minmax(auto,1fr) 다 — nowrap 명령어의 min-content 가
|
||||
트랙을 뷰포트 밖까지 밀어낸다(390px 실측 +5px). min 0 이여야 접는다 */
|
||||
.install-grid { grid-template-columns: minmax(0, 1fr); }
|
||||
}
|
||||
</style>
|
||||
501
apps/site/src/components/Landing.astro
Normal file
501
apps/site/src/components/Landing.astro
Normal file
|
|
@ -0,0 +1,501 @@
|
|||
---
|
||||
import CopyCommand from "./CopyCommand.astro";
|
||||
import HeroSystemGraphic from "./HeroSystemGraphic.astro";
|
||||
import OutputSpecimens from "./OutputSpecimens.astro";
|
||||
import type { LandingContent } from "../i18n/landing";
|
||||
|
||||
interface Props {
|
||||
c: LandingContent;
|
||||
lang: "ko" | "en";
|
||||
}
|
||||
|
||||
const { c, lang } = Astro.props;
|
||||
const repoUrl = "https://git.chanpaca.net/yunchan/designpaca";
|
||||
const docsUrl = `${repoUrl}#readme`;
|
||||
const showcasePath = lang === "ko" ? "/showcase/" : "/en/showcase/";
|
||||
const copyLabel = c.hero.primaryCta;
|
||||
const copiedLabel = lang === "ko" ? "복사했어요" : "Copied";
|
||||
---
|
||||
|
||||
<section class="landing-hero grain" aria-labelledby="hero-title">
|
||||
<div class="hero-grid shell">
|
||||
<div class="hero-copy">
|
||||
<h1 id="hero-title">
|
||||
{c.hero.h1.split("\n").map((line) => <span>{line}</span>)}
|
||||
</h1>
|
||||
<p class="hero-lead">{c.hero.lead}</p>
|
||||
<div class="hero-actions">
|
||||
<CopyCommand
|
||||
command={c.hero.command}
|
||||
copyLabel={copyLabel}
|
||||
copiedLabel={copiedLabel}
|
||||
/>
|
||||
<a class="btn btn-text" href="#outputs">
|
||||
{c.hero.secondaryCta}
|
||||
<svg viewBox="0 0 16 16" width="15" height="15" aria-hidden="true">
|
||||
<path d="M3 5.5 8 10l5-4.5" />
|
||||
</svg>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="hero-visual">
|
||||
<HeroSystemGraphic lang={lang} />
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section id="outputs" class="output-section">
|
||||
<div class="section-head shell">
|
||||
<h2>{c.outputs.h2}</h2>
|
||||
<div>
|
||||
<p>{c.outputs.lead}</p>
|
||||
<a class="section-link" href={showcasePath}>
|
||||
{c.outputs.archiveCta}
|
||||
<svg viewBox="0 0 16 16" width="15" height="15" aria-hidden="true">
|
||||
<path d="M3 8h10M9 4l4 4-4 4" />
|
||||
</svg>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="output-surface shell">
|
||||
<OutputSpecimens lang={lang} />
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section id="process" class="process-section grain">
|
||||
<div class="process-grid shell">
|
||||
<header class="process-head">
|
||||
<h2>{c.process.h2}</h2>
|
||||
<p>{c.process.lead}</p>
|
||||
</header>
|
||||
|
||||
<ol class="stage-list">
|
||||
{c.process.stages.map((stage) => (
|
||||
<li>
|
||||
<span class="stage-index nums">{stage.step}</span>
|
||||
<h3>{stage.name}</h3>
|
||||
<p>{stage.result}</p>
|
||||
</li>
|
||||
))}
|
||||
</ol>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section id="proof" class="proof-section">
|
||||
<div class="section-head shell">
|
||||
<h2>{c.proof.h2}</h2>
|
||||
<p>{c.proof.lead}</p>
|
||||
</div>
|
||||
|
||||
<dl class="proof-facts shell">
|
||||
{c.proof.facts.map((fact) => (
|
||||
<div>
|
||||
<dt>
|
||||
<span class="proof-value nums">{fact.value}</span>
|
||||
<span>{fact.label}</span>
|
||||
</dt>
|
||||
<dd>{fact.description}</dd>
|
||||
</div>
|
||||
))}
|
||||
</dl>
|
||||
|
||||
<details class="audit-details shell">
|
||||
<summary>
|
||||
<span>{c.proof.details.summary}</span>
|
||||
<svg viewBox="0 0 16 16" width="16" height="16" aria-hidden="true">
|
||||
<path d="M3 5.5 8 10l5-4.5" />
|
||||
</svg>
|
||||
</summary>
|
||||
<ol>
|
||||
{c.proof.details.items.map((item) => <li>{item}</li>)}
|
||||
</ol>
|
||||
</details>
|
||||
</section>
|
||||
|
||||
<section id="install" class="install-section">
|
||||
<div class="install-grid shell">
|
||||
<div>
|
||||
<h2>{c.install.h2}</h2>
|
||||
<p class="install-lead">{c.install.lead}</p>
|
||||
</div>
|
||||
<div class="install-action">
|
||||
<CopyCommand
|
||||
command={c.install.command}
|
||||
copyLabel={copyLabel}
|
||||
copiedLabel={copiedLabel}
|
||||
/>
|
||||
<ul>
|
||||
{c.install.support.map((item) => (
|
||||
<li>
|
||||
<svg viewBox="0 0 16 16" width="16" height="16" aria-hidden="true">
|
||||
<path d="m3 8 3 3 7-7" />
|
||||
</svg>
|
||||
<span>{item}</span>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
<div class="install-links">
|
||||
<a href={docsUrl}>{c.install.docsLabel}</a>
|
||||
<a href={repoUrl}>{c.install.repoLabel}</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<footer class="site-footer">
|
||||
<div class="shell">
|
||||
<p>{c.footer.tagline}</p>
|
||||
<p>{c.footer.license}</p>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
<style>
|
||||
.landing-hero {
|
||||
padding-block: var(--space-7) var(--space-9);
|
||||
border-bottom: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.hero-grid {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 0.82fr) minmax(34rem, 1.18fr);
|
||||
gap: var(--space-8);
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.hero-copy {
|
||||
display: grid;
|
||||
align-content: center;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.hero-copy h1 span { display: block; }
|
||||
|
||||
.hero-lead {
|
||||
max-width: var(--measure-narrow);
|
||||
margin-top: var(--space-6);
|
||||
color: var(--ink-muted);
|
||||
font-size: var(--step-1);
|
||||
}
|
||||
|
||||
.hero-actions {
|
||||
margin-top: var(--space-7);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--space-3);
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.hero-actions :global(.cmd-shell) { width: min(100%, 31rem); }
|
||||
.hero-actions .btn-text svg,
|
||||
.section-link svg,
|
||||
.audit-details summary svg,
|
||||
.install-action li svg {
|
||||
fill: none;
|
||||
stroke: currentColor;
|
||||
stroke-width: 1.5;
|
||||
stroke-linecap: round;
|
||||
stroke-linejoin: round;
|
||||
flex: none;
|
||||
}
|
||||
|
||||
.hero-visual {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.output-section,
|
||||
.proof-section {
|
||||
padding-block: var(--space-9);
|
||||
}
|
||||
|
||||
.section-head {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) minmax(20rem, 0.82fr);
|
||||
gap: var(--space-8);
|
||||
align-items: start;
|
||||
}
|
||||
|
||||
.section-head > div,
|
||||
.section-head > p {
|
||||
max-width: var(--measure-narrow);
|
||||
color: var(--ink-muted);
|
||||
}
|
||||
|
||||
.section-link {
|
||||
min-height: var(--control-h);
|
||||
width: fit-content;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: var(--space-2);
|
||||
margin-top: var(--space-5);
|
||||
color: var(--ink);
|
||||
font-weight: var(--weight-medium);
|
||||
}
|
||||
|
||||
.output-surface {
|
||||
margin-top: var(--space-8);
|
||||
}
|
||||
|
||||
.process-section {
|
||||
padding-block: var(--space-9);
|
||||
background: var(--surface-inverse);
|
||||
color: var(--ink-inverse);
|
||||
}
|
||||
|
||||
.process-section.grain::after {
|
||||
mix-blend-mode: screen;
|
||||
opacity: 0.035;
|
||||
}
|
||||
|
||||
.process-grid {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(18rem, 0.72fr) minmax(0, 1.28fr);
|
||||
gap: var(--space-8);
|
||||
align-items: start;
|
||||
}
|
||||
|
||||
.process-head {
|
||||
position: sticky;
|
||||
top: calc(var(--header-h) + var(--space-6));
|
||||
}
|
||||
|
||||
.process-head p {
|
||||
max-width: var(--measure-narrow);
|
||||
margin-top: var(--space-5);
|
||||
color: var(--ink-muted-inverse);
|
||||
}
|
||||
|
||||
.stage-list {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border-top: var(--line-width) solid var(--line-inverse);
|
||||
}
|
||||
|
||||
.stage-list li {
|
||||
position: relative;
|
||||
display: grid;
|
||||
grid-template-columns: 2.5rem minmax(10rem, 0.62fr) minmax(0, 1fr);
|
||||
gap: var(--space-4) var(--space-6);
|
||||
align-items: baseline;
|
||||
padding-block: var(--space-5);
|
||||
border-bottom: var(--line-width) solid var(--line-inverse);
|
||||
}
|
||||
|
||||
.stage-index {
|
||||
color: var(--accent);
|
||||
font-weight: var(--weight-medium);
|
||||
}
|
||||
|
||||
.stage-list h3 { font-size: var(--step-1); }
|
||||
.stage-list p {
|
||||
color: var(--ink-muted-inverse);
|
||||
font-size: var(--step-0);
|
||||
}
|
||||
|
||||
@supports (animation-timeline: view()) {
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.stage-list li::after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
inset-inline-start: 0;
|
||||
bottom: calc(var(--line-width) * -1);
|
||||
width: 2.5rem;
|
||||
height: var(--line-width);
|
||||
background: var(--accent);
|
||||
transform-origin: left center;
|
||||
animation: stage-rail-register linear both;
|
||||
animation-timeline: view(block);
|
||||
animation-range: entry 12% cover 32%;
|
||||
}
|
||||
|
||||
@keyframes stage-rail-register {
|
||||
from { opacity: 0.25; transform: scaleX(0); }
|
||||
to { opacity: 1; transform: scaleX(1); }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.proof-facts {
|
||||
margin-top: var(--space-8);
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, minmax(0, 1fr));
|
||||
border-block: var(--line-width) solid var(--line-strong);
|
||||
}
|
||||
|
||||
.proof-facts > div {
|
||||
min-width: 0;
|
||||
padding: var(--space-6);
|
||||
}
|
||||
|
||||
.proof-facts > div + div { border-left: var(--line-width) solid var(--line); }
|
||||
|
||||
.proof-facts dt { display: grid; gap: var(--space-2); }
|
||||
.proof-value {
|
||||
color: var(--accent);
|
||||
font-size: clamp(2.5rem, 2rem + 2vw, 4rem);
|
||||
font-weight: var(--weight-medium);
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
.proof-facts dd {
|
||||
margin-top: var(--space-4);
|
||||
color: var(--ink-muted);
|
||||
font-size: var(--step--1);
|
||||
}
|
||||
|
||||
.audit-details {
|
||||
margin-top: var(--space-6);
|
||||
border-bottom: var(--line-width) solid var(--line-strong);
|
||||
}
|
||||
|
||||
.audit-details summary {
|
||||
min-height: var(--control-h);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
gap: var(--space-4);
|
||||
padding-block: var(--space-4);
|
||||
font-weight: var(--weight-medium);
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
.audit-details summary::-webkit-details-marker { display: none; }
|
||||
.audit-details summary::marker { content: ""; }
|
||||
.audit-details summary svg { transition: transform var(--dur-quick) var(--ease-out); }
|
||||
.audit-details[open] summary svg { transform: rotate(180deg); }
|
||||
|
||||
.audit-details ol {
|
||||
margin: 0;
|
||||
padding: 0 0 var(--space-6);
|
||||
list-style: none;
|
||||
counter-reset: audit;
|
||||
}
|
||||
|
||||
.audit-details li {
|
||||
counter-increment: audit;
|
||||
display: grid;
|
||||
grid-template-columns: 2rem minmax(0, 1fr);
|
||||
gap: var(--space-3);
|
||||
padding-block: var(--space-3);
|
||||
border-top: var(--line-width) solid var(--line);
|
||||
color: var(--ink-muted);
|
||||
}
|
||||
|
||||
.audit-details li::before {
|
||||
content: counter(audit, decimal-leading-zero);
|
||||
color: var(--accent);
|
||||
font-family: var(--font-mono);
|
||||
font-size: var(--mono-size);
|
||||
}
|
||||
|
||||
.install-section {
|
||||
padding-block: var(--space-9);
|
||||
background: var(--surface-soft);
|
||||
border-block: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.install-grid {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 0.95fr) minmax(28rem, 1.05fr);
|
||||
gap: var(--space-8);
|
||||
align-items: start;
|
||||
}
|
||||
|
||||
.install-lead {
|
||||
max-width: var(--measure-narrow);
|
||||
margin-top: var(--space-5);
|
||||
color: var(--ink-muted);
|
||||
}
|
||||
|
||||
.install-action :global(.cmd-shell) { max-width: none; }
|
||||
|
||||
.install-action ul {
|
||||
list-style: none;
|
||||
margin: var(--space-6) 0 0;
|
||||
padding: 0;
|
||||
border-top: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.install-action li {
|
||||
min-height: var(--control-h);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--space-3);
|
||||
padding-block: var(--space-3);
|
||||
border-bottom: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.install-action li svg { color: var(--accent); }
|
||||
|
||||
.install-links {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: var(--space-4) var(--space-6);
|
||||
margin-top: var(--space-6);
|
||||
}
|
||||
|
||||
.install-links a {
|
||||
min-height: var(--control-h);
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
font-weight: var(--weight-medium);
|
||||
}
|
||||
|
||||
.site-footer { padding-block: var(--space-7); }
|
||||
.site-footer .shell {
|
||||
display: flex;
|
||||
align-items: flex-end;
|
||||
justify-content: space-between;
|
||||
gap: var(--space-6);
|
||||
color: var(--ink-muted);
|
||||
font-size: var(--step--1);
|
||||
}
|
||||
.site-footer p:first-child { max-width: 32rem; color: var(--ink); }
|
||||
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.audit-details summary svg { transition: none; }
|
||||
}
|
||||
|
||||
@media (max-width: 68rem) {
|
||||
.hero-grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-8); }
|
||||
.hero-copy { max-width: 44rem; }
|
||||
.process-grid { grid-template-columns: minmax(15rem, 0.62fr) minmax(0, 1.38fr); }
|
||||
}
|
||||
|
||||
@media (max-width: 56rem) {
|
||||
.hero-grid,
|
||||
.section-head,
|
||||
.process-grid,
|
||||
.install-grid {
|
||||
grid-template-columns: minmax(0, 1fr);
|
||||
}
|
||||
.hero-grid { gap: var(--space-8); }
|
||||
.hero-copy { max-width: 44rem; }
|
||||
.process-head { position: static; }
|
||||
.section-head { gap: var(--space-5); }
|
||||
.proof-facts { grid-template-columns: 1fr; }
|
||||
.proof-facts > div + div { border-left: 0; border-top: var(--line-width) solid var(--line); }
|
||||
}
|
||||
|
||||
@media (max-width: 47.5rem) {
|
||||
.landing-hero { padding-top: var(--space-8); }
|
||||
.hero-copy h1 { font-size: clamp(2.2rem, 11.2vw, 2.8125rem); }
|
||||
:global(html[lang="en"]) .hero-copy h1 { font-size: clamp(2.25rem, 10.2vw, 2.65rem); }
|
||||
.stage-list li {
|
||||
grid-template-columns: 2rem minmax(0, 1fr);
|
||||
gap: var(--space-2) var(--space-4);
|
||||
}
|
||||
.stage-list p { grid-column: 2; }
|
||||
}
|
||||
|
||||
@media (max-width: 34rem) {
|
||||
.hero-actions { align-items: stretch; }
|
||||
.hero-actions :global(.cmd-shell),
|
||||
.hero-actions .btn-text { width: 100%; }
|
||||
.site-footer .shell { display: grid; align-items: start; }
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,248 +0,0 @@
|
|||
---
|
||||
import BgPhoto from "./BgPhoto.astro";
|
||||
import FilterArt from "./FilterArt.astro";
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props { c: Content["materials"]; }
|
||||
const { c } = Astro.props;
|
||||
|
||||
/* 변위 지도 두 장. 가장자리에서 안쪽으로 미는 값만 담고 가운데는 중립(128)이다.
|
||||
`#` 이 data URI 를 끊으므로 색은 rgb() 로 적는다. */
|
||||
const W = 216;
|
||||
const H = 72;
|
||||
const map = (vertical: boolean, from: string, to: string) => {
|
||||
const dir = vertical ? 'x1="0" y1="0" x2="0" y2="1"' : 'x1="0" y1="0" x2="1" y2="0"';
|
||||
const svg =
|
||||
`<svg xmlns="http://www.w3.org/2000/svg" width="${W}" height="${H}">` +
|
||||
`<defs><linearGradient id="g" ${dir}>` +
|
||||
`<stop offset="0" stop-color="${from}"/>` +
|
||||
`<stop offset="0.30" stop-color="rgb(128,128,128)"/>` +
|
||||
`<stop offset="0.70" stop-color="rgb(128,128,128)"/>` +
|
||||
`<stop offset="1" stop-color="${to}"/>` +
|
||||
`</linearGradient></defs>` +
|
||||
`<rect width="${W}" height="${H}" fill="url(#g)"/></svg>`;
|
||||
return `data:image/svg+xml;utf8,${encodeURIComponent(svg)}`;
|
||||
};
|
||||
const MAP_X = map(false, "rgb(255,128,128)", "rgb(0,128,128)");
|
||||
const MAP_Y = map(true, "rgb(128,255,128)", "rgb(128,0,128)");
|
||||
---
|
||||
|
||||
{/*
|
||||
이 섹션은 한동안 "필터로 재질 만들기" 였다 — 추상 사각형에 그레인·굴절·듀오톤.
|
||||
화면에서 아무 말도 하지 않았다. 필터가 실제로 값을 하는 자리는 질감이 아니라
|
||||
**실무에서 반복되는 네 가지 수작업**이고, 넷 다 이 스킬의 프리플라이트 항목이다.
|
||||
왼쪽이 문제, 오른쪽이 같은 소재에 선언 하나만 얹은 것이다.
|
||||
*/}
|
||||
<section class="section materials has-bg" aria-labelledby="mat-h">
|
||||
<BgPhoto variant="refraction" mode="fixed" opacity={0.9} />
|
||||
<p class="eyebrow reveal">{c.eyebrow}</p>
|
||||
<h2 id="mat-h" class="reveal">{c.h2}</h2>
|
||||
<p class="lead mat-lead reveal">{c.lead}</p>
|
||||
|
||||
<div class="full stage glass">
|
||||
<span class="rim" aria-hidden="true"></span>
|
||||
<div class="stage-fallback" aria-hidden="true"></div>
|
||||
{/* GPU 가 만드는 배경. WebGL 이 없으면 위 그라디언트가 그대로 결과물이다 */}
|
||||
<canvas id="mat-canvas" class="stage-canvas" aria-hidden="true"></canvas>
|
||||
|
||||
<ol role="list" class="fdemos">
|
||||
{
|
||||
c.demos.map((d, i) => (
|
||||
<li class="fdemo reveal" style={`--reveal-delay:${i * 70}ms`}>
|
||||
<h3 class="fd-name">{d.name}</h3>
|
||||
|
||||
<div class="fd-pair">
|
||||
{[false, true].map((on) => (
|
||||
<figure class="fd-side">
|
||||
<FilterArt kind={d.id} on={on} />
|
||||
<figcaption class:list={["fd-tag", "mono", on ? "is-good" : "is-bad"]}>
|
||||
{on ? d.afterLabel : d.beforeLabel}
|
||||
</figcaption>
|
||||
</figure>
|
||||
))}
|
||||
</div>
|
||||
|
||||
<div class="fd-text">
|
||||
<p class="fd-problem">{d.problem}</p>
|
||||
<p class="fd-how muted">{d.how}</p>
|
||||
<p class="fd-verdict mono">{d.verdict}</p>
|
||||
</div>
|
||||
</li>
|
||||
))
|
||||
}
|
||||
</ol>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
{/*
|
||||
필터 정의. 화면에 그려지지 않고 참조만 된다.
|
||||
|
||||
전부 color-interpolation-filters 를 명시한다. 기본값은 linearRGB 인데,
|
||||
블렌드와 합성이 씻겨 보인다 — 대부분 sRGB 가 맞다.
|
||||
단 하나, 색각 시뮬레이션은 반대다. 색각 변환은 물리적인 빛의 혼합이라
|
||||
선형 공간에서 계산해야 실제로 그 사람이 보는 색이 나온다.
|
||||
*/}
|
||||
<svg class="visually-hidden" aria-hidden="true" focusable="false">
|
||||
<defs>
|
||||
<!--
|
||||
글자 모양대로 생기는 스크림.
|
||||
박스를 그리는 대신 알파를 부풀려 그 모양만 채운다.
|
||||
영역을 넉넉히 잡지 않으면 부풀린 만큼 가장자리가 잘린다.
|
||||
-->
|
||||
<filter id="f-scrim" color-interpolation-filters="sRGB"
|
||||
x="-25%" y="-60%" width="150%" height="220%">
|
||||
<feMorphology in="SourceAlpha" operator="dilate" radius="4" result="fat" />
|
||||
<feGaussianBlur in="fat" stdDeviation="3.5" result="soft" />
|
||||
<!-- 블러가 알파를 옅게 만든다. 다시 세우지 않으면 스크림이 비쳐서
|
||||
대비가 3.1:1 에서 멈춘다 — 실측으로 확인하고 올린 값이다 -->
|
||||
<feComponentTransfer in="soft" result="dense">
|
||||
<feFuncA type="linear" slope="4.4" />
|
||||
</feComponentTransfer>
|
||||
<feFlood flood-color="#04100f" flood-opacity="1" result="ink" />
|
||||
<feComposite in="ink" in2="dense" operator="in" result="scrim" />
|
||||
<feMerge>
|
||||
<feMergeNode in="scrim" />
|
||||
<feMergeNode in="SourceGraphic" />
|
||||
</feMerge>
|
||||
</filter>
|
||||
|
||||
<!--
|
||||
적록색약(2형) 시뮬레이션. Brettel–Viénot–Mollon 계열 근사 행렬.
|
||||
여기만 linearRGB 다 — sRGB 로 돌리면 감마가 섞여 실제보다 덜 심하게 보인다.
|
||||
-->
|
||||
<filter id="f-deuter" color-interpolation-filters="linearRGB">
|
||||
<feColorMatrix type="matrix"
|
||||
values="0.625 0.375 0 0 0
|
||||
0.700 0.300 0 0 0
|
||||
0 0.300 0.700 0 0
|
||||
0 0 0 1 0" />
|
||||
</filter>
|
||||
|
||||
<!--
|
||||
구이. 커뮤니티에서 가장 많이 만들어지는 필터이고, 값 두 개가 전부다.
|
||||
stdDeviation 이 얼마나 멀리서부터 붙을지를, 알파 기울기(18)가
|
||||
얼마나 단단하게 잘릴지를 정한다. 기울기를 낮추면 흐릿한 젤리가 된다.
|
||||
마지막 atop 이 없으면 블러된 헤일로가 남는다.
|
||||
-->
|
||||
<filter id="f-goo" color-interpolation-filters="sRGB"
|
||||
x="-20%" y="-40%" width="140%" height="180%">
|
||||
<feGaussianBlur in="SourceGraphic" stdDeviation="10" result="blur" />
|
||||
<feColorMatrix in="blur" type="matrix" result="goo"
|
||||
values="1 0 0 0 0
|
||||
0 1 0 0 0
|
||||
0 0 1 0 0
|
||||
0 0 0 18 -7" />
|
||||
<feComposite in="SourceGraphic" in2="goo" operator="atop" />
|
||||
</filter>
|
||||
|
||||
|
||||
<!--
|
||||
리퀴드 글래스. 변위 지도는 **노이즈가 아니다** — 유리는 무작위로 휘지 않고
|
||||
가장자리에서 안쪽으로 휜다. feTurbulence 로 만들면 지도가 중립값(128)으로
|
||||
수렴해 scale 을 아무리 키워도 아무 일도 안 일어난다(실측: 채널차 1.66).
|
||||
|
||||
R 채널이 X, G 채널이 Y 이동량이고 128 이 "움직이지 마라" 다.
|
||||
한 장의 그라디언트로 R 과 G 를 따로 만들 수 없으니, 지도 두 장을 놓고
|
||||
displacement 를 두 번 건다. 안 쓰는 축은 B(=128 고정)를 물려 0 으로 만든다.
|
||||
|
||||
feImage 의 width/height 는 요소 크기와 같아야 한다 — 자동으로 안 맞춰준다.
|
||||
그래서 이 패널만 크기를 고정해 뒀다.
|
||||
-->
|
||||
<filter id="f-lens" color-interpolation-filters="sRGB"
|
||||
x="0" y="0" width="100%" height="100%">
|
||||
<feImage href={MAP_X} x="0" y="0" width="216" height="72" result="mx" />
|
||||
<feDisplacementMap in="SourceGraphic" in2="mx" scale="30"
|
||||
xChannelSelector="R" yChannelSelector="B" result="dx" />
|
||||
<feImage href={MAP_Y} x="0" y="0" width="216" height="72" result="my" />
|
||||
<feDisplacementMap in="dx" in2="my" scale="30"
|
||||
xChannelSelector="B" yChannelSelector="G" />
|
||||
</filter>
|
||||
</defs>
|
||||
</svg>
|
||||
|
||||
<style>
|
||||
.mat-lead { margin-bottom: var(--space-6); max-width: var(--measure); }
|
||||
|
||||
.stage {
|
||||
position: relative;
|
||||
max-width: 1180px;
|
||||
margin-inline: auto;
|
||||
/* --wide-pad 는 페이지 그리드의 바깥 칼럼을 정의하는 토큰이다(최대 10rem).
|
||||
여기에 그대로 쓰면 1440px 화면에서 좌우 160px 씩, 폭 320px 이 사라진다.
|
||||
그만큼 오른쪽 설명 칸이 170px 로 줄어 여덟 자마다 줄이 바뀌었다. */
|
||||
padding: var(--space-6);
|
||||
border-radius: var(--radius-frame);
|
||||
overflow: hidden;
|
||||
isolation: isolate;
|
||||
}
|
||||
.stage-fallback,
|
||||
.stage-canvas {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: -1;
|
||||
}
|
||||
.stage-fallback {
|
||||
background:
|
||||
radial-gradient(60% 70% at 22% 20%,
|
||||
color-mix(in oklab, var(--accent) 16%, transparent), transparent 70%),
|
||||
radial-gradient(56% 64% at 80% 76%,
|
||||
color-mix(in oklab, var(--glow-2) 14%, transparent), transparent 68%);
|
||||
}
|
||||
.stage-canvas { opacity: 0; transition: opacity 1s var(--ease-soft); }
|
||||
.stage-canvas.is-live { opacity: 0.55; }
|
||||
|
||||
.fdemos {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
display: grid;
|
||||
gap: var(--space-6);
|
||||
}
|
||||
.fdemo + .fdemo { border-top: 1px solid var(--line); padding-top: var(--space-6); }
|
||||
|
||||
/* 데모와 설명을 세로로 쌓으면 한 항목이 320px 을 먹는다.
|
||||
넷이면 섹션이 3.1 화면 — 파이프라인 설명보다 길어졌다.
|
||||
그림은 왼쪽, 말은 오른쪽에 두면 같은 내용이 절반 높이에 들어간다. */
|
||||
.fdemo {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 584px) minmax(0, 1fr);
|
||||
column-gap: var(--space-6);
|
||||
align-items: start;
|
||||
}
|
||||
.fd-name {
|
||||
grid-column: 1 / -1;
|
||||
font-size: var(--step-1);
|
||||
margin-bottom: var(--space-4);
|
||||
}
|
||||
.fd-problem { color: var(--ink-muted); }
|
||||
|
||||
.fd-pair {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(2, minmax(0, 280px));
|
||||
gap: var(--space-3);
|
||||
}
|
||||
.fd-side { margin: 0; }
|
||||
.fd-tag {
|
||||
margin: var(--space-2) 0 0;
|
||||
font-size: var(--mono-size);
|
||||
letter-spacing: 0;
|
||||
}
|
||||
.is-bad { color: var(--ink-muted); }
|
||||
.is-good { color: var(--accent); }
|
||||
|
||||
.fd-text > * + * { margin-top: var(--space-3); }
|
||||
.fd-verdict {
|
||||
margin: var(--space-2) 0 0;
|
||||
font-size: var(--mono-size);
|
||||
color: var(--accent);
|
||||
}
|
||||
|
||||
@media (max-width: 1080px) {
|
||||
.fdemo { grid-template-columns: 1fr; row-gap: var(--space-4); }
|
||||
}
|
||||
@media (max-width: 720px) {
|
||||
.fd-pair { grid-template-columns: 1fr; }
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,120 +0,0 @@
|
|||
---
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props { c: Content["metrics"]; }
|
||||
const { c } = Astro.props;
|
||||
const feature = c.items.filter((m) => m.feature);
|
||||
const rest = c.items.filter((m) => !m.feature);
|
||||
---
|
||||
|
||||
{/*
|
||||
레이아웃 패밀리: 수치 조판.
|
||||
카드에 담지 않는다. 숫자가 크기와 정렬선으로 스스로 위계를 만든다.
|
||||
카드는 elevation 이 진짜 위계를 나를 때만 쓴다는 규칙을 여기서 지킨다.
|
||||
*/}
|
||||
{/*
|
||||
이 섹션에는 패럴랙스를 넣지 않는다. 빠뜨린 것이 아니라 결정이다.
|
||||
|
||||
여기가 이 페이지의 수치를 공개하는 자리다. 숫자가 스크롤에 따라
|
||||
흔들리면 그 값도 흔들리는 것처럼 읽힌다. 계기판의 바늘은 떨지 않는다.
|
||||
움직임이 의미를 만드는 자리가 있으면, 움직이지 않는 것이 의미인 자리도 있다.
|
||||
*/}
|
||||
<section id="metrics" class="section metrics" aria-labelledby="metrics-h">
|
||||
<div class="head">
|
||||
<p class="eyebrow reveal">{c.eyebrow}</p>
|
||||
<h2 id="metrics-h" class="reveal">{c.h2}</h2>
|
||||
</div>
|
||||
<p class="lead metrics-lead reveal">{c.lead}</p>
|
||||
|
||||
<div class="full figures">
|
||||
{
|
||||
feature.map((m, i) => (
|
||||
<div class="fig fig-lead reveal" style={`--reveal-delay:${i * 80}ms`}>
|
||||
<span class="fig-value nums">{m.value}</span>
|
||||
<span class="fig-label">{m.label}</span>
|
||||
<span class="fig-note muted">{m.note}</span>
|
||||
</div>
|
||||
))
|
||||
}
|
||||
|
||||
<dl class="fig-rest">
|
||||
{
|
||||
rest.map((m, i) => (
|
||||
<div class="row reveal" style={`--reveal-delay:${(i + 2) * 50}ms`}>
|
||||
<dt>{m.label}</dt>
|
||||
<dd class="nums">{m.value}</dd>
|
||||
<dd class="row-note muted">{m.note}</dd>
|
||||
</div>
|
||||
))
|
||||
}
|
||||
</dl>
|
||||
</div>
|
||||
|
||||
<p class="caveat muted reveal">{c.caveat}</p>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
.metrics-lead { margin-bottom: var(--space-7); max-width: 30em; }
|
||||
|
||||
.figures {
|
||||
max-width: 1180px;
|
||||
margin-inline: auto;
|
||||
padding-inline: var(--gutter);
|
||||
display: grid;
|
||||
/* 비대칭. 큰 수치 둘이 왼쪽을 차지하고 나머지는 오른쪽 여백에 흐른다 */
|
||||
grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
|
||||
column-gap: var(--space-7);
|
||||
row-gap: var(--space-6);
|
||||
align-items: start;
|
||||
}
|
||||
|
||||
.fig-lead { display: grid; gap: var(--space-1); }
|
||||
.fig-lead:nth-child(2) {
|
||||
/* 두 번째 큰 수치는 한 칸 내려앉는다 */
|
||||
margin-top: var(--space-6);
|
||||
}
|
||||
.fig-value {
|
||||
font-size: clamp(3.4rem, 2rem + 5vw, 6rem);
|
||||
line-height: 0.92;
|
||||
font-weight: var(--weight-strong);
|
||||
letter-spacing: -0.04em;
|
||||
color: var(--accent);
|
||||
}
|
||||
.fig-label { font-size: var(--step-1); font-weight: var(--weight-medium); margin-top: var(--space-2); }
|
||||
.fig-note { font-size: var(--step-0); max-width: 22em; }
|
||||
|
||||
/* 나머지 수치는 오른쪽 열에서 두 칸을 세로로 이어 쓴다 */
|
||||
.fig-rest {
|
||||
grid-column: 2;
|
||||
grid-row: 1 / span 2;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
align-content: start;
|
||||
}
|
||||
.row {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) auto;
|
||||
column-gap: var(--space-4);
|
||||
align-items: baseline;
|
||||
padding-block: var(--space-3);
|
||||
border-top: 1px solid var(--line);
|
||||
}
|
||||
.row:last-child { border-bottom: 1px solid var(--line); }
|
||||
dt { font-weight: var(--weight-medium); }
|
||||
dd { margin: 0; }
|
||||
dd.nums { font-size: var(--step-1); color: var(--accent); justify-self: end; }
|
||||
.row-note {
|
||||
grid-column: 1 / -1;
|
||||
font-size: var(--step-0);
|
||||
margin-top: var(--space-1);
|
||||
max-width: 32em;
|
||||
}
|
||||
|
||||
.caveat { margin-top: var(--space-6); font-size: var(--step-0); max-width: 34em; }
|
||||
|
||||
@media (max-width: 860px) {
|
||||
.figures { grid-template-columns: 1fr; }
|
||||
.fig-rest { grid-column: 1; grid-row: auto; }
|
||||
.fig-lead:nth-child(2) { margin-top: 0; }
|
||||
}
|
||||
</style>
|
||||
650
apps/site/src/components/OutputSpecimens.astro
Normal file
650
apps/site/src/components/OutputSpecimens.astro
Normal file
|
|
@ -0,0 +1,650 @@
|
|||
---
|
||||
interface Props {
|
||||
lang?: "ko" | "en";
|
||||
}
|
||||
|
||||
const { lang = "ko" } = Astro.props;
|
||||
const suffix = lang === "en" ? "en" : "ko";
|
||||
const copy = lang === "en"
|
||||
? {
|
||||
title: "Three designpaca output specimens",
|
||||
direction: {
|
||||
name: "Direction",
|
||||
axes: ["Structure", "Tone", "Detail"],
|
||||
statement: "Evidence converges into one visual position.",
|
||||
note: "References are separated by role before their decisions are combined.",
|
||||
},
|
||||
tokens: {
|
||||
name: "Tokens & type",
|
||||
specimen: "Aa",
|
||||
koreanSpecimen: "가",
|
||||
roles: ["Surface", "Ink", "Signal"],
|
||||
values: ["--surface", "--ink", "--accent"],
|
||||
note: "Type, color roles, and spacing become reusable constraints.",
|
||||
},
|
||||
proof: {
|
||||
name: "Verification contract",
|
||||
checks: ["Line count", "Content inset", "Contrast", "Keyboard path"],
|
||||
note: "The same rules are measured at narrow, medium, and wide widths before completion.",
|
||||
},
|
||||
}
|
||||
: {
|
||||
title: "디자인파카 결과 표본 세 가지",
|
||||
direction: {
|
||||
name: "방향 결정",
|
||||
axes: ["구조", "분위기", "디테일"],
|
||||
statement: "서로 다른 근거가 하나의 시각 방향으로 모입니다.",
|
||||
note: "레퍼런스를 역할별로 분리한 뒤, 필요한 결정만 한 방향으로 결합합니다.",
|
||||
},
|
||||
tokens: {
|
||||
name: "토큰과 조판",
|
||||
specimen: "Aa",
|
||||
koreanSpecimen: "가",
|
||||
roles: ["바탕", "본문", "신호"],
|
||||
values: ["--surface", "--ink", "--accent"],
|
||||
note: "글자, 색의 역할, 간격을 다시 쓸 수 있는 제약으로 정리합니다.",
|
||||
},
|
||||
proof: {
|
||||
name: "검사 계약",
|
||||
checks: ["제목 줄 수", "콘텐츠 여백", "색 대비", "키보드 경로"],
|
||||
note: "완료 전에 같은 기준을 좁은 화면, 중간 화면, 넓은 화면에서 실제 수치로 검사합니다.",
|
||||
},
|
||||
};
|
||||
---
|
||||
|
||||
<div class="output-specimens" role="group" aria-labelledby={`specimens-title-${suffix}`}>
|
||||
<h3 id={`specimens-title-${suffix}`} class="visually-hidden">{copy.title}</h3>
|
||||
|
||||
<article class="specimen specimen-direction" aria-labelledby={`direction-title-${suffix}`}>
|
||||
<header class="specimen-head">
|
||||
<span class="specimen-index nums" aria-hidden="true">01</span>
|
||||
<h3 id={`direction-title-${suffix}`}>{copy.direction.name}</h3>
|
||||
</header>
|
||||
|
||||
<div class="direction-stage">
|
||||
<svg viewBox="0 0 760 380" aria-hidden="true" preserveAspectRatio="none">
|
||||
<path class="direction-field" d="M42 320 242 56l241 86 234 162-337 44Z" />
|
||||
<path class="direction-field direction-field-inner" d="m130 295 134-177 190 68 157 109-231 30Z" />
|
||||
<path class="direction-axis" d="M42 320 380 348 242 56m138 292 337-44M380 348 483 142" />
|
||||
<path class="direction-vector" d="m194 275 186 73 175-99" />
|
||||
<circle class="direction-node" cx="194" cy="275" r="7" />
|
||||
<circle class="direction-node" cx="380" cy="348" r="7" />
|
||||
<circle class="direction-node" cx="555" cy="249" r="7" />
|
||||
</svg>
|
||||
|
||||
<ol class="direction-axes">
|
||||
{copy.direction.axes.map((axis, index) => (
|
||||
<li class={`direction-axis-label direction-axis-${index + 1}`}>
|
||||
<span class="nums" aria-hidden="true">0{index + 1}</span>
|
||||
<span>{axis}</span>
|
||||
</li>
|
||||
))}
|
||||
</ol>
|
||||
|
||||
<p class="direction-statement">{copy.direction.statement}</p>
|
||||
</div>
|
||||
<p class="specimen-note">{copy.direction.note}</p>
|
||||
</article>
|
||||
|
||||
<article class="specimen specimen-tokens" aria-labelledby={`tokens-title-${suffix}`}>
|
||||
<header class="specimen-head">
|
||||
<span class="specimen-index nums" aria-hidden="true">02</span>
|
||||
<h3 id={`tokens-title-${suffix}`}>{copy.tokens.name}</h3>
|
||||
</header>
|
||||
|
||||
<div class="type-stage">
|
||||
<div class="type-glyphs" role="img" aria-label={`${copy.tokens.specimen} ${copy.tokens.koreanSpecimen}`}>
|
||||
<span aria-hidden="true">{copy.tokens.specimen}</span>
|
||||
<span aria-hidden="true">{copy.tokens.koreanSpecimen}</span>
|
||||
</div>
|
||||
|
||||
<div class="type-baselines" aria-hidden="true">
|
||||
<span></span><span></span><span></span><span></span>
|
||||
</div>
|
||||
|
||||
<dl class="token-register">
|
||||
{copy.tokens.roles.map((role, index) => (
|
||||
<div>
|
||||
<dt>{role}</dt>
|
||||
<dd>
|
||||
<span class={`token-sample token-sample-${index + 1}`} aria-hidden="true"></span>
|
||||
<span class="token-value nums">{copy.tokens.values[index]}</span>
|
||||
</dd>
|
||||
</div>
|
||||
))}
|
||||
</dl>
|
||||
</div>
|
||||
<p class="specimen-note">{copy.tokens.note}</p>
|
||||
</article>
|
||||
|
||||
<article class="specimen specimen-proof" aria-labelledby={`proof-title-${suffix}`}>
|
||||
<header class="specimen-head">
|
||||
<span class="specimen-index nums" aria-hidden="true">03</span>
|
||||
<h3 id={`proof-title-${suffix}`}>{copy.proof.name}</h3>
|
||||
</header>
|
||||
|
||||
<div class="proof-stage">
|
||||
<div class="viewport-family" aria-hidden="true">
|
||||
<div class="viewport viewport-narrow">
|
||||
<span class="viewport-size nums">320</span>
|
||||
<i></i><i></i><i></i>
|
||||
</div>
|
||||
<div class="viewport viewport-medium">
|
||||
<span class="viewport-size nums">768</span>
|
||||
<i></i><i></i><i></i>
|
||||
</div>
|
||||
<div class="viewport viewport-wide">
|
||||
<span class="viewport-size nums">1440</span>
|
||||
<i></i><i></i><i></i>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ol class="check-register">
|
||||
{copy.proof.checks.map((check, index) => (
|
||||
<li>
|
||||
<span class="check-index nums" aria-hidden="true">{String(index + 1).padStart(2, "0")}</span>
|
||||
<span>{check}</span>
|
||||
<svg viewBox="0 0 18 18" width="18" height="18" aria-hidden="true">
|
||||
<path d="M3 9h12M12 6l3 3-3 3" />
|
||||
</svg>
|
||||
</li>
|
||||
))}
|
||||
</ol>
|
||||
</div>
|
||||
<p class="specimen-note">{copy.proof.note}</p>
|
||||
</article>
|
||||
</div>
|
||||
|
||||
<style>
|
||||
.visually-hidden {
|
||||
position: absolute;
|
||||
width: 1px;
|
||||
height: 1px;
|
||||
padding: 0;
|
||||
margin: -1px;
|
||||
overflow: hidden;
|
||||
clip: rect(0, 0, 0, 0);
|
||||
white-space: nowrap;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.output-specimens {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(12, minmax(0, 1fr));
|
||||
gap: var(--space-8) var(--space-5);
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.specimen {
|
||||
min-width: 0;
|
||||
border-top: var(--line-width) solid var(--line-strong);
|
||||
}
|
||||
|
||||
.specimen-direction { grid-column: 1 / span 8; }
|
||||
.specimen-tokens { grid-column: 9 / -1; margin-top: var(--space-8); }
|
||||
.specimen-proof { grid-column: 3 / -1; }
|
||||
|
||||
.specimen-head {
|
||||
min-height: var(--control-h);
|
||||
display: grid;
|
||||
grid-template-columns: 2.5rem minmax(0, 1fr);
|
||||
gap: var(--space-3);
|
||||
align-items: center;
|
||||
border-bottom: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.specimen-head h3 {
|
||||
font-size: var(--step-0);
|
||||
font-weight: var(--weight-medium);
|
||||
}
|
||||
|
||||
.specimen-index {
|
||||
color: var(--accent);
|
||||
font-size: var(--mono-size);
|
||||
}
|
||||
|
||||
.specimen-note {
|
||||
max-width: 38rem;
|
||||
margin-top: var(--space-4);
|
||||
color: var(--ink-muted);
|
||||
font-size: var(--step--1);
|
||||
}
|
||||
|
||||
.direction-stage {
|
||||
position: relative;
|
||||
min-height: 24rem;
|
||||
overflow: clip;
|
||||
background: var(--surface-soft);
|
||||
border-bottom: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.direction-stage > svg {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.direction-field {
|
||||
fill: var(--surface-raised);
|
||||
stroke: var(--line-strong);
|
||||
stroke-width: 1;
|
||||
vector-effect: non-scaling-stroke;
|
||||
}
|
||||
|
||||
.direction-field-inner {
|
||||
fill: var(--surface);
|
||||
stroke: var(--line);
|
||||
}
|
||||
|
||||
.direction-axis {
|
||||
fill: none;
|
||||
stroke: var(--line-strong);
|
||||
stroke-width: 1;
|
||||
stroke-dasharray: 2 5;
|
||||
vector-effect: non-scaling-stroke;
|
||||
}
|
||||
|
||||
.direction-vector {
|
||||
fill: none;
|
||||
stroke: var(--accent);
|
||||
stroke-width: 2.2;
|
||||
vector-effect: non-scaling-stroke;
|
||||
}
|
||||
|
||||
.direction-node {
|
||||
fill: var(--accent);
|
||||
stroke: var(--surface-raised);
|
||||
stroke-width: 3;
|
||||
vector-effect: non-scaling-stroke;
|
||||
}
|
||||
|
||||
.direction-axes {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.direction-axis-label {
|
||||
position: absolute;
|
||||
display: grid;
|
||||
gap: var(--space-1);
|
||||
font-size: var(--step--1);
|
||||
line-height: 1.3;
|
||||
}
|
||||
|
||||
.direction-axis-label .nums { color: var(--ink-muted); font-size: var(--mono-size); }
|
||||
.direction-axis-1 { left: 5%; bottom: 7%; }
|
||||
.direction-axis-2 { left: 30%; top: 7%; }
|
||||
.direction-axis-3 { right: 5%; bottom: 12%; text-align: right; }
|
||||
|
||||
.direction-statement {
|
||||
position: absolute;
|
||||
left: 48%;
|
||||
top: 48%;
|
||||
width: min(43%, 18rem);
|
||||
color: var(--ink);
|
||||
font-size: var(--step-1);
|
||||
line-height: 1.38;
|
||||
text-wrap: balance;
|
||||
}
|
||||
|
||||
.type-stage {
|
||||
position: relative;
|
||||
min-height: 29rem;
|
||||
padding: var(--space-5);
|
||||
overflow: clip;
|
||||
background: var(--surface-inverse);
|
||||
color: var(--ink-inverse);
|
||||
border-bottom: var(--line-width) solid var(--line-strong);
|
||||
}
|
||||
|
||||
.type-glyphs {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) auto;
|
||||
align-items: baseline;
|
||||
gap: var(--space-2);
|
||||
padding-bottom: var(--space-4);
|
||||
border-bottom: var(--line-width) solid var(--line-inverse);
|
||||
}
|
||||
|
||||
.type-glyphs span:first-child {
|
||||
font-size: clamp(4rem, 8vw, 7rem);
|
||||
font-weight: var(--weight-body);
|
||||
line-height: 0.9;
|
||||
letter-spacing: -0.055em;
|
||||
}
|
||||
|
||||
.type-glyphs span:last-child {
|
||||
color: var(--accent);
|
||||
font-size: clamp(2.25rem, 5vw, 4rem);
|
||||
font-weight: var(--weight-medium);
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
.type-baselines {
|
||||
position: absolute;
|
||||
inset: var(--space-5);
|
||||
display: grid;
|
||||
grid-template-rows: repeat(4, 1fr);
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.type-baselines span { border-bottom: var(--line-width) solid var(--line-inverse); opacity: 0.38; }
|
||||
|
||||
.token-register {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
margin-top: var(--space-8);
|
||||
}
|
||||
|
||||
.token-register > div {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) auto;
|
||||
gap: var(--space-3);
|
||||
align-items: center;
|
||||
min-height: var(--control-h);
|
||||
border-top: var(--line-width) solid var(--line-inverse);
|
||||
}
|
||||
|
||||
.token-register dt { color: var(--ink-muted-inverse); font-size: var(--step--1); }
|
||||
.token-register dd { display: flex; align-items: center; gap: var(--space-2); margin: 0; }
|
||||
|
||||
.token-sample {
|
||||
width: 2.75rem;
|
||||
height: 0.5rem;
|
||||
border: var(--line-width) solid var(--line-inverse);
|
||||
}
|
||||
|
||||
.token-sample-1 { background: var(--surface-raised); }
|
||||
.token-sample-2 { background: var(--ink-inverse); }
|
||||
.token-sample-3 { background: var(--accent); }
|
||||
.token-value { color: var(--ink-muted-inverse); font-size: var(--mono-size); }
|
||||
|
||||
.proof-stage {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1.25fr) minmax(15rem, 0.75fr);
|
||||
min-height: 22rem;
|
||||
background: var(--surface-raised);
|
||||
border-bottom: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.viewport-family {
|
||||
position: relative;
|
||||
min-width: 0;
|
||||
padding: var(--space-7) var(--space-5);
|
||||
border-right: var(--line-width) solid var(--line);
|
||||
}
|
||||
|
||||
.viewport {
|
||||
position: absolute;
|
||||
bottom: var(--space-7);
|
||||
display: grid;
|
||||
grid-template-rows: auto repeat(3, 1fr);
|
||||
gap: var(--space-2);
|
||||
padding: var(--space-3);
|
||||
border: var(--line-width) solid var(--ink);
|
||||
background: var(--surface);
|
||||
}
|
||||
|
||||
.viewport i {
|
||||
display: block;
|
||||
border-top: var(--line-width) solid var(--line-strong);
|
||||
}
|
||||
|
||||
.viewport i:nth-of-type(2) { width: 72%; }
|
||||
.viewport i:nth-of-type(3) { width: 46%; }
|
||||
.viewport-size { color: var(--ink-muted); font-size: var(--mono-size); }
|
||||
|
||||
.viewport-narrow { left: 8%; width: 18%; height: 48%; z-index: 3; }
|
||||
.viewport-medium { left: 25%; width: 34%; height: 64%; z-index: 2; }
|
||||
.viewport-wide { right: 7%; width: 55%; height: 80%; z-index: 1; }
|
||||
|
||||
.check-register {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: var(--space-5);
|
||||
align-self: stretch;
|
||||
display: grid;
|
||||
align-content: center;
|
||||
}
|
||||
|
||||
.check-register li {
|
||||
min-height: var(--control-h);
|
||||
display: grid;
|
||||
grid-template-columns: 2rem minmax(0, 1fr) auto;
|
||||
gap: var(--space-3);
|
||||
align-items: center;
|
||||
border-bottom: var(--line-width) solid var(--line);
|
||||
font-size: var(--step--1);
|
||||
}
|
||||
|
||||
.check-index { color: var(--ink-muted); font-size: var(--mono-size); }
|
||||
|
||||
.check-register svg {
|
||||
fill: none;
|
||||
stroke: var(--accent);
|
||||
stroke-width: 1.8;
|
||||
stroke-linecap: square;
|
||||
stroke-linejoin: miter;
|
||||
}
|
||||
|
||||
@supports (animation-timeline: view()) {
|
||||
.specimen-direction {
|
||||
view-timeline-name: --direction-specimen;
|
||||
view-timeline-axis: block;
|
||||
}
|
||||
|
||||
.specimen-tokens {
|
||||
view-timeline-name: --tokens-specimen;
|
||||
view-timeline-axis: block;
|
||||
}
|
||||
|
||||
.specimen-proof {
|
||||
view-timeline-name: --proof-specimen;
|
||||
view-timeline-axis: block;
|
||||
}
|
||||
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.direction-field-inner {
|
||||
animation: direction-plane-in linear both;
|
||||
animation-timeline: --direction-specimen;
|
||||
animation-range: entry 8% cover 30%;
|
||||
transform-box: fill-box;
|
||||
transform-origin: center;
|
||||
}
|
||||
|
||||
.direction-vector,
|
||||
.direction-node {
|
||||
--direction-shift-x: calc(var(--space-3) * -1);
|
||||
animation: direction-lock linear both;
|
||||
animation-timeline: --direction-specimen;
|
||||
animation-range: entry 18% cover 38%;
|
||||
transform-box: fill-box;
|
||||
transform-origin: center;
|
||||
}
|
||||
|
||||
.type-glyphs {
|
||||
animation: type-register linear both;
|
||||
animation-timeline: --tokens-specimen;
|
||||
animation-range: entry 8% cover 27%;
|
||||
}
|
||||
|
||||
.token-sample {
|
||||
animation: token-resolve linear both;
|
||||
animation-timeline: --tokens-specimen;
|
||||
transform-origin: left center;
|
||||
}
|
||||
|
||||
.token-register > div:nth-child(1) .token-sample {
|
||||
animation-range: entry 22% cover 34%;
|
||||
}
|
||||
|
||||
.token-register > div:nth-child(2) .token-sample {
|
||||
animation-range: entry 26% cover 38%;
|
||||
}
|
||||
|
||||
.token-register > div:nth-child(3) .token-sample {
|
||||
animation-range: entry 30% cover 42%;
|
||||
}
|
||||
|
||||
.viewport {
|
||||
animation: frame-resolve linear both;
|
||||
animation-timeline: --proof-specimen;
|
||||
animation-range: entry 8% cover 32%;
|
||||
}
|
||||
|
||||
.viewport-narrow {
|
||||
--frame-x: var(--space-6);
|
||||
--frame-y: var(--space-3);
|
||||
}
|
||||
|
||||
.viewport-medium {
|
||||
--frame-x: var(--space-4);
|
||||
--frame-y: var(--space-2);
|
||||
}
|
||||
|
||||
.viewport-wide {
|
||||
--frame-x: 0;
|
||||
--frame-y: 0;
|
||||
}
|
||||
|
||||
.check-register svg {
|
||||
animation: check-pass linear both;
|
||||
animation-timeline: --proof-specimen;
|
||||
transform-box: fill-box;
|
||||
transform-origin: center;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(1) svg {
|
||||
animation-range: entry 30% cover 42%;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(2) svg {
|
||||
animation-range: entry 34% cover 46%;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(3) svg {
|
||||
animation-range: entry 38% cover 50%;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(4) svg {
|
||||
animation-range: entry 42% cover 54%;
|
||||
}
|
||||
|
||||
@keyframes direction-plane-in {
|
||||
from { opacity: 0.42; translate: 0 var(--space-3); }
|
||||
to { opacity: 1; translate: 0 0; }
|
||||
}
|
||||
|
||||
@keyframes direction-lock {
|
||||
from { opacity: 0; translate: var(--direction-shift-x) var(--space-1); }
|
||||
to { opacity: 1; translate: 0 0; }
|
||||
}
|
||||
|
||||
@keyframes type-register {
|
||||
from { opacity: 0.35; translate: 0 var(--space-3); }
|
||||
to { opacity: 1; translate: 0 0; }
|
||||
}
|
||||
|
||||
@keyframes token-resolve {
|
||||
from { opacity: 0.35; scale: 0.18 1; }
|
||||
to { opacity: 1; scale: 1 1; }
|
||||
}
|
||||
|
||||
@keyframes frame-resolve {
|
||||
from { translate: var(--frame-x) var(--frame-y); }
|
||||
to { translate: 0 0; }
|
||||
}
|
||||
|
||||
@keyframes check-pass {
|
||||
from { opacity: 0.2; translate: calc(var(--space-2) * -1) 0; }
|
||||
to { opacity: 1; translate: 0 0; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 62rem) {
|
||||
.specimen-direction { grid-column: 1 / span 7; }
|
||||
.specimen-tokens { grid-column: 8 / -1; }
|
||||
.specimen-proof { grid-column: 1 / -1; }
|
||||
}
|
||||
|
||||
@media (max-width: 47.5rem) {
|
||||
.output-specimens { grid-template-columns: minmax(0, 1fr); gap: var(--space-8); }
|
||||
.specimen-direction,
|
||||
.specimen-tokens,
|
||||
.specimen-proof { grid-column: 1; margin-top: 0; }
|
||||
.direction-stage { min-height: 21rem; }
|
||||
.type-stage { min-height: 24rem; }
|
||||
.proof-stage { grid-template-columns: minmax(0, 1fr); }
|
||||
.viewport-family { min-height: 18rem; border-right: 0; border-bottom: var(--line-width) solid var(--line); }
|
||||
|
||||
@supports (animation-timeline: view()) {
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.direction-vector,
|
||||
.direction-node {
|
||||
--direction-shift-x: calc(var(--space-2) * -1);
|
||||
}
|
||||
|
||||
.viewport-narrow {
|
||||
--frame-x: var(--space-3);
|
||||
--frame-y: var(--space-2);
|
||||
}
|
||||
|
||||
.viewport-medium {
|
||||
--frame-x: var(--space-2);
|
||||
--frame-y: var(--space-1);
|
||||
}
|
||||
|
||||
.viewport {
|
||||
animation-range: entry 4% cover 28%;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(1) svg {
|
||||
animation-range: entry 26% cover 38%;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(2) svg {
|
||||
animation-range: entry 30% cover 42%;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(3) svg {
|
||||
animation-range: entry 34% cover 46%;
|
||||
}
|
||||
|
||||
.check-register li:nth-child(4) svg {
|
||||
animation-range: entry 38% cover 50%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 28rem) {
|
||||
.direction-statement { left: 39%; width: 55%; font-size: var(--step-0); }
|
||||
.direction-axis-2 { left: 25%; }
|
||||
.viewport-family { padding-inline: var(--space-3); }
|
||||
.viewport-narrow { left: 4%; }
|
||||
.viewport-medium { left: 20%; }
|
||||
.viewport-wide { right: 3%; }
|
||||
}
|
||||
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.direction-field-inner,
|
||||
.direction-vector,
|
||||
.direction-node,
|
||||
.type-glyphs,
|
||||
.token-sample,
|
||||
.viewport,
|
||||
.check-register svg {
|
||||
animation: none;
|
||||
opacity: 1;
|
||||
translate: 0 0;
|
||||
scale: 1 1;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,274 +0,0 @@
|
|||
---
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props {
|
||||
c: Content["pipeline"];
|
||||
}
|
||||
const { c } = Astro.props;
|
||||
---
|
||||
|
||||
{/*
|
||||
순서를 번호 없이 표현하는 세 층:
|
||||
① 시각 — 스파인 위의 위치가 순서를 만든다 (Beck 튜브맵)
|
||||
② 내용 — 같은 브리프가 단계마다 변해간다 (IKEA 조립 설명서)
|
||||
③ 의미 — <ol role="list"> — 화면에 번호는 없지만 보조기술은 "6개 중 n번째"로 읽는다
|
||||
role="list" 는 list-style:none 일 때 Safari/VoiceOver 가 목록 의미를 버리는 것을 되돌린다
|
||||
*/}
|
||||
<section id="pipeline" class="section has-bg" aria-labelledby="pipeline-h">
|
||||
{/* 히어로에 있던 게이트 씬을 여기로 옮겼다.
|
||||
히어로에서는 그 은유를 판독기가 자막으로 설명해야 했다 — 그림이 스스로
|
||||
말하지 못한다는 뜻이다. 여기서는 옆에 실제 여섯 단계가 적혀 있고,
|
||||
판을 통과할 때 그 단계가 켜진다. 자막이 아니라 콘텐츠가 반응한다. */}
|
||||
<div class="gate-bg" aria-hidden="true">
|
||||
<div class="gate-fallback"></div>
|
||||
<canvas id="pipeline-canvas" class="gate-canvas"></canvas>
|
||||
</div>
|
||||
{/* 제목·리드·브리프·스파인을 한 컨테이너에 담는다.
|
||||
섹션 기본 그리드에 두면 제목은 main 칼럼의 음수 마진으로 x=371,
|
||||
리드는 x=435, 스파인은 x=143 에 서서 정렬선이 셋이 된다. */}
|
||||
<div class="full spine-wrap">
|
||||
<p class="eyebrow reveal">{c.eyebrow}</p>
|
||||
<h2 id="pipeline-h" class="reveal">{c.h2}</h2>
|
||||
<p class="lead pipeline-lead reveal">{c.lead}</p>
|
||||
|
||||
<div class="brief reveal"><div class="brief-core">
|
||||
<span class="brief-label">{c.briefLabel}</span>
|
||||
<p class="brief-text">{c.brief}</p>
|
||||
</div></div>
|
||||
|
||||
<ol role="list" class="spine">
|
||||
{
|
||||
c.stages.map((s, i) => (
|
||||
<li class="stop reveal" data-stage={i}>
|
||||
<div class="stop-head">
|
||||
<h3 class="stop-name">{s.name}</h3>
|
||||
<p class="stop-does">{s.does}</p>
|
||||
</div>
|
||||
<p class:list={["stop-becomes", "par-lag", { mono: s.mono }]}>{s.becomes}</p>
|
||||
</li>
|
||||
))
|
||||
}
|
||||
</ol>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
/* 컨테이너는 넓어도 읽는 것은 measure 안에 둔다 */
|
||||
.pipeline-lead {
|
||||
margin-bottom: var(--space-5);
|
||||
max-width: var(--measure);
|
||||
}
|
||||
.brief { max-width: var(--measure); }
|
||||
#pipeline-h { max-width: 24ch; }
|
||||
|
||||
/* ---- 게이트 배경 ------------------------------------------
|
||||
sticky 로 화면에 머물고 음수 마진으로 레이아웃 자리는 차지하지 않는다.
|
||||
섹션이 지나가는 동안 카메라가 판 여섯 장을 통과한다. */
|
||||
.gate-bg {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
height: 100dvh;
|
||||
/* 섹션 패딩(112px) 아래에서 시작하면 히어로 배경이 끝난 자리와
|
||||
이 캔버스 사이에 200px 짜리 검은 띠가 생긴다. 패딩만큼 끌어올린다. */
|
||||
margin-top: calc(var(--space-7) * -1);
|
||||
margin-bottom: -100dvh;
|
||||
z-index: -1;
|
||||
pointer-events: none;
|
||||
grid-column: full;
|
||||
}
|
||||
.gate-fallback,
|
||||
.gate-canvas {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: block;
|
||||
}
|
||||
.gate-fallback {
|
||||
background:
|
||||
radial-gradient(46% 54% at 28% 34%,
|
||||
color-mix(in oklab, var(--accent) 20%, transparent), transparent 70%),
|
||||
radial-gradient(42% 50% at 76% 68%,
|
||||
color-mix(in oklab, var(--glow-2) 18%, transparent), transparent 68%);
|
||||
}
|
||||
/* 캔버스가 섹션 패딩 위까지 덮으면 이웃 섹션과 딱 붙어 보인다.
|
||||
위아래를 지워 여백을 되돌린다. */
|
||||
.gate-bg {
|
||||
-webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 6%, black 88%, transparent 100%);
|
||||
mask-image: linear-gradient(to bottom, transparent 0%, black 6%, black 88%, transparent 100%);
|
||||
}
|
||||
.gate-canvas { opacity: 0; transition: opacity 1s var(--ease-soft); }
|
||||
.gate-canvas.is-live { opacity: 0.7; }
|
||||
/* 세로 화면에서는 캔버스가 화면 전체를 덮는다. 같은 밝기면 본문이 묻힌다 */
|
||||
@media (max-width: 760px) {
|
||||
.gate-canvas.is-live { opacity: 0.45; }
|
||||
}
|
||||
|
||||
/* 통과한 단계가 켜진다. 3D 와 텍스트를 잇는 유일한 연결이다 */
|
||||
.stop { transition: opacity var(--dur-quick) var(--ease-out); }
|
||||
.stop.is-active .stop-name { color: var(--accent); }
|
||||
.stop.is-active::before {
|
||||
background: var(--accent);
|
||||
box-shadow: 0 0 0 4px color-mix(in oklab, var(--accent) 22%, transparent);
|
||||
}
|
||||
|
||||
/* 스파인은 페이지의 본체다. main 칼럼(561px)에 가두면
|
||||
페이지에서 가장 긴 섹션이 가장 좁아진다.
|
||||
R1(zed.dev) 실측: 컨테이너 1120px 과 전체폭이 교대한다. */
|
||||
.spine-wrap {
|
||||
max-width: 1180px;
|
||||
margin-inline: auto;
|
||||
padding-inline: var(--gutter);
|
||||
}
|
||||
|
||||
.brief { margin-bottom: var(--space-2); }
|
||||
.brief-core { padding: var(--space-4); }
|
||||
.brief-label {
|
||||
display: block;
|
||||
font-size: var(--step-0);
|
||||
letter-spacing: var(--tracking-label);
|
||||
color: var(--ink-muted);
|
||||
margin-bottom: var(--space-2);
|
||||
}
|
||||
.brief-text {
|
||||
margin: 0;
|
||||
font-size: var(--step-1);
|
||||
}
|
||||
|
||||
/* ---- 스파인 ---------------------------------------------
|
||||
선은 장식이 아니라 순서 그 자체다. 정거장의 위치가 번호를 대신한다.
|
||||
---------------------------------------------------------- */
|
||||
.spine {
|
||||
/* 정거장의 세로 리듬은 여기 한 곳에서 나온다.
|
||||
전에는 패딩이 space-6, 마커 위치가 space-4 로 각자 적혀 있어서
|
||||
원이 제목보다 24px 위에 떠 있었다. 값을 각자 쓰면 이렇게 어긋난다. */
|
||||
--stop-pad: var(--space-5);
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0 0 0 var(--space-5);
|
||||
position: relative;
|
||||
}
|
||||
.spine::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
left: 5px;
|
||||
top: var(--stop-pad);
|
||||
bottom: var(--stop-pad);
|
||||
width: 1px;
|
||||
background: var(--line-strong);
|
||||
}
|
||||
|
||||
.stop {
|
||||
position: relative;
|
||||
/* 정거장 간격이 곧 3D 게이트의 스크롤 구간이다.
|
||||
space-4(24px)로는 섹션이 1493px 밖에 안 돼 sticky 이동 거리가 593px 뿐이었다.
|
||||
섹션이 화면에 보이는 구간(2393px)의 4분의 1이라, 조금만 스크롤해도
|
||||
여섯 게이트를 다 지나쳐 버렸다.
|
||||
|
||||
space-7 까지 올렸더니 이번엔 정거장 사이가 224px 로 벌어져
|
||||
목록이 흩어져 보였다 — 여섯 개가 한 목록으로 안 읽힌다.
|
||||
읽기 간격과 스크롤 구간은 같은 손잡이가 아니다.
|
||||
간격은 읽기에 맞추고, 스크롤 구간은 스파인 뒤 여백에서 번다. */
|
||||
padding-block: var(--stop-pad);
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
|
||||
gap: var(--space-5);
|
||||
align-items: start;
|
||||
}
|
||||
.stop-head { min-width: 0; }
|
||||
.stop + .stop {
|
||||
border-top: 1px solid var(--line);
|
||||
}
|
||||
|
||||
/* 정거장 표시 — 채워진 원. 숫자가 아니다 */
|
||||
.stop::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
left: calc(var(--space-5) * -1);
|
||||
top: calc(var(--stop-pad) + 0.55em);
|
||||
width: 11px;
|
||||
height: 11px;
|
||||
border-radius: var(--radius-sm);
|
||||
background: var(--surface);
|
||||
border: 3px solid var(--accent);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.stop-name {
|
||||
font-size: var(--step-1);
|
||||
margin-bottom: var(--space-2);
|
||||
}
|
||||
.stop-does {
|
||||
color: var(--ink-muted);
|
||||
margin: 0;
|
||||
max-width: 34ch;
|
||||
}
|
||||
|
||||
/* 브리프가 이 단계에서 무엇이 됐는가 — 변화가 순서를 만든다 */
|
||||
.stop-becomes {
|
||||
margin: 0;
|
||||
padding-left: var(--space-3);
|
||||
border-left: 2px solid var(--accent);
|
||||
}
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.stop::before {
|
||||
transition: transform var(--dur-quick) var(--ease-out);
|
||||
}
|
||||
.stop:hover::before { transform: scale(1.5); }
|
||||
.stop-becomes { transition: border-color var(--dur-quick) var(--ease-out); }
|
||||
.stop:hover .stop-becomes { border-color: var(--ink); }
|
||||
}
|
||||
|
||||
.stop-becomes.mono {
|
||||
font-family: var(--font-mono);
|
||||
font-size: var(--mono-size);
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
/* 한때 여기에 padding-bottom: 62dvh 가 있었다. 게이트 진행도를 섹션 높이로
|
||||
재고 있어서, 여섯 단계를 다 돌리려면 목록 뒤에 화면 절반이 넘는 빈 공간이
|
||||
필요했다. 콘텐츠가 아니라 스크롤 연료였다.
|
||||
진행도를 목록이 화면을 지나는 구간으로 바꾸면서 그 여백이 필요 없어졌다. */
|
||||
|
||||
@media (max-width: 780px) {
|
||||
.stop {
|
||||
grid-template-columns: 1fr;
|
||||
gap: var(--space-3);
|
||||
}
|
||||
}
|
||||
|
||||
/* 스크롤 진입 페이드를 넣었다가 뺐다.
|
||||
`animation-range: entry 10% cover 22%` 로는 페이지 하단 요소가 cover 22% 에
|
||||
영영 도달하지 못해, 6개 정거장 중 뒤 3개가 opacity 0 으로 잠겼다.
|
||||
이펙트를 끄면 보이지만 켜면 사라지는 것은 폴백이 있는 것과 다르다.
|
||||
이 섹션은 페이지의 본체다. 콘텐츠를 걸고 하는 연출은 하지 않는다. */
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
// 게이트를 통과할 때 해당 단계를 켠다. 값이 바뀔 때만 DOM 을 쓴다.
|
||||
import { mountGateScene } from "../lib/gate-scene";
|
||||
|
||||
const canvas = document.getElementById("pipeline-canvas") as HTMLCanvasElement | null;
|
||||
const section = document.getElementById("pipeline");
|
||||
const spine = document.querySelector<HTMLElement>("#pipeline .spine");
|
||||
const stops = [...document.querySelectorAll<HTMLElement>("#pipeline .stop")];
|
||||
|
||||
if (canvas && section && spine && stops.length) {
|
||||
let last = -1;
|
||||
mountGateScene({
|
||||
canvas,
|
||||
accentVar: "--accent",
|
||||
glowVar: "--glow-2",
|
||||
// 캔버스는 sticky 라 rect 가 변하지 않는다.
|
||||
// 진행도는 섹션이 아니라 **정거장 목록**에서 읽는다 — 게이트가 도는 구간과
|
||||
// 읽는 구간이 같아야 목록 뒤에 스크롤용 빈 공간을 두지 않아도 된다.
|
||||
progressFrom: spine,
|
||||
onGate(index) {
|
||||
if (index === last) return;
|
||||
last = index;
|
||||
stops.forEach((el, i) => el.classList.toggle("is-active", i === index));
|
||||
},
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
|
@ -1,81 +0,0 @@
|
|||
---
|
||||
import BgPhoto from "./BgPhoto.astro";
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props { c: Content["preflight"]; }
|
||||
const { c } = Astro.props;
|
||||
---
|
||||
|
||||
{/*
|
||||
레이아웃 패밀리: 로그.
|
||||
걸린 것과 고친 것이 한 줄에서 이어진다. 상자에 담지 않는다.
|
||||
왼쪽 세로선이 로그라는 형식을 만든다.
|
||||
*/}
|
||||
<section class="section preflight has-bg" aria-labelledby="pf-h">
|
||||
<BgPhoto variant="align" mode="fixed" opacity={1} />
|
||||
<h2 id="pf-h" class="reveal">{c.h2}</h2>
|
||||
<p class="lead pf-lead reveal">{c.lead}</p>
|
||||
|
||||
<div class="full log">
|
||||
{
|
||||
c.items.map((i, idx) => (
|
||||
<article class="entry reveal par-lag" style={`--reveal-delay:${idx * 45}ms; --par-lag:${6 + idx * 2}px`}>
|
||||
<p class="caught">{i.caught}</p>
|
||||
<p class="fixed muted">{i.fixed}</p>
|
||||
</article>
|
||||
))
|
||||
}
|
||||
</div>
|
||||
|
||||
<p class="pf-note muted reveal">{c.note}</p>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
.pf-lead { margin-block: var(--space-4) var(--space-7); max-width: 30em; }
|
||||
|
||||
.log {
|
||||
max-width: 1180px;
|
||||
margin-inline: auto;
|
||||
padding-inline: var(--gutter);
|
||||
display: grid;
|
||||
}
|
||||
.entry {
|
||||
position: relative;
|
||||
padding: var(--space-4) 0 var(--space-4) var(--space-5);
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
|
||||
gap: var(--space-5);
|
||||
align-items: start;
|
||||
}
|
||||
/* 로그를 관통하는 세로선. 항목마다 상자를 두르지 않는다 */
|
||||
.entry::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
width: 1px;
|
||||
background: var(--line);
|
||||
}
|
||||
.entry:first-child::before { top: var(--space-4); }
|
||||
.entry:last-child::before { bottom: var(--space-4); }
|
||||
/* 걸린 지점을 표시하는 짧은 획 */
|
||||
.entry::after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
left: -2px;
|
||||
top: calc(var(--space-4) + 0.55em);
|
||||
width: 5px;
|
||||
height: 5px;
|
||||
border-radius: var(--radius-sm);
|
||||
background: var(--accent);
|
||||
}
|
||||
|
||||
.caught { margin: 0; font-weight: var(--weight-medium); }
|
||||
.fixed { margin: 0; font-size: var(--step-0); }
|
||||
.pf-note { margin-top: var(--space-6); font-size: var(--step-0); max-width: 34em; }
|
||||
|
||||
@media (max-width: 800px) {
|
||||
.entry { grid-template-columns: 1fr; gap: var(--space-2); }
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,62 +0,0 @@
|
|||
---
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props { c: Content["rules"]; }
|
||||
const { c } = Astro.props;
|
||||
---
|
||||
|
||||
{/*
|
||||
레이아웃 패밀리: 어긋난 목록.
|
||||
규칙은 왼쪽 정렬선에, 근거는 오른쪽으로 밀어 흘린다.
|
||||
카드도 상자도 없다. 어긋남 자체가 두 층위를 구분한다.
|
||||
*/}
|
||||
<section class="section rules" aria-labelledby="rules-h">
|
||||
<h2 id="rules-h" class="reveal">{c.h2}</h2>
|
||||
<p class="lead rules-lead reveal">{c.lead}</p>
|
||||
|
||||
<dl class="full rule-list">
|
||||
{
|
||||
c.items.map((r, i) => (
|
||||
<div class="rule reveal" style={`--reveal-delay:${i * 45}ms`}>
|
||||
<dt>{r.rule}</dt>
|
||||
<dd class="muted">{r.why}</dd>
|
||||
</div>
|
||||
))
|
||||
}
|
||||
</dl>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
.rules-lead { margin-block: var(--space-4) var(--space-7); max-width: 30em; }
|
||||
|
||||
.rule-list {
|
||||
max-width: 1180px;
|
||||
margin: 0 auto;
|
||||
padding-inline: var(--gutter);
|
||||
}
|
||||
.rule {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
|
||||
gap: var(--space-4) var(--space-6);
|
||||
padding-block: var(--space-5);
|
||||
border-top: 1px solid var(--line);
|
||||
align-items: baseline;
|
||||
}
|
||||
.rule:last-child { border-bottom: 1px solid var(--line); }
|
||||
|
||||
/* 홀수 규칙은 근거가 한 칸 더 밀려난다. 목록이 일정하게 흐르지 않는다 */
|
||||
.rule:nth-child(odd) dd { padding-left: var(--space-6); }
|
||||
|
||||
dt {
|
||||
font-size: var(--step-2);
|
||||
font-weight: var(--weight-medium);
|
||||
letter-spacing: var(--tracking-display);
|
||||
line-height: var(--leading-tight);
|
||||
}
|
||||
dd { margin: 0; font-size: var(--step-0); max-width: 34em; }
|
||||
|
||||
@media (max-width: 800px) {
|
||||
.rule { grid-template-columns: 1fr; gap: var(--space-2); }
|
||||
.rule:nth-child(odd) dd { padding-left: 0; }
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,64 +0,0 @@
|
|||
---
|
||||
interface Props {
|
||||
class?: string;
|
||||
}
|
||||
const { class: className } = Astro.props;
|
||||
---
|
||||
|
||||
<div class:list={["hero-gl-wrap", className]} aria-hidden="true">
|
||||
<div class="hero-gl-fallback"></div>
|
||||
<canvas id="showcase-gl" class="hero-gl-canvas" style="opacity: 0;"></canvas>
|
||||
<div class="hero-gl-scrim"></div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
import { boot } from "../gl/boot.ts";
|
||||
|
||||
const canvas = document.getElementById("showcase-gl") as HTMLCanvasElement | null;
|
||||
if (canvas) {
|
||||
boot(canvas, () => import("../gl/scenes/showcase-hero.ts"));
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.hero-gl-wrap {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
z-index: 0;
|
||||
pointer-events: none;
|
||||
overflow: hidden;
|
||||
mask-image: linear-gradient(to bottom, black 70%, transparent 100%);
|
||||
-webkit-mask-image: linear-gradient(to bottom, black 70%, transparent 100%);
|
||||
}
|
||||
|
||||
.hero-gl-fallback {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
background:
|
||||
radial-gradient(85% 60% at 50% -10%, color-mix(in oklab, var(--accent) 18%, transparent) 0%, transparent 70%),
|
||||
radial-gradient(60% 50% at 85% 20%, rgba(217, 155, 56, 0.12) 0%, transparent 60%),
|
||||
linear-gradient(180deg, var(--surface-sunken) 0%, var(--surface) 100%);
|
||||
}
|
||||
|
||||
.hero-gl-canvas {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100% !important;
|
||||
height: 100% !important;
|
||||
max-width: none !important;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.hero-gl-scrim {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
background: radial-gradient(circle at 50% 30%, rgba(12, 16, 23, 0.35) 0%, rgba(12, 16, 23, 0.8) 100%);
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.hero-gl-canvas {
|
||||
display: none !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,129 +0,0 @@
|
|||
---
|
||||
import BgPhoto from "./BgPhoto.astro";
|
||||
import type { Content } from "../i18n/content";
|
||||
|
||||
interface Props {
|
||||
c: Content["typography"];
|
||||
}
|
||||
const { c } = Astro.props;
|
||||
---
|
||||
|
||||
<section class="section band-inverse has-bg" aria-labelledby="type-h">
|
||||
<BgPhoto variant="paper" mode="drift" depth={0.25} opacity={1} />
|
||||
<p class="eyebrow reveal">{c.eyebrow}</p>
|
||||
<h2 id="type-h" class="reveal">{c.h2}</h2>
|
||||
<p class="lead type-lead reveal">{c.lead}</p>
|
||||
|
||||
{/*
|
||||
주장을 글로 하지 않고 실물로 보여준다.
|
||||
|
||||
한때 word-break 하나만 두 칼럼으로 비교했는데, 어절이 짧아 두 쪽이
|
||||
같은 자리에서 끊겼다 — 줄 수도 높이도 똑같았다. 차이가 0 인 비교는
|
||||
증명이 아니라 주장의 반증이다. 셋으로 늘리고, 잘리는 긴 어절을 넣고,
|
||||
폭을 좁혀 실제로 갈리게 만들었다.
|
||||
*/}
|
||||
<div class="full demos reveal">
|
||||
{
|
||||
c.demos.map((d) => (
|
||||
<section class="demo" aria-label={d.title}>
|
||||
<h3 class="demo-title">{d.title}</h3>
|
||||
<div class="demo-pair">
|
||||
<div class="demo-side">
|
||||
<p class="demo-tag mono is-bad">{d.badLabel}</p>
|
||||
<p lang="ko" class:list={["demo-text", `bad-${d.id}`]}>{c.sample}</p>
|
||||
</div>
|
||||
<div class="demo-side">
|
||||
<p class="demo-tag mono is-good">{d.goodLabel}</p>
|
||||
<p lang="ko" class:list={["demo-text", `good-${d.id}`]}>{c.sample}</p>
|
||||
</div>
|
||||
</div>
|
||||
<p class="demo-note muted">{d.note}</p>
|
||||
</section>
|
||||
))
|
||||
}
|
||||
</div>
|
||||
|
||||
<ul class="type-rules reveal">
|
||||
{c.rules.map((r) => (<li>{r}</li>))}
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
.type-lead { margin-bottom: var(--space-6); max-width: var(--measure); }
|
||||
|
||||
.demos {
|
||||
max-width: 1180px;
|
||||
margin-inline: auto;
|
||||
padding-inline: var(--gutter);
|
||||
display: grid;
|
||||
gap: var(--space-6);
|
||||
}
|
||||
|
||||
.demo-title {
|
||||
font-size: var(--step-1);
|
||||
margin-bottom: var(--space-3);
|
||||
}
|
||||
|
||||
.demo-pair {
|
||||
display: grid;
|
||||
/* 폭을 좁게 고정한다. 넓으면 두 쪽이 같은 자리에서 끊겨 차이가 사라진다 */
|
||||
grid-template-columns: repeat(2, minmax(0, 15rem));
|
||||
gap: var(--space-5);
|
||||
align-items: start;
|
||||
}
|
||||
|
||||
.demo-side { min-width: 0; }
|
||||
|
||||
.demo-tag {
|
||||
font-size: var(--step--1);
|
||||
letter-spacing: var(--tracking-label);
|
||||
margin-bottom: var(--space-2);
|
||||
padding-bottom: var(--space-1);
|
||||
border-bottom: 1px solid var(--line);
|
||||
}
|
||||
.is-bad { color: var(--ink-muted); }
|
||||
.is-good { color: var(--accent); border-bottom-color: var(--accent); }
|
||||
|
||||
.demo-text {
|
||||
margin: 0;
|
||||
font-size: var(--step-0);
|
||||
line-height: var(--leading-normal);
|
||||
word-break: keep-all;
|
||||
overflow-wrap: break-word;
|
||||
}
|
||||
|
||||
/* ---- 셋의 실제 차이 ------------------------------------- */
|
||||
/* 1) 줄바꿈 — 기본값은 어절 한가운데를 끊는다 */
|
||||
.bad-break { word-break: break-all; }
|
||||
.good-break { word-break: keep-all; }
|
||||
|
||||
/* 2) 행간 — 라틴 표준을 그대로 쓰면 받침이 붙어 보인다 */
|
||||
.bad-leading { line-height: 1.45; }
|
||||
.good-leading { line-height: 1.75; }
|
||||
|
||||
/* 3) 크기 — 라틴의 라벨 크기는 한글에서 획이 뭉갠다 */
|
||||
.bad-size { font-size: 11px; }
|
||||
.good-size { font-size: 15px; }
|
||||
|
||||
.demo-note {
|
||||
margin: var(--space-3) 0 0;
|
||||
font-size: var(--step-0);
|
||||
max-width: var(--measure);
|
||||
}
|
||||
|
||||
.type-rules {
|
||||
list-style: none;
|
||||
margin: var(--space-7) 0 0;
|
||||
padding: 0;
|
||||
display: grid;
|
||||
gap: 0;
|
||||
}
|
||||
.type-rules li {
|
||||
padding-block: var(--space-3);
|
||||
border-top: 1px solid var(--line);
|
||||
}
|
||||
|
||||
@media (max-width: 760px) {
|
||||
.demo-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); }
|
||||
}
|
||||
</style>
|
||||
Loading…
Add table
Add a link
Reference in a new issue