@memberjunction/ng-entity-viewer 6.2.0-edge.4 → 6.2.0-edge.6
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/README.md +28 -0
- package/dist/lib/aggregate-setup-dialog/aggregate-setup-dialog.component.d.ts +48 -1
- package/dist/lib/aggregate-setup-dialog/aggregate-setup-dialog.component.d.ts.map +1 -1
- package/dist/lib/aggregate-setup-dialog/aggregate-setup-dialog.component.js +631 -279
- package/dist/lib/aggregate-setup-dialog/aggregate-setup-dialog.component.js.map +1 -1
- package/dist/lib/entity-cards/entity-cards.component.d.ts +2 -0
- package/dist/lib/entity-cards/entity-cards.component.d.ts.map +1 -1
- package/dist/lib/entity-cards/entity-cards.component.js +30 -2
- package/dist/lib/entity-cards/entity-cards.component.js.map +1 -1
- package/dist/lib/entity-data-grid/entity-data-grid.component.d.ts +64 -2
- package/dist/lib/entity-data-grid/entity-data-grid.component.d.ts.map +1 -1
- package/dist/lib/entity-data-grid/entity-data-grid.component.js +516 -187
- package/dist/lib/entity-data-grid/entity-data-grid.component.js.map +1 -1
- package/dist/lib/entity-record-detail-panel/entity-record-detail-panel.component.d.ts +2 -0
- package/dist/lib/entity-record-detail-panel/entity-record-detail-panel.component.d.ts.map +1 -1
- package/dist/lib/entity-record-detail-panel/entity-record-detail-panel.component.js +38 -4
- package/dist/lib/entity-record-detail-panel/entity-record-detail-panel.component.js.map +1 -1
- package/dist/lib/entity-viewer/entity-viewer.component.d.ts +39 -3
- package/dist/lib/entity-viewer/entity-viewer.component.d.ts.map +1 -1
- package/dist/lib/entity-viewer/entity-viewer.component.js +189 -50
- package/dist/lib/entity-viewer/entity-viewer.component.js.map +1 -1
- package/dist/lib/entity-viewer/view-property-chips.d.ts +17 -0
- package/dist/lib/entity-viewer/view-property-chips.d.ts.map +1 -0
- package/dist/lib/entity-viewer/view-property-chips.js +42 -0
- package/dist/lib/entity-viewer/view-property-chips.js.map +1 -0
- package/dist/lib/recycle-bin/recycle-bin-chip.component.d.ts +10 -2
- package/dist/lib/recycle-bin/recycle-bin-chip.component.d.ts.map +1 -1
- package/dist/lib/recycle-bin/recycle-bin-chip.component.js +37 -5
- package/dist/lib/recycle-bin/recycle-bin-chip.component.js.map +1 -1
- package/dist/lib/recycle-bin/recycle-bin.component.js +3 -3
- package/dist/lib/recycle-bin/recycle-bin.component.js.map +1 -1
- package/dist/lib/utils/record.util.d.ts +21 -1
- package/dist/lib/utils/record.util.d.ts.map +1 -1
- package/dist/lib/utils/record.util.js +108 -0
- package/dist/lib/utils/record.util.js.map +1 -1
- package/dist/lib/view-config-panel/view-config-panel.component.d.ts +378 -54
- package/dist/lib/view-config-panel/view-config-panel.component.d.ts.map +1 -1
- package/dist/lib/view-config-panel/view-config-panel.component.js +3837 -1010
- package/dist/lib/view-config-panel/view-config-panel.component.js.map +1 -1
- package/dist/lib/view-properties-editor/view-properties-editor.component.d.ts +52 -0
- package/dist/lib/view-properties-editor/view-properties-editor.component.d.ts.map +1 -0
- package/dist/lib/view-properties-editor/view-properties-editor.component.js +445 -0
- package/dist/lib/view-properties-editor/view-properties-editor.component.js.map +1 -0
- package/dist/lib/view-selector/view-selector.component.d.ts +22 -1
- package/dist/lib/view-selector/view-selector.component.d.ts.map +1 -1
- package/dist/lib/view-selector/view-selector.component.js +288 -149
- package/dist/lib/view-selector/view-selector.component.js.map +1 -1
- package/dist/lib/view-types/descriptors/calendar-view-type.d.ts +22 -0
- package/dist/lib/view-types/descriptors/calendar-view-type.d.ts.map +1 -0
- package/dist/lib/view-types/descriptors/calendar-view-type.js +38 -0
- package/dist/lib/view-types/descriptors/calendar-view-type.js.map +1 -0
- package/dist/lib/view-types/index.d.ts +3 -2
- package/dist/lib/view-types/index.d.ts.map +1 -1
- package/dist/lib/view-types/index.js +5 -2
- package/dist/lib/view-types/index.js.map +1 -1
- package/dist/lib/view-types/renderers/calendar-placement.d.ts +97 -0
- package/dist/lib/view-types/renderers/calendar-placement.d.ts.map +1 -0
- package/dist/lib/view-types/renderers/calendar-placement.js +145 -0
- package/dist/lib/view-types/renderers/calendar-placement.js.map +1 -0
- package/dist/lib/view-types/renderers/calendar-view-prop-sheet.component.d.ts +36 -0
- package/dist/lib/view-types/renderers/calendar-view-prop-sheet.component.d.ts.map +1 -0
- package/dist/lib/view-types/renderers/calendar-view-prop-sheet.component.js +167 -0
- package/dist/lib/view-types/renderers/calendar-view-prop-sheet.component.js.map +1 -0
- package/dist/lib/view-types/renderers/calendar-view-renderer.component.d.ts +107 -0
- package/dist/lib/view-types/renderers/calendar-view-renderer.component.d.ts.map +1 -0
- package/dist/lib/view-types/renderers/calendar-view-renderer.component.js +501 -0
- package/dist/lib/view-types/renderers/calendar-view-renderer.component.js.map +1 -0
- package/dist/lib/view-types/renderers/grid-view-renderer.component.d.ts +3 -1
- package/dist/lib/view-types/renderers/grid-view-renderer.component.d.ts.map +1 -1
- package/dist/lib/view-types/renderers/grid-view-renderer.component.js +12 -3
- package/dist/lib/view-types/renderers/grid-view-renderer.component.js.map +1 -1
- package/dist/lib/view-types/renderers/map-view-renderer.component.d.ts.map +1 -1
- package/dist/lib/view-types/renderers/map-view-renderer.component.js +3 -3
- package/dist/lib/view-types/renderers/map-view-renderer.component.js.map +1 -1
- package/dist/lib/view-workspace/view-workspace.component.d.ts +40 -1
- package/dist/lib/view-workspace/view-workspace.component.d.ts.map +1 -1
- package/dist/lib/view-workspace/view-workspace.component.js +185 -15
- package/dist/lib/view-workspace/view-workspace.component.js.map +1 -1
- package/dist/module.d.ts +35 -31
- package/dist/module.d.ts.map +1 -1
- package/dist/module.js +21 -3
- package/dist/module.js.map +1 -1
- package/dist/public-api.d.ts +5 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +5 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +22 -21
|
@@ -0,0 +1,501 @@
|
|
|
1
|
+
import { Component, Input, Output, EventEmitter, ChangeDetectorRef, ViewEncapsulation, inject, } from '@angular/core';
|
|
2
|
+
import { EntityFieldTSType } from '@memberjunction/core';
|
|
3
|
+
import { GetMonthYearLabel } from '@memberjunction/ng-ui-components';
|
|
4
|
+
import { BaseAngularComponent } from '@memberjunction/ng-base-types';
|
|
5
|
+
import { BuildCalendarItems, CALENDAR_WEEK_DAYS, DayKey, GetMonthWeeks, GetVisibleDays, GroupItemsByDay, ResolveCalendarFields, ShiftAnchor, StartOfDay, } from './calendar-placement';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
import * as i1 from "@angular/common";
|
|
8
|
+
import * as i2 from "@memberjunction/ng-ui-components";
|
|
9
|
+
import * as i3 from "./calendar-view-prop-sheet.component";
|
|
10
|
+
const _c0 = (a0, a1) => ({ $implicit: a0, day: a1 });
|
|
11
|
+
const _forTrack0 = ($index, $item) => $item.getTime();
|
|
12
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_12_Template(rf, ctx) { if (rf & 1) {
|
|
13
|
+
const _r3 = i0.ɵɵgetCurrentView();
|
|
14
|
+
i0.ɵɵelementStart(0, "mj-calendar-view-prop-sheet", 16);
|
|
15
|
+
i0.ɵɵlistener("configChange", function CalendarViewRendererComponent_Conditional_1_Conditional_12_Template_mj_calendar_view_prop_sheet_configChange_0_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.OnSettingsChange($event)); });
|
|
16
|
+
i0.ɵɵelementEnd();
|
|
17
|
+
} if (rf & 2) {
|
|
18
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
19
|
+
i0.ɵɵproperty("entity", ctx_r1.entity)("config", ctx_r1.config);
|
|
20
|
+
} }
|
|
21
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_13_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
22
|
+
i0.ɵɵelementStart(0, "div", 17);
|
|
23
|
+
i0.ɵɵtext(1);
|
|
24
|
+
i0.ɵɵelementEnd();
|
|
25
|
+
} if (rf & 2) {
|
|
26
|
+
const label_r4 = ctx.$implicit;
|
|
27
|
+
i0.ɵɵadvance();
|
|
28
|
+
i0.ɵɵtextInterpolate(label_r4);
|
|
29
|
+
} }
|
|
30
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_For_4_ng_container_0_Template(rf, ctx) { if (rf & 1) {
|
|
31
|
+
i0.ɵɵelementContainer(0);
|
|
32
|
+
} }
|
|
33
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_For_4_Template(rf, ctx) { if (rf & 1) {
|
|
34
|
+
i0.ɵɵtemplate(0, CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_For_4_ng_container_0_Template, 1, 0, "ng-container", 22);
|
|
35
|
+
} if (rf & 2) {
|
|
36
|
+
const item_r5 = ctx.$implicit;
|
|
37
|
+
const day_r6 = i0.ɵɵnextContext().$implicit;
|
|
38
|
+
i0.ɵɵnextContext(4);
|
|
39
|
+
const itemChip_r7 = i0.ɵɵreference(4);
|
|
40
|
+
i0.ɵɵproperty("ngTemplateOutlet", itemChip_r7)("ngTemplateOutletContext", i0.ɵɵpureFunction2(2, _c0, item_r5, day_r6));
|
|
41
|
+
} }
|
|
42
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_Conditional_5_Template(rf, ctx) { if (rf & 1) {
|
|
43
|
+
const _r8 = i0.ɵɵgetCurrentView();
|
|
44
|
+
i0.ɵɵelementStart(0, "button", 23);
|
|
45
|
+
i0.ɵɵlistener("click", function CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_Conditional_5_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r8); const day_r6 = i0.ɵɵnextContext().$implicit; const ctx_r1 = i0.ɵɵnextContext(4); return i0.ɵɵresetView(ctx_r1.GoToDay(day_r6)); });
|
|
46
|
+
i0.ɵɵtext(1);
|
|
47
|
+
i0.ɵɵelementEnd();
|
|
48
|
+
} if (rf & 2) {
|
|
49
|
+
const day_r6 = i0.ɵɵnextContext().$implicit;
|
|
50
|
+
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
51
|
+
i0.ɵɵadvance();
|
|
52
|
+
i0.ɵɵtextInterpolate1("+", ctx_r1.ItemsFor(day_r6).length - ctx_r1.MaxItemsPerCell, " more");
|
|
53
|
+
} }
|
|
54
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_Template(rf, ctx) { if (rf & 1) {
|
|
55
|
+
i0.ɵɵelementStart(0, "div", 19)(1, "div", 20);
|
|
56
|
+
i0.ɵɵtext(2);
|
|
57
|
+
i0.ɵɵelementEnd();
|
|
58
|
+
i0.ɵɵrepeaterCreate(3, CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_For_4_Template, 1, 5, "ng-container", null, i0.ɵɵrepeaterTrackByIndex);
|
|
59
|
+
i0.ɵɵconditionalCreate(5, CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_Conditional_5_Template, 2, 1, "button", 21);
|
|
60
|
+
i0.ɵɵelementEnd();
|
|
61
|
+
} if (rf & 2) {
|
|
62
|
+
const day_r6 = ctx.$implicit;
|
|
63
|
+
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
64
|
+
i0.ɵɵclassProp("is-other-month", day_r6.getMonth() !== ctx_r1.Anchor.getMonth())("is-today", ctx_r1.IsToday(day_r6));
|
|
65
|
+
i0.ɵɵadvance(2);
|
|
66
|
+
i0.ɵɵtextInterpolate(day_r6.getDate());
|
|
67
|
+
i0.ɵɵadvance();
|
|
68
|
+
i0.ɵɵrepeater(ctx_r1.ItemsFor(day_r6).slice(0, ctx_r1.MaxItemsPerCell));
|
|
69
|
+
i0.ɵɵadvance(2);
|
|
70
|
+
i0.ɵɵconditional(ctx_r1.ItemsFor(day_r6).length > ctx_r1.MaxItemsPerCell ? 5 : -1);
|
|
71
|
+
} }
|
|
72
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_Template(rf, ctx) { if (rf & 1) {
|
|
73
|
+
i0.ɵɵrepeaterCreate(0, CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_For_1_Template, 6, 6, "div", 18, _forTrack0);
|
|
74
|
+
} if (rf & 2) {
|
|
75
|
+
const week_r9 = ctx.$implicit;
|
|
76
|
+
i0.ɵɵrepeater(week_r9);
|
|
77
|
+
} }
|
|
78
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_13_Template(rf, ctx) { if (rf & 1) {
|
|
79
|
+
i0.ɵɵelementStart(0, "div", 14);
|
|
80
|
+
i0.ɵɵrepeaterCreate(1, CalendarViewRendererComponent_Conditional_1_Conditional_13_For_2_Template, 2, 1, "div", 17, i0.ɵɵrepeaterTrackByIdentity);
|
|
81
|
+
i0.ɵɵrepeaterCreate(3, CalendarViewRendererComponent_Conditional_1_Conditional_13_For_4_Template, 2, 0, null, null, i0.ɵɵrepeaterTrackByIndex);
|
|
82
|
+
i0.ɵɵelementEnd();
|
|
83
|
+
} if (rf & 2) {
|
|
84
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
85
|
+
i0.ɵɵadvance();
|
|
86
|
+
i0.ɵɵrepeater(ctx_r1.WeekDayLabels);
|
|
87
|
+
i0.ɵɵadvance(2);
|
|
88
|
+
i0.ɵɵrepeater(ctx_r1.MonthWeeks);
|
|
89
|
+
} }
|
|
90
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_For_4_ng_container_0_Template(rf, ctx) { if (rf & 1) {
|
|
91
|
+
i0.ɵɵelementContainer(0);
|
|
92
|
+
} }
|
|
93
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_For_4_Template(rf, ctx) { if (rf & 1) {
|
|
94
|
+
i0.ɵɵtemplate(0, CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_For_4_ng_container_0_Template, 1, 0, "ng-container", 22);
|
|
95
|
+
} if (rf & 2) {
|
|
96
|
+
const item_r10 = ctx.$implicit;
|
|
97
|
+
const day_r11 = i0.ɵɵnextContext().$implicit;
|
|
98
|
+
i0.ɵɵnextContext(3);
|
|
99
|
+
const itemChip_r7 = i0.ɵɵreference(4);
|
|
100
|
+
i0.ɵɵproperty("ngTemplateOutlet", itemChip_r7)("ngTemplateOutletContext", i0.ɵɵpureFunction2(2, _c0, item_r10, day_r11));
|
|
101
|
+
} }
|
|
102
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_ForEmpty_5_Template(rf, ctx) { if (rf & 1) {
|
|
103
|
+
i0.ɵɵelementStart(0, "div", 27);
|
|
104
|
+
i0.ɵɵtext(1, "No records");
|
|
105
|
+
i0.ɵɵelementEnd();
|
|
106
|
+
} }
|
|
107
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
108
|
+
i0.ɵɵelementStart(0, "div", 25)(1, "div", 26);
|
|
109
|
+
i0.ɵɵtext(2);
|
|
110
|
+
i0.ɵɵelementEnd();
|
|
111
|
+
i0.ɵɵrepeaterCreate(3, CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_For_4_Template, 1, 5, "ng-container", null, i0.ɵɵrepeaterTrackByIndex, false, CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_ForEmpty_5_Template, 2, 0, "div", 27);
|
|
112
|
+
i0.ɵɵelementEnd();
|
|
113
|
+
} if (rf & 2) {
|
|
114
|
+
const day_r11 = ctx.$implicit;
|
|
115
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
116
|
+
i0.ɵɵclassProp("is-today", ctx_r1.IsToday(day_r11));
|
|
117
|
+
i0.ɵɵadvance(2);
|
|
118
|
+
i0.ɵɵtextInterpolate(ctx_r1.DayHeader(day_r11));
|
|
119
|
+
i0.ɵɵadvance();
|
|
120
|
+
i0.ɵɵrepeater(ctx_r1.ItemsFor(day_r11));
|
|
121
|
+
} }
|
|
122
|
+
function CalendarViewRendererComponent_Conditional_1_Conditional_14_Template(rf, ctx) { if (rf & 1) {
|
|
123
|
+
i0.ɵɵelementStart(0, "div", 15);
|
|
124
|
+
i0.ɵɵrepeaterCreate(1, CalendarViewRendererComponent_Conditional_1_Conditional_14_For_2_Template, 6, 4, "div", 24, _forTrack0);
|
|
125
|
+
i0.ɵɵelementEnd();
|
|
126
|
+
} if (rf & 2) {
|
|
127
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
128
|
+
i0.ɵɵadvance();
|
|
129
|
+
i0.ɵɵrepeater(ctx_r1.VisibleDays);
|
|
130
|
+
} }
|
|
131
|
+
function CalendarViewRendererComponent_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
132
|
+
const _r1 = i0.ɵɵgetCurrentView();
|
|
133
|
+
i0.ɵɵelementStart(0, "div", 3)(1, "button", 4);
|
|
134
|
+
i0.ɵɵlistener("click", function CalendarViewRendererComponent_Conditional_1_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.Previous()); });
|
|
135
|
+
i0.ɵɵelement(2, "i", 5);
|
|
136
|
+
i0.ɵɵelementEnd();
|
|
137
|
+
i0.ɵɵelementStart(3, "button", 6);
|
|
138
|
+
i0.ɵɵlistener("click", function CalendarViewRendererComponent_Conditional_1_Template_button_click_3_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.Today()); });
|
|
139
|
+
i0.ɵɵtext(4, "Today");
|
|
140
|
+
i0.ɵɵelementEnd();
|
|
141
|
+
i0.ɵɵelementStart(5, "button", 7);
|
|
142
|
+
i0.ɵɵlistener("click", function CalendarViewRendererComponent_Conditional_1_Template_button_click_5_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.Next()); });
|
|
143
|
+
i0.ɵɵelement(6, "i", 8);
|
|
144
|
+
i0.ɵɵelementEnd();
|
|
145
|
+
i0.ɵɵelementStart(7, "span", 9);
|
|
146
|
+
i0.ɵɵtext(8);
|
|
147
|
+
i0.ɵɵelementEnd();
|
|
148
|
+
i0.ɵɵelementStart(9, "mj-view-toggle", 10);
|
|
149
|
+
i0.ɵɵlistener("KeyChange", function CalendarViewRendererComponent_Conditional_1_Template_mj_view_toggle_KeyChange_9_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.SetMode($event)); });
|
|
150
|
+
i0.ɵɵelementEnd();
|
|
151
|
+
i0.ɵɵelementStart(10, "button", 11);
|
|
152
|
+
i0.ɵɵtwoWayListener("SelectedChange", function CalendarViewRendererComponent_Conditional_1_Template_button_SelectedChange_10_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); i0.ɵɵtwoWayBindingSet(ctx_r1.ShowSettings, $event) || (ctx_r1.ShowSettings = $event); return i0.ɵɵresetView($event); });
|
|
153
|
+
i0.ɵɵelement(11, "i", 12);
|
|
154
|
+
i0.ɵɵelementEnd()();
|
|
155
|
+
i0.ɵɵconditionalCreate(12, CalendarViewRendererComponent_Conditional_1_Conditional_12_Template, 1, 2, "mj-calendar-view-prop-sheet", 13);
|
|
156
|
+
i0.ɵɵconditionalCreate(13, CalendarViewRendererComponent_Conditional_1_Conditional_13_Template, 5, 0, "div", 14)(14, CalendarViewRendererComponent_Conditional_1_Conditional_14_Template, 3, 0, "div", 15);
|
|
157
|
+
} if (rf & 2) {
|
|
158
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
159
|
+
i0.ɵɵadvance(8);
|
|
160
|
+
i0.ɵɵtextInterpolate(ctx_r1.Title);
|
|
161
|
+
i0.ɵɵadvance();
|
|
162
|
+
i0.ɵɵproperty("Options", ctx_r1.ModeOptions)("ActiveKey", ctx_r1.Mode);
|
|
163
|
+
i0.ɵɵadvance();
|
|
164
|
+
i0.ɵɵproperty("Toggleable", true);
|
|
165
|
+
i0.ɵɵtwoWayProperty("Selected", ctx_r1.ShowSettings);
|
|
166
|
+
i0.ɵɵadvance(2);
|
|
167
|
+
i0.ɵɵconditional(ctx_r1.ShowSettings ? 12 : -1);
|
|
168
|
+
i0.ɵɵadvance();
|
|
169
|
+
i0.ɵɵconditional(ctx_r1.Mode === "month" ? 13 : 14);
|
|
170
|
+
} }
|
|
171
|
+
function CalendarViewRendererComponent_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
172
|
+
i0.ɵɵelement(0, "mj-empty-state", 2);
|
|
173
|
+
} }
|
|
174
|
+
function CalendarViewRendererComponent_ng_template_3_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
175
|
+
i0.ɵɵelementStart(0, "span", 29);
|
|
176
|
+
i0.ɵɵtext(1);
|
|
177
|
+
i0.ɵɵelementEnd();
|
|
178
|
+
} if (rf & 2) {
|
|
179
|
+
i0.ɵɵadvance();
|
|
180
|
+
i0.ɵɵtextInterpolate(ctx);
|
|
181
|
+
} }
|
|
182
|
+
function CalendarViewRendererComponent_ng_template_3_Template(rf, ctx) { if (rf & 1) {
|
|
183
|
+
const _r12 = i0.ɵɵgetCurrentView();
|
|
184
|
+
i0.ɵɵelementStart(0, "button", 28);
|
|
185
|
+
i0.ɵɵlistener("click", function CalendarViewRendererComponent_ng_template_3_Template_button_click_0_listener() { const item_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnItemClick(item_r13)); })("dblclick", function CalendarViewRendererComponent_ng_template_3_Template_button_dblclick_0_listener() { const item_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnItemOpen(item_r13)); });
|
|
186
|
+
i0.ɵɵconditionalCreate(1, CalendarViewRendererComponent_ng_template_3_Conditional_1_Template, 2, 1, "span", 29);
|
|
187
|
+
i0.ɵɵelementStart(2, "span", 30);
|
|
188
|
+
i0.ɵɵtext(3);
|
|
189
|
+
i0.ɵɵelementEnd()();
|
|
190
|
+
} if (rf & 2) {
|
|
191
|
+
let tmp_6_0;
|
|
192
|
+
const item_r13 = ctx.$implicit;
|
|
193
|
+
const day_r14 = ctx.day;
|
|
194
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
195
|
+
i0.ɵɵclassProp("is-continued", !ctx_r1.IsFirstDay(item_r13, day_r14));
|
|
196
|
+
i0.ɵɵproperty("title", ctx_r1.ItemLabel(item_r13));
|
|
197
|
+
i0.ɵɵadvance();
|
|
198
|
+
i0.ɵɵconditional((tmp_6_0 = ctx_r1.ItemTime(item_r13, day_r14)) ? 1 : -1, tmp_6_0);
|
|
199
|
+
i0.ɵɵadvance(2);
|
|
200
|
+
i0.ɵɵtextInterpolate(ctx_r1.ItemLabel(item_r13));
|
|
201
|
+
} }
|
|
202
|
+
/**
|
|
203
|
+
* CalendarViewRendererComponent
|
|
204
|
+
* -----------------------------
|
|
205
|
+
* The Calendar **view type** ({@link IViewRenderer}): records placed on a day, week (Monday
|
|
206
|
+
* first) or month layout by a start field and an optional end field named in the view's
|
|
207
|
+
* {@link CalendarViewConfig}. Placement is the pure logic in `calendar-placement.ts`; this
|
|
208
|
+
* component only holds the anchor date and binds the result.
|
|
209
|
+
*
|
|
210
|
+
* Like Map, it asks the host for the full record set (`dataRequest({ loadAll: true })`), so it
|
|
211
|
+
* sees up to the host's load-all cap rather than one page. Clicking a record emits
|
|
212
|
+
* `recordSelected` and double-clicking emits `recordOpened`, as the Cards renderer does. A gear
|
|
213
|
+
* button opens the {@link CalendarViewPropSheetComponent} inline, because no host mounts a
|
|
214
|
+
* descriptor's prop sheet yet.
|
|
215
|
+
*
|
|
216
|
+
* Inputs/outputs use the camelCase names the {@link IViewRenderer} contract mandates.
|
|
217
|
+
*/
|
|
218
|
+
export class CalendarViewRendererComponent extends BaseAngularComponent {
|
|
219
|
+
_entity = null;
|
|
220
|
+
/** The entity whose records are placed. */
|
|
221
|
+
set entity(value) {
|
|
222
|
+
this._entity = value;
|
|
223
|
+
this.rebuild();
|
|
224
|
+
}
|
|
225
|
+
get entity() {
|
|
226
|
+
return this._entity;
|
|
227
|
+
}
|
|
228
|
+
_records = [];
|
|
229
|
+
/** The records to place (loaded/filtered by the host). */
|
|
230
|
+
set records(value) {
|
|
231
|
+
this._records = value ?? [];
|
|
232
|
+
this.rebuild();
|
|
233
|
+
}
|
|
234
|
+
get records() {
|
|
235
|
+
return this._records;
|
|
236
|
+
}
|
|
237
|
+
/** Primary-key string of the selected record. Accepted for contract uniformity. */
|
|
238
|
+
selectedRecordId = null;
|
|
239
|
+
/** Active filter text. Accepted for contract uniformity; the host pre-filters `records`. */
|
|
240
|
+
filterText = null;
|
|
241
|
+
_config = {};
|
|
242
|
+
/** The persisted view config: start/end fields and the layout the view opens in. */
|
|
243
|
+
set config(value) {
|
|
244
|
+
this._config = value ?? {};
|
|
245
|
+
this.Mode = this._config.mode ?? 'month';
|
|
246
|
+
this.rebuild();
|
|
247
|
+
}
|
|
248
|
+
get config() {
|
|
249
|
+
return this._config;
|
|
250
|
+
}
|
|
251
|
+
/** Emitted on a record click with the raw record. */
|
|
252
|
+
recordSelected = new EventEmitter();
|
|
253
|
+
/** Emitted on a record double-click with the raw record (a navigation request). */
|
|
254
|
+
recordOpened = new EventEmitter();
|
|
255
|
+
/** Emitted with the full config when the layout or the settings change. */
|
|
256
|
+
configChanged = new EventEmitter();
|
|
257
|
+
/** Asks the host for the full record set on init. */
|
|
258
|
+
dataRequest = new EventEmitter();
|
|
259
|
+
/** The current layout. */
|
|
260
|
+
Mode = 'month';
|
|
261
|
+
/** A date inside the period on screen. */
|
|
262
|
+
Anchor = StartOfDay(new Date());
|
|
263
|
+
/** Whether the inline settings sheet is open. */
|
|
264
|
+
ShowSettings = false;
|
|
265
|
+
/** Whether the entity has any date field. */
|
|
266
|
+
HasDateFields = false;
|
|
267
|
+
/** Month cells shown before "+N more". */
|
|
268
|
+
MaxItemsPerCell = 3;
|
|
269
|
+
/** Monday-first weekday labels. */
|
|
270
|
+
WeekDayLabels = CALENDAR_WEEK_DAYS;
|
|
271
|
+
/** The layout switch options. */
|
|
272
|
+
ModeOptions = [
|
|
273
|
+
{ key: 'day', label: 'Day' },
|
|
274
|
+
{ key: 'week', label: 'Week' },
|
|
275
|
+
{ key: 'month', label: 'Month' },
|
|
276
|
+
];
|
|
277
|
+
/** The month grid's weeks. */
|
|
278
|
+
MonthWeeks = [];
|
|
279
|
+
/** The days of the day/week layout. */
|
|
280
|
+
VisibleDays = [];
|
|
281
|
+
items = [];
|
|
282
|
+
itemsByDay = new Map();
|
|
283
|
+
titleFieldName = null;
|
|
284
|
+
cdr = inject(ChangeDetectorRef);
|
|
285
|
+
ngOnInit() {
|
|
286
|
+
this.dataRequest.emit({ loadAll: true });
|
|
287
|
+
}
|
|
288
|
+
/** The header label for the period on screen. */
|
|
289
|
+
get Title() {
|
|
290
|
+
if (this.Mode === 'month') {
|
|
291
|
+
return GetMonthYearLabel(this.Anchor);
|
|
292
|
+
}
|
|
293
|
+
const options = { month: 'short', day: 'numeric', year: 'numeric' };
|
|
294
|
+
if (this.Mode === 'day') {
|
|
295
|
+
return this.Anchor.toLocaleDateString(undefined, { weekday: 'long', ...options });
|
|
296
|
+
}
|
|
297
|
+
const days = this.VisibleDays;
|
|
298
|
+
return `${days[0].toLocaleDateString(undefined, options)} – ${days[6].toLocaleDateString(undefined, options)}`;
|
|
299
|
+
}
|
|
300
|
+
Previous() {
|
|
301
|
+
this.moveTo(ShiftAnchor(this.Mode, this.Anchor, -1));
|
|
302
|
+
}
|
|
303
|
+
Next() {
|
|
304
|
+
this.moveTo(ShiftAnchor(this.Mode, this.Anchor, 1));
|
|
305
|
+
}
|
|
306
|
+
Today() {
|
|
307
|
+
this.moveTo(StartOfDay(new Date()));
|
|
308
|
+
}
|
|
309
|
+
/** Switch layout (a `ModeOptions` key) and persist it as the view's mode. */
|
|
310
|
+
SetMode(key) {
|
|
311
|
+
const mode = key === 'day' || key === 'week' ? key : 'month';
|
|
312
|
+
this.Mode = mode;
|
|
313
|
+
this._config = { ...this._config, mode };
|
|
314
|
+
this.configChanged.emit(this._config);
|
|
315
|
+
this.layout();
|
|
316
|
+
}
|
|
317
|
+
/** Open the day layout on `day` (from a month cell's "+N more"). */
|
|
318
|
+
GoToDay(day) {
|
|
319
|
+
this.Anchor = day;
|
|
320
|
+
this.SetMode('day');
|
|
321
|
+
}
|
|
322
|
+
/** Apply and persist a change from the settings sheet. */
|
|
323
|
+
OnSettingsChange(config) {
|
|
324
|
+
this.config = config;
|
|
325
|
+
this.configChanged.emit(this._config);
|
|
326
|
+
}
|
|
327
|
+
ItemsFor(day) {
|
|
328
|
+
return this.itemsByDay.get(DayKey(day)) ?? [];
|
|
329
|
+
}
|
|
330
|
+
IsToday(day) {
|
|
331
|
+
return DayKey(day) === DayKey(new Date());
|
|
332
|
+
}
|
|
333
|
+
IsFirstDay(item, day) {
|
|
334
|
+
return DayKey(item.FirstDay) === DayKey(day);
|
|
335
|
+
}
|
|
336
|
+
/** The record's display title. */
|
|
337
|
+
ItemLabel(item) {
|
|
338
|
+
const value = this.titleFieldName ? item.Record[this.titleFieldName] : null;
|
|
339
|
+
return value != null && value !== '' ? String(value) : '(untitled)';
|
|
340
|
+
}
|
|
341
|
+
/** The start time, on the item's first day only; empty for a date-only start. */
|
|
342
|
+
ItemTime(item, day) {
|
|
343
|
+
if (item.AllDay || !this.IsFirstDay(item, day)) {
|
|
344
|
+
return '';
|
|
345
|
+
}
|
|
346
|
+
return item.Start.toLocaleTimeString(undefined, { hour: 'numeric', minute: '2-digit' });
|
|
347
|
+
}
|
|
348
|
+
DayHeader(day) {
|
|
349
|
+
return day.toLocaleDateString(undefined, { weekday: 'short', month: 'short', day: 'numeric' });
|
|
350
|
+
}
|
|
351
|
+
OnItemClick(item) {
|
|
352
|
+
this.recordSelected.emit(item.Record);
|
|
353
|
+
}
|
|
354
|
+
OnItemOpen(item) {
|
|
355
|
+
this.recordOpened.emit(item.Record);
|
|
356
|
+
}
|
|
357
|
+
moveTo(anchor) {
|
|
358
|
+
this.Anchor = anchor;
|
|
359
|
+
this.layout();
|
|
360
|
+
}
|
|
361
|
+
/** Re-resolve fields and re-place every record (entity, records or config changed). */
|
|
362
|
+
rebuild() {
|
|
363
|
+
const fields = ResolveCalendarFields(this._entity, this._config);
|
|
364
|
+
this.HasDateFields = fields.Start != null;
|
|
365
|
+
this.titleFieldName = this.findTitleField();
|
|
366
|
+
this.items = BuildCalendarItems(this._records, fields.Start, fields.End);
|
|
367
|
+
this.layout();
|
|
368
|
+
}
|
|
369
|
+
/** Recompute the days on screen and the items on each. */
|
|
370
|
+
layout() {
|
|
371
|
+
this.MonthWeeks = this.Mode === 'month' ? GetMonthWeeks(this.Anchor) : [];
|
|
372
|
+
this.VisibleDays = GetVisibleDays(this.Mode, this.Anchor);
|
|
373
|
+
this.itemsByDay = GroupItemsByDay(this.items, this.VisibleDays);
|
|
374
|
+
this.cdr.markForCheck();
|
|
375
|
+
}
|
|
376
|
+
/** The entity's name field, else its first visible text field. */
|
|
377
|
+
findTitleField() {
|
|
378
|
+
const entity = this._entity;
|
|
379
|
+
if (!entity) {
|
|
380
|
+
return null;
|
|
381
|
+
}
|
|
382
|
+
if (entity.NameField) {
|
|
383
|
+
return entity.NameField.Name;
|
|
384
|
+
}
|
|
385
|
+
const text = entity.Fields
|
|
386
|
+
.filter((f) => f.TSType === EntityFieldTSType.String && f.DefaultInView && !f.Name.startsWith('__mj_'))
|
|
387
|
+
.sort((a, b) => a.Sequence - b.Sequence);
|
|
388
|
+
return text[0]?.Name ?? null;
|
|
389
|
+
}
|
|
390
|
+
static ɵfac = /*@__PURE__*/ (() => { let ɵCalendarViewRendererComponent_BaseFactory; return function CalendarViewRendererComponent_Factory(__ngFactoryType__) { return (ɵCalendarViewRendererComponent_BaseFactory || (ɵCalendarViewRendererComponent_BaseFactory = i0.ɵɵgetInheritedFactory(CalendarViewRendererComponent)))(__ngFactoryType__ || CalendarViewRendererComponent); }; })();
|
|
391
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CalendarViewRendererComponent, selectors: [["mj-calendar-view-renderer"]], inputs: { entity: "entity", records: "records", selectedRecordId: "selectedRecordId", filterText: "filterText", config: "config" }, outputs: { recordSelected: "recordSelected", recordOpened: "recordOpened", configChanged: "configChanged", dataRequest: "dataRequest" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 5, vars: 1, consts: [["itemChip", ""], [1, "calendar-view"], ["Variant", "warning", "Icon", "fa-solid fa-calendar-xmark", "Title", "This entity has no date fields to place on a calendar.", 1, "calendar-view-empty-fill"], [1, "calendar-view-chrome"], ["mjButton", "", "Variant", "outline", "Size", "sm", "type", "button", "title", "Previous", "AriaLabel", "Previous", 3, "click"], ["aria-hidden", "true", 1, "fa-solid", "fa-chevron-left"], ["mjButton", "", "Variant", "outline", "Size", "sm", "type", "button", 3, "click"], ["mjButton", "", "Variant", "outline", "Size", "sm", "type", "button", "title", "Next", "AriaLabel", "Next", 3, "click"], ["aria-hidden", "true", 1, "fa-solid", "fa-chevron-right"], [1, "calendar-view-title"], [3, "KeyChange", "Options", "ActiveKey"], ["mjButton", "", "Variant", "icon", "Size", "sm", "type", "button", "title", "Calendar settings", "AriaLabel", "Calendar settings", 3, "SelectedChange", "Toggleable", "Selected"], ["aria-hidden", "true", 1, "fa-solid", "fa-gear"], [3, "entity", "config"], [1, "calendar-month"], [1, "calendar-columns"], [3, "configChange", "entity", "config"], [1, "calendar-weekday"], [1, "calendar-cell", 3, "is-other-month", "is-today"], [1, "calendar-cell"], [1, "calendar-day-number"], ["type", "button", 1, "calendar-more"], [4, "ngTemplateOutlet", "ngTemplateOutletContext"], ["type", "button", 1, "calendar-more", 3, "click"], [1, "calendar-column", 3, "is-today"], [1, "calendar-column"], [1, "calendar-column-header"], [1, "calendar-column-empty"], ["type", "button", 1, "calendar-item", 3, "click", "dblclick", "title"], [1, "calendar-item-time"], [1, "calendar-item-label"]], template: function CalendarViewRendererComponent_Template(rf, ctx) { if (rf & 1) {
|
|
392
|
+
i0.ɵɵelementStart(0, "div", 1);
|
|
393
|
+
i0.ɵɵconditionalCreate(1, CalendarViewRendererComponent_Conditional_1_Template, 15, 7)(2, CalendarViewRendererComponent_Conditional_2_Template, 1, 0, "mj-empty-state", 2);
|
|
394
|
+
i0.ɵɵelementEnd();
|
|
395
|
+
i0.ɵɵtemplate(3, CalendarViewRendererComponent_ng_template_3_Template, 4, 5, "ng-template", null, 0, i0.ɵɵtemplateRefExtractor);
|
|
396
|
+
} if (rf & 2) {
|
|
397
|
+
i0.ɵɵadvance();
|
|
398
|
+
i0.ɵɵconditional(ctx.HasDateFields ? 1 : 2);
|
|
399
|
+
} }, dependencies: [i1.NgTemplateOutlet, i2.MJButtonDirective, i2.MJEmptyStateComponent, i2.MJViewToggleComponent, i3.CalendarViewPropSheetComponent], styles: ["\n /* The host forces display:block on the renderer element, so the flex column lives on a wrapper. */\n .calendar-view {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n }\n .calendar-view-chrome {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 8px 12px;\n flex: 0 0 auto;\n }\n .calendar-view-title {\n flex: 1 1 auto;\n font-size: 15px;\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n .calendar-month {\n flex: 1 1 auto;\n min-height: 0;\n overflow: auto;\n display: grid;\n grid-template-columns: repeat(7, minmax(0, 1fr));\n grid-template-rows: auto; /* the weekday header row */\n grid-auto-rows: minmax(96px, auto);\n border-top: 1px solid var(--mj-border-default);\n border-left: 1px solid var(--mj-border-default);\n }\n .calendar-weekday {\n padding: 4px 8px;\n font-size: 12px;\n font-weight: 600;\n color: var(--mj-text-muted);\n background: var(--mj-bg-surface-card);\n border-right: 1px solid var(--mj-border-default);\n border-bottom: 1px solid var(--mj-border-default);\n }\n .calendar-cell,\n .calendar-column {\n display: flex;\n flex-direction: column;\n gap: 2px;\n padding: 4px;\n min-width: 0;\n background: var(--mj-bg-surface);\n border-right: 1px solid var(--mj-border-default);\n border-bottom: 1px solid var(--mj-border-default);\n }\n .calendar-cell.is-other-month {\n background: var(--mj-bg-surface-sunken);\n }\n .calendar-cell.is-other-month .calendar-day-number {\n color: var(--mj-text-disabled);\n }\n .calendar-day-number {\n font-size: 12px;\n color: var(--mj-text-secondary);\n }\n .is-today .calendar-day-number,\n .is-today .calendar-column-header {\n color: var(--mj-brand-primary);\n font-weight: 700;\n }\n .calendar-columns {\n flex: 1 1 auto;\n min-height: 0;\n overflow: auto;\n display: grid;\n grid-auto-flow: column;\n grid-auto-columns: minmax(0, 1fr);\n border-top: 1px solid var(--mj-border-default);\n border-left: 1px solid var(--mj-border-default);\n }\n .calendar-column-header {\n padding: 4px;\n font-size: 13px;\n font-weight: 600;\n color: var(--mj-text-secondary);\n }\n .calendar-column-empty {\n padding: 4px;\n font-size: 12px;\n color: var(--mj-text-disabled);\n }\n .calendar-item {\n display: flex;\n gap: 6px;\n align-items: baseline;\n width: 100%;\n padding: 2px 6px;\n border: none;\n border-left: 3px solid var(--mj-brand-primary);\n border-radius: 4px;\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n color: var(--mj-text-primary);\n font-size: 12px;\n text-align: left;\n cursor: pointer;\n }\n .calendar-item:hover {\n background: color-mix(in srgb, var(--mj-brand-primary) 18%, var(--mj-bg-surface));\n }\n .calendar-item.is-continued {\n border-left-style: dashed;\n }\n .calendar-item-time {\n flex: 0 0 auto;\n color: var(--mj-text-muted);\n }\n .calendar-item-label {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .calendar-more {\n border: none;\n background: transparent;\n color: var(--mj-text-link);\n font-size: 12px;\n text-align: left;\n cursor: pointer;\n padding: 0 6px;\n }\n .calendar-view-empty-fill {\n flex: 1 1 auto;\n }\n "], encapsulation: 2 });
|
|
400
|
+
}
|
|
401
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CalendarViewRendererComponent, [{
|
|
402
|
+
type: Component,
|
|
403
|
+
args: [{ standalone: false, selector: 'mj-calendar-view-renderer', encapsulation: ViewEncapsulation.None, template: `
|
|
404
|
+
<div class="calendar-view">
|
|
405
|
+
@if (HasDateFields) {
|
|
406
|
+
<div class="calendar-view-chrome">
|
|
407
|
+
<button mjButton Variant="outline" Size="sm" type="button" title="Previous" AriaLabel="Previous" (click)="Previous()">
|
|
408
|
+
<i class="fa-solid fa-chevron-left" aria-hidden="true"></i>
|
|
409
|
+
</button>
|
|
410
|
+
<button mjButton Variant="outline" Size="sm" type="button" (click)="Today()">Today</button>
|
|
411
|
+
<button mjButton Variant="outline" Size="sm" type="button" title="Next" AriaLabel="Next" (click)="Next()">
|
|
412
|
+
<i class="fa-solid fa-chevron-right" aria-hidden="true"></i>
|
|
413
|
+
</button>
|
|
414
|
+
<span class="calendar-view-title">{{ Title }}</span>
|
|
415
|
+
<mj-view-toggle [Options]="ModeOptions" [ActiveKey]="Mode" (KeyChange)="SetMode($event)"></mj-view-toggle>
|
|
416
|
+
<button mjButton Variant="icon" Size="sm" type="button" title="Calendar settings" AriaLabel="Calendar settings" [Toggleable]="true" [(Selected)]="ShowSettings">
|
|
417
|
+
<i class="fa-solid fa-gear" aria-hidden="true"></i>
|
|
418
|
+
</button>
|
|
419
|
+
</div>
|
|
420
|
+
|
|
421
|
+
@if (ShowSettings) {
|
|
422
|
+
<mj-calendar-view-prop-sheet [entity]="entity" [config]="config" (configChange)="OnSettingsChange($event)"></mj-calendar-view-prop-sheet>
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
@if (Mode === 'month') {
|
|
426
|
+
<div class="calendar-month">
|
|
427
|
+
@for (label of WeekDayLabels; track label) {
|
|
428
|
+
<div class="calendar-weekday">{{ label }}</div>
|
|
429
|
+
}
|
|
430
|
+
@for (week of MonthWeeks; track $index) {
|
|
431
|
+
@for (day of week; track day.getTime()) {
|
|
432
|
+
<div class="calendar-cell" [class.is-other-month]="day.getMonth() !== Anchor.getMonth()" [class.is-today]="IsToday(day)">
|
|
433
|
+
<div class="calendar-day-number">{{ day.getDate() }}</div>
|
|
434
|
+
@for (item of ItemsFor(day).slice(0, MaxItemsPerCell); track $index) {
|
|
435
|
+
<ng-container *ngTemplateOutlet="itemChip; context: { $implicit: item, day: day }"></ng-container>
|
|
436
|
+
}
|
|
437
|
+
@if (ItemsFor(day).length > MaxItemsPerCell) {
|
|
438
|
+
<button type="button" class="calendar-more" (click)="GoToDay(day)">+{{ ItemsFor(day).length - MaxItemsPerCell }} more</button>
|
|
439
|
+
}
|
|
440
|
+
</div>
|
|
441
|
+
}
|
|
442
|
+
}
|
|
443
|
+
</div>
|
|
444
|
+
} @else {
|
|
445
|
+
<div class="calendar-columns">
|
|
446
|
+
@for (day of VisibleDays; track day.getTime()) {
|
|
447
|
+
<div class="calendar-column" [class.is-today]="IsToday(day)">
|
|
448
|
+
<div class="calendar-column-header">{{ DayHeader(day) }}</div>
|
|
449
|
+
@for (item of ItemsFor(day); track $index) {
|
|
450
|
+
<ng-container *ngTemplateOutlet="itemChip; context: { $implicit: item, day: day }"></ng-container>
|
|
451
|
+
} @empty {
|
|
452
|
+
<div class="calendar-column-empty">No records</div>
|
|
453
|
+
}
|
|
454
|
+
</div>
|
|
455
|
+
}
|
|
456
|
+
</div>
|
|
457
|
+
}
|
|
458
|
+
} @else {
|
|
459
|
+
<mj-empty-state
|
|
460
|
+
class="calendar-view-empty-fill"
|
|
461
|
+
Variant="warning"
|
|
462
|
+
Icon="fa-solid fa-calendar-xmark"
|
|
463
|
+
Title="This entity has no date fields to place on a calendar." />
|
|
464
|
+
}
|
|
465
|
+
</div>
|
|
466
|
+
|
|
467
|
+
<ng-template #itemChip let-item let-day="day">
|
|
468
|
+
<button type="button" class="calendar-item" [class.is-continued]="!IsFirstDay(item, day)"
|
|
469
|
+
[title]="ItemLabel(item)" (click)="OnItemClick(item)" (dblclick)="OnItemOpen(item)">
|
|
470
|
+
@if (ItemTime(item, day); as time) {
|
|
471
|
+
<span class="calendar-item-time">{{ time }}</span>
|
|
472
|
+
}
|
|
473
|
+
<span class="calendar-item-label">{{ ItemLabel(item) }}</span>
|
|
474
|
+
</button>
|
|
475
|
+
</ng-template>
|
|
476
|
+
`, styles: ["\n /* The host forces display:block on the renderer element, so the flex column lives on a wrapper. */\n .calendar-view {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n }\n .calendar-view-chrome {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 8px 12px;\n flex: 0 0 auto;\n }\n .calendar-view-title {\n flex: 1 1 auto;\n font-size: 15px;\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n .calendar-month {\n flex: 1 1 auto;\n min-height: 0;\n overflow: auto;\n display: grid;\n grid-template-columns: repeat(7, minmax(0, 1fr));\n grid-template-rows: auto; /* the weekday header row */\n grid-auto-rows: minmax(96px, auto);\n border-top: 1px solid var(--mj-border-default);\n border-left: 1px solid var(--mj-border-default);\n }\n .calendar-weekday {\n padding: 4px 8px;\n font-size: 12px;\n font-weight: 600;\n color: var(--mj-text-muted);\n background: var(--mj-bg-surface-card);\n border-right: 1px solid var(--mj-border-default);\n border-bottom: 1px solid var(--mj-border-default);\n }\n .calendar-cell,\n .calendar-column {\n display: flex;\n flex-direction: column;\n gap: 2px;\n padding: 4px;\n min-width: 0;\n background: var(--mj-bg-surface);\n border-right: 1px solid var(--mj-border-default);\n border-bottom: 1px solid var(--mj-border-default);\n }\n .calendar-cell.is-other-month {\n background: var(--mj-bg-surface-sunken);\n }\n .calendar-cell.is-other-month .calendar-day-number {\n color: var(--mj-text-disabled);\n }\n .calendar-day-number {\n font-size: 12px;\n color: var(--mj-text-secondary);\n }\n .is-today .calendar-day-number,\n .is-today .calendar-column-header {\n color: var(--mj-brand-primary);\n font-weight: 700;\n }\n .calendar-columns {\n flex: 1 1 auto;\n min-height: 0;\n overflow: auto;\n display: grid;\n grid-auto-flow: column;\n grid-auto-columns: minmax(0, 1fr);\n border-top: 1px solid var(--mj-border-default);\n border-left: 1px solid var(--mj-border-default);\n }\n .calendar-column-header {\n padding: 4px;\n font-size: 13px;\n font-weight: 600;\n color: var(--mj-text-secondary);\n }\n .calendar-column-empty {\n padding: 4px;\n font-size: 12px;\n color: var(--mj-text-disabled);\n }\n .calendar-item {\n display: flex;\n gap: 6px;\n align-items: baseline;\n width: 100%;\n padding: 2px 6px;\n border: none;\n border-left: 3px solid var(--mj-brand-primary);\n border-radius: 4px;\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n color: var(--mj-text-primary);\n font-size: 12px;\n text-align: left;\n cursor: pointer;\n }\n .calendar-item:hover {\n background: color-mix(in srgb, var(--mj-brand-primary) 18%, var(--mj-bg-surface));\n }\n .calendar-item.is-continued {\n border-left-style: dashed;\n }\n .calendar-item-time {\n flex: 0 0 auto;\n color: var(--mj-text-muted);\n }\n .calendar-item-label {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .calendar-more {\n border: none;\n background: transparent;\n color: var(--mj-text-link);\n font-size: 12px;\n text-align: left;\n cursor: pointer;\n padding: 0 6px;\n }\n .calendar-view-empty-fill {\n flex: 1 1 auto;\n }\n "] }]
|
|
477
|
+
}], null, { entity: [{
|
|
478
|
+
type: Input
|
|
479
|
+
}], records: [{
|
|
480
|
+
type: Input
|
|
481
|
+
}], selectedRecordId: [{
|
|
482
|
+
type: Input
|
|
483
|
+
}], filterText: [{
|
|
484
|
+
type: Input
|
|
485
|
+
}], config: [{
|
|
486
|
+
type: Input
|
|
487
|
+
}], recordSelected: [{
|
|
488
|
+
type: Output
|
|
489
|
+
}], recordOpened: [{
|
|
490
|
+
type: Output
|
|
491
|
+
}], configChanged: [{
|
|
492
|
+
type: Output
|
|
493
|
+
}], dataRequest: [{
|
|
494
|
+
type: Output
|
|
495
|
+
}] }); })();
|
|
496
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(CalendarViewRendererComponent, { className: "CalendarViewRendererComponent", filePath: "src/lib/view-types/renderers/calendar-view-renderer.component.ts", lineNumber: 258 }); })();
|
|
497
|
+
/** Tree-shaking guard for the dynamically mounted renderer. */
|
|
498
|
+
export function LoadCalendarViewRenderer() {
|
|
499
|
+
void CalendarViewRendererComponent;
|
|
500
|
+
}
|
|
501
|
+
//# sourceMappingURL=calendar-view-renderer.component.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"calendar-view-renderer.component.js","sourceRoot":"","sources":["../../../../src/lib/view-types/renderers/calendar-view-renderer.component.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,KAAK,EACL,MAAM,EACN,YAAY,EACZ,iBAAiB,EAEjB,iBAAiB,EACjB,MAAM,GACP,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,iBAAiB,EAAc,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AACrE,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AAErE,OAAO,EACL,kBAAkB,EAClB,kBAAkB,EAIlB,MAAM,EACN,aAAa,EACb,cAAc,EACd,eAAe,EACf,qBAAqB,EACrB,WAAW,EACX,UAAU,GACX,MAAM,sBAAsB,CAAC;;;;;;sCAkDlB,eAAa;;;IATjB,uDAA2G;IAA1C,0PAAgB,+BAAwB,KAAC;IAAC,iBAA8B;;;IAA1F,AAAlB,sCAAiB,yBAAkB;;;IAM5D,+BAA8B;IAAA,YAAW;IAAA,iBAAM;;;IAAjB,cAAW;IAAX,8BAAW;;;IAOnC,wBAAkG;;;IAAlG,gJAAmF;;;;;;IAAxC,AAA5B,8CAA4B,wEAAsC;;;;IAGjF,kCAAmE;IAAvB,wRAAS,sBAAY,KAAC;IAAC,YAAkD;IAAA,iBAAS;;;;IAA3D,cAAkD;IAAlD,4FAAkD;;;IALvH,AADF,+BAAyH,cACtF;IAAA,YAAmB;IAAA,iBAAM;IAC1D,oKAEC;IACD,4IAA8C;IAGhD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,+HAA8C;;YA9D9C,cA2DC;YA3DD,2CA2DC;;;iFAmJQ,6BAA6B;cApNzC,SAAS;6BACI,KAAK,YACP,2BAA2B,iBACtB,iBAAiB,CAAC,IAAI,YAC3B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyET;;kBA6IA,KAAK;;kBAWL,KAAK;;kBAUL,KAAK;;kBAGL,KAAK;;kBAIL,KAAK;;kBAWL,MAAM;;kBAEN,MAAM;;kBAEN,MAAM;;kBAEN,MAAM;;kFAnDI,6BAA6B;AA+M1C,+DAA+D;AAC/D,MAAM,UAAU,wBAAwB;IACtC,KAAK,6BAA6B,CAAC;AACrC,CAAC","sourcesContent":["import {\n Component,\n Input,\n Output,\n EventEmitter,\n ChangeDetectorRef,\n OnInit,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport { EntityFieldTSType, EntityInfo } from '@memberjunction/core';\nimport { GetMonthYearLabel } from '@memberjunction/ng-ui-components';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport { IViewRenderer, ViewDataRequest } from '../view-type.contracts';\nimport {\n BuildCalendarItems,\n CALENDAR_WEEK_DAYS,\n CalendarItem,\n CalendarMode,\n CalendarViewConfig,\n DayKey,\n GetMonthWeeks,\n GetVisibleDays,\n GroupItemsByDay,\n ResolveCalendarFields,\n ShiftAnchor,\n StartOfDay,\n} from './calendar-placement';\n\n/**\n * CalendarViewRendererComponent\n * -----------------------------\n * The Calendar **view type** ({@link IViewRenderer}): records placed on a day, week (Monday\n * first) or month layout by a start field and an optional end field named in the view's\n * {@link CalendarViewConfig}. Placement is the pure logic in `calendar-placement.ts`; this\n * component only holds the anchor date and binds the result.\n *\n * Like Map, it asks the host for the full record set (`dataRequest({ loadAll: true })`), so it\n * sees up to the host's load-all cap rather than one page. Clicking a record emits\n * `recordSelected` and double-clicking emits `recordOpened`, as the Cards renderer does. A gear\n * button opens the {@link CalendarViewPropSheetComponent} inline, because no host mounts a\n * descriptor's prop sheet yet.\n *\n * Inputs/outputs use the camelCase names the {@link IViewRenderer} contract mandates.\n */\n@Component({\n standalone: false,\n selector: 'mj-calendar-view-renderer',\n encapsulation: ViewEncapsulation.None,\n template: `\n <div class=\"calendar-view\">\n @if (HasDateFields) {\n <div class=\"calendar-view-chrome\">\n <button mjButton Variant=\"outline\" Size=\"sm\" type=\"button\" title=\"Previous\" AriaLabel=\"Previous\" (click)=\"Previous()\">\n <i class=\"fa-solid fa-chevron-left\" aria-hidden=\"true\"></i>\n </button>\n <button mjButton Variant=\"outline\" Size=\"sm\" type=\"button\" (click)=\"Today()\">Today</button>\n <button mjButton Variant=\"outline\" Size=\"sm\" type=\"button\" title=\"Next\" AriaLabel=\"Next\" (click)=\"Next()\">\n <i class=\"fa-solid fa-chevron-right\" aria-hidden=\"true\"></i>\n </button>\n <span class=\"calendar-view-title\">{{ Title }}</span>\n <mj-view-toggle [Options]=\"ModeOptions\" [ActiveKey]=\"Mode\" (KeyChange)=\"SetMode($event)\"></mj-view-toggle>\n <button mjButton Variant=\"icon\" Size=\"sm\" type=\"button\" title=\"Calendar settings\" AriaLabel=\"Calendar settings\" [Toggleable]=\"true\" [(Selected)]=\"ShowSettings\">\n <i class=\"fa-solid fa-gear\" aria-hidden=\"true\"></i>\n </button>\n </div>\n\n @if (ShowSettings) {\n <mj-calendar-view-prop-sheet [entity]=\"entity\" [config]=\"config\" (configChange)=\"OnSettingsChange($event)\"></mj-calendar-view-prop-sheet>\n }\n\n @if (Mode === 'month') {\n <div class=\"calendar-month\">\n @for (label of WeekDayLabels; track label) {\n <div class=\"calendar-weekday\">{{ label }}</div>\n }\n @for (week of MonthWeeks; track $index) {\n @for (day of week; track day.getTime()) {\n <div class=\"calendar-cell\" [class.is-other-month]=\"day.getMonth() !== Anchor.getMonth()\" [class.is-today]=\"IsToday(day)\">\n <div class=\"calendar-day-number\">{{ day.getDate() }}</div>\n @for (item of ItemsFor(day).slice(0, MaxItemsPerCell); track $index) {\n <ng-container *ngTemplateOutlet=\"itemChip; context: { $implicit: item, day: day }\"></ng-container>\n }\n @if (ItemsFor(day).length > MaxItemsPerCell) {\n <button type=\"button\" class=\"calendar-more\" (click)=\"GoToDay(day)\">+{{ ItemsFor(day).length - MaxItemsPerCell }} more</button>\n }\n </div>\n }\n }\n </div>\n } @else {\n <div class=\"calendar-columns\">\n @for (day of VisibleDays; track day.getTime()) {\n <div class=\"calendar-column\" [class.is-today]=\"IsToday(day)\">\n <div class=\"calendar-column-header\">{{ DayHeader(day) }}</div>\n @for (item of ItemsFor(day); track $index) {\n <ng-container *ngTemplateOutlet=\"itemChip; context: { $implicit: item, day: day }\"></ng-container>\n } @empty {\n <div class=\"calendar-column-empty\">No records</div>\n }\n </div>\n }\n </div>\n }\n } @else {\n <mj-empty-state\n class=\"calendar-view-empty-fill\"\n Variant=\"warning\"\n Icon=\"fa-solid fa-calendar-xmark\"\n Title=\"This entity has no date fields to place on a calendar.\" />\n }\n </div>\n\n <ng-template #itemChip let-item let-day=\"day\">\n <button type=\"button\" class=\"calendar-item\" [class.is-continued]=\"!IsFirstDay(item, day)\"\n [title]=\"ItemLabel(item)\" (click)=\"OnItemClick(item)\" (dblclick)=\"OnItemOpen(item)\">\n @if (ItemTime(item, day); as time) {\n <span class=\"calendar-item-time\">{{ time }}</span>\n }\n <span class=\"calendar-item-label\">{{ ItemLabel(item) }}</span>\n </button>\n </ng-template>\n `,\n styles: [\n `\n /* The host forces display:block on the renderer element, so the flex column lives on a wrapper. */\n .calendar-view {\n display: flex;\n flex-direction: column;\n height: 100%;\n min-height: 0;\n }\n .calendar-view-chrome {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 8px 12px;\n flex: 0 0 auto;\n }\n .calendar-view-title {\n flex: 1 1 auto;\n font-size: 15px;\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n .calendar-month {\n flex: 1 1 auto;\n min-height: 0;\n overflow: auto;\n display: grid;\n grid-template-columns: repeat(7, minmax(0, 1fr));\n grid-template-rows: auto; /* the weekday header row */\n grid-auto-rows: minmax(96px, auto);\n border-top: 1px solid var(--mj-border-default);\n border-left: 1px solid var(--mj-border-default);\n }\n .calendar-weekday {\n padding: 4px 8px;\n font-size: 12px;\n font-weight: 600;\n color: var(--mj-text-muted);\n background: var(--mj-bg-surface-card);\n border-right: 1px solid var(--mj-border-default);\n border-bottom: 1px solid var(--mj-border-default);\n }\n .calendar-cell,\n .calendar-column {\n display: flex;\n flex-direction: column;\n gap: 2px;\n padding: 4px;\n min-width: 0;\n background: var(--mj-bg-surface);\n border-right: 1px solid var(--mj-border-default);\n border-bottom: 1px solid var(--mj-border-default);\n }\n .calendar-cell.is-other-month {\n background: var(--mj-bg-surface-sunken);\n }\n .calendar-cell.is-other-month .calendar-day-number {\n color: var(--mj-text-disabled);\n }\n .calendar-day-number {\n font-size: 12px;\n color: var(--mj-text-secondary);\n }\n .is-today .calendar-day-number,\n .is-today .calendar-column-header {\n color: var(--mj-brand-primary);\n font-weight: 700;\n }\n .calendar-columns {\n flex: 1 1 auto;\n min-height: 0;\n overflow: auto;\n display: grid;\n grid-auto-flow: column;\n grid-auto-columns: minmax(0, 1fr);\n border-top: 1px solid var(--mj-border-default);\n border-left: 1px solid var(--mj-border-default);\n }\n .calendar-column-header {\n padding: 4px;\n font-size: 13px;\n font-weight: 600;\n color: var(--mj-text-secondary);\n }\n .calendar-column-empty {\n padding: 4px;\n font-size: 12px;\n color: var(--mj-text-disabled);\n }\n .calendar-item {\n display: flex;\n gap: 6px;\n align-items: baseline;\n width: 100%;\n padding: 2px 6px;\n border: none;\n border-left: 3px solid var(--mj-brand-primary);\n border-radius: 4px;\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n color: var(--mj-text-primary);\n font-size: 12px;\n text-align: left;\n cursor: pointer;\n }\n .calendar-item:hover {\n background: color-mix(in srgb, var(--mj-brand-primary) 18%, var(--mj-bg-surface));\n }\n .calendar-item.is-continued {\n border-left-style: dashed;\n }\n .calendar-item-time {\n flex: 0 0 auto;\n color: var(--mj-text-muted);\n }\n .calendar-item-label {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .calendar-more {\n border: none;\n background: transparent;\n color: var(--mj-text-link);\n font-size: 12px;\n text-align: left;\n cursor: pointer;\n padding: 0 6px;\n }\n .calendar-view-empty-fill {\n flex: 1 1 auto;\n }\n `,\n ],\n})\nexport class CalendarViewRendererComponent\n extends BaseAngularComponent\n implements IViewRenderer<CalendarViewConfig>, OnInit\n{\n private _entity: EntityInfo | null = null;\n /** The entity whose records are placed. */\n @Input()\n set entity(value: EntityInfo | null) {\n this._entity = value;\n this.rebuild();\n }\n get entity(): EntityInfo | null {\n return this._entity;\n }\n\n private _records: Record<string, unknown>[] = [];\n /** The records to place (loaded/filtered by the host). */\n @Input()\n set records(value: Record<string, unknown>[]) {\n this._records = value ?? [];\n this.rebuild();\n }\n get records(): Record<string, unknown>[] {\n return this._records;\n }\n\n /** Primary-key string of the selected record. Accepted for contract uniformity. */\n @Input() selectedRecordId: string | null = null;\n\n /** Active filter text. Accepted for contract uniformity; the host pre-filters `records`. */\n @Input() filterText: string | null = null;\n\n private _config: CalendarViewConfig = {};\n /** The persisted view config: start/end fields and the layout the view opens in. */\n @Input()\n set config(value: CalendarViewConfig) {\n this._config = value ?? {};\n this.Mode = this._config.mode ?? 'month';\n this.rebuild();\n }\n get config(): CalendarViewConfig {\n return this._config;\n }\n\n /** Emitted on a record click with the raw record. */\n @Output() recordSelected = new EventEmitter<unknown>();\n /** Emitted on a record double-click with the raw record (a navigation request). */\n @Output() recordOpened = new EventEmitter<unknown>();\n /** Emitted with the full config when the layout or the settings change. */\n @Output() configChanged = new EventEmitter<CalendarViewConfig>();\n /** Asks the host for the full record set on init. */\n @Output() dataRequest = new EventEmitter<ViewDataRequest>();\n\n /** The current layout. */\n public Mode: CalendarMode = 'month';\n /** A date inside the period on screen. */\n public Anchor: Date = StartOfDay(new Date());\n /** Whether the inline settings sheet is open. */\n public ShowSettings = false;\n /** Whether the entity has any date field. */\n public HasDateFields = false;\n /** Month cells shown before \"+N more\". */\n public readonly MaxItemsPerCell = 3;\n /** Monday-first weekday labels. */\n public readonly WeekDayLabels = CALENDAR_WEEK_DAYS;\n /** The layout switch options. */\n public readonly ModeOptions = [\n { key: 'day', label: 'Day' },\n { key: 'week', label: 'Week' },\n { key: 'month', label: 'Month' },\n ];\n /** The month grid's weeks. */\n public MonthWeeks: Date[][] = [];\n /** The days of the day/week layout. */\n public VisibleDays: Date[] = [];\n\n private items: CalendarItem[] = [];\n private itemsByDay = new Map<number, CalendarItem[]>();\n private titleFieldName: string | null = null;\n private cdr = inject(ChangeDetectorRef);\n\n ngOnInit(): void {\n this.dataRequest.emit({ loadAll: true });\n }\n\n /** The header label for the period on screen. */\n get Title(): string {\n if (this.Mode === 'month') {\n return GetMonthYearLabel(this.Anchor);\n }\n const options: Intl.DateTimeFormatOptions = { month: 'short', day: 'numeric', year: 'numeric' };\n if (this.Mode === 'day') {\n return this.Anchor.toLocaleDateString(undefined, { weekday: 'long', ...options });\n }\n const days = this.VisibleDays;\n return `${days[0].toLocaleDateString(undefined, options)} – ${days[6].toLocaleDateString(undefined, options)}`;\n }\n\n Previous(): void {\n this.moveTo(ShiftAnchor(this.Mode, this.Anchor, -1));\n }\n\n Next(): void {\n this.moveTo(ShiftAnchor(this.Mode, this.Anchor, 1));\n }\n\n Today(): void {\n this.moveTo(StartOfDay(new Date()));\n }\n\n /** Switch layout (a `ModeOptions` key) and persist it as the view's mode. */\n SetMode(key: string): void {\n const mode: CalendarMode = key === 'day' || key === 'week' ? key : 'month';\n this.Mode = mode;\n this._config = { ...this._config, mode };\n this.configChanged.emit(this._config);\n this.layout();\n }\n\n /** Open the day layout on `day` (from a month cell's \"+N more\"). */\n GoToDay(day: Date): void {\n this.Anchor = day;\n this.SetMode('day');\n }\n\n /** Apply and persist a change from the settings sheet. */\n OnSettingsChange(config: CalendarViewConfig): void {\n this.config = config;\n this.configChanged.emit(this._config);\n }\n\n ItemsFor(day: Date): CalendarItem[] {\n return this.itemsByDay.get(DayKey(day)) ?? [];\n }\n\n IsToday(day: Date): boolean {\n return DayKey(day) === DayKey(new Date());\n }\n\n IsFirstDay(item: CalendarItem, day: Date): boolean {\n return DayKey(item.FirstDay) === DayKey(day);\n }\n\n /** The record's display title. */\n ItemLabel(item: CalendarItem): string {\n const value = this.titleFieldName ? item.Record[this.titleFieldName] : null;\n return value != null && value !== '' ? String(value) : '(untitled)';\n }\n\n /** The start time, on the item's first day only; empty for a date-only start. */\n ItemTime(item: CalendarItem, day: Date): string {\n if (item.AllDay || !this.IsFirstDay(item, day)) {\n return '';\n }\n return item.Start.toLocaleTimeString(undefined, { hour: 'numeric', minute: '2-digit' });\n }\n\n DayHeader(day: Date): string {\n return day.toLocaleDateString(undefined, { weekday: 'short', month: 'short', day: 'numeric' });\n }\n\n OnItemClick(item: CalendarItem): void {\n this.recordSelected.emit(item.Record);\n }\n\n OnItemOpen(item: CalendarItem): void {\n this.recordOpened.emit(item.Record);\n }\n\n private moveTo(anchor: Date): void {\n this.Anchor = anchor;\n this.layout();\n }\n\n /** Re-resolve fields and re-place every record (entity, records or config changed). */\n private rebuild(): void {\n const fields = ResolveCalendarFields(this._entity, this._config);\n this.HasDateFields = fields.Start != null;\n this.titleFieldName = this.findTitleField();\n this.items = BuildCalendarItems(this._records, fields.Start, fields.End);\n this.layout();\n }\n\n /** Recompute the days on screen and the items on each. */\n private layout(): void {\n this.MonthWeeks = this.Mode === 'month' ? GetMonthWeeks(this.Anchor) : [];\n this.VisibleDays = GetVisibleDays(this.Mode, this.Anchor);\n this.itemsByDay = GroupItemsByDay(this.items, this.VisibleDays);\n this.cdr.markForCheck();\n }\n\n /** The entity's name field, else its first visible text field. */\n private findTitleField(): string | null {\n const entity = this._entity;\n if (!entity) {\n return null;\n }\n if (entity.NameField) {\n return entity.NameField.Name;\n }\n const text = entity.Fields\n .filter((f) => f.TSType === EntityFieldTSType.String && f.DefaultInView && !f.Name.startsWith('__mj_'))\n .sort((a, b) => a.Sequence - b.Sequence);\n return text[0]?.Name ?? null;\n }\n}\n\n/** Tree-shaking guard for the dynamically mounted renderer. */\nexport function LoadCalendarViewRenderer(): void {\n void CalendarViewRendererComponent;\n}\n"]}
|
|
@@ -139,6 +139,8 @@ export declare class GridViewRendererComponent extends BaseAngularComponent impl
|
|
|
139
139
|
pageSize?: number;
|
|
140
140
|
/** Whether the host is currently (re)loading the record set. Accepted per contract; unused here. */
|
|
141
141
|
isLoading?: boolean;
|
|
142
|
+
/** Active alternate base view semantic name pushed by the host, forwarded into `EffectiveParams`. */
|
|
143
|
+
alternateBaseView: string | null;
|
|
142
144
|
/** Emitted when a row is single-clicked — payload is the raw record object (host builds the key). */
|
|
143
145
|
recordSelected: EventEmitter<unknown>;
|
|
144
146
|
/** Emitted when a row is double-clicked — payload is the raw record object (host builds the key). */
|
|
@@ -454,7 +456,7 @@ export declare class GridViewRendererComponent extends BaseAngularComponent impl
|
|
|
454
456
|
*/
|
|
455
457
|
private resolveEntityNameById;
|
|
456
458
|
static ɵfac: i0.ɵɵFactoryDeclaration<GridViewRendererComponent, never>;
|
|
457
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<GridViewRendererComponent, "mj-grid-view-renderer", never, { "entity": { "alias": "entity"; "required": false; }; "records": { "alias": "records"; "required": false; }; "ExportDataProvider": { "alias": "ExportDataProvider"; "required": false; }; "exportDataProvider": { "alias": "exportDataProvider"; "required": false; }; "selectedRecordId": { "alias": "selectedRecordId"; "required": false; }; "filterText": { "alias": "filterText"; "required": false; }; "config": { "alias": "config"; "required": false; }; "AutoLoadEntityActions": { "alias": "AutoLoadEntityActions"; "required": false; }; "totalRecordCount": { "alias": "totalRecordCount"; "required": false; }; "page": { "alias": "page"; "required": false; }; "pageSize": { "alias": "pageSize"; "required": false; }; "isLoading": { "alias": "isLoading"; "required": false; }; }, { "recordSelected": "recordSelected"; "recordOpened": "recordOpened"; "configChanged": "configChanged"; "dataRequest": "dataRequest"; "configureRequested": "configureRequested"; "openRelatedRecordRequested": "openRelatedRecordRequested"; "createRecordRequested": "createRecordRequested"; }, never, never, false, never>;
|
|
459
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<GridViewRendererComponent, "mj-grid-view-renderer", never, { "entity": { "alias": "entity"; "required": false; }; "records": { "alias": "records"; "required": false; }; "ExportDataProvider": { "alias": "ExportDataProvider"; "required": false; }; "exportDataProvider": { "alias": "exportDataProvider"; "required": false; }; "selectedRecordId": { "alias": "selectedRecordId"; "required": false; }; "filterText": { "alias": "filterText"; "required": false; }; "config": { "alias": "config"; "required": false; }; "AutoLoadEntityActions": { "alias": "AutoLoadEntityActions"; "required": false; }; "totalRecordCount": { "alias": "totalRecordCount"; "required": false; }; "page": { "alias": "page"; "required": false; }; "pageSize": { "alias": "pageSize"; "required": false; }; "isLoading": { "alias": "isLoading"; "required": false; }; "alternateBaseView": { "alias": "alternateBaseView"; "required": false; }; }, { "recordSelected": "recordSelected"; "recordOpened": "recordOpened"; "configChanged": "configChanged"; "dataRequest": "dataRequest"; "configureRequested": "configureRequested"; "openRelatedRecordRequested": "openRelatedRecordRequested"; "createRecordRequested": "createRecordRequested"; }, never, never, false, never>;
|
|
458
460
|
}
|
|
459
461
|
/**
|
|
460
462
|
* Tree-shaking guard. Force-references this renderer so bundlers (ESBuild/Vite) don't drop the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid-view-renderer.component.d.ts","sourceRoot":"","sources":["../../../../src/lib/view-types/renderers/grid-view-renderer.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,YAAY,EAAmD,SAAS,EAAU,MAAM,eAAe,CAAC;AAC3I,OAAO,EAAE,UAAU,EAAE,aAAa,EAAY,YAAY,EAA+B,MAAM,sBAAsB,CAAC;AACtH,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAC7D,OAAO,EAEL,KAAK,eAAe,EACpB,KAAK,WAA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AAE,SAAS;IACrH,0FAA0F;IAC1F,OAAO,CAAC,GAAG,CAA6B;IAIxC,qGAAqG;IAC5F,MAAM,EAAE,UAAU,GAAG,IAAI,CAAQ;IAE1C,gGAAgG;IACvF,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,CAAM;IAEjD;;;OAGG;IACM,kBAAkB,EAAE,CAAC,MAAM,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,CAAC,CAAC,GAAG,IAAI,CAAQ;IAEtF,kDAAkD;IAClD,IAAa,kBAAkB,CAAC,KAAK,EAAE,CAAC,MAAM,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,CAAC,CAAC,GAAG,IAAI,EAEvF;IACD,kDAAkD;IAClD,IAAI,kBAAkB,IAAI,CAAC,MAAM,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,CAAC,CAAC,GAAG,IAAI,CAE1E;IAED,mEAAmE;IAC1D,gBAAgB,EAAE,MAAM,GAAG,IAAI,CAAQ;IAEhD,4EAA4E;IACnE,UAAU,EAAE,MAAM,GAAG,IAAI,CAAQ;IAE1C,oGAAoG;IAC3F,MAAM,EAAE,cAAc,CAAM;IAErC;;;;OAIG;IACM,qBAAqB,UAAQ;IAItC,6FAA6F;IACpF,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAEnC,kGAAkG;IACzF,IAAI,CAAC,EAAE,MAAM,CAAC;IAEvB,+EAA+E;IACtE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAE3B,oGAAoG;IAC3F,SAAS,CAAC,EAAE,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"grid-view-renderer.component.d.ts","sourceRoot":"","sources":["../../../../src/lib/view-types/renderers/grid-view-renderer.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,YAAY,EAAmD,SAAS,EAAU,MAAM,eAAe,CAAC;AAC3I,OAAO,EAAE,UAAU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