diff --git a/B08_Quantity/B08_Quantity_UI_Earthwork_Sheets.ts b/B08_Quantity/B08_Quantity_UI_Earthwork_Sheets.ts index 884c95f86..bb9e1bc02 100644 --- a/B08_Quantity/B08_Quantity_UI_Earthwork_Sheets.ts +++ b/B08_Quantity/B08_Quantity_UI_Earthwork_Sheets.ts @@ -12,7 +12,7 @@ import { note, tableCard, type EarthworkTable, type HaulList } from "./B08_Quant const fmt = (value: number | null | undefined): string => value == null || !Number.isFinite(value) - ? "—" + ? "-" : value.toLocaleString("ko-KR", { maximumFractionDigits: 2 }); const SUMMARY_COLUMNS: DataColumn[] = [ @@ -28,11 +28,11 @@ const SUMMARY_COLUMNS: DataColumn[] = [ export function renderEarthworkSummary(host: HTMLElement, table: EarthworkTable): void { const info = note( "토적표 합계 · 평균운반거리 · 종방향 무대운반거리를 실무 토공집계표 식대로 묶음 · " + - "리핑암 = 연암 · 발파암 = 경암 · 구조물 쪽 줄은 구조물 수량에서(— = 아직 값 없음)", + "리핑암 = 연암 · 발파암 = 경암 · 구조물 쪽 줄은 구조물 수량에서(- = 아직 값 없음)", ); const grid = createDataTable({ columns: SUMMARY_COLUMNS, - // 칸이 없는 글(공종 · 규격 · 비고)은 빈칸 — 공용 표는 "" 를 「—」(값 없음)로 그림 + // 칸이 없는 글(공종 · 규격 · 비고)은 빈칸 — 공용 표는 "" 를 「-」(값 없음)로 그림 rows: table.summary.map((row) => ({ ...row, kind: row.kind || " ", diff --git a/B08_Quantity/B08_Quantity_UI_Hydro_Sheet.ts b/B08_Quantity/B08_Quantity_UI_Hydro_Sheet.ts index a5c1a6b1a..93d3b0187 100644 --- a/B08_Quantity/B08_Quantity_UI_Hydro_Sheet.ts +++ b/B08_Quantity/B08_Quantity_UI_Hydro_Sheet.ts @@ -5,7 +5,7 @@ * 왼쪽 카드 「1. 홍수량 계산」 1-1 합리식 · 1-2 도달시간(Kirpich) · 1-3 강우강도 * 오른쪽 카드 「2. 단면 검토」 관 단면 그림 · 단면적 · 윤변 · 경심 · 경사 · n · 유속 · 유출량 · 판정 * 테두리는 입력 · 선택 칸만(공용 ui-input · ui-select) · 계산 칸은 글자만 - * 굵게 + 붉은 계열은 중요 결과(Qd · 유출량 · 판정 · 유출율)만 · 빈칸에 기대는 계산 칸은 「—」. + * 굵게 + 붉은 계열은 중요 결과(Qd · 유출량 · 판정 · 유출율)만 · 빈칸에 기대는 계산 칸은 「-」. * * 입력 칸은 한 번 만들고 계산 결과만 제자리에 바꿈 — 고치는 중 칸 포커스를 잃지 않게. * ========================================================================== */ @@ -85,7 +85,7 @@ const NULLABLE = new Set([ "r24_mm", ]); -const DASH = "—"; +const DASH = "-"; const fmt = (value: number | null | undefined, digits: number, unit = ""): string => value == null || !Number.isFinite(value) ? DASH : `${value.toFixed(digits)}${unit}`; diff --git a/B08_Quantity/B08_Quantity_UI_Summary.ts b/B08_Quantity/B08_Quantity_UI_Summary.ts index 78b456d94..8fae5e08e 100644 --- a/B08_Quantity/B08_Quantity_UI_Summary.ts +++ b/B08_Quantity/B08_Quantity_UI_Summary.ts @@ -57,7 +57,7 @@ function buildTable(stations: number[], columns: ComboColumn[], interval: number width: widthOf(column.name), })), ], - // 칸은 아직 비움 — 사용자가 채울 자리라 「—」 대신 빈칸 + // 칸은 아직 비움 — 사용자가 채울 자리라 「-」 대신 빈칸 rows: stations.map((station) => ({ station: stationLabel(station, interval) })), frozen: 1, empty: "", diff --git a/resources/tester/test_ui_data_table.py b/resources/tester/test_ui_data_table.py index 8ada6fcaa..cbbecc7c5 100644 --- a/resources/tester/test_ui_data_table.py +++ b/resources/tester/test_ui_data_table.py @@ -58,7 +58,7 @@ def test_숫자_꼴(r): assert f["thousands"] == "1,234,567.89" assert f["neg"] == "-97.90" assert f["zero"] == "0.00" - assert f["nul"] == f["undef"] == f["blank"] == f["nan"] == "—" + assert f["nul"] == f["undef"] == f["blank"] == f["nan"] == "-" assert f["text"] == "120+18" and f["textNum"] == "5" @@ -89,6 +89,6 @@ def test_보이는_줄만_그림(r): def test_빈_칸_글_풍선_꾸밈_옵션(r): o = r["opts"] - assert '' in o # empty="" — 「—」 대신 빈칸 + assert '' in o # empty="" — 「-」 대신 빈칸 assert '메쌓기' in o assert 'rowspan="2" class="is-frozen is-edge" style="left:0px" title="측점">측점' in o diff --git a/ui_template/ui_template_data_table.ts b/ui_template/ui_template_data_table.ts index 0ef3c3c7d..a20737edb 100644 --- a/ui_template/ui_template_data_table.ts +++ b/ui_template/ui_template_data_table.ts @@ -1,7 +1,7 @@ /* ============================================================================= * ui_template_data_table.ts * 많은 자료용 읽기 표(B08 · B09 공용) — 묶음 머리 여러 줄 · 머리 · 앞 열 고정 스크롤 · - * 숫자 오른쪽 맞춤 · 천 단위 쉼표 · 열마다 소수 자리 · 빈 값 「—」 · 합계 줄. + * 숫자 오른쪽 맞춤 · 천 단위 쉼표 · 열마다 소수 자리 · 빈 값 「-」 · 합계 줄. * 줄 1,000개도 빠르게 — HTML 글로 통째로 넣고(칸마다 요소 만들지 않음) 보이는 줄 근처만 그림. * * const t = createDataTable({ columns, rows, frozen: 1, total }); @@ -41,7 +41,7 @@ export interface DataTableOptions { total?: DataRow | null; /** 표 이름(화면 읽기용) */ caption?: string; - /** 빈 값 글(기본 「—」 · 사용자가 채울 칸은 "") */ + /** 빈 값 글(기본 「-」 · 사용자가 채울 칸은 "") */ empty?: string; } @@ -50,7 +50,7 @@ export interface DataTable { setRows: (rows: DataRow[], total?: DataRow | null) => void; } -const EMPTY = "—"; +const EMPTY = "-"; const ESC: Record = { "&": "&", "<": "<", ">": ">", '"': """ }; const esc = (s: string): string => s.replace(/[&<>"]/g, (c) => ESC[c]);