@ember-nexus/app-core 0.0.9 → 0.0.11
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/dist/browser/index.js +1 -1
- package/dist/browser/index.js.map +1 -1
- package/dist/esm/Component/Page/PageError404.js +14 -0
- package/dist/esm/Component/Page/PageError404.js.map +1 -0
- package/dist/esm/Component/Page/index.js +2 -0
- package/dist/esm/Component/Page/index.js.map +1 -0
- package/dist/esm/Component/Router.js +106 -0
- package/dist/esm/Component/Router.js.map +1 -0
- package/dist/esm/Component/index.js +3 -0
- package/dist/esm/Component/index.js.map +1 -0
- package/dist/esm/Service/RouteResolver.js +88 -0
- package/dist/esm/Service/RouteResolver.js.map +1 -0
- package/dist/esm/Service/index.js +1 -0
- package/dist/esm/Service/index.js.map +1 -1
- package/dist/esm/Type/Definition/PluginIdentifier.js +10 -0
- package/dist/esm/Type/Definition/PluginIdentifier.js.map +1 -0
- package/dist/esm/Type/Definition/PluginInit.js +2 -0
- package/dist/esm/Type/Definition/PluginInit.js.map +1 -0
- package/dist/esm/Type/Definition/RouteConfiguration.js +2 -0
- package/dist/esm/Type/Definition/RouteConfiguration.js.map +1 -0
- package/dist/esm/Type/Definition/RouteGuardFunction.js +2 -0
- package/dist/esm/Type/Definition/RouteGuardFunction.js.map +1 -0
- package/dist/esm/Type/Definition/RouteIdentifier.js +10 -0
- package/dist/esm/Type/Definition/RouteIdentifier.js.map +1 -0
- package/dist/esm/Type/Definition/RouteNode.js +26 -0
- package/dist/esm/Type/Definition/RouteNode.js.map +1 -0
- package/dist/esm/Type/Definition/RouteToWebComponentFunction.js +2 -0
- package/dist/esm/Type/Definition/RouteToWebComponentFunction.js.map +1 -0
- package/dist/esm/Type/Definition/index.js +7 -0
- package/dist/esm/Type/Definition/index.js.map +1 -1
- package/dist/esm/Type/Enum/ServiceIdentifier.js +1 -0
- package/dist/esm/Type/Enum/ServiceIdentifier.js.map +1 -1
- package/dist/esm/index.js +4 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/{Init.js → init.js} +7 -11
- package/dist/esm/init.js.map +1 -0
- package/dist/esm/initEventListeners.js +9 -0
- package/dist/esm/initEventListeners.js.map +1 -0
- package/dist/esm/optimizeDynamicConfigurations.js +5 -0
- package/dist/esm/optimizeDynamicConfigurations.js.map +1 -0
- package/dist/esm/tsconfig.esm.tsbuildinfo +1 -1
- package/dist/types/Component/Page/PageError404.d.ts +5 -0
- package/dist/types/Component/Page/index.d.ts +1 -0
- package/dist/types/Component/Router.d.ts +15 -0
- package/dist/types/Component/index.d.ts +2 -0
- package/dist/types/Service/RouteResolver.d.ts +20 -0
- package/dist/types/Service/index.d.ts +1 -0
- package/dist/types/Type/Definition/PluginIdentifier.d.ts +8 -0
- package/dist/types/Type/Definition/PluginInit.d.ts +10 -0
- package/dist/types/Type/Definition/RouteConfiguration.d.ts +13 -0
- package/dist/types/Type/Definition/RouteGuardFunction.d.ts +2 -0
- package/dist/types/Type/Definition/RouteIdentifier.d.ts +8 -0
- package/dist/types/Type/Definition/RouteNode.d.ts +10 -0
- package/dist/types/Type/Definition/RouteToWebComponentFunction.d.ts +2 -0
- package/dist/types/Type/Definition/index.d.ts +7 -0
- package/dist/types/Type/Enum/ServiceIdentifier.d.ts +1 -0
- package/dist/types/index.d.ts +4 -1
- package/dist/types/init.d.ts +3 -0
- package/dist/types/initEventListeners.d.ts +3 -0
- package/dist/types/optimizeDynamicConfigurations.d.ts +3 -0
- package/package.json +2 -1
- package/dist/esm/Init.js.map +0 -1
- package/dist/types/Init.d.ts +0 -3
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ServiceResolver } from '../../Service/index.js';
|
|
2
|
+
/**
|
|
3
|
+
* Function which every Ember Nexus compatible plugin must expose as its top level `init` export.
|
|
4
|
+
*/
|
|
5
|
+
type pluginInit = (serviceResolver: ServiceResolver) => Promise<void>;
|
|
6
|
+
/**
|
|
7
|
+
* Function which every Ember Nexus compatible plugin must expose as its top level `optimizeDynamicConfigurations` export.
|
|
8
|
+
*/
|
|
9
|
+
type pluginOptimizeDynamicConfigurations = (serviceResolver: ServiceResolver) => Promise<void>;
|
|
10
|
+
export { pluginInit, pluginOptimizeDynamicConfigurations };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { PluginIdentifier } from './PluginIdentifier.js';
|
|
2
|
+
import { RouteGuardFunction } from './RouteGuardFunction.js';
|
|
3
|
+
import { RouteIdentifier } from './RouteIdentifier.js';
|
|
4
|
+
import { RouteToWebComponentFunction } from './RouteToWebComponentFunction.js';
|
|
5
|
+
type RouteConfiguration = {
|
|
6
|
+
pluginIdentifier: PluginIdentifier;
|
|
7
|
+
routeIdentifier: RouteIdentifier;
|
|
8
|
+
route: string;
|
|
9
|
+
priority: number;
|
|
10
|
+
webComponent: string | RouteToWebComponentFunction;
|
|
11
|
+
guard: RouteGuardFunction;
|
|
12
|
+
};
|
|
13
|
+
export { RouteConfiguration };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Branded } from './Branded.js';
|
|
2
|
+
/**
|
|
3
|
+
* Type safe variant of string containing route identifier.
|
|
4
|
+
*/
|
|
5
|
+
type RouteIdentifier = Branded<string, 'routeIdentifier'> | string;
|
|
6
|
+
declare const routeIdentifierRegex: RegExp;
|
|
7
|
+
declare function validateRouteIdentifierFromString(routeIdentifier: string): RouteIdentifier;
|
|
8
|
+
export { RouteIdentifier, routeIdentifierRegex, validateRouteIdentifierFromString };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { RouteIdentifier } from './RouteIdentifier.js';
|
|
2
|
+
declare class RouteNode {
|
|
3
|
+
private childRouteNodes;
|
|
4
|
+
private routeHandler;
|
|
5
|
+
getChildRouteNode(segment: string): RouteNode;
|
|
6
|
+
hasChildRouteNode(segment: string): boolean;
|
|
7
|
+
addRouteHandler(routeHandler: RouteIdentifier): RouteNode;
|
|
8
|
+
getRouteHandlers(): RouteIdentifier[];
|
|
9
|
+
}
|
|
10
|
+
export { RouteNode };
|
|
@@ -14,6 +14,8 @@ export * from './Logger.js';
|
|
|
14
14
|
export * from './Node.js';
|
|
15
15
|
export * from './NodeWithOptionalId.js';
|
|
16
16
|
export * from './OptionalPromise.js';
|
|
17
|
+
export * from './PluginIdentifier.js';
|
|
18
|
+
export * from './PluginInit.js';
|
|
17
19
|
export * from './PriorityRegistry.js';
|
|
18
20
|
export * from './Proxy.js';
|
|
19
21
|
export * from './Registry.js';
|
|
@@ -21,6 +23,11 @@ export * from './Relation.js';
|
|
|
21
23
|
export * from './RelationWithOptionalId.js';
|
|
22
24
|
export * from './RequestProblem.js';
|
|
23
25
|
export * as Response from './Response/index.js';
|
|
26
|
+
export * from './RouteConfiguration.js';
|
|
27
|
+
export * from './RouteGuardFunction.js';
|
|
28
|
+
export * from './RouteIdentifier.js';
|
|
29
|
+
export * from './RouteNode.js';
|
|
30
|
+
export * from './RouteToWebComponentFunction.js';
|
|
24
31
|
export * from './ServiceIdentifier.js';
|
|
25
32
|
export * from './Token.js';
|
|
26
33
|
export * from './UniqueUserIdentifier.js';
|
|
@@ -4,6 +4,7 @@ declare enum ServiceIdentifier {
|
|
|
4
4
|
action = "global.action-registry",
|
|
5
5
|
setting = "global.setting-registry",
|
|
6
6
|
icon = "global.icon-registry",
|
|
7
|
+
routeResolver = "global.route-resolver",
|
|
7
8
|
serviceFetchHelper = "ember-nexus.app-core.service.fetch-helper-service",
|
|
8
9
|
serviceApiConfiguration = "ember-nexus.app-core.service.api-configuration-service",
|
|
9
10
|
serviceElementParser = "ember-nexus.app-core.service.element-parser-service",
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
export * as BrowserEvent from './BrowserEvent/index.js';
|
|
2
2
|
export * as BrowserEventListener from './BrowserEventListener/index.js';
|
|
3
3
|
export * as Cache from './Cache/index.js';
|
|
4
|
+
export * as Component from './Component/index.js';
|
|
4
5
|
export * as Endpoint from './Endpoint/index.js';
|
|
5
6
|
export * as Error from './Error/index.js';
|
|
6
7
|
export * as Event from './Event/index.js';
|
|
7
8
|
export * as EventListener from './EventListener/index.js';
|
|
8
|
-
export * from './
|
|
9
|
+
export * from './init.js';
|
|
10
|
+
export * from './initEventListeners.js';
|
|
11
|
+
export * from './optimizeDynamicConfigurations.js';
|
|
9
12
|
export * as Service from './Service/index.js';
|
|
10
13
|
export * as Type from './Type/index.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ember-nexus/app-core",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.11",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"engines": {
|
|
6
6
|
"node": ">= 20.0"
|
|
@@ -134,6 +134,7 @@
|
|
|
134
134
|
"last 1 years and not dead"
|
|
135
135
|
],
|
|
136
136
|
"dependencies": {
|
|
137
|
+
"lit": "^3.3.2",
|
|
137
138
|
"lru-cache": "^11.1.0",
|
|
138
139
|
"luxon": "^3.4.4",
|
|
139
140
|
"tslib": "^2.8.1",
|
package/dist/esm/Init.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Init.js","sourceRoot":"","sources":["../../src/Init.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAG/B,OAAO,EACL,YAAY,EACZ,oBAAoB,EACpB,mBAAmB,EACnB,mBAAmB,EACnB,UAAU,GACX,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,qBAAqB,EACrB,0BAA0B,EAC1B,kBAAkB,EAClB,yBAAyB,EACzB,yBAAyB,EACzB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,GACnB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,mBAAmB,EACnB,aAAa,EACb,gBAAgB,EAChB,0BAA0B,EAC1B,oBAAoB,EACpB,iBAAiB,GAClB,MAAM,0BAA0B,CAAC;AAClC,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