@bimetal/calendar-headless 0.34.0 → 0.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +57 -0
- package/README.md +1 -1
- package/dist/.tsbuildinfo +1 -1
- package/dist/click-intent.d.ts +2 -0
- package/dist/click-intent.d.ts.map +1 -1
- package/dist/click-intent.js +2 -0
- package/dist/click-intent.js.map +1 -1
- package/dist/controller/agenda.d.ts +4 -1
- package/dist/controller/agenda.d.ts.map +1 -1
- package/dist/controller/agenda.js +17 -8
- package/dist/controller/agenda.js.map +1 -1
- package/dist/controller/config.d.ts +5 -0
- package/dist/controller/config.d.ts.map +1 -1
- package/dist/controller/config.js +27 -3
- package/dist/controller/config.js.map +1 -1
- package/dist/controller/create-controller.d.ts +20 -0
- package/dist/controller/create-controller.d.ts.map +1 -1
- package/dist/controller/create-controller.js +839 -93
- package/dist/controller/create-controller.js.map +1 -1
- package/dist/controller/types.d.ts +343 -39
- package/dist/controller/types.d.ts.map +1 -1
- package/dist/controller/view-configs.d.ts +4 -2
- package/dist/controller/view-configs.d.ts.map +1 -1
- package/dist/controller/view-configs.js +12 -6
- package/dist/controller/view-configs.js.map +1 -1
- package/dist/date-strings.d.ts +20 -10
- package/dist/date-strings.d.ts.map +1 -1
- package/dist/date-strings.js +28 -6
- package/dist/date-strings.js.map +1 -1
- package/dist/defaults.d.ts +0 -2
- package/dist/defaults.d.ts.map +1 -1
- package/dist/defaults.js +0 -2
- package/dist/defaults.js.map +1 -1
- package/dist/dialog-keys.d.ts +44 -0
- package/dist/dialog-keys.d.ts.map +1 -0
- package/dist/dialog-keys.js +32 -0
- package/dist/dialog-keys.js.map +1 -0
- package/dist/drag-helpers.d.ts +0 -11
- package/dist/drag-helpers.d.ts.map +1 -1
- package/dist/drag-helpers.js +14 -21
- package/dist/drag-helpers.js.map +1 -1
- package/dist/drag-preview.d.ts +1 -0
- package/dist/drag-preview.d.ts.map +1 -1
- package/dist/drag-preview.js +2 -1
- package/dist/drag-preview.js.map +1 -1
- package/dist/event-actions.d.ts +33 -16
- package/dist/event-actions.d.ts.map +1 -1
- package/dist/event-actions.js +38 -31
- package/dist/event-actions.js.map +1 -1
- package/dist/grid-geometry.d.ts +3 -2
- package/dist/grid-geometry.d.ts.map +1 -1
- package/dist/grid-geometry.js +16 -11
- package/dist/grid-geometry.js.map +1 -1
- package/dist/history-entries.d.ts +78 -0
- package/dist/history-entries.d.ts.map +1 -0
- package/dist/history-entries.js +91 -0
- package/dist/history-entries.js.map +1 -0
- package/dist/index.d.ts +20 -12
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +23 -9
- package/dist/index.js.map +1 -1
- package/dist/pointer-drag-gesture.d.ts +68 -0
- package/dist/pointer-drag-gesture.d.ts.map +1 -0
- package/dist/pointer-drag-gesture.js +73 -0
- package/dist/pointer-drag-gesture.js.map +1 -0
- package/dist/validate-save.d.ts.map +1 -1
- package/dist/validate-save.js +12 -1
- package/dist/validate-save.js.map +1 -1
- package/package.json +8 -8
|
@@ -6,10 +6,9 @@
|
|
|
6
6
|
* only the parts that carry a framework component reference (custom-view
|
|
7
7
|
* component, custom dialog component, render-slot ReactNode/Snippet/etc.).
|
|
8
8
|
*/
|
|
9
|
-
import type { CalendarEvent, CalendarDateTime, TimeRange, ViewType, CoreConfig, Resource, RecurrenceFrequency } from '@bimetal/calendar-core';
|
|
9
|
+
import type { CalendarEvent, CalendarDateTime, TimeRange, ViewType, BuiltInViewType, CoreConfig, Resource, RecurrenceFrequency, Month } from '@bimetal/calendar-core';
|
|
10
10
|
import type { CalendarStore, DomainEvent, Unsubscribe } from '@bimetal/calendar-data';
|
|
11
|
-
import type { CalendarRule } from '@bimetal/calendar-rules';
|
|
12
|
-
import type { LastAction } from '@bimetal/headless-core';
|
|
11
|
+
import type { CalendarRule, CalendarRuleResult } from '@bimetal/calendar-rules';
|
|
13
12
|
import type { DragInfo } from '../drag-preview.js';
|
|
14
13
|
import type { AgendaRow } from './agenda.js';
|
|
15
14
|
export type { AgendaRow, AgendaHeaderRow, AgendaEventRow } from './agenda.js';
|
|
@@ -73,12 +72,41 @@ export interface CalendarLocale {
|
|
|
73
72
|
historyLoading: string;
|
|
74
73
|
historyError: string;
|
|
75
74
|
historyEventTypes: Record<string, string>;
|
|
75
|
+
/**
|
|
76
|
+
* bimetal-147 — Beschriftung einer Historien-Zeile OHNE `metadata.userId`,
|
|
77
|
+
* aber nur, wenn mindestens eine andere Zeile derselben Historie einen Akteur
|
|
78
|
+
* trägt (dann ist die Lücke eine Aussage). Läuft die ganze Historie ohne
|
|
79
|
+
* Akteur, rendert die Zeile gar keine Akteur-Spalte — der Text erscheint nie.
|
|
80
|
+
*
|
|
81
|
+
* OPTIONAL wie {@link undoBlockedForeign}: ein Consumer mit einem
|
|
82
|
+
* VOLLSTÄNDIGEN Locale-Literal soll an einem neuen Schlüssel nicht zerbrechen.
|
|
83
|
+
* Fehlt er, greift der eingebaute Text.
|
|
84
|
+
*/
|
|
85
|
+
historyUnknownActor?: string;
|
|
76
86
|
timeFrom: string;
|
|
77
87
|
timeUntil: string;
|
|
78
88
|
undo: string;
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
89
|
+
/** Label / aria-name for the redo affordance (mirror of {@link undo}). */
|
|
90
|
+
redo: string;
|
|
91
|
+
/**
|
|
92
|
+
* Meldung, wenn ein Toolbar-Undo ins Leere lief, weil oben im geteilten
|
|
93
|
+
* Undo-Stapel der Entität inzwischen der Frame eines ANDEREN Writers liegt
|
|
94
|
+
* (zweites Fenster am selben Store, Sync-Echo) — bimetal-155. Die eigene
|
|
95
|
+
* Änderung bleibt undo-bar, sobald der andere seine Frames zurücknimmt.
|
|
96
|
+
*
|
|
97
|
+
* OPTIONAL (R1, Review 5): ein Consumer, der ein VOLLSTÄNDIGES Locale-Objekt
|
|
98
|
+
* übergibt, soll an einem neuen Schlüssel nicht zerbrechen — das ist die in
|
|
99
|
+
* `plattform-i18n-rtl` zugesagte Vorwärtskompatibilität. Fehlt er, greift der
|
|
100
|
+
* eingebaute Text.
|
|
101
|
+
*/
|
|
102
|
+
undoBlockedForeign?: string;
|
|
103
|
+
/**
|
|
104
|
+
* bimetal-159, Spiegelbild von {@link undoBlockedForeign}: ein anderer
|
|
105
|
+
* Writer hat zuletzt zurückgenommen, sein Frame liegt oben auf dem
|
|
106
|
+
* Redo-Stapel. Wiederherstellen würde dessen bewusste Rücknahme aufheben.
|
|
107
|
+
* Optional wie der Undo-Schlüssel.
|
|
108
|
+
*/
|
|
109
|
+
redoBlockedForeign?: string;
|
|
82
110
|
location: string;
|
|
83
111
|
description: string;
|
|
84
112
|
moreEvents: string;
|
|
@@ -97,25 +125,45 @@ export interface CalendarLocale {
|
|
|
97
125
|
};
|
|
98
126
|
/** Note shown when editing a single instance of a recurring series (EventDialog). */
|
|
99
127
|
recurringInstanceNote: string;
|
|
128
|
+
/** Label of the way from an instance to its series master (`openEditSeries`). */
|
|
129
|
+
editSeries: string;
|
|
100
130
|
resources: string;
|
|
101
131
|
unassigned: string;
|
|
102
132
|
}
|
|
133
|
+
/** An event category: display name plus the colour its events render in. */
|
|
103
134
|
export interface Category {
|
|
104
135
|
name: string;
|
|
105
136
|
color: string;
|
|
106
137
|
}
|
|
138
|
+
/** Navigation + title behaviour for one calendar view (built-in or custom). */
|
|
107
139
|
export interface ViewConfig {
|
|
108
140
|
type: ViewType;
|
|
109
141
|
label: string;
|
|
110
142
|
step: (dt: CalendarDateTime, direction: 1 | -1) => CalendarDateTime;
|
|
111
143
|
formatTitle: (dt: CalendarDateTime) => string;
|
|
112
144
|
}
|
|
145
|
+
/** The fully-merged calendar config (see `CalendarConfigInput` for the partial,
|
|
146
|
+
* user-facing shape and `mergeCalendarConfig` for the merge). */
|
|
113
147
|
export interface CalendarConfig {
|
|
114
148
|
core: CoreConfig;
|
|
115
149
|
locale: CalendarLocale;
|
|
116
150
|
categories: Category[];
|
|
117
151
|
resources: Resource[];
|
|
118
152
|
clickThresholdMs: number;
|
|
153
|
+
/**
|
|
154
|
+
* Which built-in views appear in the view bar, and IN THIS ORDER. Omit (or
|
|
155
|
+
* `undefined`) for all built-ins in their default order (today's behaviour).
|
|
156
|
+
* `resource`/`timeline` still require `resources` (both are resource-based) —
|
|
157
|
+
* `enabledViews` is the selection/ordering layer, not a data override.
|
|
158
|
+
*/
|
|
159
|
+
enabledViews?: readonly BuiltInViewType[];
|
|
160
|
+
/** mcp-64: Ein-Flag-View-Only-Modus (ticket-35-Muster). Harter Controller-
|
|
161
|
+
* Guard: alle mutierenden Intents (Drops, Dialog-Save/Delete, Create,
|
|
162
|
+
* Undo/Redo inkl. Tastatur-Chords) sind No-ops; die Per-Event-Policy wird
|
|
163
|
+
* global auf locked überschrieben, wodurch die Bindings ihre Affordanzen
|
|
164
|
+
* (`--static`/`--locked`, Drag-Attribute) von selbst fallen lassen.
|
|
165
|
+
* Navigation, Auswahl, Filter und Ansicht bleiben voll bedienbar. */
|
|
166
|
+
readOnly: boolean;
|
|
119
167
|
}
|
|
120
168
|
/** Input type for Calendar props — all fields optional, deeply merged with defaults. */
|
|
121
169
|
export interface CalendarConfigInput {
|
|
@@ -124,6 +172,10 @@ export interface CalendarConfigInput {
|
|
|
124
172
|
categories?: Category[];
|
|
125
173
|
resources?: Resource[];
|
|
126
174
|
clickThresholdMs?: number;
|
|
175
|
+
/** Allow-list + order of built-in views in the view bar (see {@link CalendarConfig.enabledViews}). */
|
|
176
|
+
enabledViews?: readonly BuiltInViewType[];
|
|
177
|
+
/** View-Only-Modus — siehe {@link CalendarConfig.readOnly}. Default false. */
|
|
178
|
+
readOnly?: boolean;
|
|
127
179
|
}
|
|
128
180
|
/**
|
|
129
181
|
* The framework-agnostic part of a custom view: everything the controller
|
|
@@ -163,10 +215,6 @@ export interface AnchorRect {
|
|
|
163
215
|
readonly bottom: number;
|
|
164
216
|
readonly left: number;
|
|
165
217
|
}
|
|
166
|
-
/**
|
|
167
|
-
* The currently-open dialog. `anchorRect` is a plain measured rectangle the
|
|
168
|
-
* framework passes through from the DOM; the controller never reads it.
|
|
169
|
-
*/
|
|
170
218
|
/**
|
|
171
219
|
* The controlled new-/edit-event draft — the dialog's editable fields as RAW
|
|
172
220
|
* STRINGS (exactly what the `<input>`s hold), owned by the controller (B-CAL-2).
|
|
@@ -192,6 +240,10 @@ export interface EventDraft {
|
|
|
192
240
|
recInterval: number;
|
|
193
241
|
recUntil: string;
|
|
194
242
|
}
|
|
243
|
+
/**
|
|
244
|
+
* The currently-open dialog. `anchorRect` is a plain measured rectangle the
|
|
245
|
+
* framework passes through from the DOM; the controller never reads it.
|
|
246
|
+
*/
|
|
195
247
|
export interface DialogState {
|
|
196
248
|
event: CalendarEvent | null;
|
|
197
249
|
defaultDate: CalendarDateTime;
|
|
@@ -207,13 +259,47 @@ export interface DialogState {
|
|
|
207
259
|
/** Live validation messages from the last `saveDialogFromInput` attempt. */
|
|
208
260
|
validationErrors: readonly string[];
|
|
209
261
|
}
|
|
262
|
+
/** The selected event, identified by id plus an optional recurring-instance marker. */
|
|
210
263
|
export interface SelectionState {
|
|
211
264
|
eventId: string;
|
|
212
265
|
instanceDate?: number;
|
|
213
266
|
}
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
267
|
+
import type { CalendarHistoryEntry } from '../history-entries.js';
|
|
268
|
+
export type { CalendarHistoryEntry };
|
|
269
|
+
/**
|
|
270
|
+
* The fachliche notification emitted when an undo or redo actually changed
|
|
271
|
+
* something. Carries ONLY domain facts — the operation, the affected entity, and
|
|
272
|
+
* the compensating/redo domain events (which themselves carry `restoredState` +
|
|
273
|
+
* `timestamp`). Deliberately free of ANY presentation concern (no message text,
|
|
274
|
+
* duration, position, or toast variant): the calendar knows nothing of how — or
|
|
275
|
+
* whether — the app reacts. An app that wants a toast maps this to one itself
|
|
276
|
+
* (see the reference demo). Fires on REAL changes only (never per snapshot).
|
|
277
|
+
*/
|
|
278
|
+
export interface CalendarHistoryChange {
|
|
279
|
+
readonly operation: 'undo' | 'redo';
|
|
280
|
+
readonly entityId: string;
|
|
281
|
+
/** The compensating (undo) or replay (redo) domain events; always non-empty. */
|
|
282
|
+
readonly events: readonly DomainEvent[];
|
|
283
|
+
}
|
|
284
|
+
/** Per-event interaction policy returned by the `eventInteraction` hook. Each flag
|
|
285
|
+
* defaults to `true` (allowed) when omitted; `locked: true` is a shorthand for
|
|
286
|
+
* "immutable" — every interaction disabled (a holiday, a sent invoice). */
|
|
287
|
+
export interface EventInteractionPolicy {
|
|
288
|
+
readonly draggable?: boolean;
|
|
289
|
+
readonly resizable?: boolean;
|
|
290
|
+
readonly editable?: boolean;
|
|
291
|
+
readonly deletable?: boolean;
|
|
292
|
+
/** Shorthand: the event is immutable — drag/resize/edit/delete all disabled. */
|
|
293
|
+
readonly locked?: boolean;
|
|
294
|
+
}
|
|
295
|
+
/** The RESOLVED policy (every flag concrete) — what `getEventInteraction` returns. */
|
|
296
|
+
export interface ResolvedEventInteraction {
|
|
297
|
+
readonly draggable: boolean;
|
|
298
|
+
readonly resizable: boolean;
|
|
299
|
+
readonly editable: boolean;
|
|
300
|
+
readonly deletable: boolean;
|
|
301
|
+
}
|
|
302
|
+
/** Options accepted by `createCalendarController`. */
|
|
217
303
|
export interface CalendarControllerOptions {
|
|
218
304
|
/**
|
|
219
305
|
* The base store. The controller wraps it `withRules` internally.
|
|
@@ -243,14 +329,85 @@ export interface CalendarControllerOptions {
|
|
|
243
329
|
*/
|
|
244
330
|
onSelectionChange?: (selectedEvent: SelectionState | null) => void;
|
|
245
331
|
/**
|
|
246
|
-
*
|
|
247
|
-
*
|
|
248
|
-
*
|
|
249
|
-
*
|
|
332
|
+
* OBSERVE hook (ticket-32): fires after an undo or redo that actually changed
|
|
333
|
+
* something, with the domain-only {@link CalendarHistoryChange}. The fachliche
|
|
334
|
+
* replacement for the old feedback toast — the app decides whether to surface a
|
|
335
|
+
* toast/snackbar/nothing. Fires on REAL changes only (never on an empty stack /
|
|
336
|
+
* per snapshot). The calendar carries NO presentation concern.
|
|
337
|
+
*/
|
|
338
|
+
onHistoryChange?: (change: CalendarHistoryChange) => void;
|
|
339
|
+
/**
|
|
340
|
+
* OBSERVE hook (ticket-32): fires with the non-blocking rule WARNINGS produced by
|
|
341
|
+
* the last dispatch (a rule that returned `severity: 'warning'`). Domain-only —
|
|
342
|
+
* the app decides how (or whether) to show them. Replaces the old warning toast.
|
|
343
|
+
*/
|
|
344
|
+
onWarning?: (warnings: readonly CalendarRuleResult[]) => void;
|
|
345
|
+
/**
|
|
346
|
+
* Consumer error channel — the SINGLE error contract (ticket-32): EVERY dispatch
|
|
347
|
+
* rejection is passed here — a domain rule violation (`RuleViolationError`, with
|
|
348
|
+
* its structured `.violations`), a `DataValidationError`, a `ConcurrencyError`,
|
|
349
|
+
* a storage failure, or a bug. No error becomes a toast inside the calendar;
|
|
350
|
+
* presentation is the app's decision.
|
|
351
|
+
*
|
|
352
|
+
* OHNE `onError` gilt „never swallowed" über ZWEI Wege, und beide braucht es
|
|
353
|
+
* (bimetal-192 — vorher galt nur der erste, und er trug auf dem
|
|
354
|
+
* Standalone-Pfad nicht):
|
|
355
|
+
* 1. Wer eine Intent-Methode AWAITET (`saveDialog`, `deleteDialog`, `undo`,
|
|
356
|
+
* die vier `drop*`), bekommt die Ablehnung — das Promise rejectet laut.
|
|
357
|
+
* 2. Wer sie fire-and-forget über die `void*`-Hüllen feuert (das tun alle
|
|
358
|
+
* fünf Bindings), hat niemanden, der abwartet. Der Fehler geht dann an
|
|
359
|
+
* `reportUnroutedCalendarError`: eine Konsolen-Meldung mit Adresse und
|
|
360
|
+
* Abhilfe. NICHT dev-only — genau in Produktion wäre das Schweigen der
|
|
361
|
+
* Schaden. Sie verschwindet, sobald `onError` gesetzt ist; auch ein
|
|
362
|
+
* bewusst leeres `onError: () => {}` ist eine Aussage.
|
|
363
|
+
*
|
|
364
|
+
* Auf welchem der beiden Wege ein Fehler in der Konsole landet, hängt am
|
|
365
|
+
* Binding: die VIER SPA-Bindings belegen `onError` selbst mit
|
|
366
|
+
* `reportUnroutedCalendarError` (dann greift Weg 1 gar nicht — `handleError`
|
|
367
|
+
* wirft nicht); `calendar-vanilla-components`, React `CalendarBound` und der
|
|
368
|
+
* Hook `useCalendarController` reichen `onError` roh durch, dort trägt Weg 2.
|
|
369
|
+
* Das Ergebnis ist beidesmal dasselbe: GENAU EINE Meldung, kein Doppel-Melden.
|
|
370
|
+
*
|
|
371
|
+
* NICHT gemeldet werden Domänen-Ablehnungen — `RuleViolationError` und
|
|
372
|
+
* `DataValidationError`. Sie erreichen `onError` und das Intent-Promise
|
|
373
|
+
* unverändert; still ist nur der ERSATZ-Kanal, weil eine abgelehnte Regel
|
|
374
|
+
* kein verlorener Schreibvorgang ist, sondern eine Antwort (bimetal-192 R1).
|
|
250
375
|
*/
|
|
251
376
|
onError?: (err: unknown) => void;
|
|
252
377
|
/** Injectable clock for tests. Defaults to core `now(timezone, clock)`. */
|
|
253
378
|
now?: () => CalendarDateTime;
|
|
379
|
+
/**
|
|
380
|
+
* Per-event interaction policy (ticket-19, Read-Side). Called per event to decide
|
|
381
|
+
* whether it can be dragged / resized / edited / deleted — the PREVENTIVE gate for
|
|
382
|
+
* immutable events (a holiday) and state-derived ones (an invoice draggable while
|
|
383
|
+
* `draft`, not while `sent`). ES-neutral: derive the policy from ANY data
|
|
384
|
+
* (`event.domains`, `event.metadata`) — it never mutates the event, and nothing is
|
|
385
|
+
* persisted. Should be a PURE function of the event (it is memoized on the event's
|
|
386
|
+
* identity). Omit it, or omit a flag, → that interaction is allowed. The controller
|
|
387
|
+
* enforces the result on EVERY path (pointer, keyboard, programmatic); bindings read
|
|
388
|
+
* the resolved policy via `getEventInteraction` to drop the affordances. Complements
|
|
389
|
+
* the rule engine (which is the reactive last line at dispatch), not a replacement.
|
|
390
|
+
*
|
|
391
|
+
* A PURE function of the event ONLY (no ambient/mutable state) — the result is
|
|
392
|
+
* memoized on the event's identity, so a decision that varied with external state
|
|
393
|
+
* (`config`, `now`) would go stale. Derive locking from the event's OWN data.
|
|
394
|
+
*/
|
|
395
|
+
eventInteraction?: (event: CalendarEvent) => EventInteractionPolicy;
|
|
396
|
+
/**
|
|
397
|
+
* Akteur-Auflösung für die eingebaute Historie (bimetal-147): macht aus der
|
|
398
|
+
* Audit-Id `event.metadata.userId` einen anzeigbaren Text.
|
|
399
|
+
*
|
|
400
|
+
* Der Kern kennt nur die ID — Event Sourcing führt keine Personalstammdaten,
|
|
401
|
+
* und der Kalender soll auch keine laden. Wer Namen zeigen will, mappt hier
|
|
402
|
+
* gegen sein eigenes Verzeichnis. OHNE diesen Hook zeigt die Historie die ID
|
|
403
|
+
* roh an; sie erfindet nie einen Namen. Gibt der Hook `undefined` (oder einen
|
|
404
|
+
* leeren String) zurück — unbekannte Id —, fällt die Anzeige auf die rohe Id
|
|
405
|
+
* zurück, nie auf eine leere Zelle.
|
|
406
|
+
*
|
|
407
|
+
* Sollte eine REINE Funktion der Id sein; sie wird pro gerenderter
|
|
408
|
+
* Historien-Zeile aufgerufen (kein Store-Zugriff, kein `await`).
|
|
409
|
+
*/
|
|
410
|
+
resolveActor?: (userId: string) => string | undefined;
|
|
254
411
|
}
|
|
255
412
|
/**
|
|
256
413
|
* Identity-stable view of all interaction state: `getSnapshot()` returns the
|
|
@@ -262,23 +419,23 @@ export interface CalendarControllerOptions {
|
|
|
262
419
|
* break framework reactive proxies (e.g. Vue's `reactive()`).
|
|
263
420
|
*/
|
|
264
421
|
export interface CalendarControllerSnapshot {
|
|
265
|
-
currentDate: CalendarDateTime;
|
|
266
|
-
currentView: ViewType;
|
|
267
|
-
viewConfig: ViewConfig;
|
|
268
|
-
viewConfigList: readonly ViewConfig[];
|
|
269
|
-
title: string;
|
|
270
|
-
range: TimeRange;
|
|
422
|
+
readonly currentDate: CalendarDateTime;
|
|
423
|
+
readonly currentView: ViewType;
|
|
424
|
+
readonly viewConfig: ViewConfig;
|
|
425
|
+
readonly viewConfigList: readonly ViewConfig[];
|
|
426
|
+
readonly title: string;
|
|
427
|
+
readonly range: TimeRange;
|
|
271
428
|
/** Expanded → category-filtered. THE canonical visible-event list. */
|
|
272
|
-
events: readonly CalendarEvent[];
|
|
429
|
+
readonly events: readonly CalendarEvent[];
|
|
273
430
|
/** The windowed agenda row list — present ONLY in the agenda view, else `null`
|
|
274
431
|
* (v0.30 Slice 5b). The agenda binding renders this; other views ignore it. */
|
|
275
|
-
agenda: AgendaWindow | null;
|
|
276
|
-
visibleResources: readonly Resource[];
|
|
277
|
-
dialog: DialogState | null;
|
|
432
|
+
readonly agenda: AgendaWindow | null;
|
|
433
|
+
readonly visibleResources: readonly Resource[];
|
|
434
|
+
readonly dialog: DialogState | null;
|
|
278
435
|
/** The selected event — a NAMED semantic exception to the `selectedId` canon: it
|
|
279
436
|
* carries a recurrence instance reference `{ eventId, instanceDate? }`
|
|
280
437
|
* (`SelectionState`), not a plain id, because a modify targets one occurrence. */
|
|
281
|
-
selectedEvent: SelectionState | null;
|
|
438
|
+
readonly selectedEvent: SelectionState | null;
|
|
282
439
|
/**
|
|
283
440
|
* The dragged event with its `timeRange` already rebuilt — the SINGLE
|
|
284
441
|
* preview-applied projection (B-CAL-1). Views render this in place of the
|
|
@@ -286,41 +443,131 @@ export interface CalendarControllerSnapshot {
|
|
|
286
443
|
* when no drag is in progress. (The raw `DragPreview` strings are a controller-
|
|
287
444
|
* internal change-detection detail and are NOT exposed on the snapshot.)
|
|
288
445
|
*/
|
|
289
|
-
previewEvent: CalendarEvent | null;
|
|
446
|
+
readonly previewEvent: CalendarEvent | null;
|
|
290
447
|
/** The month-grid day cell currently hover-expanded (its day's epochMs), or
|
|
291
448
|
* null. Transient view state lifted OUT of the binding (B-CAL-3) so the
|
|
292
449
|
* hover-expand is controller-owned, not a per-binding `useState`. */
|
|
293
|
-
expandedMonthDay: number | null;
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
450
|
+
readonly expandedMonthDay: number | null;
|
|
451
|
+
/** Whether there is anything to undo/redo for the CURRENT target (the last-MUTATED
|
|
452
|
+
* entity for undo, the last-undone entity for redo — ticket-31). Drives the toolbar
|
|
453
|
+
* undo/redo enabled-state; derived from the same resolver as `undo()`/`redo()`, never
|
|
454
|
+
* persisted. Undo/redo are self-contained: no feedback state lives on the snapshot
|
|
455
|
+
* (ticket-32 — any user feedback is the app's concern, driven by `onHistoryChange`). */
|
|
456
|
+
readonly canUndo: boolean;
|
|
457
|
+
readonly canRedo: boolean;
|
|
458
|
+
readonly hiddenCategories: ReadonlySet<string>;
|
|
459
|
+
readonly hiddenResources: ReadonlySet<string>;
|
|
460
|
+
readonly config: Readonly<CalendarConfig>;
|
|
298
461
|
}
|
|
299
462
|
import type { NormalizedKeyEvent } from '@bimetal/headless-core';
|
|
300
463
|
export type { NormalizedKeyEvent };
|
|
464
|
+
/**
|
|
465
|
+
* The canonical calendar controller: owns snapshot access, navigation, dialog
|
|
466
|
+
* lifecycle, drag/drop, selection, category/resource filters, undo/error
|
|
467
|
+
* surfacing, and keyboard semantics. Framework bindings only subscribe, render
|
|
468
|
+
* the snapshot, and forward DOM events to these methods.
|
|
469
|
+
*/
|
|
301
470
|
export interface CalendarController {
|
|
471
|
+
/** Returns the current identity-stable snapshot; unchanged (`===`) until an intent actually changes state. */
|
|
302
472
|
getSnapshot(): CalendarControllerSnapshot;
|
|
473
|
+
/** Registers a listener invoked after any state change; returns an unsubscribe function. */
|
|
303
474
|
subscribe(listener: () => void): Unsubscribe;
|
|
475
|
+
/** Tears down the controller (unsubscribes from the store, releases resources). Call on unmount. */
|
|
304
476
|
destroy(): void;
|
|
477
|
+
/** The RESOLVED interaction policy for `event` (ticket-19): whether it may be
|
|
478
|
+
* dragged/resized/edited/deleted. Memoized on the event's identity WITHIN the
|
|
479
|
+
* current policy generation (see `setEventInteraction`) — bindings call it per
|
|
480
|
+
* rendered event to drop the affordances (draggable attr, resize handles,
|
|
481
|
+
* dialog edit); the controller uses the SAME resolver to gate every intent. Returns
|
|
482
|
+
* all-`true` when no `eventInteraction` hook is configured. */
|
|
483
|
+
getEventInteraction(event: CalendarEvent): ResolvedEventInteraction;
|
|
484
|
+
/**
|
|
485
|
+
* bimetal-180 — der `eventInteraction`-Hook als REAKTIVE OPTION.
|
|
486
|
+
*
|
|
487
|
+
* Er ist wertliefernd wie `config`/`rules`, keine Benachrichtigung: ein Wechsel
|
|
488
|
+
* muss sofort wirken, so wie `setConfig({readOnly})` es tut. Ohne diesen Aufruf
|
|
489
|
+
* blieb die beim ersten Auflösen gespeicherte Antwort DAUERHAFT stehen, für die
|
|
490
|
+
* Affordanz UND für die Durchsetzung (openEdit, alle vier Drops, save, delete) —
|
|
491
|
+
* das Memo ist auf die Event-Identität gekeyt, ein Hook-Wechsel bewegt keinen
|
|
492
|
+
* Schlüssel.
|
|
493
|
+
*
|
|
494
|
+
* `undefined` NIMMT DIE POLICY WEG und ist damit eine Entsperrung: alle vier
|
|
495
|
+
* Affordanzen kehren zurück. Das ist bewusst so — die Option ist wertliefernd wie
|
|
496
|
+
* `rules`, nicht ein Callback, dessen Anwesenheit am Mount festgelegt wäre. Die
|
|
497
|
+
* Abwägung samt Sicherheitsargument steht an EINER Stelle: `useLiveOptions`
|
|
498
|
+
* (`@bimetal/react`), Abschnitt „DIE AUSNAHME: EINE OPTION MIT EIGENER REAKTIVER
|
|
499
|
+
* LEITUNG". Wer hart sperren will, nimmt `config.readOnly` — der Guard ausserhalb
|
|
500
|
+
* des Memos.
|
|
501
|
+
*
|
|
502
|
+
* Ein Wechsel verwirft die memoisierten Antworten und benachrichtigt NUR, wenn
|
|
503
|
+
* sich für die aktuell sichtbaren Events wirklich eine Antwort ändert — ein
|
|
504
|
+
* inline geschriebener Hook (neue Identität je Render) läuft damit still durch,
|
|
505
|
+
* statt eine Render-Schleife zu erzeugen. Er kostet dann aber EINEN Hook-Aufruf je
|
|
506
|
+
* Event im sichtbaren Bereich, JE RENDER (gemessen: 30 bei 30 Events); ein
|
|
507
|
+
* referenzstabiler Hook kostet nichts.
|
|
508
|
+
*
|
|
509
|
+
* VERDRAHTET IST DIESER SETTER HEUTE NUR IM REACT-BINDING
|
|
510
|
+
* (`calendar-react-components`, `useCalendarController.ts` — `useReactivePush`).
|
|
511
|
+
* Die Bindings für Vue, Svelte und Angular übergeben `eventInteraction` allein
|
|
512
|
+
* bei der ERZEUGUNG und rufen den Setter nie; dort steht die erste aufgelöste
|
|
513
|
+
* Antwort je Event weiterhin bis zum Unmount, für die Affordanz wie für die
|
|
514
|
+
* Durchsetzung. Der Vertrag hier ist der KERN-Vertrag und beschreibt, was der
|
|
515
|
+
* Controller zusagt — nicht, was vier von fünf Render-Layern heute abrufen.
|
|
516
|
+
* Erfasst als **bimetal-185**; bis dahin ist `config.readOnly` (`setConfig`) die
|
|
517
|
+
* einzige Policy-Umschaltung, die in allen fünf Stacks ankommt.
|
|
518
|
+
*/
|
|
519
|
+
setEventInteraction(hook?: (event: CalendarEvent) => EventInteractionPolicy): void;
|
|
520
|
+
/** Replaces the merged config and rebuilds the rule-wrapped store + view configs from it. */
|
|
305
521
|
setConfig(config?: CalendarConfigInput): void;
|
|
522
|
+
/** Replaces the active validation rules and rebuilds the rule-wrapped store. */
|
|
306
523
|
setRules(rules?: readonly CalendarRule[]): void;
|
|
524
|
+
/** Replaces the custom view specs and rebuilds the view config list. */
|
|
307
525
|
setCustomViews(customViews?: readonly CustomViewSpec[]): void;
|
|
308
526
|
/** Dialog mode is a dynamic prop — push changes after mount (see EventDialogKind). */
|
|
309
527
|
setEventDialogKind(kind: EventDialogKind): void;
|
|
528
|
+
/** Steps `currentDate` one unit back via the active view's `step` function. */
|
|
310
529
|
prev(): void;
|
|
530
|
+
/** Steps `currentDate` one unit forward via the active view's `step` function. */
|
|
311
531
|
next(): void;
|
|
532
|
+
/** Jumps `currentDate` to now. */
|
|
312
533
|
today(): void;
|
|
534
|
+
/** Switches the active view type. */
|
|
313
535
|
setView(view: ViewType): void;
|
|
314
|
-
|
|
536
|
+
/** Jumps to the first day of the given month and switches to the month view.
|
|
537
|
+
* `month` is the branded `Month` (§7); pass `monthIndex(n)` for a computed value. */
|
|
538
|
+
goToMonth(year: number, month: Month): void;
|
|
315
539
|
/** Report the agenda scroll container's `scrollTop` + measured height (v0.30
|
|
316
540
|
* Slice 5b). Additive/transient — never a command, no undo, no store touch. The
|
|
317
541
|
* agenda binding wires it to the `.agenda-view` scroll + a ResizeObserver; the
|
|
318
542
|
* controller windows the agenda-row build to the visible slice. A height of 0
|
|
319
543
|
* (unmeasured/hidden) renders all rows (fallback). No effect outside agenda view. */
|
|
320
544
|
setViewport(scrollTop: number, viewportHeight: number): void;
|
|
545
|
+
/** Opens the edit dialog for an event (or forwards to `onEventClickExternal` when
|
|
546
|
+
* `eventDialogKind` is `'none'`); `instanceDate` disambiguates a recurring occurrence. */
|
|
321
547
|
openEdit(eventId: string, anchorRect: AnchorRect, instanceDate?: number): void;
|
|
548
|
+
/**
|
|
549
|
+
* Opens the edit dialog on the SERIES MASTER behind `eventId` — the only way to
|
|
550
|
+
* reach a recurrence rule after creation.
|
|
551
|
+
*
|
|
552
|
+
* `openEdit` cannot do this: the read path expands every event carrying a rule into
|
|
553
|
+
* its occurrences, so the master is not among the visible events it searches, and the
|
|
554
|
+
* occurrences do not carry the rule. Saving from here updates the master, i.e. it
|
|
555
|
+
* changes the WHOLE series (existing per-instance exceptions survive) — the same
|
|
556
|
+
* effect the recurrence cookbook documents for a programmatic master update.
|
|
557
|
+
*
|
|
558
|
+
* A no-op unless `eventId` resolves to an event that actually has a `recurrence`, so
|
|
559
|
+
* it can never become a second, subtly different `openEdit` for plain events. Editing
|
|
560
|
+
* only the occurrences from here is unchanged: that stays `openEdit` + `modifyInstance`.
|
|
561
|
+
* Splitting a series ("this and all following") is NOT this method — that would end the
|
|
562
|
+
* old master and start a new one, which is an aggregate concern.
|
|
563
|
+
*/
|
|
564
|
+
openEditSeries(eventId: string, anchorRect: AnchorRect): void;
|
|
565
|
+
/** Opens the create dialog seeded with defaults for `date` (or forwards to
|
|
566
|
+
* `onNewEventRequestedExternal` when `eventDialogKind` is `'none'`). */
|
|
322
567
|
openCreate(date: CalendarDateTime, anchorRect: AnchorRect, resourceId?: string): void;
|
|
568
|
+
/** Opens the create dialog for a specific resource-row date/time cell. */
|
|
323
569
|
openCreateFromResourceCell(date: CalendarDateTime, time: string, resourceId: string, anchorRect: AnchorRect): void;
|
|
570
|
+
/** Closes the open dialog without saving. */
|
|
324
571
|
closeDialog(): void;
|
|
325
572
|
/** Patch the controlled draft from raw input; applies the derived policy
|
|
326
573
|
* (category→color, start>end bumps end, interval clamp) in the controller. */
|
|
@@ -333,30 +580,87 @@ export interface CalendarController {
|
|
|
333
580
|
/** Save an externally-assembled event (the CUSTOM dialog mode, where the app
|
|
334
581
|
* builds its own CalendarEvent). The builtin dialog uses saveDialogFromInput. */
|
|
335
582
|
saveDialog(updated: CalendarEvent): Promise<void>;
|
|
583
|
+
/** Deletes the event behind the open dialog (or its recurring instance) and closes it. */
|
|
336
584
|
deleteDialog(eventId: string): Promise<void>;
|
|
585
|
+
/** Runs the save-preview validation rules against `evt` without dispatching; returns error/warning messages. */
|
|
337
586
|
validateSave(evt: CalendarEvent): string[];
|
|
587
|
+
/** Fire-and-forget {@link saveDialogFromInput} — the builtin dialog's save button. */
|
|
588
|
+
voidSaveDialogFromInput(): void;
|
|
589
|
+
/** Fire-and-forget {@link saveDialog} — the custom-dialog save path. */
|
|
590
|
+
voidSaveDialog(updated: CalendarEvent): void;
|
|
591
|
+
/** Fire-and-forget {@link deleteDialog}. */
|
|
592
|
+
voidDeleteDialog(eventId: string): void;
|
|
593
|
+
/** Commits an allDay move/resize drop; always ends the drag, even on failure. */
|
|
338
594
|
dropAllDay(info: DragInfo, dropDate: CalendarDateTime): Promise<void>;
|
|
595
|
+
/** Commits a timed move/resize drop; always ends the drag, even on failure. */
|
|
339
596
|
dropTimed(info: DragInfo, dropDate: CalendarDateTime, dropTime: string): Promise<void>;
|
|
597
|
+
/** Commits a timed move/resize drop on a resource row (a move also reassigns
|
|
598
|
+
* the resource); always ends the drag, even on failure. */
|
|
340
599
|
dropResource(info: DragInfo, dropDate: CalendarDateTime, dropTime: string, resourceId: string): Promise<void>;
|
|
600
|
+
/** Commits a day-grain move/resize drop on the timeline view (a move also
|
|
601
|
+
* reassigns the resource); always ends the drag, even on failure. */
|
|
341
602
|
dropTimeline(info: DragInfo, dropDate: CalendarDateTime, targetResourceId: string): Promise<void>;
|
|
603
|
+
/** Fire-and-forget {@link dropAllDay} — the family-conformant `void*` shape a
|
|
604
|
+
* binding fires from a DOM drop handler without awaiting (see voidSaveDialog). */
|
|
605
|
+
voidDropAllDay(info: DragInfo, dropDate: CalendarDateTime): void;
|
|
606
|
+
/** Fire-and-forget {@link dropTimed}. */
|
|
607
|
+
voidDropTimed(info: DragInfo, dropDate: CalendarDateTime, dropTime: string): void;
|
|
608
|
+
/** Fire-and-forget {@link dropResource}. */
|
|
609
|
+
voidDropResource(info: DragInfo, dropDate: CalendarDateTime, dropTime: string, resourceId: string): void;
|
|
610
|
+
/** Fire-and-forget {@link dropTimeline}. */
|
|
611
|
+
voidDropTimeline(info: DragInfo, dropDate: CalendarDateTime, targetResourceId: string): void;
|
|
612
|
+
/** Begins tracking a drag gesture (transient — no snapshot change). */
|
|
342
613
|
startDrag(info: DragInfo): void;
|
|
614
|
+
/** Recomputes the allDay drag preview for the current hover position. */
|
|
343
615
|
updatePreview(hoverDate: CalendarDateTime): void;
|
|
616
|
+
/** Recomputes the timed drag preview for the current hover position. */
|
|
344
617
|
updateTimedPreview(hoverDate: CalendarDateTime, hoverTime: string): void;
|
|
618
|
+
/** Clears the current drag preview without ending the drag. */
|
|
345
619
|
hidePreview(): void;
|
|
620
|
+
/** Ends the drag gesture, clearing the drag and preview state. */
|
|
346
621
|
endDrag(): void;
|
|
622
|
+
/** Selects an event (optionally a specific recurring instance). */
|
|
347
623
|
selectEvent(eventId: string, instanceDate?: number): void;
|
|
624
|
+
/** Clears the current selection. */
|
|
348
625
|
clearSelection(): void;
|
|
626
|
+
/** Expands the given month-grid day cell to show its overflow events. */
|
|
349
627
|
expandMonthCell(dayEpochMs: number): void;
|
|
628
|
+
/** Collapses the currently hover-expanded month-grid cell. */
|
|
350
629
|
collapseMonthCell(): void;
|
|
630
|
+
/** Toggles whether events in the given category are hidden. */
|
|
351
631
|
toggleCategory(name: string): void;
|
|
632
|
+
/** Toggles whether the given resource's row is hidden. */
|
|
352
633
|
toggleResource(resourceId: string): void;
|
|
634
|
+
/** Undoes the last domain action for the given entity, routed through the controller's error contract. */
|
|
353
635
|
undo(entityId: string): Promise<void>;
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
636
|
+
/** Redoes the last undone domain action for the given entity (mirror of {@link undo}).
|
|
637
|
+
* Keyboard redo (Ctrl+Shift+Z) targets the most recently undone entity. */
|
|
638
|
+
redo(entityId: string): Promise<void>;
|
|
639
|
+
/** No-arg fire-and-forget undo for a toolbar button — resolves the current target
|
|
640
|
+
* itself (the last-mutated entity, ticket-31) and is a no-op when `canUndo` is false.
|
|
641
|
+
* Uniform with the other families' `voidUndo`. Keyboard undo remains independent. */
|
|
642
|
+
voidUndo(): void;
|
|
643
|
+
/** No-arg fire-and-forget redo (mirror of {@link voidUndo}); targets the last-undone
|
|
644
|
+
* entity and is a no-op when `canRedo` is false. */
|
|
645
|
+
voidRedo(): void;
|
|
646
|
+
/** Route an error through the controller's single error contract (ticket-32):
|
|
647
|
+
* EVERY rejection goes to `onError` (or rethrows if none is set). */
|
|
358
648
|
handleError(err: unknown): void;
|
|
649
|
+
/** Returns the full domain-event history for the given entity. */
|
|
359
650
|
getHistory(entityId: string): DomainEvent[];
|
|
651
|
+
/**
|
|
652
|
+
* Die ANZEIGEFERTIGE Historie derselben Entität (bimetal-147): Badge-Label,
|
|
653
|
+
* lokalisierter Zeitstempel, Kurzfassung — und WER (`metadata.userId`, durch
|
|
654
|
+
* {@link CalendarControllerOptions.resolveActor} gereicht).
|
|
655
|
+
*
|
|
656
|
+
* Das ist die Quelle, aus der die eingebaute `EventHistory` aller vier Stacks
|
|
657
|
+
* rendert. Vorher leitete jede Hülle dieselbe Zeile selbst ab und keine zeigte
|
|
658
|
+
* den Akteur. `getHistory` bleibt daneben als roher ES-Zugriff bestehen.
|
|
659
|
+
*/
|
|
660
|
+
getHistoryEntries(entityId: string): CalendarHistoryEntry[];
|
|
661
|
+
/** Applies the controller's keyboard semantics (undo shortcut, Escape to close
|
|
662
|
+
* the dialog or clear selection); ignores shortcuts while a native text input
|
|
663
|
+
* owns the keystroke (`e.isEditable`). */
|
|
360
664
|
handleKeydown(e: NormalizedKeyEvent): void;
|
|
361
665
|
}
|
|
362
666
|
export type { DragInfo, DragPreview } from '../drag-preview.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/controller/types.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EACV,aAAa,EAAE,gBAAgB,EAAE,SAAS,EAAE,QAAQ,EAAE,UAAU,EAAE,QAAQ,EAAE,mBAAmB,EAChG,MAAM,wBAAwB,CAAC;AAChC,OAAO,KAAK,EAAE,aAAa,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACtF,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAC5D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,KAAK,EAAE,QAAQ,EAAe,MAAM,oBAAoB,CAAC;AAChE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAE7C,YAAY,EAAE,SAAS,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE9E;;;;;;;;GAQG;AACH,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,IAAI,EAAE,SAAS,SAAS,EAAE,CAAC;IACpC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,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ACjB;yDACqD;IACrD,QAAQ,IAAI,IAAI,CAAC;IACjB;0EACsE;IACtE,WAAW,CAAC,GAAG,EAAE,OAAO,GAAG,IAAI,CAAC;IAChC,kEAAkE;IAClE,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,WAAW,EAAE,CAAC;IAC5C;;;;;;;;OAQG;IACH,iBAAiB,CAAC,QAAQ,EAAE,MAAM,GAAG,oBAAoB,EAAE,CAAC;IAG5D;;+CAE2C;IAC3C,aAAa,CAAC,CAAC,EAAE,kBAAkB,GAAG,IAAI,CAAC;CAC5C;AAED,YAAY,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC"}
|
|
@@ -5,7 +5,9 @@
|
|
|
5
5
|
* view-configs.ts`. This is now the single source; framework packages
|
|
6
6
|
* re-export `createViewConfigs` from here.
|
|
7
7
|
*/
|
|
8
|
-
import
|
|
8
|
+
import { Weekday } from '@bimetal/temporal';
|
|
9
9
|
import type { ViewConfig, CalendarLocale } from './types.js';
|
|
10
|
-
|
|
10
|
+
/** Builds the built-in view configs (year/month/week/day/resource/agenda/timeline)
|
|
11
|
+
* for the given locale and week-start day. */
|
|
12
|
+
export declare function createViewConfigs(locale: CalendarLocale, weekStart?: Weekday): Record<string, ViewConfig>;
|
|
11
13
|
//# sourceMappingURL=view-configs.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"view-configs.d.ts","sourceRoot":"","sources":["../../src/controller/view-configs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;
|
|
1
|
+
{"version":3,"file":"view-configs.d.ts","sourceRoot":"","sources":["../../src/controller/view-configs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,EAA2H,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACrK,OAAO,KAAK,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAE7D;+CAC+C;AAC/C,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,cAAc,EAAE,SAAS,GAAE,OAAwB,GAAG,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC,CAoEzH"}
|
|
@@ -5,22 +5,28 @@
|
|
|
5
5
|
* view-configs.ts`. This is now the single source; framework packages
|
|
6
6
|
* re-export `createViewConfigs` from here.
|
|
7
7
|
*/
|
|
8
|
-
import { addDays, createDateTime, getYear, getMonth, getDayOfWeek, formatDateTime } from '@bimetal/
|
|
9
|
-
|
|
8
|
+
import { addDays, addMonths, createDateTime, getYear, getMonth, getDayOfWeek, formatDateTime, formatMonthYear, Month, monthIndex, Weekday } from '@bimetal/temporal';
|
|
9
|
+
/** Builds the built-in view configs (year/month/week/day/resource/agenda/timeline)
|
|
10
|
+
* for the given locale and week-start day. */
|
|
11
|
+
export function createViewConfigs(locale, weekStart = Weekday.Monday) {
|
|
10
12
|
const code = locale.code;
|
|
11
13
|
return {
|
|
12
14
|
year: {
|
|
13
15
|
type: 'year',
|
|
14
16
|
label: locale.views.year ?? 'Year',
|
|
15
|
-
step: (dt, dir) => createDateTime(getYear(dt) + dir,
|
|
17
|
+
step: (dt, dir) => createDateTime(getYear(dt) + dir, Month.January, 1, 0, 0, dt.timezone),
|
|
16
18
|
formatTitle: (dt) => String(getYear(dt)),
|
|
17
19
|
},
|
|
18
20
|
month: {
|
|
19
21
|
type: 'month',
|
|
20
22
|
label: locale.views.month,
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
23
|
+
// addMonths carries the year correctly (Dec + 1 → Jan next year, DST-safe);
|
|
24
|
+
// month nav then normalizes to the first of the target month, as before.
|
|
25
|
+
step: (dt, dir) => {
|
|
26
|
+
const m = addMonths(dt, dir);
|
|
27
|
+
return createDateTime(getYear(m), monthIndex(getMonth(m)), 1, 0, 0, m.timezone);
|
|
28
|
+
},
|
|
29
|
+
formatTitle: (dt) => formatMonthYear(dt, code),
|
|
24
30
|
},
|
|
25
31
|
week: {
|
|
26
32
|
type: 'week',
|