fix: 편집기에서 글을 쓸 수 있게 하고 종류 이름을 한 곳에 모은다

칸이 내용을 따라 자란다. 112px 고정이라 659자짜리 규칙 본문을 세 줄짜리
구멍으로 편집했다 — 편집기의 칸 22개 중 10개가 내용이 넘쳐 잘려 있었다.
상한을 70vh 로 두는 이유는 긴 본문 하나가 화면을 통째로 차지하면 나머지
칸으로 이동할 수 없기 때문이다. field-sizing 을 모르는 브라우저는 예전
동작 그대로다 — 나빠지지 않는다.

미리보기가 제자리에 붙는다. 폼과 같은 흐름에 놓여 있어서 편집기가
8,872px 이면 미리보기도 그만큼 아래로 흘렀고, 아래쪽 칸을 고치는 동안
미리보기는 화면 밖이었다. 한 열로 접히는 폭에서는 붙박이를 푼다 —
위아래로 쌓인 상태에서 붙이면 폼을 가린다.

종류 이름을 한 곳에 모은다. 표가 화면마다 복사되어 여섯 벌이었고 그래서
갈라졌다: 같은 QUESTION 이 공개 화면에서 "Open Question", 작업본 목록과
게시 기록에서 "Question", 편집기 상태 줄에서 "QUESTION" 이었다. 쓰는
사람은 같은 문서를 화면마다 다른 이름으로 만난다. Record<RecordKind,
string> 이므로 종류가 늘면 빠진 자리를 타입이 잡는다.

미리보기는 공개 화면과 같은 렌더러를 쓰므로, 오늘 고친 문단·인라인 코드가
편집기 미리보기에도 그대로 적용된다.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011nAjrqNHGPNngN4aUbcyvJ
This commit is contained in:
DongHyeonka
2026-08-31 08:29:10 +09:00
co-authored by Claude Opus 5
parent 9b7ad82fe3
commit ca1fc92e6d
10 changed files with 58 additions and 65 deletions
@@ -28,7 +28,12 @@
/* 반쪽 폭에는 62px 짜리 제목이 앉을 자리가 없다. */
.studio-app .studio-editor-split .studio-editor-heading h1 { font-size: clamp(28px, 3vw, 40px); }
.studio-app .studio-editor-preview { display: flex; flex-direction: column; padding-left: 40px; border-left: 1px solid var(--line); }
/*
미리보기는 제자리에 붙어 따라온다. 예전에는 폼과 같은 흐름에 나란히 놓여 있어서, 편집기가
8,872px 이면 미리보기도 그만큼 아래로 흘렀다 — 아래쪽 칸을 고치는 동안 미리보기는 화면 밖이었다.
`align-self: start` 가 없으면 격자가 칸을 늘려 버려 붙박이가 걸리지 않는다.
*/
.studio-app .studio-editor-preview { position: sticky; top: 24px; align-self: start; max-height: calc(100vh - 48px); overflow-y: auto; display: flex; flex-direction: column; padding-left: 40px; border-left: 1px solid var(--line); }
.studio-app .studio-editor-preview__heading { padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.studio-app .studio-editor-preview__heading .studio-eyebrow { margin-bottom: 8px; }
.studio-app .studio-editor-preview__body { padding-top: 20px; }
@@ -54,8 +59,15 @@
.studio-app .studio-ordered-item textarea,
.studio-app .studio-relation-item input,
.studio-app .studio-relation-item select { width: 100%; min-width: 0; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 5px; background: var(--paper); color: var(--ink); font: inherit; font-size: 15px; font-weight: 450; line-height: 1.55; }
/*
칸이 내용을 따라 자란다. 예전에는 112px 에 고정이라 659자짜리 규칙 본문을 세 줄짜리 구멍으로
편집했다 — 편집기의 칸 22개 중 10개가 내용이 넘쳐 잘려 있었다. 상한을 두는 이유는 긴 본문
하나가 화면을 통째로 차지하면 나머지 칸으로 이동할 수 없기 때문이다.
`field-sizing` 을 모르는 브라우저에서는 예전처럼 112px 에 스크롤이다 — 나빠지지는 않는다.
*/
.studio-app .studio-field textarea,
.studio-app .studio-ordered-item textarea { min-height: 112px; resize: vertical; }
.studio-app .studio-ordered-item textarea { min-height: 112px; max-height: 70vh; field-sizing: content; resize: vertical; }
.studio-app .studio-field .studio-markdown-field { min-height: 420px; font-family: "IBM Plex Mono", monospace; font-size: 13px; }
/* 칸 아래 한 줄 설명. 라벨과 같은 격자 안에 들어가므로 별도 여백을 두지 않는다. */
@@ -163,7 +175,7 @@
@media (max-width: 1024px) {
.studio-app .studio-editor-split { grid-template-columns: minmax(0, 1fr); gap: 40px; }
.studio-app .studio-editor-split .studio-editor-heading h1 { font-size: clamp(38px, 5vw, 62px); }
.studio-app .studio-editor-preview { padding-top: 8px; padding-left: 0; border-top: 1px solid var(--line-strong); border-left: 0; }
.studio-app .studio-editor-preview { position: static; max-height: none; overflow-y: visible; padding-top: 8px; padding-left: 0; border-top: 1px solid var(--line-strong); border-left: 0; }
}
@media (max-width: 767px) {