@gomusdev/web-components 4.11.0 → 4.13.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/README.md +12 -0
- package/dist-js/gomus-webcomponents.iife.js +200 -26
- package/dist-js/gomus-webcomponents.js +200 -26
- package/dist-js/gomus-webcomponents.min.iife.js +35 -35
- package/dist-js/gomus-webcomponents.min.js +6122 -5996
- package/dist-js/src/components/ticketSelection/subcomponents/calendar/components/Calendar.spec.d.ts +1 -0
- package/dist-js/src/components/ticketSelection/subcomponents/calendar/lib/calendar.spec.d.ts +1 -0
- package/dist-js/src/components/ticketSelection/subcomponents/calendar/lib/calendar.svelte.d.ts +28 -2
- package/dist-js/src/lib/stores/shop.svelte.d.ts +1 -3
- package/dist-js/src/lib/stores/shop.translate.spec.d.ts +1 -0
- package/package.json +1 -1
package/dist-js/src/components/ticketSelection/subcomponents/calendar/components/Calendar.spec.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist-js/src/components/ticketSelection/subcomponents/calendar/lib/calendar.svelte.d.ts
CHANGED
|
@@ -6,12 +6,38 @@ export type CalendarDates = {
|
|
|
6
6
|
export type CalendarDatesDepthAvailabilityStatus = {
|
|
7
7
|
[key: string]: 'unavailable' | 'available' | 'fully_booked';
|
|
8
8
|
};
|
|
9
|
+
/**
|
|
10
|
+
* How a single date is offered, as seen by an integrator.
|
|
11
|
+
*
|
|
12
|
+
* - `available` — bookable, the date is clickable.
|
|
13
|
+
* - `sold_out` — on sale but no capacity left (the backend's `fully_booked`).
|
|
14
|
+
* - `unavailable` — nothing sellable that date, so it is blocked.
|
|
15
|
+
*/
|
|
16
|
+
export type GoAvailability = 'available' | 'sold_out' | 'unavailable';
|
|
17
|
+
/**
|
|
18
|
+
* Per-date override supplied by the integrator, either as
|
|
19
|
+
* `<go-calendar availability-override="fnName">` or as a property
|
|
20
|
+
* (`element.availabilityOverride = fn`). Returning `'pass_through'` defers to gomus. Called for
|
|
21
|
+
* every rendered cell on every render, so it must be synchronous and cheap.
|
|
22
|
+
*/
|
|
23
|
+
export type GoAvailabilityOverride = (date: string, defaultAvailability: GoAvailability) => GoAvailability | 'pass_through';
|
|
9
24
|
export declare class Calendar {
|
|
25
|
+
#private;
|
|
10
26
|
details: TicketSelectionDetails | undefined;
|
|
11
27
|
startAt: CalendarDate;
|
|
12
28
|
selected: CalendarDate | undefined;
|
|
29
|
+
/**
|
|
30
|
+
* Integrator override for each date's availability: either the callback itself
|
|
31
|
+
* (`element.availabilityOverride = fn`) or the name of a global one
|
|
32
|
+
* (`<go-calendar availability-override="fnName">`).
|
|
33
|
+
*/
|
|
34
|
+
availabilityOverride: string | GoAvailabilityOverride | undefined;
|
|
13
35
|
get endpoint(): 'tickets' | 'events' | null;
|
|
14
36
|
get dates(): CalendarDatesDepthAvailabilityStatus | undefined;
|
|
37
|
+
/** What gomus makes of a date on its own, ignoring any integrator override. */
|
|
38
|
+
defaultAvailability(date: DateValue): GoAvailability;
|
|
39
|
+
/** The gomus default, with the integrator's override given the last word. */
|
|
40
|
+
availability(date: DateValue): GoAvailability;
|
|
15
41
|
isDateDisabled(date: DateValue): boolean;
|
|
16
42
|
isDateUnavailable(date: DateValue): boolean;
|
|
17
43
|
get apiFilters(): (string | undefined)[] | undefined;
|
|
@@ -34,8 +60,8 @@ export declare class Calendar {
|
|
|
34
60
|
depth?: string;
|
|
35
61
|
} | undefined;
|
|
36
62
|
fetchPeriod(): CalendarDate[];
|
|
37
|
-
eventsDates():
|
|
38
|
-
ticketsDates():
|
|
63
|
+
eventsDates(): CalendarDatesDepthAvailabilityStatus;
|
|
64
|
+
ticketsDates(): CalendarDatesDepthAvailabilityStatus;
|
|
39
65
|
}
|
|
40
66
|
export declare class StaticCalendar extends Calendar {
|
|
41
67
|
#private;
|
|
@@ -331,9 +331,7 @@ export declare class Shop {
|
|
|
331
331
|
};
|
|
332
332
|
}[];
|
|
333
333
|
} | undefined;
|
|
334
|
-
get translations():
|
|
335
|
-
[key: string]: string;
|
|
336
|
-
};
|
|
334
|
+
get translations(): Record<string, string>;
|
|
337
335
|
get currency(): string;
|
|
338
336
|
t(key: string, values?: {
|
|
339
337
|
[key: string]: string | number;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|