feat(ux): 전체 시스템 모바일 UX 개선 — 햄버거메뉴·필터반응형·터치타겟·iOS줌방지

7개 시스템(tkpurchase/tksafety/tksupport/tkuser/system1/system2/system3)의
모바일 사용성 일괄 개선. system1(tkfb)의 모바일 메뉴 패턴을 3개 신규 시스템에 적용.

주요 변경:
- 모바일 햄버거 메뉴: tkpurchase/tksafety/tksupport에 toggleMobileMenu+overlay 추가
- 필터 반응형: 768px 이하 2열 그리드 전환 (filter-bar/filter-actions 클래스)
- 터치 타겟 44px: 테이블 액션 버튼 36px+gap, tksafety ±버튼 w-11
- iOS 줌 방지: input/select/textarea font-size 16px
- tkuser: 탭 가로스크롤+fade힌트, 사이드바·grid·드롭다운 반응형
- system1: 대시보드 인라인 width 제거, 이동설비 그리드 1열
- system2: 사진그리드 4열, 유형버튼 2열 (480px 이하)
- system3: 카드 내 액션 버튼 stopPropagation 추가
- 캐시 무효화: 전체 HTML ?v=2026031401

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Hyungi Ahn
2026-03-14 17:57:47 +09:00
parent 2d8ac92404
commit fe5f7cd155
86 changed files with 667 additions and 373 deletions

View File

