Files
raucao 11f8d3f049 WIP: Add calendar settings and a nested modal stack
Add a 'days with events' preference (default 3, range 1-7) that drives the upcoming events widget, and extend the fetch window to 8 days so the largest window can populate.

Add a Calendar settings pane (moved under Integrations) that lists the connected CalDAV/ICS sources in a two-column grid with add/edit/remove, and remove calendars from Manage Integrations.

Turn the modal service into a stack so add/edit forms open on top of the settings dialog, with one dialog per level, per-entry title ids, and a softened stacked backdrop.

Move CALENDAR_ACTOR into its own config module to break the calendar/caldav/ics import cycle.
2026-11-06 15:48:08 +04:00

33 lines
835 B
Plaintext

import Component from '@glimmer/component';
import { action } from '@ember/object';
import { fn } from '@ember/helper';
import { service } from '@ember/service';
import ModalEntry from './modal-entry.gjs';
// Renders the modal stack: one <dialog> per entry, so a form can open on top of
// the settings dialog without replacing it.
export default class ModalHostComponent extends Component {
@service modal;
@action
finished(descriptor) {
this.modal.finished(descriptor);
}
@action
replace(descriptor) {
this.modal.replace(descriptor);
}
<template>
{{#each this.modal.stack as |descriptor index|}}
<ModalEntry
@descriptor={{descriptor}}
@depth={{index}}
@onFinished={{fn this.finished descriptor}}
@onReplace={{this.replace}}
/>
{{/each}}
</template>
}