@lwrjs/router 0.24.1 → 0.24.3
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/cjs/modules/lwr/contextProvider/contextProvider.cjs +25 -22
- package/build/cjs/modules/lwr/contextUtils/contextInfo.cjs +59 -8
- package/build/cjs/modules/lwr/contextUtils/contextUtils.cjs +57 -22
- package/build/cjs/modules/lwr/contextUtils/navigationApiStore.cjs +16 -19
- package/build/cjs/modules/lwr/currentPageReference/currentPageReference.cjs +18 -19
- package/build/cjs/modules/lwr/currentView/currentView.cjs +16 -19
- package/build/cjs/modules/lwr/domRouter/domRouter.cjs +175 -54
- package/build/cjs/modules/lwr/domRouterUtils/domRouterUtils.cjs +16 -19
- package/build/cjs/modules/lwr/domRouterUtils/historyUtils.cjs +17 -4
- package/build/cjs/modules/lwr/domRouterUtils/types.cjs +15 -2
- package/build/cjs/modules/lwr/domRouterUtils/uriUtils.cjs +16 -18
- package/build/cjs/modules/lwr/historyRouter/historyRouter.cjs +37 -20
- package/build/cjs/modules/lwr/navigation/constants.cjs +21 -8
- package/build/cjs/modules/lwr/navigation/navigation.cjs +20 -23
- package/build/cjs/modules/lwr/navigation/navigationApi.cjs +15 -18
- package/build/cjs/modules/lwr/navigation/navigationMixin.cjs +30 -29
- package/build/cjs/modules/lwr/navigationContext/navigationContext.cjs +15 -18
- package/build/cjs/modules/lwr/navigationMixinHacks/navigationMixinHacks.cjs +15 -18
- package/build/cjs/modules/lwr/observable/observable.cjs +17 -4
- package/build/cjs/modules/lwr/outlet/outlet.cjs +30 -34
- package/build/cjs/modules/lwr/router/router.cjs +122 -38
- package/build/cjs/modules/lwr/routerBridge/routerBridge.cjs +25 -19
- package/build/cjs/modules/lwr/routerContainer/routerContainer.cjs +49 -29
- package/build/cjs/modules/lwr/routerContainer/utils.cjs +41 -20
- package/build/cjs/modules/lwr/routerErrors/routerErrors.cjs +17 -4
- package/build/cjs/modules/lwr/routerUtils/domUtils.cjs +17 -4
- package/build/cjs/modules/lwr/routerUtils/filterUtils.cjs +36 -17
- package/build/cjs/modules/lwr/routerUtils/parseUtils.cjs +27 -30
- package/build/cjs/modules/lwr/routerUtils/pathToRegexp.cjs +64 -52
- package/build/cjs/modules/lwr/routerUtils/routeDefUtils.cjs +26 -28
- package/build/cjs/modules/lwr/routerUtils/routeUtils.cjs +31 -34
- package/build/cjs/modules/lwr/routerUtils/routerUtils.cjs +22 -25
- package/build/cjs/modules/lwr/routerUtils/typeUtils.cjs +22 -7
- package/build/cjs/modules/lwr/routerUtils/types.cjs +15 -2
- package/build/cjs/modules/lwr/routerUtils/uriUtils.cjs +18 -5
- package/build/cjs/modules/lwr/serverRouter/serverRouter.cjs +57 -27
- package/build/cjs/services/index.cjs +47 -37
- package/build/cjs/services/module-provider/index.cjs +36 -29
- package/build/cjs/services/module-provider/utils.cjs +38 -31
- package/package.json +6 -6
|
@@ -1,37 +1,34 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
-
var
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
6
|
var __export = (target, all) => {
|
|
9
7
|
for (var name in all)
|
|
10
|
-
__defProp(target, name, {get: all[name], enumerable: true});
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
9
|
};
|
|
12
|
-
var
|
|
13
|
-
if (
|
|
14
|
-
for (let key of __getOwnPropNames(
|
|
15
|
-
if (!__hasOwnProp.call(
|
|
16
|
-
__defProp(
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
15
|
}
|
|
18
|
-
return
|
|
19
|
-
};
|
|
20
|
-
var __toModule = (module2) => {
|
|
21
|
-
return __exportStar(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? {get: () => module2.default, enumerable: true} : {value: module2, enumerable: true})), module2);
|
|
16
|
+
return to;
|
|
22
17
|
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
19
|
|
|
24
20
|
// packages/@lwrjs/router/src/modules/lwr/contextProvider/contextProvider.ts
|
|
25
|
-
|
|
26
|
-
__export(
|
|
21
|
+
var contextProvider_exports = {};
|
|
22
|
+
__export(contextProvider_exports, {
|
|
27
23
|
currentPageReferenceContextualizer: () => currentPageReferenceContextualizer,
|
|
28
24
|
currentViewContextualizer: () => currentViewContextualizer,
|
|
29
25
|
navigationContextContextualizer: () => navigationContextContextualizer,
|
|
30
26
|
provideContext: () => provideContext
|
|
31
27
|
});
|
|
32
|
-
|
|
33
|
-
var
|
|
34
|
-
var
|
|
28
|
+
module.exports = __toCommonJS(contextProvider_exports);
|
|
29
|
+
var import_lwc = require("lwc");
|
|
30
|
+
var import_routerUtils = require("lwr/routerUtils");
|
|
31
|
+
var import_navigation = require("lwr/navigation");
|
|
35
32
|
var currentPageReferenceContextualizer = (0, import_lwc.createContextProvider)(import_navigation.CurrentPageReference);
|
|
36
33
|
var currentViewContextualizer = import_routerUtils.hasDocument ? (0, import_lwc.createContextProvider)(import_navigation.CurrentView) : void 0;
|
|
37
34
|
var navigationContextContextualizer = (0, import_lwc.createContextProvider)(import_navigation.NavigationContext);
|
|
@@ -39,8 +36,14 @@ function provideContext(contextValue, providerNode, contextualizer, contextualAd
|
|
|
39
36
|
if (contextualizer && contextualAdapter) {
|
|
40
37
|
contextualAdapter.setContext(providerNode, contextValue);
|
|
41
38
|
contextualizer(providerNode, {
|
|
42
|
-
consumerConnectedCallback: contextualAdapter.subscribeContext.bind(
|
|
43
|
-
|
|
39
|
+
consumerConnectedCallback: contextualAdapter.subscribeContext.bind(
|
|
40
|
+
contextualAdapter,
|
|
41
|
+
providerNode
|
|
42
|
+
),
|
|
43
|
+
consumerDisconnectedCallback: contextualAdapter.unsubscribeContext.bind(
|
|
44
|
+
contextualAdapter,
|
|
45
|
+
providerNode
|
|
46
|
+
)
|
|
44
47
|
});
|
|
45
48
|
}
|
|
46
49
|
}
|
|
@@ -1,15 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
1
2
|
var __defProp = Object.defineProperty;
|
|
2
|
-
var
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
3
6
|
var __export = (target, all) => {
|
|
4
7
|
for (var name in all)
|
|
5
|
-
__defProp(target, name, {get: all[name], enumerable: true});
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
6
9
|
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
7
19
|
|
|
8
20
|
// packages/@lwrjs/router/src/modules/lwr/contextUtils/contextInfo.ts
|
|
9
|
-
|
|
10
|
-
__export(
|
|
21
|
+
var contextInfo_exports = {};
|
|
22
|
+
__export(contextInfo_exports, {
|
|
11
23
|
ContextInfo: () => ContextInfo
|
|
12
24
|
});
|
|
25
|
+
module.exports = __toCommonJS(contextInfo_exports);
|
|
13
26
|
function validateProvider(obj) {
|
|
14
27
|
if (obj === void 0 || obj === null) {
|
|
15
28
|
throw new TypeError("Provider must be defined.");
|
|
@@ -17,17 +30,27 @@ function validateProvider(obj) {
|
|
|
17
30
|
}
|
|
18
31
|
var ContextInfo = class {
|
|
19
32
|
constructor(defaultValue) {
|
|
20
|
-
this.infoMap = new WeakMap();
|
|
33
|
+
this.infoMap = /* @__PURE__ */ new WeakMap();
|
|
21
34
|
this.defaultValue = defaultValue;
|
|
22
35
|
}
|
|
36
|
+
/**
|
|
37
|
+
* Gets the stored info for a context provider
|
|
38
|
+
* @param targetProvider the context provider
|
|
39
|
+
*/
|
|
23
40
|
getInfo(targetProvider) {
|
|
24
41
|
let info = this.infoMap.get(targetProvider);
|
|
25
42
|
if (info === void 0) {
|
|
26
|
-
info = {consumers: new Set()};
|
|
43
|
+
info = { consumers: /* @__PURE__ */ new Set() };
|
|
27
44
|
this.infoMap.set(targetProvider, info);
|
|
28
45
|
}
|
|
29
46
|
return info;
|
|
30
47
|
}
|
|
48
|
+
/**
|
|
49
|
+
* Set the context value directly associated with the target as a context provider.
|
|
50
|
+
*
|
|
51
|
+
* @param {Object} targetProvider
|
|
52
|
+
* @param {FeatureContext} contextValue
|
|
53
|
+
*/
|
|
31
54
|
setContext(targetProvider, contextValue) {
|
|
32
55
|
validateProvider(targetProvider);
|
|
33
56
|
const value = contextValue;
|
|
@@ -38,23 +61,51 @@ var ContextInfo = class {
|
|
|
38
61
|
value.onComplete();
|
|
39
62
|
}
|
|
40
63
|
}
|
|
64
|
+
/**
|
|
65
|
+
* Get the context value directly associated with the target as a context provider.
|
|
66
|
+
*
|
|
67
|
+
* @param {Object} targetProvider
|
|
68
|
+
*/
|
|
41
69
|
getContext(targetProvider) {
|
|
42
70
|
validateProvider(targetProvider);
|
|
43
|
-
const {contextValue} = this.getInfo(targetProvider);
|
|
71
|
+
const { contextValue } = this.getInfo(targetProvider);
|
|
44
72
|
return contextValue !== void 0 ? contextValue : this.defaultValue;
|
|
45
73
|
}
|
|
74
|
+
/**
|
|
75
|
+
* Clear the context value and registered subscribers directly associated with the
|
|
76
|
+
* target as a context provider.
|
|
77
|
+
*
|
|
78
|
+
* @param {Object} targetProvider
|
|
79
|
+
*/
|
|
46
80
|
clearContext(targetProvider) {
|
|
47
81
|
validateProvider(targetProvider);
|
|
48
82
|
this.infoMap.delete(targetProvider);
|
|
49
83
|
}
|
|
84
|
+
/**
|
|
85
|
+
* Subscribe a consumer to the context value directly associated with the target as
|
|
86
|
+
* a context provider. Calls to #set(targetProvider, contextValue) with the same
|
|
87
|
+
* target will invoke the consumer.provide(contextValue) function.
|
|
88
|
+
*
|
|
89
|
+
* NOTE: Mutations to the contextValue directly do not result in calls to
|
|
90
|
+
* consumer.provide(contextValue).
|
|
91
|
+
*
|
|
92
|
+
* @param {Object} targetProvider
|
|
93
|
+
* @param {ContextConsumer} consumer object with a provide(context) function property.
|
|
94
|
+
*/
|
|
50
95
|
subscribeContext(targetProvider, consumer) {
|
|
51
96
|
validateProvider(targetProvider);
|
|
52
|
-
const {consumers, contextValue} = this.getInfo(targetProvider);
|
|
97
|
+
const { consumers, contextValue } = this.getInfo(targetProvider);
|
|
53
98
|
if (!consumers.has(consumer)) {
|
|
54
99
|
consumers.add(consumer);
|
|
55
100
|
consumer.provide(contextValue);
|
|
56
101
|
}
|
|
57
102
|
}
|
|
103
|
+
/**
|
|
104
|
+
* Unsubscribe a previously subscribed consumer from listening to changes on the
|
|
105
|
+
* target
|
|
106
|
+
* @param {Object} targetProvider
|
|
107
|
+
* @param {ContextConsumer} consumer
|
|
108
|
+
*/
|
|
58
109
|
unsubscribeContext(targetProvider, consumer) {
|
|
59
110
|
validateProvider(targetProvider);
|
|
60
111
|
this.getInfo(targetProvider).consumers.delete(consumer);
|
|
@@ -1,39 +1,35 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
-
var
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
6
|
var __export = (target, all) => {
|
|
9
7
|
for (var name in all)
|
|
10
|
-
__defProp(target, name, {get: all[name], enumerable: true});
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
9
|
};
|
|
12
|
-
var
|
|
13
|
-
if (
|
|
14
|
-
for (let key of __getOwnPropNames(
|
|
15
|
-
if (!__hasOwnProp.call(
|
|
16
|
-
__defProp(
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
15
|
}
|
|
18
|
-
return
|
|
19
|
-
};
|
|
20
|
-
var __toModule = (module2) => {
|
|
21
|
-
return __exportStar(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? {get: () => module2.default, enumerable: true} : {value: module2, enumerable: true})), module2);
|
|
16
|
+
return to;
|
|
22
17
|
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
19
|
|
|
24
20
|
// packages/@lwrjs/router/src/modules/lwr/contextUtils/contextUtils.ts
|
|
25
|
-
|
|
26
|
-
__export(
|
|
21
|
+
var contextUtils_exports = {};
|
|
22
|
+
__export(contextUtils_exports, {
|
|
27
23
|
ContextInfo: () => import_contextInfo.ContextInfo,
|
|
28
24
|
generateContextualWireAdapter: () => generateContextualWireAdapter,
|
|
29
25
|
getNavigationHelm: () => import_navigationApiStore.getNavigationHelm,
|
|
30
26
|
registerNavigationHelm: () => import_navigationApiStore.registerNavigationHelm
|
|
31
27
|
});
|
|
32
|
-
|
|
33
|
-
var
|
|
28
|
+
module.exports = __toCommonJS(contextUtils_exports);
|
|
29
|
+
var import_contextInfo = require("./contextInfo.cjs");
|
|
30
|
+
var import_navigationApiStore = require("./navigationApiStore.cjs");
|
|
34
31
|
function generateContextualWireAdapter(contextInstance) {
|
|
35
|
-
|
|
36
|
-
const Adapter = (_a = class {
|
|
32
|
+
const Adapter = class Adapter {
|
|
37
33
|
constructor(callback) {
|
|
38
34
|
this._callback = callback;
|
|
39
35
|
}
|
|
@@ -41,26 +37,65 @@ function generateContextualWireAdapter(contextInstance) {
|
|
|
41
37
|
}
|
|
42
38
|
disconnect() {
|
|
43
39
|
}
|
|
40
|
+
// The default update method services wires that emit context as TEmit when their value changes.
|
|
41
|
+
// Wires that need more complex logic or use another emit type should override this method.
|
|
44
42
|
update(config, context) {
|
|
45
43
|
if (context) {
|
|
46
44
|
this._callback(context);
|
|
47
45
|
}
|
|
48
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
* Set the context value directly associated with the target as a context provider.
|
|
49
|
+
*
|
|
50
|
+
* @param {EventTarget} targetProvider
|
|
51
|
+
* @param {ContextId} contextValue
|
|
52
|
+
*/
|
|
49
53
|
static setContext(targetProvider, contextValue) {
|
|
50
54
|
contextInstance.setContext(targetProvider, contextValue);
|
|
51
55
|
}
|
|
56
|
+
/**
|
|
57
|
+
* Get the context value directly associated with the target as a context provider.
|
|
58
|
+
*
|
|
59
|
+
* @param {EventTarget} targetProvider
|
|
60
|
+
*/
|
|
52
61
|
static getContext(targetProvider) {
|
|
53
62
|
return contextInstance.getContext(targetProvider);
|
|
54
63
|
}
|
|
64
|
+
/**
|
|
65
|
+
* Clear the context value and registered subscribers directly associated with the
|
|
66
|
+
* target as a context provider.
|
|
67
|
+
*
|
|
68
|
+
* @param {EventTarget} targetProvider
|
|
69
|
+
*/
|
|
55
70
|
static clearContext(targetProvider) {
|
|
56
71
|
contextInstance.clearContext(targetProvider);
|
|
57
72
|
}
|
|
73
|
+
/**
|
|
74
|
+
* Subscribe a consumer to the context value directly associated with the target as
|
|
75
|
+
* a context provider. Calls to #set(targetProvider, contextValue) with the same
|
|
76
|
+
* target will invoke the consumer.provide(contextValue) function.
|
|
77
|
+
*
|
|
78
|
+
* NOTE: Mutations to the contextValue directly do not result in calls to
|
|
79
|
+
* consumer.provide(contextValue).
|
|
80
|
+
*
|
|
81
|
+
* @param {EventTarget} targetProvider
|
|
82
|
+
* @param {ContextConsumer} consumer object with a provide(context) function property.
|
|
83
|
+
*/
|
|
58
84
|
static subscribeContext(targetProvider, consumer) {
|
|
59
85
|
contextInstance.subscribeContext(targetProvider, consumer);
|
|
60
86
|
}
|
|
87
|
+
/**
|
|
88
|
+
* Unsubscribe a previously subscribed consumer from listening to changes on the
|
|
89
|
+
* target
|
|
90
|
+
* @param {EventTarget} targetProvider
|
|
91
|
+
* @param {ContextConsumer} consumer
|
|
92
|
+
*/
|
|
61
93
|
static unsubscribeContext(targetProvider, consumer) {
|
|
62
94
|
contextInstance.unsubscribeContext(targetProvider, consumer);
|
|
63
95
|
}
|
|
64
|
-
|
|
96
|
+
static {
|
|
97
|
+
this.contextSchema = { value: "required" };
|
|
98
|
+
}
|
|
99
|
+
};
|
|
65
100
|
return Adapter;
|
|
66
101
|
}
|
|
@@ -1,34 +1,31 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
-
var
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
6
|
var __export = (target, all) => {
|
|
9
7
|
for (var name in all)
|
|
10
|
-
__defProp(target, name, {get: all[name], enumerable: true});
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
9
|
};
|
|
12
|
-
var
|
|
13
|
-
if (
|
|
14
|
-
for (let key of __getOwnPropNames(
|
|
15
|
-
if (!__hasOwnProp.call(
|
|
16
|
-
__defProp(
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
15
|
}
|
|
18
|
-
return
|
|
19
|
-
};
|
|
20
|
-
var __toModule = (module2) => {
|
|
21
|
-
return __exportStar(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? {get: () => module2.default, enumerable: true} : {value: module2, enumerable: true})), module2);
|
|
16
|
+
return to;
|
|
22
17
|
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
19
|
|
|
24
20
|
// packages/@lwrjs/router/src/modules/lwr/contextUtils/navigationApiStore.ts
|
|
25
|
-
|
|
26
|
-
__export(
|
|
21
|
+
var navigationApiStore_exports = {};
|
|
22
|
+
__export(navigationApiStore_exports, {
|
|
27
23
|
getNavigationHelm: () => getNavigationHelm,
|
|
28
24
|
registerNavigationHelm: () => registerNavigationHelm
|
|
29
25
|
});
|
|
30
|
-
|
|
31
|
-
var
|
|
26
|
+
module.exports = __toCommonJS(navigationApiStore_exports);
|
|
27
|
+
var import_routerErrors = require("lwr/routerErrors");
|
|
28
|
+
var CACHE = /* @__PURE__ */ new WeakMap();
|
|
32
29
|
function getNavigationHelm(id) {
|
|
33
30
|
const metadata = CACHE.get(id);
|
|
34
31
|
if (!metadata || !metadata.value) {
|
|
@@ -1,31 +1,30 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
-
var
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
6
|
var __export = (target, all) => {
|
|
9
7
|
for (var name in all)
|
|
10
|
-
__defProp(target, name, {get: all[name], enumerable: true});
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
9
|
};
|
|
12
|
-
var
|
|
13
|
-
if (
|
|
14
|
-
for (let key of __getOwnPropNames(
|
|
15
|
-
if (!__hasOwnProp.call(
|
|
16
|
-
__defProp(
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
15
|
}
|
|
18
|
-
return
|
|
19
|
-
};
|
|
20
|
-
var __toModule = (module2) => {
|
|
21
|
-
return __exportStar(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? {get: () => module2.default, enumerable: true} : {value: module2, enumerable: true})), module2);
|
|
16
|
+
return to;
|
|
22
17
|
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
19
|
|
|
24
20
|
// packages/@lwrjs/router/src/modules/lwr/currentPageReference/currentPageReference.ts
|
|
25
|
-
|
|
26
|
-
__export(
|
|
21
|
+
var currentPageReference_exports = {};
|
|
22
|
+
__export(currentPageReference_exports, {
|
|
27
23
|
CurrentPageReference: () => CurrentPageReference
|
|
28
24
|
});
|
|
29
|
-
|
|
25
|
+
module.exports = __toCommonJS(currentPageReference_exports);
|
|
26
|
+
var import_contextUtils = require("lwr/contextUtils");
|
|
30
27
|
var CURRENT_PAGE_REFERENCE_CONTEXT = new import_contextUtils.ContextInfo(void 0);
|
|
31
|
-
var CurrentPageReference = (0, import_contextUtils.generateContextualWireAdapter)(
|
|
28
|
+
var CurrentPageReference = (0, import_contextUtils.generateContextualWireAdapter)(
|
|
29
|
+
CURRENT_PAGE_REFERENCE_CONTEXT
|
|
30
|
+
);
|
|
@@ -1,33 +1,30 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
-
var
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
6
|
var __export = (target, all) => {
|
|
9
7
|
for (var name in all)
|
|
10
|
-
__defProp(target, name, {get: all[name], enumerable: true});
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
9
|
};
|
|
12
|
-
var
|
|
13
|
-
if (
|
|
14
|
-
for (let key of __getOwnPropNames(
|
|
15
|
-
if (!__hasOwnProp.call(
|
|
16
|
-
__defProp(
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
15
|
}
|
|
18
|
-
return
|
|
19
|
-
};
|
|
20
|
-
var __toModule = (module2) => {
|
|
21
|
-
return __exportStar(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? {get: () => module2.default, enumerable: true} : {value: module2, enumerable: true})), module2);
|
|
16
|
+
return to;
|
|
22
17
|
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
23
19
|
|
|
24
20
|
// packages/@lwrjs/router/src/modules/lwr/currentView/currentView.ts
|
|
25
|
-
|
|
26
|
-
__export(
|
|
21
|
+
var currentView_exports = {};
|
|
22
|
+
__export(currentView_exports, {
|
|
27
23
|
CurrentView: () => CurrentView
|
|
28
24
|
});
|
|
29
|
-
|
|
30
|
-
var
|
|
25
|
+
module.exports = __toCommonJS(currentView_exports);
|
|
26
|
+
var import_contextUtils = require("lwr/contextUtils");
|
|
27
|
+
var import_routerErrors = require("lwr/routerErrors");
|
|
31
28
|
var CURRENT_VIEW_CONTEXT = new import_contextUtils.ContextInfo(void 0);
|
|
32
29
|
var CurrentView = class CurrentView2 extends (0, import_contextUtils.generateContextualWireAdapter)(CURRENT_VIEW_CONTEXT) {
|
|
33
30
|
async update(config, context) {
|