@@ -6,7 +6,7 @@
<title>계정 관리 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260312">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -14,6 +14,9 @@
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-14">
<div class="flex items-center gap-3">
<button id="mobileMenuBtn" onclick="toggleMobileMenu()" class="lg:hidden text-emerald-200 hover:text-white">
<i class="fas fa-bars text-xl"></i>
</button>
<i class="fas fa-truck text-xl text-emerald-200"></i>
<h1 class="text-lg font-semibold">TK 구매관리</h1>
</div>
@@ -33,9 +36,9 @@
<!-- Main -->
<div class="flex-1 min-w-0">
<div class="flex gap-5">
<div class="flex flex-col lg:flex-row gap-5">
<!-- 업체 목록 (왼쪽) -->
<div class="w-64 flex-shrink-0">
<div class="w-full lg:w-64 lg:flex-shrink-0">
<div class="bg-white rounded-xl shadow-sm p-4">
<h2 class="text-base font-semibold text-gray-800 mb-3">
<i class="fas fa-building text-emerald-500 mr-2"></i>협력업체
@@ -130,8 +133,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313b"></script>
<script src="/static/js/tkpurchase-accounts.js?v=20260312"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-accounts.js?v=2026031401"></script>
<script>initAccountsPage();</script>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<title>일용공 신청 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260312">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -14,6 +14,9 @@
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-14">
<div class="flex items-center gap-3">
<button id="mobileMenuBtn" onclick="toggleMobileMenu()" class="lg:hidden text-emerald-200 hover:text-white">
<i class="fas fa-bars text-xl"></i>
</button>
<i class="fas fa-truck text-xl text-emerald-200"></i>
<h1 class="text-lg font-semibold">TK 구매관리</h1>
</div>
@@ -35,7 +38,7 @@
<div class="flex-1 min-w-0">
<!-- 필터 및 추가 버튼 -->
<div class="bg-white rounded-xl shadow-sm p-4 mb-5">
<div class="flex flex-wrap items-end gap-3">
<div class="flex flex-wrap items-end gap-3 filter-bar">
<div>
<label class="block text-xs font-medium text-gray-600 mb-1">시작일</label>
<input type="date" id="filterDateFrom" class="input-field px-3 py-2 rounded-lg text-sm">
@@ -65,13 +68,14 @@
<option value="영업">영업</option>
</select>
</div>
<button onclick="loadDayLabor()" class="px-4 py-2 bg-gray-100 text-gray-700 rounded-lg text-sm hover:bg-gray-200">
<i class="fas fa-search mr-1"></i>조회
</button>
<div class="flex-1"></div>
<button onclick="openAddDayLabor()" class="px-4 py-2 bg-emerald-600 text-white rounded-lg text-sm hover:bg-emerald-700 font-medium">
<i class="fas fa-plus mr-1"></i>일용공 신청
</button>
<div class="filter-actions">
<button onclick="loadDayLabor()" class="px-4 py-2 bg-gray-100 text-gray-700 rounded-lg text-sm hover:bg-gray-200">
<i class="fas fa-search mr-1"></i>조회
</button>
<button onclick="openAddDayLabor()" class="px-4 py-2 bg-emerald-600 text-white rounded-lg text-sm hover:bg-emerald-700 font-medium">
<i class="fas fa-plus mr-1"></i>일용공 신청
</button>
</div>
</div>
</div>
@@ -144,8 +148,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313b"></script>
<script src="/static/js/tkpurchase-daylabor.js?v=20260312"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-daylabor.js?v=2026031401"></script>
<script>initDayLaborPage();</script>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<title>대시보드 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260312">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -14,6 +14,9 @@
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-14">
<div class="flex items-center gap-3">
<button id="mobileMenuBtn" onclick="toggleMobileMenu()" class="lg:hidden text-emerald-200 hover:text-white">
<i class="fas fa-bars text-xl"></i>
</button>
<i class="fas fa-truck text-xl text-emerald-200"></i>
<h1 class="text-lg font-semibold">TK 구매관리</h1>
</div>
@@ -85,8 +88,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313b"></script>
<script src="/static/js/tkpurchase-dashboard.js?v=20260312"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-dashboard.js?v=2026031401"></script>
<script>initDashboard();</script>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<title>작업 이력 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260313">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -61,8 +61,8 @@
<div id="historyPagination" class="mt-4 flex justify-center gap-2"></div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313"></script>
<script src="/static/js/tkpurchase-partner-history.js?v=20260313"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-partner-history.js?v=2026031401"></script>
<script>initPartnerHistory();</script>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<title>협력업체 포털 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260313a">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -81,8 +81,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313c"></script>
<script src="/static/js/tkpurchase-partner-portal.js?v=20260313c"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-partner-portal.js?v=2026031401"></script>
<script>initPartnerPortal();</script>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<title>협력업체 관리 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260312">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -14,6 +14,9 @@
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-14">
<div class="flex items-center gap-3">
<button id="mobileMenuBtn" onclick="toggleMobileMenu()" class="lg:hidden text-emerald-200 hover:text-white">
<i class="fas fa-bars text-xl"></i>
</button>
<i class="fas fa-truck text-xl text-emerald-200"></i>
<h1 class="text-lg font-semibold">TK 구매관리</h1>
</div>
@@ -291,8 +294,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313b"></script>
<script src="/static/js/tkpurchase-partner.js?v=20260312"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-partner.js?v=2026031401"></script>
<script>initPartnerPage();</script>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<title>작업일정 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260313aa">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -14,6 +14,9 @@
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-14">
<div class="flex items-center gap-3">
<button id="mobileMenuBtn" onclick="toggleMobileMenu()" class="lg:hidden text-emerald-200 hover:text-white">
<i class="fas fa-bars text-xl"></i>
</button>
<i class="fas fa-truck text-xl text-emerald-200"></i>
<h1 class="text-lg font-semibold">TK 구매관리</h1>
</div>
@@ -35,7 +38,7 @@
<div class="flex-1 min-w-0">
<!-- 필터 및 추가 버튼 -->
<div class="bg-white rounded-xl shadow-sm p-4 mb-5">
<div class="flex flex-wrap items-end gap-3">
<div class="flex flex-wrap items-end gap-3 filter-bar">
<div>
<label class="block text-xs font-medium text-gray-600 mb-1">업체 검색</label>
<input type="text" id="filterCompany" class="input-field px-3 py-2 rounded-lg text-sm" placeholder="업체명">
@@ -60,13 +63,14 @@
<option value="rejected">반려</option>
</select>
</div>
<button onclick="loadSchedules()" class="px-4 py-2 bg-gray-100 text-gray-700 rounded-lg text-sm hover:bg-gray-200">
<i class="fas fa-search mr-1"></i>조회
</button>
<div class="flex-1"></div>
<button onclick="openAddSchedule()" class="px-4 py-2 bg-emerald-600 text-white rounded-lg text-sm hover:bg-emerald-700 font-medium">
<i class="fas fa-plus mr-1"></i>일정 등록
</button>
<div class="filter-actions">
<button onclick="loadSchedules()" class="px-4 py-2 bg-gray-100 text-gray-700 rounded-lg text-sm hover:bg-gray-200">
<i class="fas fa-search mr-1"></i>조회
</button>
<button onclick="openAddSchedule()" class="px-4 py-2 bg-emerald-600 text-white rounded-lg text-sm hover:bg-emerald-700 font-medium">
<i class="fas fa-plus mr-1"></i>일정 등록
</button>
</div>
</div>
</div>
@@ -271,8 +275,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313b"></script>
<script src="/static/js/tkpurchase-schedule.js?v=20260313a"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-schedule.js?v=2026031401"></script>
<script>initSchedulePage();</script>
</body>
</html>

