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.
184 lines
3.1 KiB
CSS
184 lines
3.1 KiB
CSS
/* === Loading / error / access denied / current duty view */
|
|
.loading {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
gap: 10px;
|
|
padding: 12px;
|
|
color: var(--muted);
|
|
text-align: center;
|
|
}
|
|
|
|
.loading__spinner {
|
|
display: block;
|
|
width: 20px;
|
|
height: 20px;
|
|
border: 2px solid transparent;
|
|
border-top-color: var(--accent);
|
|
border-radius: 50%;
|
|
animation: loading-spin 0.8s linear infinite;
|
|
}
|
|
|
|
@media (prefers-reduced-motion: reduce) {
|
|
.loading__spinner {
|
|
animation: none;
|
|
border-top-color: var(--accent);
|
|
border-right-color: color-mix(in srgb, var(--accent) 50%, transparent);
|
|
}
|
|
}
|
|
|
|
@keyframes loading-spin {
|
|
to {
|
|
transform: rotate(360deg);
|
|
}
|
|
}
|
|
|
|
.loading, .error {
|
|
text-align: center;
|
|
padding: 12px;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.error,
|
|
.access-denied {
|
|
transition: opacity 0.2s ease-out;
|
|
}
|
|
|
|
.error {
|
|
color: var(--error);
|
|
}
|
|
|
|
.error[hidden], .loading.hidden,
|
|
.current-duty-view.hidden {
|
|
display: none !important;
|
|
}
|
|
|
|
/* Current duty view (Mini App deep link startapp=duty) */
|
|
[data-view="currentDuty"] .calendar-sticky,
|
|
[data-view="currentDuty"] .duty-list {
|
|
display: none !important;
|
|
}
|
|
|
|
.current-duty-view {
|
|
padding: 24px 16px;
|
|
min-height: 60vh;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
.current-duty-card {
|
|
background: var(--surface);
|
|
border-radius: 12px;
|
|
padding: 24px;
|
|
max-width: 360px;
|
|
width: 100%;
|
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
|
|
}
|
|
|
|
.current-duty-title {
|
|
margin: 0 0 16px 0;
|
|
font-size: 1.25rem;
|
|
font-weight: 600;
|
|
color: var(--text);
|
|
}
|
|
|
|
.current-duty-name {
|
|
margin: 0 0 8px 0;
|
|
font-size: 1.5rem;
|
|
font-weight: 600;
|
|
color: var(--duty);
|
|
}
|
|
|
|
.current-duty-shift {
|
|
margin: 0 0 12px 0;
|
|
font-size: 0.95rem;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.current-duty-no-duty,
|
|
.current-duty-error {
|
|
margin: 0 0 16px 0;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.current-duty-error {
|
|
color: var(--error);
|
|
}
|
|
|
|
.current-duty-contact-row {
|
|
margin: 12px 0 20px 0;
|
|
}
|
|
|
|
.current-duty-contact {
|
|
display: inline-block;
|
|
margin-right: 12px;
|
|
font-size: 0.95rem;
|
|
}
|
|
|
|
.current-duty-contact-link,
|
|
.current-duty-contact-phone,
|
|
.current-duty-contact-username {
|
|
color: var(--accent);
|
|
text-decoration: none;
|
|
}
|
|
|
|
.current-duty-contact-link:hover,
|
|
.current-duty-contact-phone:hover,
|
|
.current-duty-contact-username:hover {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
.current-duty-back-btn {
|
|
display: block;
|
|
width: 100%;
|
|
padding: 12px 16px;
|
|
margin-top: 8px;
|
|
font-size: 1rem;
|
|
font-weight: 500;
|
|
color: var(--bg);
|
|
background: var(--accent);
|
|
border: none;
|
|
border-radius: 8px;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.current-duty-back-btn:hover {
|
|
opacity: 0.9;
|
|
}
|
|
|
|
.current-duty-back-btn:focus-visible {
|
|
outline: 2px solid var(--accent);
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
.current-duty-loading {
|
|
text-align: center;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.access-denied {
|
|
text-align: center;
|
|
padding: 24px 12px;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.access-denied p {
|
|
margin: 0 0 8px 0;
|
|
}
|
|
|
|
.access-denied p:first-child {
|
|
color: var(--error);
|
|
font-weight: 600;
|
|
}
|
|
|
|
.access-denied .access-denied-detail {
|
|
margin-top: 8px;
|
|
font-size: 0.9rem;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.access-denied[hidden] {
|
|
display: none !important;
|
|
}
|