feat(performance): 일자별 표 열 너비 자동/수동 옵션

실적 설정 "보기 설정"에 표 열 너비 [자동(글자 길이)]·[수동 조절] 추가(쿠키 perf_colw).
수동이면 매출 실적·광고비 일자별 표 머리글 오른쪽 경계를 끌어 열 너비를 바꾸고,
바꾼 너비는 localStorage(perf_colw_sales/ads)에 유지. 경계 두 번 클릭 = 그 열만 자동,
설정 [조절한 너비 초기화]로 전부 되돌림. 그룹 접기·펴기 애니메이션과 연동.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-27 23:20:24 +09:00
parent d48a942932
commit d9dd03ecc8
10 changed files with 360 additions and 12 deletions
+10 -1
View File
@@ -88,7 +88,7 @@ def main() -> None:
os.makedirs(OUT_DIR, exist_ok=True)
e = env()
base = {"user": {"email": "me@test.local"}, "is_admin": True, "nav_items": [], "page_title": "실적", "page_subtitle": "",
"unit": "won", "unit_label": "원", "amt": lambda v: amount_text(v)}
"unit": "won", "unit_label": "원", "amt": lambda v: amount_text(v), "colw": "auto"}
ctx = build_dashboard(FakeStore(), kind="week", anchor=date(2026, 10, 7), today=date(2026, 10, 7))
# 다음 자동 업데이트(router._auto_sync_ctx 와 같은 모양) — 화면이 초 단위로 센다
# 일정 = 실적 설정 "자동 업데이트"(2026-10-26) — 화면이 schedule 로 다음 회차를 계산
@@ -150,6 +150,15 @@ def main() -> None:
html = e.get_template("performance/settings.html").render(**base, active_tab="settings", **gsctx)
with open(os.path.join(OUT_DIR, "perf_settings_groups.html"), "w", encoding="utf-8") as f:
f.write(html)
# 표 열 너비 수동 조절(2026-10-27, 쿠키 perf_colw=manual) — 진짜 셸 + 그룹 있는 매출 실적·광고비 (perf_colw.browser.test.js)
cctx = build_dashboard(GroupStore(), kind="month", anchor=date(2026, 10, 7), today=date(2026, 10, 7))
cctx.update(auto_sync=None, update_watch=None)
html = shell.get_template("performance/index.html").render(**{**sbase, "colw": "manual"}, active_tab="dashboard", metric="gross", **cctx)
with open(os.path.join(OUT_DIR, "perf_dash_colw_shell.html"), "w", encoding="utf-8") as f:
f.write(html)
html = shell.get_template("performance/ads.html").render(**{**sbase, "colw": "manual"}, active_tab="ads", **sactx)
with open(os.path.join(OUT_DIR, "perf_ads_colw_shell.html"), "w", encoding="utf-8") as f:
f.write(html)
print("ok")