View File

@@ -63,3 +63,48 @@ body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; b
.visit-table th, .visit-table td { padding: 0.5rem; }
.hide-mobile { display: none; }
}
/* Mobile menu */
#mobileOverlay { z-index: 30; }
#sideNav { transition: transform 0.3s ease; }
@media (max-width: 1023px) {
#sideNav {
position: fixed; top: 3.5rem; left: 0; bottom: 0;
width: 14rem; background: white; z-index: 40;
transform: translateX(-100%);
box-shadow: 2px 0 8px rgba(0,0,0,0.1);
padding: 0.5rem; overflow-y: auto;
display: flex !important; flex-direction: column; gap: 0.25rem;
}
#sideNav.mobile-open { transform: translateX(0); }
}
/* Filter responsive */
@media (max-width: 768px) {
.filter-bar {
display: grid !important; grid-template-columns: 1fr 1fr;
gap: 0.5rem; align-items: end;
}
.filter-bar > div { width: 100%; }
.filter-bar > div > input,
.filter-bar > div > select { width: 100%; }
.filter-actions {
grid-column: 1 / -1; display: flex; gap: 0.5rem;
}
.filter-actions > * { flex: 1; }
}
/* Table action button touch targets */
@media (max-width: 768px) {
.visit-table td:last-child button,
.visit-table td:last-child a {
display: inline-flex; align-items: center; justify-content: center;
min-width: 36px; min-height: 36px; padding: 6px;
}
.visit-table td:last-child { gap: 2px; display: flex; flex-wrap: nowrap; justify-content: flex-end; align-items: center; }
}
/* iOS zoom prevention */
@media (max-width: 768px) {
input, select, textarea { font-size: 16px !important; }
}

View File

@@ -84,6 +84,25 @@ function doLogout() {
location.href = getLoginUrl() + '&logout=1';
}
/* ===== Mobile Menu ===== */
function toggleMobileMenu() {
const nav = document.getElementById('sideNav');
const overlay = document.getElementById('mobileOverlay');
if (!overlay) {
const o = document.createElement('div');
o.id = 'mobileOverlay';
o.className = 'fixed inset-0 bg-black bg-opacity-30 hidden';
o.style.zIndex = '30';
o.onclick = toggleMobileMenu;
document.body.appendChild(o);
toggleMobileMenu();
return;
}
const open = nav.classList.toggle('mobile-open');
overlay.classList.toggle('hidden', !open);
document.body.style.overflow = open ? 'hidden' : '';
}
/* ===== Navbar ===== */
function renderNavbar() {
const currentPage = location.pathname.replace(/\//g, '') || 'index.html';
@@ -102,6 +121,12 @@ function renderNavbar() {
return `<a href="${l.href}" class="nav-link flex items-center gap-3 px-4 py-2.5 rounded-lg text-sm transition-colors ${active ? 'active' : 'text-gray-600 hover:bg-gray-100'}">
<i class="fas ${l.icon} w-5 text-center"></i><span>${l.label}</span></a>`;
}).join('');
// 모바일: nav-link 클릭 시 메뉴 닫기
nav.querySelectorAll('.nav-link').forEach(a => {
a.addEventListener('click', () => {
if (nav.classList.contains('mobile-open')) toggleMobileMenu();
});
});
}
/* ===== State ===== */

View File

