@hubs101/js-api-skd-client 1.0.10587 → 1.0.10589
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/lib/api/event/types.d.ts +7 -22
- package/lib/api/event/types.js +53 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.js +12 -1
- package/package.json +1 -1
package/lib/api/event/types.d.ts
CHANGED
|
@@ -514,29 +514,14 @@ export declare const DEFAULT_MENU_TYPES: {
|
|
|
514
514
|
readonly EVENT_INFO: "event-info";
|
|
515
515
|
readonly CONTENT_HUB: "content-hub";
|
|
516
516
|
};
|
|
517
|
-
export declare const DEFAULT_MENU_ITEM: readonly [
|
|
518
|
-
|
|
519
|
-
"agenda",
|
|
520
|
-
"speaker",
|
|
521
|
-
"partner",
|
|
522
|
-
"who-&-why",
|
|
523
|
-
"event-info",
|
|
524
|
-
"content-hub"
|
|
525
|
-
];
|
|
526
|
-
export declare const MENU_ITEM_TYPE: readonly [
|
|
527
|
-
"home",
|
|
528
|
-
"agenda",
|
|
529
|
-
"speaker",
|
|
530
|
-
"partner",
|
|
531
|
-
"who-&-why",
|
|
532
|
-
"event-info",
|
|
533
|
-
"content-hub",
|
|
534
|
-
"internal",
|
|
535
|
-
"external",
|
|
536
|
-
"mailto"
|
|
537
|
-
];
|
|
517
|
+
export declare const DEFAULT_MENU_ITEM: readonly ["home", "agenda", "speaker", "partner", "who-&-why", "event-info", "content-hub"];
|
|
518
|
+
export declare const MENU_ITEM_TYPE: readonly ["home", "agenda", "speaker", "partner", "who-&-why", "event-info", "content-hub", "internal", "external", "mailto"];
|
|
538
519
|
export declare const MENU_ITEM_STYLING_LINK = 0;
|
|
539
520
|
export declare const MENU_ITEM_STYLING_BUTTON = 1;
|
|
521
|
+
export declare const MENU_ITEM_STYLING: {
|
|
522
|
+
readonly LINK: 0;
|
|
523
|
+
readonly BUTTON: 1;
|
|
524
|
+
};
|
|
540
525
|
export type MenuItem = {
|
|
541
526
|
label: string;
|
|
542
527
|
level: 0 | 1;
|
|
@@ -552,7 +537,7 @@ export type MenuItem = {
|
|
|
552
537
|
to?: string;
|
|
553
538
|
subject?: string;
|
|
554
539
|
body?: string;
|
|
555
|
-
|
|
540
|
+
element: (typeof MENU_ELEMENT_TYPE)[number];
|
|
556
541
|
};
|
|
557
542
|
export type EventServerResponse = {
|
|
558
543
|
id: string;
|
package/lib/api/event/types.js
CHANGED
|
@@ -1,12 +1,64 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.MENU_ITEM_STYLING_BUTTON = exports.MENU_ITEM_STYLING_LINK = exports.GROUP_STYLE = void 0;
|
|
3
|
+
exports.MENU_ITEM_STYLING = exports.MENU_ITEM_STYLING_BUTTON = exports.MENU_ITEM_STYLING_LINK = exports.MENU_ITEM_TYPE = exports.DEFAULT_MENU_ITEM = exports.DEFAULT_MENU_TYPES = exports.MENU_ELEMENT_TYPE = exports.MENU_ELEMENT_TYPES = exports.MENU_ITEM_TYPES = exports.GROUP_STYLE = void 0;
|
|
4
4
|
exports.GROUP_STYLE = [
|
|
5
5
|
{ "": "" }, // unassigned, top of the list
|
|
6
6
|
{ "1": "default" }, // BP
|
|
7
7
|
{ "2": "highlighted" }, // PP
|
|
8
8
|
{ "3": "big" }, // LP
|
|
9
9
|
];
|
|
10
|
+
// Update MENU_ITEM_TYPES to include MAILING
|
|
11
|
+
exports.MENU_ITEM_TYPES = {
|
|
12
|
+
INTERNAL: "internal",
|
|
13
|
+
EXTERNAL: "external",
|
|
14
|
+
MAILING: "mailto",
|
|
15
|
+
DOWNLOAD: "download",
|
|
16
|
+
APPLY_AS_SPEAKER: "apply-as-speaker",
|
|
17
|
+
BECOME_PARTNER: "become-partner",
|
|
18
|
+
};
|
|
19
|
+
// Add MENU_ELEMENT_TYPES (new constant)
|
|
20
|
+
exports.MENU_ELEMENT_TYPES = {
|
|
21
|
+
ITEM: "item",
|
|
22
|
+
BUTTON: "button",
|
|
23
|
+
};
|
|
24
|
+
exports.MENU_ELEMENT_TYPE = ["item", "button"];
|
|
25
|
+
// Keep existing DEFAULT_MENU_TYPES as is
|
|
26
|
+
exports.DEFAULT_MENU_TYPES = {
|
|
27
|
+
HOME: "home",
|
|
28
|
+
AGENDA: "agenda",
|
|
29
|
+
SPEAKER: "speaker",
|
|
30
|
+
PARTNER: "partner",
|
|
31
|
+
WHO_WHY: "who-&-why",
|
|
32
|
+
EVENT_INFO: "event-info",
|
|
33
|
+
CONTENT_HUB: "content-hub",
|
|
34
|
+
};
|
|
35
|
+
exports.DEFAULT_MENU_ITEM = [
|
|
36
|
+
"home",
|
|
37
|
+
"agenda",
|
|
38
|
+
"speaker",
|
|
39
|
+
"partner",
|
|
40
|
+
"who-&-why",
|
|
41
|
+
"event-info",
|
|
42
|
+
"content-hub",
|
|
43
|
+
];
|
|
44
|
+
// Update MENU_ITEM_TYPE to include "mailto"
|
|
45
|
+
exports.MENU_ITEM_TYPE = [
|
|
46
|
+
"home",
|
|
47
|
+
"agenda",
|
|
48
|
+
"speaker",
|
|
49
|
+
"partner",
|
|
50
|
+
"who-&-why",
|
|
51
|
+
"event-info",
|
|
52
|
+
"content-hub",
|
|
53
|
+
"internal",
|
|
54
|
+
"external",
|
|
55
|
+
"mailto",
|
|
56
|
+
];
|
|
10
57
|
// Define constants for styling: 0 for link, 1 for button
|
|
11
58
|
exports.MENU_ITEM_STYLING_LINK = 0;
|
|
12
59
|
exports.MENU_ITEM_STYLING_BUTTON = 1;
|
|
60
|
+
// Add MENU_ITEM_STYLING object for backwards compatibility
|
|
61
|
+
exports.MENU_ITEM_STYLING = {
|
|
62
|
+
LINK: exports.MENU_ITEM_STYLING_LINK,
|
|
63
|
+
BUTTON: exports.MENU_ITEM_STYLING_BUTTON,
|
|
64
|
+
};
|
package/lib/index.d.ts
CHANGED
|
@@ -5,3 +5,4 @@ export declare function EventAPIProvider(props: {
|
|
|
5
5
|
}): React.JSX.Element;
|
|
6
6
|
export declare const BaseAPI: BaseAPIType;
|
|
7
7
|
export declare const useAPIContext: () => import("./types/base").EventAPIType;
|
|
8
|
+
export { MENU_ITEM_TYPES, MENU_ELEMENT_TYPES, MENU_ELEMENT_TYPE, DEFAULT_MENU_TYPES, DEFAULT_MENU_ITEM, MENU_ITEM_TYPE, MENU_ITEM_STYLING_LINK, MENU_ITEM_STYLING_BUTTON, MENU_ITEM_STYLING, } from "./api/event/types";
|
package/lib/index.js
CHANGED
|
@@ -42,7 +42,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
42
42
|
});
|
|
43
43
|
};
|
|
44
44
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
45
|
-
exports.useAPIContext = exports.BaseAPI = void 0;
|
|
45
|
+
exports.MENU_ITEM_STYLING = exports.MENU_ITEM_STYLING_BUTTON = exports.MENU_ITEM_STYLING_LINK = exports.MENU_ITEM_TYPE = exports.DEFAULT_MENU_ITEM = exports.DEFAULT_MENU_TYPES = exports.MENU_ELEMENT_TYPE = exports.MENU_ELEMENT_TYPES = exports.MENU_ITEM_TYPES = exports.useAPIContext = exports.BaseAPI = void 0;
|
|
46
46
|
exports.EventAPIProvider = EventAPIProvider;
|
|
47
47
|
const EventAPIContext_1 = __importStar(require("./api/context/EventAPIContext"));
|
|
48
48
|
/* eslint-disable prefer-arrow/prefer-arrow-functions */
|
|
@@ -1687,3 +1687,14 @@ exports.BaseAPI = {
|
|
|
1687
1687
|
addPostNative: posts_1._addPostNative,
|
|
1688
1688
|
};
|
|
1689
1689
|
exports.useAPIContext = EventAPIContext_1.useAPIContext;
|
|
1690
|
+
// Export menu constants
|
|
1691
|
+
var types_1 = require("./api/event/types");
|
|
1692
|
+
Object.defineProperty(exports, "MENU_ITEM_TYPES", { enumerable: true, get: function () { return types_1.MENU_ITEM_TYPES; } });
|
|
1693
|
+
Object.defineProperty(exports, "MENU_ELEMENT_TYPES", { enumerable: true, get: function () { return types_1.MENU_ELEMENT_TYPES; } });
|
|
1694
|
+
Object.defineProperty(exports, "MENU_ELEMENT_TYPE", { enumerable: true, get: function () { return types_1.MENU_ELEMENT_TYPE; } });
|
|
1695
|
+
Object.defineProperty(exports, "DEFAULT_MENU_TYPES", { enumerable: true, get: function () { return types_1.DEFAULT_MENU_TYPES; } });
|
|
1696
|
+
Object.defineProperty(exports, "DEFAULT_MENU_ITEM", { enumerable: true, get: function () { return types_1.DEFAULT_MENU_ITEM; } });
|
|
1697
|
+
Object.defineProperty(exports, "MENU_ITEM_TYPE", { enumerable: true, get: function () { return types_1.MENU_ITEM_TYPE; } });
|
|
1698
|
+
Object.defineProperty(exports, "MENU_ITEM_STYLING_LINK", { enumerable: true, get: function () { return types_1.MENU_ITEM_STYLING_LINK; } });
|
|
1699
|
+
Object.defineProperty(exports, "MENU_ITEM_STYLING_BUTTON", { enumerable: true, get: function () { return types_1.MENU_ITEM_STYLING_BUTTON; } });
|
|
1700
|
+
Object.defineProperty(exports, "MENU_ITEM_STYLING", { enumerable: true, get: function () { return types_1.MENU_ITEM_STYLING; } });
|