@wix/himalaya-cli 0.899.0 → 0.900.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.
|
@@ -35,7 +35,11 @@ export interface WixEventLocation {
|
|
|
35
35
|
export interface WixEvent {
|
|
36
36
|
id: string;
|
|
37
37
|
title?: string;
|
|
38
|
-
/**
|
|
38
|
+
/** Normally one of `WixEventStatus`, but deliberately NOT narrowed to it: `decodeEvent`
|
|
39
|
+
* fills this from the server's `status` and passes a value it does not recognise straight
|
|
40
|
+
* through, because dropping or rewriting one would lose a real event. A union here would
|
|
41
|
+
* be a claim this SDK cannot enforce. Compare against `WixEventStatus` when you need the
|
|
42
|
+
* stored set; the narrowing that IS enforced is on the `statuses` filter below. */
|
|
39
43
|
eventStatus?: string;
|
|
40
44
|
/** EventType: RSVP | TICKETS | EXTERNAL | NO_REGISTRATION */
|
|
41
45
|
eventType?: string;
|
|
@@ -55,6 +59,23 @@ export interface WixGetEventResponse {
|
|
|
55
59
|
}
|
|
56
60
|
export interface WixDeleteEventResponse {
|
|
57
61
|
}
|
|
62
|
+
/** The stored event statuses — what this SDK knows the server stores, and so the only values
|
|
63
|
+
* the `statuses` filter can match. The one source for both the runtime guard and the type
|
|
64
|
+
* below, so a status added here cannot be missed by either.
|
|
65
|
+
*
|
|
66
|
+
* Exported because `WixEventStatus` is declared in terms of it: the generated SDK reference
|
|
67
|
+
* ships each exported declaration verbatim, and a reader copying a type that names a symbol
|
|
68
|
+
* they cannot see gets TS2304.
|
|
69
|
+
*
|
|
70
|
+
* Frozen because `as const` is erased: it makes the TYPE readonly and leaves an ordinary
|
|
71
|
+
* mutable array behind. Unexported that was academic; exported it is not — module bindings
|
|
72
|
+
* share one array object, so a `push` from any untyped caller would edit the very set
|
|
73
|
+
* `queryEvents` validates against, for every caller in that realm. The freeze makes the
|
|
74
|
+
* runtime keep the promise the type already makes. */
|
|
75
|
+
export declare const EVENT_STATUSES: readonly ["SCHEDULED", "STARTED", "ENDED", "CANCELED", "DRAFT"];
|
|
76
|
+
/** One of the stored event statuses. `WixQueryEventsOptions.statuses` takes these, so a value
|
|
77
|
+
* outside the set is refused while the call is being written rather than when it is made. */
|
|
78
|
+
export type WixEventStatus = (typeof EVENT_STATUSES)[number];
|
|
58
79
|
export interface WixQueryEventsOptions {
|
|
59
80
|
/** Server-side WQL filter/sort for Events v3. Unlike the legacy convenience
|
|
60
81
|
* options below, these criteria are applied before paging. */
|
|
@@ -73,13 +94,13 @@ export interface WixQueryEventsOptions {
|
|
|
73
94
|
limit?: number;
|
|
74
95
|
/** Page offset. */
|
|
75
96
|
offset?: number;
|
|
76
|
-
/** Status filter (e.g. `["SCHEDULED"]`). Every entry must be
|
|
77
|
-
*
|
|
78
|
-
*
|
|
97
|
+
/** Status filter (e.g. `["SCHEDULED"]`). Every entry must be a `WixEventStatus`; anything
|
|
98
|
+
* else is refused rather than quietly matching nothing — by the compiler for a typed caller,
|
|
99
|
+
* and at runtime for one that is not. Omitted → all statuses returned.
|
|
79
100
|
* There is no stored "upcoming" status; select future events by their start date.
|
|
80
|
-
* For a value the server accepts that
|
|
81
|
-
* passed through to the server unchanged. */
|
|
82
|
-
statuses?:
|
|
101
|
+
* For a value the server accepts that `WixEventStatus` does not name, use `query.filter`,
|
|
102
|
+
* which is passed through to the server unchanged. */
|
|
103
|
+
statuses?: WixEventStatus[];
|
|
83
104
|
/** Sort property (the Owner list orders by "start"). */
|
|
84
105
|
order?: string;
|
|
85
106
|
/** Free-text title search. */
|
|
@@ -242,7 +242,7 @@ function wixCall(method, path, body) {
|
|
|
242
242
|
return globalThis.himalaya.wixApi.call(method, path, body);
|
|
243
243
|
}
|
|
244
244
|
var BASE = "https://manage.wix.com/_api/wix-one-events-server/events-in-clubs";
|
|
245
|
-
var EVENT_STATUSES = ["SCHEDULED", "STARTED", "ENDED", "CANCELED", "DRAFT"];
|
|
245
|
+
var EVENT_STATUSES = Object.freeze(["SCHEDULED", "STARTED", "ENDED", "CANCELED", "DRAFT"]);
|
|
246
246
|
function decodeEvent(raw) {
|
|
247
247
|
if (raw == null) return raw;
|
|
248
248
|
const r = raw;
|
|
@@ -365,6 +365,7 @@ function getEventsOrder(eventId, orderNumber) {
|
|
|
365
365
|
);
|
|
366
366
|
}
|
|
367
367
|
export {
|
|
368
|
+
EVENT_STATUSES,
|
|
368
369
|
cancelTicketReservation,
|
|
369
370
|
checkoutReservation,
|
|
370
371
|
createEvent,
|
|
@@ -14313,7 +14313,7 @@
|
|
|
14313
14313
|
"name": "WixEvent",
|
|
14314
14314
|
"kind": "interface",
|
|
14315
14315
|
"jsdoc": "",
|
|
14316
|
-
"decl": "export interface WixEvent {\n id: string;\n title?: string;\n /**
|
|
14316
|
+
"decl": "export interface WixEvent {\n id: string;\n title?: string;\n /** Normally one of `WixEventStatus`, but deliberately NOT narrowed to it: `decodeEvent`\n * fills this from the server's `status` and passes a value it does not recognise straight\n * through, because dropping or rewriting one would lose a real event. A union here would\n * be a claim this SDK cannot enforce. Compare against `WixEventStatus` when you need the\n * stored set; the narrowing that IS enforced is on the `statuses` filter below. */\n eventStatus?: string;\n /** EventType: RSVP | TICKETS | EXTERNAL | NO_REGISTRATION */\n eventType?: string;\n scheduling?: WixEventScheduling;\n location?: WixEventLocation;\n mainImage?: WixEventImage;\n slug?: string;\n about?: string;\n description?: string;\n}"
|
|
14317
14317
|
},
|
|
14318
14318
|
{
|
|
14319
14319
|
"name": "WixGetEventListResponse",
|
|
@@ -14333,11 +14333,23 @@
|
|
|
14333
14333
|
"jsdoc": "",
|
|
14334
14334
|
"decl": "export interface WixDeleteEventResponse {\n // Empty object on success.\n}"
|
|
14335
14335
|
},
|
|
14336
|
+
{
|
|
14337
|
+
"name": "EVENT_STATUSES",
|
|
14338
|
+
"kind": "const",
|
|
14339
|
+
"jsdoc": "/** The stored event statuses — what this SDK knows the server stores, and so the only values\n * the `statuses` filter can match. The one source for both the runtime guard and the type\n * below, so a status added here cannot be missed by either.\n *\n * Exported because `WixEventStatus` is declared in terms of it: the generated SDK reference\n * ships each exported declaration verbatim, and a reader copying a type that names a symbol\n * they cannot see gets TS2304.\n *\n * Frozen because `as const` is erased: it makes the TYPE readonly and leaves an ordinary\n * mutable array behind. Unexported that was academic; exported it is not — module bindings\n * share one array object, so a `push` from any untyped caller would edit the very set\n * `queryEvents` validates against, for every caller in that realm. The freeze makes the\n * runtime keep the promise the type already makes. */",
|
|
14340
|
+
"decl": "export const EVENT_STATUSES = Object.freeze([\"SCHEDULED\", \"STARTED\", \"ENDED\", \"CANCELED\", \"DRAFT\"] as const);"
|
|
14341
|
+
},
|
|
14342
|
+
{
|
|
14343
|
+
"name": "WixEventStatus",
|
|
14344
|
+
"kind": "type",
|
|
14345
|
+
"jsdoc": "/** One of the stored event statuses. `WixQueryEventsOptions.statuses` takes these, so a value\n * outside the set is refused while the call is being written rather than when it is made. */",
|
|
14346
|
+
"decl": "export type WixEventStatus = (typeof EVENT_STATUSES)[number];"
|
|
14347
|
+
},
|
|
14336
14348
|
{
|
|
14337
14349
|
"name": "WixQueryEventsOptions",
|
|
14338
14350
|
"kind": "interface",
|
|
14339
14351
|
"jsdoc": "",
|
|
14340
|
-
"decl": "export interface WixQueryEventsOptions {\n /** Server-side WQL filter/sort for Events v3. Unlike the legacy convenience\n * options below, these criteria are applied before paging. */\n query?: { filter?: Record<string, unknown>; sort?: Array<{ fieldName: string; order: \"ASC\" | \"DESC\" }>; paging?: { limit?: number; offset?: number } };\n /** Page size. */\n limit?: number;\n /** Page offset. */\n offset?: number;\n /** Status filter (e.g. `[\"SCHEDULED\"]`). Every entry must be
|
|
14352
|
+
"decl": "export interface WixQueryEventsOptions {\n /** Server-side WQL filter/sort for Events v3. Unlike the legacy convenience\n * options below, these criteria are applied before paging. */\n query?: { filter?: Record<string, unknown>; sort?: Array<{ fieldName: string; order: \"ASC\" | \"DESC\" }>; paging?: { limit?: number; offset?: number } };\n /** Page size. */\n limit?: number;\n /** Page offset. */\n offset?: number;\n /** Status filter (e.g. `[\"SCHEDULED\"]`). Every entry must be a `WixEventStatus`; anything\n * else is refused rather than quietly matching nothing — by the compiler for a typed caller,\n * and at runtime for one that is not. Omitted → all statuses returned.\n * There is no stored \"upcoming\" status; select future events by their start date.\n * For a value the server accepts that `WixEventStatus` does not name, use `query.filter`,\n * which is passed through to the server unchanged. */\n statuses?: WixEventStatus[];\n /** Sort property (the Owner list orders by \"start\"). */\n order?: string;\n /** Free-text title search. */\n title?: string;\n /** Include draft events in the result. */\n includeDrafts?: boolean;\n}"
|
|
14341
14353
|
},
|
|
14342
14354
|
{
|
|
14343
14355
|
"name": "decodeEvent",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/himalaya-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.900.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "himi — the Himalaya authoring CLI. Build a Tier-5 content package on your own machine, push it to the production serve as a draft, preview it on web + Himi Player, and read worker logs back — the remote dev loop. Wraps @himalaya/serve-cli for transport.",
|
|
6
6
|
"keywords": [
|
|
@@ -64,5 +64,5 @@
|
|
|
64
64
|
"artifactId": "himalaya-cli"
|
|
65
65
|
}
|
|
66
66
|
},
|
|
67
|
-
"falconPackageHash": "
|
|
67
|
+
"falconPackageHash": "da76e219579846bfb3438187f1efd8432fe18858acbbb9678699bd07"
|
|
68
68
|
}
|