@@ -120,7 +120,7 @@ async function renderScheduleCards() {
<input type="text" id="checkinNames_${s.id}" class="input-field w-full px-3 py-2 rounded-lg text-sm" placeholder="홍길동, 김철수">
</div>
</div>
<button onclick="doCheckIn(${s.id})" class="px-4 py-2 bg-emerald-600 text-white rounded-lg text-sm hover:bg-emerald-700">
<button onclick="doCheckIn(${s.id})" class="w-full px-4 py-3 bg-emerald-600 text-white rounded-lg text-sm hover:bg-emerald-700">
<i class="fas fa-play mr-1"></i>작업 시작
</button>
</div>
@@ -295,7 +295,7 @@ function workerRowHtml(checkinId, idx, worker) {
<input type="text" list="workerDatalist_${checkinId}" value="${escapeHtml(name)}" placeholder="작업자명" class="worker-name input-field flex-1 px-3 py-1.5 rounded-lg text-sm" data-pw-id="${pwId}">
<input type="number" value="${hours}" step="0.5" min="0" max="24" class="worker-hours input-field w-20 px-2 py-1.5 rounded-lg text-sm text-center" placeholder="시간">
<span class="text-xs text-gray-400">h</span>
<button onclick="removeWorkerRow('${rowId}', ${checkinId})" class="text-gray-400 hover:text-red-500 text-sm"><i class="fas fa-times"></i></button>
<button onclick="removeWorkerRow('${rowId}', ${checkinId})" class="text-gray-400 hover:text-red-500 text-sm p-2"><i class="fas fa-times"></i></button>
</div>`;
}

View File

@@ -6,7 +6,7 @@
<title>업무현황 종합 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260313">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -14,6 +14,9 @@
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-14">
<div class="flex items-center gap-3">
<button id="mobileMenuBtn" onclick="toggleMobileMenu()" class="lg:hidden text-emerald-200 hover:text-white">
<i class="fas fa-bars text-xl"></i>
</button>
<i class="fas fa-truck text-xl text-emerald-200"></i>
<h1 class="text-lg font-semibold">TK 구매관리</h1>
</div>
@@ -97,8 +100,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313"></script>
<script src="/static/js/tkpurchase-workreport-summary.js?v=20260313"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-workreport-summary.js?v=2026031401"></script>
<script>initSummaryPage();</script>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<title>업무현황 - TK 구매관리</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=20260312">
<link rel="stylesheet" href="/static/css/tkpurchase.css?v=2026031401">
</head>
<body>
<!-- Header -->
@@ -14,6 +14,9 @@
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-14">
<div class="flex items-center gap-3">
<button id="mobileMenuBtn" onclick="toggleMobileMenu()" class="lg:hidden text-emerald-200 hover:text-white">
<i class="fas fa-bars text-xl"></i>
</button>
<i class="fas fa-truck text-xl text-emerald-200"></i>
<h1 class="text-lg font-semibold">TK 구매관리</h1>
</div>
@@ -35,7 +38,7 @@
<div class="flex-1 min-w-0">
<!-- 필터 -->
<div class="bg-white rounded-xl shadow-sm p-4 mb-5">
<div class="flex flex-wrap items-end gap-3">
<div class="flex flex-wrap items-end gap-3 filter-bar">
<div>
<label class="block text-xs font-medium text-gray-600 mb-1">업체</label>
<select id="filterCompany" class="input-field px-3 py-2 rounded-lg text-sm">
@@ -58,12 +61,14 @@
<option value="true">확인완료</option>
</select>
</div>
<button onclick="loadReports()" class="px-4 py-2 bg-gray-100 text-gray-700 rounded-lg text-sm hover:bg-gray-200">
<i class="fas fa-search mr-1"></i>조회
</button>
<a href="/workreport-summary.html" class="px-4 py-2 bg-purple-50 text-purple-700 rounded-lg text-sm hover:bg-purple-100 border border-purple-200">
<i class="fas fa-chart-bar mr-1"></i>종합
</a>
<div class="filter-actions">
<button onclick="loadReports()" class="px-4 py-2 bg-gray-100 text-gray-700 rounded-lg text-sm hover:bg-gray-200">
<i class="fas fa-search mr-1"></i>조회
</button>
<a href="/workreport-summary.html" class="px-4 py-2 bg-purple-50 text-purple-700 rounded-lg text-sm hover:bg-purple-100 border border-purple-200">
<i class="fas fa-chart-bar mr-1"></i>종합
</a>
</div>
</div>
</div>
@@ -109,8 +114,8 @@
</div>
</div>
<script src="/static/js/tkpurchase-core.js?v=20260313b"></script>
<script src="/static/js/tkpurchase-workreport.js?v=20260312"></script>
<script src="/static/js/tkpurchase-core.js?v=2026031401"></script>
<script src="/static/js/tkpurchase-workreport.js?v=2026031401"></script>
<script>initWorkReportPage();</script>
</body>
</html>