- 권한 기반 공통 헤더 컴포넌트 구현 - 모바일 친화적 캘린더 날짜 필터 추가 - 페이지 프리로더 및 키보드 단축키 시스템 구현 - Service Worker 기반 캐싱 시스템 추가 Frontend Changes: - components/common-header.js: 권한 기반 동적 메뉴 생성 - components/mobile-calendar.js: 터치/스와이프 지원 캘린더 - core/permissions.js: 페이지 접근 권한 관리 - core/page-manager.js: 페이지 라이프사이클 관리 - core/page-preloader.js: 페이지 프리로딩 최적화 - core/keyboard-shortcuts.js: 키보드 네비게이션 - css/mobile-calendar.css: 모바일 최적화 캘린더 스타일 - sw.js: 3단계 캐싱 전략 서비스 워커 Removed: - auth-common.js, common-header.js (구버전 파일들)
298 lines
5.1 KiB
CSS
298 lines
5.1 KiB
CSS
/* 모바일 캘린더 스타일 */
|
|
.mobile-calendar {
|
|
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
|
|
user-select: none;
|
|
-webkit-user-select: none;
|
|
-webkit-touch-callout: none;
|
|
}
|
|
|
|
/* 빠른 선택 버튼들 */
|
|
.quick-select-buttons {
|
|
scrollbar-width: none;
|
|
-ms-overflow-style: none;
|
|
}
|
|
|
|
.quick-select-buttons::-webkit-scrollbar {
|
|
display: none;
|
|
}
|
|
|
|
.quick-btn {
|
|
flex-shrink: 0;
|
|
padding: 8px 16px;
|
|
background: #f3f4f6;
|
|
border: 1px solid #e5e7eb;
|
|
border-radius: 20px;
|
|
font-size: 14px;
|
|
font-weight: 500;
|
|
color: #374151;
|
|
transition: all 0.2s ease;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.quick-btn:hover,
|
|
.quick-btn:active {
|
|
background: #3b82f6;
|
|
color: white;
|
|
border-color: #3b82f6;
|
|
transform: scale(0.95);
|
|
}
|
|
|
|
.quick-btn.active {
|
|
background: #3b82f6;
|
|
color: white;
|
|
border-color: #3b82f6;
|
|
}
|
|
|
|
/* 캘린더 헤더 */
|
|
.calendar-header {
|
|
padding: 0 8px;
|
|
}
|
|
|
|
.nav-btn {
|
|
width: 40px;
|
|
height: 40px;
|
|
border-radius: 50%;
|
|
background: #f9fafb;
|
|
border: 1px solid #e5e7eb;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
color: #6b7280;
|
|
transition: all 0.2s ease;
|
|
}
|
|
|
|
.nav-btn:hover,
|
|
.nav-btn:active {
|
|
background: #3b82f6;
|
|
color: white;
|
|
border-color: #3b82f6;
|
|
transform: scale(0.9);
|
|
}
|
|
|
|
.month-year {
|
|
color: #1f2937;
|
|
font-weight: 600;
|
|
min-width: 120px;
|
|
text-align: center;
|
|
}
|
|
|
|
/* 요일 헤더 */
|
|
.weekdays {
|
|
margin-bottom: 8px;
|
|
}
|
|
|
|
.weekday {
|
|
text-align: center;
|
|
font-size: 12px;
|
|
font-weight: 600;
|
|
color: #6b7280;
|
|
padding: 8px 4px;
|
|
text-transform: uppercase;
|
|
}
|
|
|
|
.weekday:first-child {
|
|
color: #ef4444; /* 일요일 빨간색 */
|
|
}
|
|
|
|
.weekday:last-child {
|
|
color: #3b82f6; /* 토요일 파란색 */
|
|
}
|
|
|
|
/* 캘린더 그리드 */
|
|
.calendar-grid {
|
|
gap: 2px;
|
|
}
|
|
|
|
.calendar-day {
|
|
aspect-ratio: 1;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 14px;
|
|
font-weight: 500;
|
|
border-radius: 8px;
|
|
cursor: pointer;
|
|
transition: all 0.15s ease;
|
|
position: relative;
|
|
background: white;
|
|
border: 1px solid transparent;
|
|
min-height: 40px;
|
|
}
|
|
|
|
.calendar-day:hover {
|
|
background: #eff6ff;
|
|
border-color: #bfdbfe;
|
|
transform: scale(1.05);
|
|
}
|
|
|
|
.calendar-day:active {
|
|
transform: scale(0.95);
|
|
}
|
|
|
|
/* 다른 달 날짜 */
|
|
.calendar-day.other-month {
|
|
color: #d1d5db;
|
|
background: #f9fafb;
|
|
}
|
|
|
|
.calendar-day.other-month:hover {
|
|
background: #f3f4f6;
|
|
color: #9ca3af;
|
|
}
|
|
|
|
/* 오늘 날짜 */
|
|
.calendar-day.today {
|
|
background: #fef3c7;
|
|
color: #92400e;
|
|
font-weight: 700;
|
|
border-color: #f59e0b;
|
|
}
|
|
|
|
.calendar-day.today:hover {
|
|
background: #fde68a;
|
|
}
|
|
|
|
/* 선택된 날짜 */
|
|
.calendar-day.selected {
|
|
background: #dbeafe;
|
|
color: #1e40af;
|
|
border-color: #3b82f6;
|
|
}
|
|
|
|
/* 범위 시작/끝 */
|
|
.calendar-day.range-start,
|
|
.calendar-day.range-end {
|
|
background: #3b82f6;
|
|
color: white;
|
|
font-weight: 700;
|
|
}
|
|
|
|
.calendar-day.range-start:hover,
|
|
.calendar-day.range-end:hover {
|
|
background: #2563eb;
|
|
}
|
|
|
|
/* 범위 시작일에 표시 */
|
|
.calendar-day.range-start::before {
|
|
content: '';
|
|
position: absolute;
|
|
top: 2px;
|
|
left: 2px;
|
|
width: 6px;
|
|
height: 6px;
|
|
background: #10b981;
|
|
border-radius: 50%;
|
|
}
|
|
|
|
/* 범위 끝일에 표시 */
|
|
.calendar-day.range-end::after {
|
|
content: '';
|
|
position: absolute;
|
|
bottom: 2px;
|
|
right: 2px;
|
|
width: 6px;
|
|
height: 6px;
|
|
background: #ef4444;
|
|
border-radius: 50%;
|
|
}
|
|
|
|
/* 선택된 범위 표시 */
|
|
.selected-range {
|
|
border: 1px solid #bfdbfe;
|
|
animation: slideIn 0.3s ease;
|
|
}
|
|
|
|
@keyframes slideIn {
|
|
from {
|
|
opacity: 0;
|
|
transform: translateY(-10px);
|
|
}
|
|
to {
|
|
opacity: 1;
|
|
transform: translateY(0);
|
|
}
|
|
}
|
|
|
|
.clear-btn {
|
|
width: 24px;
|
|
height: 24px;
|
|
border-radius: 50%;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 12px;
|
|
transition: all 0.2s ease;
|
|
}
|
|
|
|
.clear-btn:hover {
|
|
background: rgba(59, 130, 246, 0.1);
|
|
}
|
|
|
|
/* 사용법 안내 */
|
|
.usage-hint {
|
|
opacity: 0.7;
|
|
line-height: 1.4;
|
|
}
|
|
|
|
/* 터치 디바이스 최적화 */
|
|
@media (hover: none) and (pointer: coarse) {
|
|
.calendar-day {
|
|
min-height: 44px; /* 터치 타겟 최소 크기 */
|
|
}
|
|
|
|
.nav-btn {
|
|
min-width: 44px;
|
|
min-height: 44px;
|
|
}
|
|
|
|
.quick-btn {
|
|
min-height: 44px;
|
|
padding: 12px 16px;
|
|
}
|
|
}
|
|
|
|
/* 작은 화면 최적화 */
|
|
@media (max-width: 375px) {
|
|
.calendar-day {
|
|
font-size: 13px;
|
|
min-height: 36px;
|
|
}
|
|
|
|
.quick-btn {
|
|
padding: 6px 12px;
|
|
font-size: 13px;
|
|
}
|
|
|
|
.month-year {
|
|
font-size: 16px;
|
|
}
|
|
}
|
|
|
|
/* 다크 모드 지원 */
|
|
@media (prefers-color-scheme: dark) {
|
|
.mobile-calendar {
|
|
color: #f9fafb;
|
|
}
|
|
|
|
.calendar-day {
|
|
background: #374151;
|
|
color: #f9fafb;
|
|
}
|
|
|
|
.calendar-day:hover {
|
|
background: #4b5563;
|
|
}
|
|
|
|
.nav-btn {
|
|
background: #374151;
|
|
color: #f9fafb;
|
|
border-color: #4b5563;
|
|
}
|
|
|
|
.quick-btn {
|
|
background: #374151;
|
|
color: #f9fafb;
|
|
border-color: #4b5563;
|
|
}
|
|
}
|