Einige kleine verbesserungen #1
@@ -975,15 +975,11 @@ a { color: var(--primary); text-decoration: none; }
|
|||||||
}
|
}
|
||||||
.ctx-item:hover { background: var(--bg-hover); }
|
.ctx-item:hover { background: var(--bg-hover); }
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
/* ── Event Popup ──────────────────────────────────────────
|
/* ── Event Popup ──────────────────────────────────────────
|
||||||
Layout: Color-Dot + Title links, kleine Icon-Toolbar rechts oben.
|
Layout: Color-Dot + Title links, kleine Icon-Toolbar rechts oben.
|
||||||
Icons sind im Ruhezustand transparent (nur das SVG selbst sichtbar),
|
Icons sind im Ruhezustand transparent (nur das SVG selbst sichtbar),
|
||||||
bekommen erst beim Hover einen runden farbigen Hintergrund. Wirkt
|
bekommen erst beim Hover einen runden farbigen Hintergrund. Wirkt
|
||||||
modern und lässt dem Titel die meiste Breite. */
|
modern und lässt dem Titel die meiste Breite. */
|
||||||
=======
|
|
||||||
/* ── Event Popup ────────────────────────────────────────── */
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
.event-popup {
|
.event-popup {
|
||||||
position: fixed; z-index: 600;
|
position: fixed; z-index: 600;
|
||||||
background: var(--bg-surface);
|
background: var(--bg-surface);
|
||||||
@@ -1701,24 +1697,12 @@ a { color: var(--primary); text-decoration: none; }
|
|||||||
.topbar-left { gap: 0; }
|
.topbar-left { gap: 0; }
|
||||||
.topbar-right { gap: 0; }
|
.topbar-right { gap: 0; }
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
/* Event-Popup auf Mobile: an Viewport-Breite anpassen */
|
/* Event-Popup auf Mobile: an Viewport-Breite anpassen */
|
||||||
.event-popup { width: min(94vw, 380px); max-width: 94vw; }
|
.event-popup { width: min(94vw, 380px); max-width: 94vw; }
|
||||||
.popup-header { padding: 10px 8px 10px 14px; }
|
.popup-header { padding: 10px 8px 10px 14px; }
|
||||||
.popup-header h4 { font-size: 13.5px; }
|
.popup-header h4 { font-size: 13.5px; }
|
||||||
.popup-icon-btn { width: 32px; height: 32px; }
|
.popup-icon-btn { width: 32px; height: 32px; }
|
||||||
.popup-icon-btn svg { width: 16px; height: 16px; }
|
.popup-icon-btn svg { width: 16px; height: 16px; }
|
||||||
=======
|
|
||||||
/* Event-Popup: Buttons kompakt halten, kein 44px-Override ───── */
|
|
||||||
.event-popup .icon-btn {
|
|
||||||
min-width: 32px !important;
|
|
||||||
min-height: 32px !important;
|
|
||||||
width: 32px;
|
|
||||||
height: 32px;
|
|
||||||
}
|
|
||||||
.event-popup .popup-header { gap: 2px; padding: 10px 12px; }
|
|
||||||
.event-popup { width: min(92vw, 340px); max-width: 92vw; }
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
|
|
||||||
/* Monatsansicht: Startzeit ausblenden — nur Titel anzeigen ──── */
|
/* Monatsansicht: Startzeit ausblenden — nur Titel anzeigen ──── */
|
||||||
.month-event-time { display: none; }
|
.month-event-time { display: none; }
|
||||||
|
|||||||
@@ -123,7 +123,6 @@ export async function initCalendar() {
|
|||||||
bindProfileModal();
|
bindProfileModal();
|
||||||
bindSwipeNavigation();
|
bindSwipeNavigation();
|
||||||
handleHAOAuthReturn();
|
handleHAOAuthReturn();
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
// Browser-Back/Forward: URL-Hash → State synchronisieren
|
// Browser-Back/Forward: URL-Hash → State synchronisieren
|
||||||
window.addEventListener('hashchange', () => {
|
window.addEventListener('hashchange', () => {
|
||||||
@@ -140,8 +139,6 @@ export async function initCalendar() {
|
|||||||
}
|
}
|
||||||
if (changed) fetchAndRender();
|
if (changed) fetchAndRender();
|
||||||
});
|
});
|
||||||
=======
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function handleHAOAuthReturn() {
|
function handleHAOAuthReturn() {
|
||||||
@@ -155,11 +152,7 @@ function handleHAOAuthReturn() {
|
|||||||
};
|
};
|
||||||
if (params.has('ha_connected')) {
|
if (params.has('ha_connected')) {
|
||||||
showToast('Home Assistant verbunden');
|
showToast('Home Assistant verbunden');
|
||||||
<<<<<<< HEAD
|
|
||||||
window.history.replaceState({}, '', window.location.pathname + window.location.hash);
|
window.history.replaceState({}, '', window.location.pathname + window.location.hash);
|
||||||
=======
|
|
||||||
window.history.replaceState({}, '', window.location.pathname);
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
fetchAndRender(true);
|
fetchAndRender(true);
|
||||||
api.get('/homeassistant/accounts').then(accs => {
|
api.get('/homeassistant/accounts').then(accs => {
|
||||||
state.haAccounts = accs || [];
|
state.haAccounts = accs || [];
|
||||||
@@ -169,11 +162,7 @@ function handleHAOAuthReturn() {
|
|||||||
} else if (params.has('ha_error')) {
|
} else if (params.has('ha_error')) {
|
||||||
const code = params.get('ha_error');
|
const code = params.get('ha_error');
|
||||||
showToast(errMap[code] || `HA-Anmeldung fehlgeschlagen: ${code}`, true);
|
showToast(errMap[code] || `HA-Anmeldung fehlgeschlagen: ${code}`, true);
|
||||||
<<<<<<< HEAD
|
|
||||||
window.history.replaceState({}, '', window.location.pathname + window.location.hash);
|
window.history.replaceState({}, '', window.location.pathname + window.location.hash);
|
||||||
=======
|
|
||||||
window.history.replaceState({}, '', window.location.pathname);
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -268,10 +257,7 @@ async function fetchAndRender(force = false, silent = false) {
|
|||||||
renderView();
|
renderView();
|
||||||
updateTitle();
|
updateTitle();
|
||||||
renderMiniCal();
|
renderMiniCal();
|
||||||
<<<<<<< HEAD
|
|
||||||
writeUrlState();
|
writeUrlState();
|
||||||
=======
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
prefetchIfNeeded(start, end); // extend cache in background if approaching an edge
|
prefetchIfNeeded(start, end); // extend cache in background if approaching an edge
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -158,11 +158,7 @@ const translations = {
|
|||||||
rec_every: 'Alle', rec_days: 'Tage', rec_weeks: 'Wochen', rec_months: 'Monate',
|
rec_every: 'Alle', rec_days: 'Tage', rec_weeks: 'Wochen', rec_months: 'Monate',
|
||||||
rec_ends: 'Endet', rec_never: 'Nie', rec_after_count: 'Nach Anzahl',
|
rec_ends: 'Endet', rec_never: 'Nie', rec_after_count: 'Nach Anzahl',
|
||||||
rec_on_date: 'Am Datum', rec_occurrences: 'Termine',
|
rec_on_date: 'Am Datum', rec_occurrences: 'Termine',
|
||||||
<<<<<<< HEAD
|
|
||||||
copy_to_calendar: 'Kopieren nach…', event_copied: 'Termin kopiert', copy: 'Kopieren',
|
copy_to_calendar: 'Kopieren nach…', event_copied: 'Termin kopiert', copy: 'Kopieren',
|
||||||
=======
|
|
||||||
copy_to_calendar: 'Kopieren nach…', event_copied: 'Termin kopiert',
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
edit_before_copy: 'Vor dem Kopieren bearbeiten',
|
edit_before_copy: 'Vor dem Kopieren bearbeiten',
|
||||||
event_updated: 'Termin aktualisiert', event_created: 'Termin erstellt',
|
event_updated: 'Termin aktualisiert', event_created: 'Termin erstellt',
|
||||||
confirm_delete_event: '"{title}" wirklich löschen?',
|
confirm_delete_event: '"{title}" wirklich löschen?',
|
||||||
@@ -377,11 +373,7 @@ const translations = {
|
|||||||
rec_every: 'Every', rec_days: 'days', rec_weeks: 'weeks', rec_months: 'months',
|
rec_every: 'Every', rec_days: 'days', rec_weeks: 'weeks', rec_months: 'months',
|
||||||
rec_ends: 'Ends', rec_never: 'Never', rec_after_count: 'After count',
|
rec_ends: 'Ends', rec_never: 'Never', rec_after_count: 'After count',
|
||||||
rec_on_date: 'On date', rec_occurrences: 'occurrences',
|
rec_on_date: 'On date', rec_occurrences: 'occurrences',
|
||||||
<<<<<<< HEAD
|
|
||||||
copy_to_calendar: 'Copy to…', event_copied: 'Event copied', copy: 'Copy',
|
copy_to_calendar: 'Copy to…', event_copied: 'Event copied', copy: 'Copy',
|
||||||
=======
|
|
||||||
copy_to_calendar: 'Copy to…', event_copied: 'Event copied',
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
edit_before_copy: 'Edit before copying',
|
edit_before_copy: 'Edit before copying',
|
||||||
event_updated: 'Event updated', event_created: 'Event created',
|
event_updated: 'Event updated', event_created: 'Event created',
|
||||||
confirm_delete_event: 'Really delete "{title}"?',
|
confirm_delete_event: 'Really delete "{title}"?',
|
||||||
|
|||||||
@@ -1,2 +1,2 @@
|
|||||||
// Increment APP_VERSION with every code change
|
// Increment APP_VERSION with every code change
|
||||||
export const APP_VERSION = 'v21';
|
export const APP_VERSION = 'v22';
|
||||||
|
|||||||
@@ -63,7 +63,6 @@ export function renderWeek(container, currentDate, events, onSlotClick, onEventC
|
|||||||
const color = ev.color || ev.calendarColor || '#4285f4';
|
const color = ev.color || ev.calendarColor || '#4285f4';
|
||||||
const pastCls = isPast(ev) ? 'past' : '';
|
const pastCls = isPast(ev) ? 'past' : '';
|
||||||
const multiCls = isMultiTimed ? 'multiday-timed' : '';
|
const multiCls = isMultiTimed ? 'multiday-timed' : '';
|
||||||
<<<<<<< HEAD
|
|
||||||
// continues-left/right: compute on date-only basis for all-day events
|
// continues-left/right: compute on date-only basis for all-day events
|
||||||
let evStart = new Date(ev.start);
|
let evStart = new Date(ev.start);
|
||||||
let evEnd = new Date(ev.end);
|
let evEnd = new Date(ev.end);
|
||||||
@@ -77,10 +76,6 @@ export function renderWeek(container, currentDate, events, onSlotClick, onEventC
|
|||||||
const lastDay = new Date(days[n-1]); lastDay.setHours(0, 0, 0, 0);
|
const lastDay = new Date(days[n-1]); lastDay.setHours(0, 0, 0, 0);
|
||||||
const cL = evStart < firstDay ? 'continues-left' : '';
|
const cL = evStart < firstDay ? 'continues-left' : '';
|
||||||
const cR = (ev.allDay ? evEnd > lastDay : evEnd > lastDayMidnight) ? 'continues-right' : '';
|
const cR = (ev.allDay ? evEnd > lastDay : evEnd > lastDayMidnight) ? 'continues-right' : '';
|
||||||
=======
|
|
||||||
const cL = new Date(ev.start) < new Date(days[0]) ? 'continues-left' : '';
|
|
||||||
const cR = new Date(ev.end) > (() => { const d = new Date(days[n-1]); d.setHours(24,0,0,0); return d; })() ? 'continues-right' : '';
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
const label = isMultiTimed && isSameDay(new Date(ev.start), days[colStart])
|
const label = isMultiTimed && isSameDay(new Date(ev.start), days[colStart])
|
||||||
? `${fmtTime(new Date(ev.start))} ${ev.title}`
|
? `${fmtTime(new Date(ev.start))} ${ev.title}`
|
||||||
: ev.title;
|
: ev.title;
|
||||||
@@ -252,7 +247,6 @@ function renderNowLine(container, days, hourH = 60) {
|
|||||||
function layoutWeekAllDay(evs, days) {
|
function layoutWeekAllDay(evs, days) {
|
||||||
const items = [];
|
const items = [];
|
||||||
evs.forEach(ev => {
|
evs.forEach(ev => {
|
||||||
<<<<<<< HEAD
|
|
||||||
// For all-day events, normalize to date-only with inclusive end-day
|
// For all-day events, normalize to date-only with inclusive end-day
|
||||||
// (iCal stores exclusive end → subtract 1). For timed events, keep
|
// (iCal stores exclusive end → subtract 1). For timed events, keep
|
||||||
// the original strict-overlap logic so events ending exactly at
|
// the original strict-overlap logic so events ending exactly at
|
||||||
@@ -275,13 +269,6 @@ function layoutWeekAllDay(evs, days) {
|
|||||||
matches = new Date(ev.start) < de && new Date(ev.end) > ds;
|
matches = new Date(ev.start) < de && new Date(ev.end) > ds;
|
||||||
}
|
}
|
||||||
if (matches) {
|
if (matches) {
|
||||||
=======
|
|
||||||
let colStart = -1, colEnd = -1;
|
|
||||||
days.forEach((day, i) => {
|
|
||||||
const ds = new Date(day); ds.setHours(0, 0, 0, 0);
|
|
||||||
const de = new Date(day); de.setHours(24, 0, 0, 0);
|
|
||||||
if (new Date(ev.start) < de && new Date(ev.end) > ds) {
|
|
||||||
>>>>>>> e744b1829e99db6b80922f75542ced329138e474
|
|
||||||
if (colStart === -1) colStart = i;
|
if (colStart === -1) colStart = i;
|
||||||
colEnd = i;
|
colEnd = i;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
// the entry HTML / version files). New releases take effect on the next
|
// the entry HTML / version files). New releases take effect on the next
|
||||||
// reload, no manual SW unregister required.
|
// reload, no manual SW unregister required.
|
||||||
|
|
||||||
const CACHE_VERSION = 'calendarr-v21';
|
const CACHE_VERSION = 'calendarr-v22';
|
||||||
const OFFLINE_SHELL = ['/', '/index.html'];
|
const OFFLINE_SHELL = ['/', '/index.html'];
|
||||||
|
|
||||||
self.addEventListener('install', event => {
|
self.addEventListener('install', event => {
|
||||||
|
|||||||
Reference in New Issue
Block a user