feat: 격자 에디터를 CodeMirror 6로 (parity) #12

Merged
tyange merged 1 commit from feat/modern-editor into main 2026-09-09 06:11:17 +00:00
Owner

격자 모드는 본질적으로 모노스페이스 텍스트 버퍼 + 캐럿이고, CM6의 state.doc
(문자열)이 Palim의 text 진실원천과 1:1이다. CM6은 CJK/한국어 IME를 제대로
처리하고 undo/redo·선택·클립보드가 내장 — 바닥부터 만들다 두 번(SVG 격자,
순수 textarea) 부딪힌 벽이 여기서 사라진다.

v1은 패리티만: 지금 textarea가 하던 것을 CM6이 하게 한다. 격자선·활성 칸·
"빈 공간 클릭 배치"는 다음 단계.

  • @codemirror/state·view·commands만. basicSetup(줄번호·폴딩·문법 등)
    안 씀 — 익스텐션 손조립: history / keymap / drawSelection / updateListener / theme
  • GridEditor.vue 전면 재작성. 테마 메트릭 = GRID(fontSize/lineHeight/pad)라
    EditorView.vue의 centerOn/onJump 기하가 그대로 맞음. word-spacing:0.5em로
    공백=1칸(CM6은 실 DOM 측정이라 캐럿 좌표 정확). updateListener↔text 동기화 +
    applyingExternal 에코 가드. grow + 무대 스크롤
  • EditorView.vue: centerOn 셀렉터에 .cm-editor 추가 (한 줄)
  • 흐름 모드는 그대로 plain <textarea> (FlowEditor.vue 안 건드림)
  • docs: docs/grid-editor.md 신규, CLAUDE.md·리셋 노트 4개 갱신

Co-Authored-By: Claude Sonnet 5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01MfW22NQxomSVmTAQiQCjQu

격자 모드는 본질적으로 모노스페이스 텍스트 버퍼 + 캐럿이고, CM6의 state.doc (문자열)이 Palim의 `text` 진실원천과 1:1이다. CM6은 CJK/한국어 IME를 제대로 처리하고 undo/redo·선택·클립보드가 내장 — 바닥부터 만들다 두 번(SVG 격자, 순수 textarea) 부딪힌 벽이 여기서 사라진다. v1은 패리티만: 지금 textarea가 하던 것을 CM6이 하게 한다. 격자선·활성 칸· "빈 공간 클릭 배치"는 다음 단계. - `@codemirror/state`·`view`·`commands`만. `basicSetup`(줄번호·폴딩·문법 등) 안 씀 — 익스텐션 손조립: history / keymap / drawSelection / updateListener / theme - `GridEditor.vue` 전면 재작성. 테마 메트릭 = `GRID`(fontSize/lineHeight/pad)라 `EditorView.vue`의 centerOn/onJump 기하가 그대로 맞음. `word-spacing:0.5em`로 공백=1칸(CM6은 실 DOM 측정이라 캐럿 좌표 정확). updateListener↔`text` 동기화 + applyingExternal 에코 가드. grow + 무대 스크롤 - `EditorView.vue`: `centerOn` 셀렉터에 `.cm-editor` 추가 (한 줄) - 흐름 모드는 그대로 plain `<textarea>` (FlowEditor.vue 안 건드림) - docs: `docs/grid-editor.md` 신규, CLAUDE.md·리셋 노트 4개 갱신 Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MfW22NQxomSVmTAQiQCjQu
feat: 격자 에디터를 CodeMirror 6로 (parity)
All checks were successful
Deploy Palim to AWS (Nginx) / deploy (push) Successful in 2m29s
c1b82033ad
격자 모드는 본질적으로 모노스페이스 텍스트 버퍼 + 캐럿이고, CM6의 state.doc
(문자열)이 Palim의 `text` 진실원천과 1:1이다. CM6은 CJK/한국어 IME를 제대로
처리하고 undo/redo·선택·클립보드가 내장 — 바닥부터 만들다 두 번(SVG 격자,
순수 textarea) 부딪힌 벽이 여기서 사라진다.

v1은 패리티만: 지금 textarea가 하던 것을 CM6이 하게 한다. 격자선·활성 칸·
"빈 공간 클릭 배치"는 다음 단계.

- `@codemirror/state`·`view`·`commands`만. `basicSetup`(줄번호·폴딩·문법 등)
  안 씀 — 익스텐션 손조립: history / keymap / drawSelection / updateListener / theme
- `GridEditor.vue` 전면 재작성. 테마 메트릭 = `GRID`(fontSize/lineHeight/pad)라
  `EditorView.vue`의 centerOn/onJump 기하가 그대로 맞음. `word-spacing:0.5em`로
  공백=1칸(CM6은 실 DOM 측정이라 캐럿 좌표 정확). updateListener↔`text` 동기화 +
  applyingExternal 에코 가드. grow + 무대 스크롤
- `EditorView.vue`: `centerOn` 셀렉터에 `.cm-editor` 추가 (한 줄)
- 흐름 모드는 그대로 plain `<textarea>` (FlowEditor.vue 안 건드림)
- docs: `docs/grid-editor.md` 신규, CLAUDE.md·리셋 노트 4개 갱신

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MfW22NQxomSVmTAQiQCjQu
tyange merged commit c1b82033ad into main 2026-09-09 06:11:17 +00:00
Sign in to join this conversation.
No description provided.