intermittent commit
This commit is contained in:
@@ -234,8 +234,10 @@ export default function CalendarPage({ settings, auth }: {settings: ApiSettings;
|
||||
setLoading(true);
|
||||
setError("");
|
||||
try {
|
||||
const response = await listCalendars(settings);
|
||||
const sourceResponse = await listSyncSources(settings);
|
||||
const [response, sourceResponse] = await Promise.all([
|
||||
listCalendars(settings),
|
||||
listSyncSources(settings)
|
||||
]);
|
||||
setCalendars(response.calendars);
|
||||
setSyncSources(sourceResponse.sources);
|
||||
const ids = response.calendars.map((calendar) => calendar.id);
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
display: grid;
|
||||
grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
|
||||
overflow: hidden;
|
||||
border: 1px solid var(--line);
|
||||
border: var(--border-line);
|
||||
border-radius: 0;
|
||||
background: var(--panel);
|
||||
}
|
||||
@@ -51,7 +51,7 @@
|
||||
align-items: center;
|
||||
gap: 14px;
|
||||
padding: 10px 14px;
|
||||
border-bottom: 1px solid var(--line);
|
||||
border-bottom: var(--border-line);
|
||||
background: var(--panel-header);
|
||||
}
|
||||
|
||||
@@ -121,14 +121,14 @@
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
border-right: 1px solid var(--line);
|
||||
border-right: var(--border-line);
|
||||
background: linear-gradient(180deg, var(--panel-soft), var(--panel));
|
||||
}
|
||||
|
||||
.calendar-sidebar-heading {
|
||||
flex: 0 0 auto;
|
||||
padding: 13px 14px;
|
||||
border-bottom: 1px solid var(--line);
|
||||
border-bottom: var(--border-line);
|
||||
color: var(--muted);
|
||||
font-size: 12px;
|
||||
font-weight: 800;
|
||||
@@ -137,7 +137,7 @@
|
||||
}
|
||||
|
||||
.calendar-sidebar-heading.is-secondary {
|
||||
border-top: 1px solid var(--line);
|
||||
border-top: var(--border-line);
|
||||
}
|
||||
|
||||
.calendar-list,
|
||||
@@ -201,9 +201,9 @@
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
padding: 2px;
|
||||
border: 1px solid #c9c3b9;
|
||||
border: 1px solid var(--control-border);
|
||||
border-radius: 999px;
|
||||
background: #d8d3cb;
|
||||
background: var(--calendar-switch-bg);
|
||||
cursor: pointer;
|
||||
transition: background .16s ease, border-color .16s ease;
|
||||
}
|
||||
@@ -217,8 +217,8 @@
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
border-radius: 50%;
|
||||
background: #fff;
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, .18);
|
||||
background: var(--surface);
|
||||
box-shadow: var(--shadow-thumb);
|
||||
transform: translateX(0);
|
||||
transition: transform .16s ease;
|
||||
}
|
||||
@@ -306,7 +306,7 @@
|
||||
min-width: 0;
|
||||
margin-top: 6px;
|
||||
padding-top: 8px;
|
||||
border-top: 1px solid var(--line);
|
||||
border-top: var(--border-line);
|
||||
}
|
||||
|
||||
.calendar-create-action .btn {
|
||||
@@ -331,7 +331,7 @@
|
||||
.calendar-agenda-group + .calendar-agenda-group {
|
||||
margin-top: 8px;
|
||||
padding-top: 8px;
|
||||
border-top: 1px solid var(--line);
|
||||
border-top: var(--border-line);
|
||||
}
|
||||
|
||||
.calendar-agenda-group h3 {
|
||||
@@ -346,15 +346,15 @@
|
||||
|
||||
.calendar-agenda-item {
|
||||
--calendar-event-color: var(--green);
|
||||
--calendar-event-bg: #edf8f5;
|
||||
--calendar-event-border: #b9d7d0;
|
||||
--calendar-event-bg: var(--calendar-event-bg-default);
|
||||
--calendar-event-border: var(--calendar-event-border-default);
|
||||
display: block;
|
||||
min-height: 28px;
|
||||
padding: 5px 7px;
|
||||
border: 1px solid var(--calendar-event-border);
|
||||
border-left: 4px solid var(--calendar-event-color, var(--green));
|
||||
background: var(--calendar-event-bg);
|
||||
color: #21453e;
|
||||
color: var(--calendar-event-text);
|
||||
}
|
||||
|
||||
.calendar-agenda-item strong {
|
||||
@@ -369,7 +369,7 @@
|
||||
.calendar-agenda-item .calendar-event-separator,
|
||||
.calendar-agenda p {
|
||||
margin: 0;
|
||||
color: #4d6764;
|
||||
color: var(--calendar-event-muted-text);
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
@@ -401,9 +401,9 @@
|
||||
inset: 0 auto auto 0;
|
||||
z-index: 4;
|
||||
padding: 10px;
|
||||
border-right: 1px solid var(--line);
|
||||
border-bottom: 1px solid var(--line);
|
||||
background: rgba(255, 255, 255, 0.9);
|
||||
border-right: var(--border-line);
|
||||
border-bottom: var(--border-line);
|
||||
background: var(--panel-glass-bright);
|
||||
}
|
||||
|
||||
.calendar-week-rows {
|
||||
@@ -439,7 +439,7 @@
|
||||
top: 0;
|
||||
z-index: 2;
|
||||
flex: 0 0 auto;
|
||||
border-bottom: 1px solid var(--line-dark);
|
||||
border-bottom: var(--border-line-dark);
|
||||
background: var(--panel);
|
||||
}
|
||||
|
||||
@@ -459,7 +459,7 @@
|
||||
|
||||
.calendar-week-row {
|
||||
min-height: 132px;
|
||||
border-bottom: 1px solid var(--line);
|
||||
border-bottom: var(--border-line);
|
||||
}
|
||||
|
||||
.calendar-week-rows.is-continuous .calendar-week-row {
|
||||
@@ -476,22 +476,22 @@
|
||||
flex-direction: column;
|
||||
gap: 6px;
|
||||
padding: 8px;
|
||||
border-right: 1px solid var(--line);
|
||||
border-right: var(--border-line);
|
||||
background: var(--surface);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.calendar-day-cell.is-even-month {
|
||||
background: #ffffff;
|
||||
background: var(--surface);
|
||||
}
|
||||
|
||||
.calendar-day-cell.is-odd-month {
|
||||
background: #f8f6f2;
|
||||
background: var(--calendar-grid-bg);
|
||||
}
|
||||
|
||||
.calendar-day-cell.is-muted {
|
||||
color: #8a8278;
|
||||
background: #f1efeb;
|
||||
color: var(--muted);
|
||||
background: var(--control-gradient-end-muted);
|
||||
}
|
||||
|
||||
.calendar-day-cell.is-today {
|
||||
@@ -499,7 +499,7 @@
|
||||
}
|
||||
|
||||
.calendar-day-cell.is-drop-target {
|
||||
background: #e3f3ef;
|
||||
background: var(--calendar-today-bg);
|
||||
box-shadow: inset 0 0 0 2px var(--green);
|
||||
}
|
||||
|
||||
@@ -535,8 +535,8 @@
|
||||
|
||||
.calendar-event-chip {
|
||||
--calendar-event-color: var(--green);
|
||||
--calendar-event-bg: #edf8f5;
|
||||
--calendar-event-border: #b9d7d0;
|
||||
--calendar-event-bg: var(--calendar-event-bg-default);
|
||||
--calendar-event-border: var(--calendar-event-border-default);
|
||||
min-width: 0;
|
||||
min-height: 26px;
|
||||
display: block;
|
||||
@@ -545,7 +545,7 @@
|
||||
border-left: 4px solid var(--calendar-event-color);
|
||||
border-radius: 4px;
|
||||
background: var(--calendar-event-bg);
|
||||
color: #21453e;
|
||||
color: var(--calendar-event-text);
|
||||
cursor: pointer;
|
||||
font: inherit;
|
||||
font-size: 12px;
|
||||
@@ -597,7 +597,7 @@
|
||||
.calendar-event-time,
|
||||
.calendar-event-separator {
|
||||
flex: 0 0 auto;
|
||||
color: #4d6764;
|
||||
color: var(--calendar-event-muted-text);
|
||||
}
|
||||
|
||||
.calendar-more-events {
|
||||
@@ -635,8 +635,8 @@
|
||||
.calendar-time-corner,
|
||||
.calendar-all-day-label,
|
||||
.calendar-all-day-cell {
|
||||
border-bottom: 1px solid var(--line-dark);
|
||||
border-right: 1px solid var(--line);
|
||||
border-bottom: var(--border-line-dark);
|
||||
border-right: var(--border-line);
|
||||
background: var(--panel);
|
||||
}
|
||||
|
||||
@@ -649,12 +649,12 @@
|
||||
}
|
||||
|
||||
.calendar-time-header > header.is-today {
|
||||
background: #e0f0ea;
|
||||
background: var(--calendar-selected-bg);
|
||||
}
|
||||
|
||||
.calendar-time-header > header.is-weekend,
|
||||
.calendar-all-day-cell.is-weekend {
|
||||
background: #f1efeb;
|
||||
background: var(--control-gradient-end-muted);
|
||||
}
|
||||
|
||||
.calendar-time-header > header span {
|
||||
@@ -665,7 +665,7 @@
|
||||
.calendar-all-day-strip {
|
||||
flex: 0 0 auto;
|
||||
min-height: 42px;
|
||||
border-bottom: 1px solid var(--line-dark);
|
||||
border-bottom: var(--border-line-dark);
|
||||
}
|
||||
|
||||
.calendar-all-day-label {
|
||||
@@ -683,7 +683,7 @@
|
||||
}
|
||||
|
||||
.calendar-all-day-cell.is-drop-target {
|
||||
background: #e3f3ef;
|
||||
background: var(--calendar-today-bg);
|
||||
box-shadow: inset 0 0 0 2px var(--green);
|
||||
}
|
||||
|
||||
@@ -712,8 +712,8 @@
|
||||
|
||||
.calendar-hour-label {
|
||||
min-height: 64px;
|
||||
border-bottom: 1px solid var(--line);
|
||||
border-right: 1px solid var(--line);
|
||||
border-bottom: var(--border-line);
|
||||
border-right: var(--border-line);
|
||||
padding: 8px;
|
||||
color: var(--muted);
|
||||
font-size: 12px;
|
||||
@@ -724,17 +724,17 @@
|
||||
position: relative;
|
||||
height: 1536px;
|
||||
min-height: 1536px;
|
||||
border-right: 1px solid var(--line);
|
||||
border-right: var(--border-line);
|
||||
background:
|
||||
linear-gradient(to bottom, var(--calendar-day-shade), var(--calendar-day-shade)),
|
||||
linear-gradient(
|
||||
to bottom,
|
||||
rgba(241, 239, 235, var(--calendar-off-hours-opacity)) 0,
|
||||
rgba(241, 239, 235, var(--calendar-off-hours-opacity)) var(--calendar-work-start-y),
|
||||
rgba(var(--calendar-off-hours-rgb), var(--calendar-off-hours-opacity)) 0,
|
||||
rgba(var(--calendar-off-hours-rgb), var(--calendar-off-hours-opacity)) var(--calendar-work-start-y),
|
||||
transparent var(--calendar-work-start-y),
|
||||
transparent var(--calendar-work-end-y),
|
||||
rgba(241, 239, 235, var(--calendar-off-hours-opacity)) var(--calendar-work-end-y),
|
||||
rgba(241, 239, 235, var(--calendar-off-hours-opacity)) 100%
|
||||
rgba(var(--calendar-off-hours-rgb), var(--calendar-off-hours-opacity)) var(--calendar-work-end-y),
|
||||
rgba(var(--calendar-off-hours-rgb), var(--calendar-off-hours-opacity)) 100%
|
||||
),
|
||||
repeating-linear-gradient(
|
||||
to bottom,
|
||||
@@ -746,11 +746,11 @@
|
||||
}
|
||||
|
||||
.calendar-day-time-column.is-weekend {
|
||||
--calendar-day-shade: rgba(241, 239, 235, .74);
|
||||
--calendar-day-shade: var(--calendar-day-shade);
|
||||
}
|
||||
|
||||
.calendar-day-time-column.is-drop-target {
|
||||
box-shadow: inset 0 0 0 2px rgba(90, 169, 155, .55);
|
||||
box-shadow: var(--calendar-focus-inset);
|
||||
}
|
||||
|
||||
.calendar-time-drop-marker {
|
||||
@@ -778,10 +778,10 @@
|
||||
top: -13px;
|
||||
left: 10px;
|
||||
padding: 2px 6px;
|
||||
border: 1px solid #4f9489;
|
||||
border: 1px solid var(--calendar-success-border);
|
||||
border-radius: 4px;
|
||||
background: var(--green);
|
||||
color: #fff;
|
||||
color: var(--on-accent);
|
||||
font-size: 11px;
|
||||
font-weight: 800;
|
||||
line-height: 1.2;
|
||||
@@ -799,15 +799,15 @@
|
||||
|
||||
.calendar-timed-event {
|
||||
--calendar-event-color: var(--green);
|
||||
--calendar-event-bg: #edf8f5;
|
||||
--calendar-event-border: #b9d7d0;
|
||||
--calendar-event-bg: var(--calendar-event-bg-default);
|
||||
--calendar-event-border: var(--calendar-event-border-default);
|
||||
display: block;
|
||||
padding: 0;
|
||||
overflow: hidden;
|
||||
border: 1px solid var(--calendar-event-border);
|
||||
border-left: 4px solid var(--calendar-event-color);
|
||||
background: var(--calendar-event-bg);
|
||||
color: #21453e;
|
||||
color: var(--calendar-event-text);
|
||||
cursor: pointer;
|
||||
font-size: 12px;
|
||||
}
|
||||
@@ -817,8 +817,8 @@
|
||||
.calendar-timed-event.is-linked-hover,
|
||||
.calendar-timed-overflow:hover,
|
||||
.calendar-timed-overflow:focus-visible {
|
||||
border-color: var(--calendar-event-color, #5aa99b);
|
||||
background: var(--calendar-event-bg, #e3f3ef);
|
||||
border-color: var(--calendar-event-color, var(--success-border));
|
||||
background: var(--calendar-event-bg, var(--calendar-today-bg));
|
||||
outline: none;
|
||||
}
|
||||
|
||||
@@ -837,7 +837,7 @@
|
||||
}
|
||||
|
||||
.calendar-timed-event-content:focus-visible {
|
||||
outline: 2px solid rgba(90, 169, 155, .35);
|
||||
outline: var(--calendar-focus-outline);
|
||||
outline-offset: -2px;
|
||||
}
|
||||
|
||||
@@ -864,7 +864,7 @@
|
||||
width: 34px;
|
||||
height: 2px;
|
||||
border-radius: 999px;
|
||||
background: rgba(33, 69, 62, .46);
|
||||
background: var(--calendar-overlay);
|
||||
content: "";
|
||||
opacity: 0;
|
||||
transform: translateX(-50%);
|
||||
@@ -890,7 +890,7 @@
|
||||
height: 28px;
|
||||
display: grid;
|
||||
place-items: center;
|
||||
border: 1px solid var(--line-dark);
|
||||
border: var(--border-line-dark);
|
||||
background: var(--panel-soft);
|
||||
color: var(--text-strong);
|
||||
cursor: pointer;
|
||||
@@ -963,7 +963,7 @@
|
||||
display: grid;
|
||||
gap: 12px;
|
||||
padding: 12px;
|
||||
border: 1px solid var(--line);
|
||||
border: var(--border-line);
|
||||
border-radius: 6px;
|
||||
background: var(--panel-soft);
|
||||
}
|
||||
@@ -1051,7 +1051,7 @@
|
||||
}
|
||||
|
||||
.calendar-vevent-details {
|
||||
border-top: 1px solid var(--line);
|
||||
border-top: var(--border-line);
|
||||
padding-top: 4px;
|
||||
}
|
||||
|
||||
@@ -1059,7 +1059,7 @@
|
||||
display: grid;
|
||||
gap: 10px;
|
||||
padding: 12px 0;
|
||||
border-top: 1px solid var(--line);
|
||||
border-top: var(--border-line);
|
||||
}
|
||||
|
||||
.calendar-vevent-section:first-of-type {
|
||||
@@ -1085,7 +1085,7 @@
|
||||
|
||||
.calendar-sync-status {
|
||||
padding: 3px 8px;
|
||||
border: 1px solid var(--line-dark);
|
||||
border: var(--border-line-dark);
|
||||
border-radius: 999px;
|
||||
background: var(--surface);
|
||||
color: var(--muted);
|
||||
@@ -1094,8 +1094,8 @@
|
||||
}
|
||||
|
||||
.calendar-sync-status.is-error {
|
||||
border-color: #f0b8b2;
|
||||
background: #fff2f0;
|
||||
border-color: var(--calendar-danger-border);
|
||||
background: var(--calendar-danger-bg);
|
||||
color: var(--red);
|
||||
}
|
||||
|
||||
@@ -1115,7 +1115,7 @@
|
||||
display: grid;
|
||||
gap: 10px;
|
||||
padding: 10px;
|
||||
border: 1px solid var(--line);
|
||||
border: var(--border-line);
|
||||
border-radius: 6px;
|
||||
background: var(--surface);
|
||||
}
|
||||
@@ -1150,9 +1150,9 @@
|
||||
.calendar-form-error {
|
||||
margin: 0;
|
||||
padding: 9px 10px;
|
||||
border: 1px solid #f0b8b2;
|
||||
border: 1px solid var(--calendar-danger-border);
|
||||
border-radius: 4px;
|
||||
background: #fff2f0;
|
||||
background: var(--calendar-danger-bg);
|
||||
color: var(--red);
|
||||
font-size: 13px;
|
||||
}
|
||||
@@ -1166,13 +1166,13 @@
|
||||
}
|
||||
|
||||
.calendar-delete-warning {
|
||||
border: 1px solid #f0b8b2;
|
||||
background: #fff2f0;
|
||||
border: 1px solid var(--calendar-danger-border);
|
||||
background: var(--calendar-danger-bg);
|
||||
color: var(--red);
|
||||
}
|
||||
|
||||
.calendar-form-note {
|
||||
border: 1px solid var(--line);
|
||||
border: var(--border-line);
|
||||
background: var(--panel-soft);
|
||||
color: var(--muted);
|
||||
}
|
||||
@@ -1182,7 +1182,7 @@
|
||||
gap: 10px;
|
||||
margin: 0;
|
||||
padding: 10px;
|
||||
border: 1px solid var(--line);
|
||||
border: var(--border-line);
|
||||
border-radius: 6px;
|
||||
background: var(--panel-soft);
|
||||
}
|
||||
@@ -1275,7 +1275,7 @@
|
||||
|
||||
.calendar-sidebar {
|
||||
border-right: 0;
|
||||
border-bottom: 1px solid var(--line);
|
||||
border-bottom: var(--border-line);
|
||||
}
|
||||
|
||||
.calendar-mode-switch {
|
||||
|
||||
Reference in New Issue
Block a user