@sprucelabs/spruce-calendar-components 25.4.0 → 25.4.2
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/build/.spruce/schemas/schemas.types.d.ts +931 -931
- package/build/calendar/Calendar.vc.d.ts +2 -28
- package/build/calendar/Calendar.vc.js +1 -2
- package/build/esm/.spruce/schemas/schemas.types.d.ts +931 -931
- package/build/esm/calendar/Calendar.vc.d.ts +2 -28
- package/build/esm/calendar/Calendar.vc.js +1 -2
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { SpruceSchemas, ViewControllerOptions, CalendarViewController as CoreCalendarViewController, ClickCalendarViewOptions,
|
|
1
|
+
import { SpruceSchemas, ViewControllerOptions, CalendarViewController as CoreCalendarViewController, ClickCalendarViewOptions, ClickEventOptions } from '@sprucelabs/heartwood-view-controllers';
|
|
2
2
|
import { RemoteEventStore } from '../stores/RemoteEventStore';
|
|
3
3
|
import { CalendarPerson, UpdateEvent } from '../types/calendar.types';
|
|
4
4
|
export default class CalendarViewController extends CoreCalendarViewController {
|
|
@@ -35,33 +35,7 @@ export default class CalendarViewController extends CoreCalendarViewController {
|
|
|
35
35
|
private persist;
|
|
36
36
|
waitForPendingSaves(): Promise<void>;
|
|
37
37
|
private _persist;
|
|
38
|
-
render():
|
|
39
|
-
controller?: import("@sprucelabs/heartwood-view-controllers").ViewController<SpruceSchemas.HeartwoodViewControllers.v2021_02_11.Calendar> | null | undefined;
|
|
40
|
-
people?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarPerson[] | null | undefined;
|
|
41
|
-
minTime?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarTime | null | undefined;
|
|
42
|
-
maxTime?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarTime | null | undefined;
|
|
43
|
-
startDate?: number | null | undefined;
|
|
44
|
-
defaultStartTime?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarTime | null | undefined;
|
|
45
|
-
defaultEndTime?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarTime | null | undefined;
|
|
46
|
-
events: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarEvent[];
|
|
47
|
-
selectedEvent?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarEvent | null | undefined;
|
|
48
|
-
selectedDates?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarSelectedDate[] | null | undefined;
|
|
49
|
-
timezoneOffsetMs?: number | null | undefined;
|
|
50
|
-
shouldEnableAnimations?: boolean | null | undefined;
|
|
51
|
-
view?: "month" | "day" | null | undefined;
|
|
52
|
-
shouldRenderHeader?: boolean | null | undefined;
|
|
53
|
-
onChangeStartDate?: ((date: number) => void | Promise<void>) | null | undefined;
|
|
54
|
-
onClickView?: ((options: ClickCalendarViewOptions) => void | Promise<void>) | null | undefined;
|
|
55
|
-
onLongPressViewDrop?: ((options: ClickCalendarViewOptions) => void | Promise<void>) | null | undefined;
|
|
56
|
-
onTapView?: ((options: ClickCalendarViewOptions) => void | Promise<void>) | null | undefined;
|
|
57
|
-
onClickEvent?: ((options: ClickEventOptions) => void | Promise<void>) | null | undefined;
|
|
58
|
-
onLongPressEvent?: ((options: ClickEventOptions) => void | Promise<void>) | null | undefined;
|
|
59
|
-
onDropEvent?: ((options: DropEventOptions) => boolean | void | Promise<boolean | void>) | null | undefined;
|
|
60
|
-
onDeselectEvent?: ((options: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarEvent) => void | Promise<void>) | null | undefined;
|
|
61
|
-
onSelectEvent?: ((options: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarEvent) => void | Promise<void>) | null | undefined;
|
|
62
|
-
onLongPressView?: (() => boolean | void) | null | undefined;
|
|
63
|
-
shifts?: SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarShift[] | null | undefined;
|
|
64
|
-
};
|
|
38
|
+
render(): Calendar;
|
|
65
39
|
}
|
|
66
40
|
type Calendar = SpruceSchemas.HeartwoodViewControllers.v2021_02_11.Calendar;
|
|
67
41
|
type Event = SpruceSchemas.HeartwoodViewControllers.v2021_02_11.CalendarEvent;
|
|
@@ -60,7 +60,6 @@ class CalendarViewController extends heartwood_view_controllers_1.CalendarViewCo
|
|
|
60
60
|
await this.removeDraftEvent(draft.id);
|
|
61
61
|
}
|
|
62
62
|
await this.addDraftEventFromClick(options);
|
|
63
|
-
this.getDevice().vibrate();
|
|
64
63
|
}
|
|
65
64
|
async handleDropEvent(options) {
|
|
66
65
|
var _a;
|
|
@@ -241,7 +240,7 @@ class CalendarViewController extends heartwood_view_controllers_1.CalendarViewCo
|
|
|
241
240
|
return event;
|
|
242
241
|
}
|
|
243
242
|
render() {
|
|
244
|
-
return Object.assign({}, super.render());
|
|
243
|
+
return Object.assign(Object.assign({}, super.render()), { onLongPressEvent: () => this.getDevice().vibrate(), onLongPressView: () => this.getDevice().vibrate() });
|
|
245
244
|
}
|
|
246
245
|
}
|
|
247
246
|
CalendarViewController.id = 'calendar';
|