feat: enhance CI workflow and update webapp styles
Some checks failed
CI / lint-and-test (push) Failing after 45s
Some checks failed
CI / lint-and-test (push) Failing after 45s
- Added Node.js setup and webapp testing steps to the CI workflow for improved integration. - Updated HTML to link multiple CSS files for better modularity and organization of styles. - Removed deprecated `style.css` and introduced new CSS files for base styles, calendar, day detail, hints, markers, states, and duty list to enhance maintainability and readability. - Implemented new styles for improved presentation of duty information and user interactions. - Added unit tests for new API functions and contact link rendering to ensure functionality and reliability.
This commit is contained in:
185
webapp/css/calendar.css
Normal file
185
webapp/css/calendar.css
Normal file
@@ -0,0 +1,185 @@
|
||||
/* === Calendar: header, nav, weekdays, grid, day cells */
|
||||
.header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
|
||||
.header[hidden],
|
||||
.weekdays[hidden] {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.nav {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
border: none;
|
||||
border-radius: 10px;
|
||||
background: var(--surface);
|
||||
color: var(--accent);
|
||||
font-size: 24px;
|
||||
line-height: 1;
|
||||
cursor: pointer;
|
||||
transition: opacity var(--transition-fast), transform var(--transition-fast);
|
||||
}
|
||||
|
||||
.nav:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.nav:focus-visible {
|
||||
outline: 2px solid var(--accent);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
|
||||
.nav:active {
|
||||
transform: scale(0.95);
|
||||
}
|
||||
|
||||
.nav:disabled {
|
||||
opacity: 0.5;
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
.title {
|
||||
margin: 0;
|
||||
font-size: 1.1rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.weekdays {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(7, 1fr);
|
||||
gap: 2px;
|
||||
margin-bottom: 6px;
|
||||
font-size: 0.75rem;
|
||||
color: var(--muted);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.calendar-sticky {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 10;
|
||||
background: var(--bg);
|
||||
padding-bottom: 12px;
|
||||
margin-bottom: 4px;
|
||||
touch-action: pan-y;
|
||||
transition: box-shadow var(--transition-fast) ease-out;
|
||||
}
|
||||
|
||||
.calendar-sticky.is-scrolled {
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
||||
}
|
||||
|
||||
.calendar {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(7, 1fr);
|
||||
gap: 4px;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.day {
|
||||
position: relative;
|
||||
aspect-ratio: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
padding: 4px;
|
||||
border-radius: 8px;
|
||||
font-size: 0.85rem;
|
||||
background: var(--surface);
|
||||
min-width: 0;
|
||||
min-height: 0;
|
||||
overflow: hidden;
|
||||
transition: background-color var(--transition-fast), transform var(--transition-fast);
|
||||
}
|
||||
|
||||
.day.other-month {
|
||||
opacity: 0.4;
|
||||
}
|
||||
|
||||
.day.today {
|
||||
background: var(--today);
|
||||
color: var(--bg);
|
||||
}
|
||||
|
||||
.day.has-duty .num {
|
||||
font-weight: 700;
|
||||
}
|
||||
|
||||
.day.holiday {
|
||||
background: linear-gradient(135deg, var(--surface) 0%, color-mix(in srgb, var(--today) 15%, transparent) 100%);
|
||||
border: 1px solid color-mix(in srgb, var(--today) 35%, transparent);
|
||||
}
|
||||
|
||||
/* Today + external calendar: same solid "today" look as weekday, plus a border to show it has external events */
|
||||
.day.today.holiday {
|
||||
background: var(--today);
|
||||
color: var(--bg);
|
||||
border: 1px solid color-mix(in srgb, var(--bg) 50%, transparent);
|
||||
}
|
||||
|
||||
.day {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.day:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.day:focus-visible {
|
||||
outline: 2px solid var(--accent);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
|
||||
.day:active {
|
||||
transform: scale(0.98);
|
||||
}
|
||||
|
||||
.day-indicator {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
gap: 2px;
|
||||
margin-top: 6px;
|
||||
}
|
||||
|
||||
.day-indicator-dot {
|
||||
width: 6px;
|
||||
height: 6px;
|
||||
border-radius: 50%;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.day-indicator-dot.duty {
|
||||
background: var(--duty);
|
||||
}
|
||||
|
||||
.day-indicator-dot.unavailable {
|
||||
background: var(--unavailable);
|
||||
}
|
||||
|
||||
.day-indicator-dot.vacation {
|
||||
background: var(--vacation);
|
||||
}
|
||||
|
||||
.day-indicator-dot.events {
|
||||
background: var(--accent);
|
||||
}
|
||||
|
||||
/* On "today" cell: dots darkened for contrast on --today background */
|
||||
.day.today .day-indicator-dot.duty {
|
||||
background: color-mix(in srgb, var(--duty) 65%, var(--bg));
|
||||
}
|
||||
.day.today .day-indicator-dot.unavailable {
|
||||
background: color-mix(in srgb, var(--unavailable) 65%, var(--bg));
|
||||
}
|
||||
.day.today .day-indicator-dot.vacation {
|
||||
background: color-mix(in srgb, var(--vacation) 65%, var(--bg));
|
||||
}
|
||||
.day.today .day-indicator-dot.events {
|
||||
background: color-mix(in srgb, var(--accent) 65%, var(--bg));
|
||||
}
|
||||
Reference in New Issue
Block a user