@daffodil/external-router 0.39.13 → 0.40.1
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/daffodil-external-router.d.ts +1 -1
- package/driver/daffodil-external-router-driver.d.ts +1 -0
- package/driver/in-memory/daffodil-external-router-driver-in-memory.d.ts +1 -1
- package/driver/in-memory/in-memory.module.d.ts +5 -0
- package/driver/in-memory/in-memory.service.d.ts +3 -0
- package/driver/in-memory/package.json +5 -6
- package/driver/magento/2.4.1/daffodil-external-router-driver-magento-2.4.1.d.ts +1 -1
- package/driver/magento/2.4.1/graphql/queries/resolve-url-v2.4.1.d.ts +1 -1
- package/driver/magento/2.4.1/magento.module.d.ts +5 -0
- package/driver/magento/2.4.1/magento.service.d.ts +4 -1
- package/driver/magento/2.4.1/package.json +5 -6
- package/driver/magento/2.4.2/daffodil-external-router-driver-magento-2.4.2.d.ts +1 -1
- package/driver/magento/2.4.2/graphql/queries/resolve-url-v2.4.2.d.ts +1 -1
- package/driver/magento/2.4.2/magento.module.d.ts +5 -0
- package/driver/magento/2.4.2/magento.service.d.ts +4 -1
- package/driver/magento/2.4.2/package.json +5 -6
- package/driver/magento/daffodil-external-router-driver-magento.d.ts +1 -0
- package/driver/magento/package.json +5 -6
- package/driver/package.json +5 -6
- package/driver/testing/daffodil-external-router-driver-testing.d.ts +1 -1
- package/driver/testing/package.json +5 -6
- package/driver/testing/testing.module.d.ts +5 -0
- package/driver/testing/testing.service.d.ts +3 -0
- package/{esm2015/config.js → esm2020/config.mjs} +0 -0
- package/esm2020/daffodil-external-router.mjs +5 -0
- package/{esm2015/driver/daffodil-external-router-driver.js → esm2020/driver/daffodil-external-router-driver.mjs} +0 -0
- package/esm2020/driver/in-memory/config.mjs +15 -0
- package/{esm2015/driver/in-memory/daffodil-external-router-driver-in-memory.js → esm2020/driver/in-memory/daffodil-external-router-driver-in-memory.mjs} +1 -2
- package/esm2020/driver/in-memory/in-memory.module.mjs +41 -0
- package/esm2020/driver/in-memory/in-memory.service.mjs +39 -0
- package/{esm2015/driver/in-memory/index.js → esm2020/driver/in-memory/index.mjs} +0 -0
- package/{esm2015/driver/in-memory/public_api.js → esm2020/driver/in-memory/public_api.mjs} +0 -0
- package/{esm2015/driver/index.js → esm2020/driver/index.mjs} +0 -0
- package/{esm2015/driver/interfaces/external-router-driver.interface.js → esm2020/driver/interfaces/external-router-driver.interface.mjs} +0 -0
- package/esm2020/driver/magento/2.4.1/daffodil-external-router-driver-magento-2.4.1.mjs +5 -0
- package/{esm2015/driver/magento/2.4.1/graphql/queries/resolve-url-v2.4.1.js → esm2020/driver/magento/2.4.1/graphql/queries/resolve-url-v2.4.1.mjs} +2 -2
- package/{esm2015/driver/magento/2.4.1/index.js → esm2020/driver/magento/2.4.1/index.mjs} +0 -0
- package/esm2020/driver/magento/2.4.1/magento.module.mjs +55 -0
- package/esm2020/driver/magento/2.4.1/magento.service.mjs +38 -0
- package/{esm2015/driver/magento/2.4.1/public_api.js → esm2020/driver/magento/2.4.1/public_api.mjs} +0 -0
- package/esm2020/driver/magento/2.4.1/transforms/resolution-to-resolvable-url.mjs +10 -0
- package/esm2020/driver/magento/2.4.2/daffodil-external-router-driver-magento-2.4.2.mjs +5 -0
- package/{esm2015/driver/magento/2.4.2/graphql/queries/resolve-url-v2.4.2.js → esm2020/driver/magento/2.4.2/graphql/queries/resolve-url-v2.4.2.mjs} +2 -2
- package/{esm2015/driver/magento/2.4.2/index.js → esm2020/driver/magento/2.4.2/index.mjs} +0 -0
- package/esm2020/driver/magento/2.4.2/magento.module.mjs +55 -0
- package/esm2020/driver/magento/2.4.2/magento.service.mjs +37 -0
- package/{esm2015/driver/magento/2.4.2/public_api.js → esm2020/driver/magento/2.4.2/public_api.mjs} +0 -0
- package/{esm2015/driver/magento/2.4.2/transforms/resolution-to-resolvable-url.js → esm2020/driver/magento/2.4.2/transforms/resolution-to-resolvable-url.mjs} +0 -0
- package/{esm2015/driver/magento/daffodil-external-router-driver-magento.js → esm2020/driver/magento/daffodil-external-router-driver-magento.mjs} +0 -0
- package/{esm2015/driver/magento/index.js → esm2020/driver/magento/index.mjs} +0 -0
- package/{esm2015/driver/magento/model/public_api.js → esm2020/driver/magento/model/public_api.mjs} +0 -0
- package/{esm2015/driver/magento/model/resolution-types.js → esm2020/driver/magento/model/resolution-types.mjs} +0 -0
- package/{esm2015/driver/magento/model/url-resolver-response.js → esm2020/driver/magento/model/url-resolver-response.mjs} +0 -0
- package/{esm2015/driver/magento/model/url-resolver.js → esm2020/driver/magento/model/url-resolver.mjs} +0 -0
- package/{esm2015/driver/magento/public_api.js → esm2020/driver/magento/public_api.mjs} +0 -0
- package/{esm2015/driver/magento/transforms/public_api.js → esm2020/driver/magento/transforms/public_api.mjs} +0 -0
- package/{esm2015/driver/magento/transforms/redirect-to-http.js → esm2020/driver/magento/transforms/redirect-to-http.mjs} +0 -0
- package/{esm2015/driver/not-found-resolution.js → esm2020/driver/not-found-resolution.mjs} +0 -0
- package/{esm2015/driver/public_api.js → esm2020/driver/public_api.mjs} +0 -0
- package/{esm2015/driver/testing/config.js → esm2020/driver/testing/config.mjs} +0 -0
- package/esm2020/driver/testing/daffodil-external-router-driver-testing.mjs +5 -0
- package/{esm2015/driver/testing/index.js → esm2020/driver/testing/index.mjs} +0 -0
- package/{esm2015/driver/testing/public_api.js → esm2020/driver/testing/public_api.mjs} +0 -0
- package/esm2020/driver/testing/testing.module.mjs +38 -0
- package/esm2020/driver/testing/testing.service.mjs +45 -0
- package/{esm2015/errors/no-wildcard.js → esm2020/errors/no-wildcard.mjs} +0 -0
- package/{esm2015/errors/unknown-type.js → esm2020/errors/unknown-type.mjs} +0 -0
- package/esm2020/external-router.module.mjs +31 -0
- package/{esm2015/model/insertion-strategy.type.js → esm2020/model/insertion-strategy.type.mjs} +0 -0
- package/{esm2015/model/public_api.js → esm2020/model/public_api.mjs} +0 -0
- package/{esm2015/model/resolvable-route.js → esm2020/model/resolvable-route.mjs} +0 -0
- package/{esm2015/model/route-info.js → esm2020/model/route-info.mjs} +0 -0
- package/{esm2015/model/route-type.js → esm2020/model/route-type.mjs} +0 -0
- package/{esm2015/model/route-with-data-path.js → esm2020/model/route-with-data-path.mjs} +0 -0
- package/{esm2015/model/route-without-path.js → esm2020/model/route-without-path.mjs} +0 -0
- package/{esm2015/model/type-route-pair.js → esm2020/model/type-route-pair.mjs} +0 -0
- package/{esm2015/public_api.js → esm2020/public_api.mjs} +0 -0
- package/esm2020/router/router.service.mjs +43 -0
- package/esm2020/router/strategies/insert-data-path.mjs +81 -0
- package/{esm2015/router/strategies/insert-route-before-wildcard.js → esm2020/router/strategies/insert-route-before-wildcard.mjs} +0 -0
- package/esm2020/router/url-matcher/data-path-matcher.mjs +31 -0
- package/{esm2015/routing/daffodil-external-router-routing.js → esm2020/routing/daffodil-external-router-routing.mjs} +0 -0
- package/{esm2015/routing/errors/client-error.js → esm2020/routing/errors/client-error.mjs} +0 -0
- package/{esm2015/routing/errors/not-found-error.js → esm2020/routing/errors/not-found-error.mjs} +0 -0
- package/{esm2015/routing/errors/permanent-redirect.js → esm2020/routing/errors/permanent-redirect.mjs} +0 -0
- package/{esm2015/routing/errors/server-error.js → esm2020/routing/errors/server-error.mjs} +0 -0
- package/{esm2015/routing/errors/temporary-redirect.js → esm2020/routing/errors/temporary-redirect.mjs} +0 -0
- package/esm2020/routing/guard/existence.guard.mjs +77 -0
- package/{esm2015/routing/index.js → esm2020/routing/index.mjs} +0 -0
- package/{esm2015/routing/processors/process-errors.js → esm2020/routing/processors/process-errors.mjs} +0 -0
- package/{esm2015/routing/processors/process-redirect.js → esm2020/routing/processors/process-redirect.mjs} +0 -0
- package/{esm2015/routing/public_api.js → esm2020/routing/public_api.mjs} +0 -0
- package/{esm2015/token/type-resolvable-routes.token.js → esm2020/token/type-resolvable-routes.token.mjs} +0 -0
- package/esm2020/transform/resolved-route-to-route.mjs +24 -0
- package/external-router.module.d.ts +5 -0
- package/fesm2015/{daffodil-external-router-driver-in-memory.js → daffodil-external-router-driver-in-memory.mjs} +28 -21
- package/fesm2015/daffodil-external-router-driver-in-memory.mjs.map +1 -0
- package/fesm2015/{daffodil-external-router-driver-magento-2.4.1.js → daffodil-external-router-driver-magento-2.4.1.mjs} +24 -20
- package/fesm2015/daffodil-external-router-driver-magento-2.4.1.mjs.map +1 -0
- package/fesm2015/{daffodil-external-router-driver-magento-2.4.2.js → daffodil-external-router-driver-magento-2.4.2.mjs} +24 -20
- package/fesm2015/daffodil-external-router-driver-magento-2.4.2.mjs.map +1 -0
- package/fesm2015/{daffodil-external-router-driver-magento.js → daffodil-external-router-driver-magento.mjs} +1 -1
- package/fesm2015/daffodil-external-router-driver-magento.mjs.map +1 -0
- package/fesm2015/daffodil-external-router-driver-testing.mjs +101 -0
- package/fesm2015/daffodil-external-router-driver-testing.mjs.map +1 -0
- package/fesm2015/{daffodil-external-router-driver.js → daffodil-external-router-driver.mjs} +1 -1
- package/fesm2015/daffodil-external-router-driver.mjs.map +1 -0
- package/fesm2015/daffodil-external-router-routing.mjs +173 -0
- package/fesm2015/daffodil-external-router-routing.mjs.map +1 -0
- package/fesm2015/{daffodil-external-router.js → daffodil-external-router.mjs} +28 -25
- package/fesm2015/daffodil-external-router.mjs.map +1 -0
- package/fesm2020/daffodil-external-router-driver-in-memory.mjs +98 -0
- package/fesm2020/daffodil-external-router-driver-in-memory.mjs.map +1 -0
- package/fesm2020/daffodil-external-router-driver-magento-2.4.1.mjs +122 -0
- package/fesm2020/daffodil-external-router-driver-magento-2.4.1.mjs.map +1 -0
- package/fesm2020/daffodil-external-router-driver-magento-2.4.2.mjs +122 -0
- package/fesm2020/daffodil-external-router-driver-magento-2.4.2.mjs.map +1 -0
- package/fesm2020/daffodil-external-router-driver-magento.mjs +22 -0
- package/fesm2020/daffodil-external-router-driver-magento.mjs.map +1 -0
- package/fesm2020/daffodil-external-router-driver-testing.mjs +99 -0
- package/fesm2020/daffodil-external-router-driver-testing.mjs.map +1 -0
- package/fesm2020/daffodil-external-router-driver.mjs +30 -0
- package/fesm2020/daffodil-external-router-driver.mjs.map +1 -0
- package/{fesm2015/daffodil-external-router-routing.js → fesm2020/daffodil-external-router-routing.mjs} +21 -19
- package/fesm2020/daffodil-external-router-routing.mjs.map +1 -0
- package/fesm2020/daffodil-external-router.mjs +291 -0
- package/fesm2020/daffodil-external-router.mjs.map +1 -0
- package/package.json +82 -14
- package/router/router.service.d.ts +3 -0
- package/routing/daffodil-external-router-routing.d.ts +1 -0
- package/routing/guard/existence.guard.d.ts +3 -0
- package/routing/package.json +5 -6
- package/bundles/daffodil-external-router-driver-in-memory.umd.js +0 -100
- package/bundles/daffodil-external-router-driver-in-memory.umd.js.map +0 -1
- package/bundles/daffodil-external-router-driver-in-memory.umd.min.js +0 -2
- package/bundles/daffodil-external-router-driver-in-memory.umd.min.js.map +0 -1
- package/bundles/daffodil-external-router-driver-magento-2.4.1.umd.js +0 -438
- package/bundles/daffodil-external-router-driver-magento-2.4.1.umd.js.map +0 -1
- package/bundles/daffodil-external-router-driver-magento-2.4.1.umd.min.js +0 -16
- package/bundles/daffodil-external-router-driver-magento-2.4.1.umd.min.js.map +0 -1
- package/bundles/daffodil-external-router-driver-magento-2.4.2.umd.js +0 -435
- package/bundles/daffodil-external-router-driver-magento-2.4.2.umd.js.map +0 -1
- package/bundles/daffodil-external-router-driver-magento-2.4.2.umd.min.js +0 -16
- package/bundles/daffodil-external-router-driver-magento-2.4.2.umd.min.js.map +0 -1
- package/bundles/daffodil-external-router-driver-magento.umd.js +0 -31
- package/bundles/daffodil-external-router-driver-magento.umd.js.map +0 -1
- package/bundles/daffodil-external-router-driver-magento.umd.min.js +0 -2
- package/bundles/daffodil-external-router-driver-magento.umd.min.js.map +0 -1
- package/bundles/daffodil-external-router-driver-testing.umd.js +0 -101
- package/bundles/daffodil-external-router-driver-testing.umd.js.map +0 -1
- package/bundles/daffodil-external-router-driver-testing.umd.min.js +0 -2
- package/bundles/daffodil-external-router-driver-testing.umd.min.js.map +0 -1
- package/bundles/daffodil-external-router-driver.umd.js +0 -39
- package/bundles/daffodil-external-router-driver.umd.js.map +0 -1
- package/bundles/daffodil-external-router-driver.umd.min.js +0 -2
- package/bundles/daffodil-external-router-driver.umd.min.js.map +0 -1
- package/bundles/daffodil-external-router-routing.umd.js +0 -505
- package/bundles/daffodil-external-router-routing.umd.js.map +0 -1
- package/bundles/daffodil-external-router-routing.umd.min.js +0 -16
- package/bundles/daffodil-external-router-routing.umd.min.js.map +0 -1
- package/bundles/daffodil-external-router.umd.js +0 -625
- package/bundles/daffodil-external-router.umd.js.map +0 -1
- package/bundles/daffodil-external-router.umd.min.js +0 -16
- package/bundles/daffodil-external-router.umd.min.js.map +0 -1
- package/daffodil-external-router.metadata.json +0 -1
- package/driver/daffodil-external-router-driver.metadata.json +0 -1
- package/driver/in-memory/daffodil-external-router-driver-in-memory.metadata.json +0 -1
- package/driver/magento/2.4.1/daffodil-external-router-driver-magento-2.4.1.metadata.json +0 -1
- package/driver/magento/2.4.2/daffodil-external-router-driver-magento-2.4.2.metadata.json +0 -1
- package/driver/magento/daffodil-external-router-driver-magento.metadata.json +0 -1
- package/driver/testing/daffodil-external-router-driver-testing.metadata.json +0 -1
- package/esm2015/daffodil-external-router.js +0 -6
- package/esm2015/driver/in-memory/config.js +0 -17
- package/esm2015/driver/in-memory/in-memory.module.js +0 -36
- package/esm2015/driver/in-memory/in-memory.service.js +0 -36
- package/esm2015/driver/magento/2.4.1/daffodil-external-router-driver-magento-2.4.1.js +0 -6
- package/esm2015/driver/magento/2.4.1/magento.module.js +0 -50
- package/esm2015/driver/magento/2.4.1/magento.service.js +0 -40
- package/esm2015/driver/magento/2.4.1/transforms/resolution-to-resolvable-url.js +0 -13
- package/esm2015/driver/magento/2.4.2/daffodil-external-router-driver-magento-2.4.2.js +0 -6
- package/esm2015/driver/magento/2.4.2/magento.module.js +0 -50
- package/esm2015/driver/magento/2.4.2/magento.service.js +0 -39
- package/esm2015/driver/testing/daffodil-external-router-driver-testing.js +0 -6
- package/esm2015/driver/testing/testing.module.js +0 -33
- package/esm2015/driver/testing/testing.service.js +0 -45
- package/esm2015/external-router.module.js +0 -26
- package/esm2015/router/router.service.js +0 -44
- package/esm2015/router/strategies/insert-data-path.js +0 -83
- package/esm2015/router/url-matcher/data-path-matcher.js +0 -32
- package/esm2015/routing/guard/existence.guard.js +0 -78
- package/esm2015/transform/resolved-route-to-route.js +0 -17
- package/fesm2015/daffodil-external-router-driver-in-memory.js.map +0 -1
- package/fesm2015/daffodil-external-router-driver-magento-2.4.1.js.map +0 -1
- package/fesm2015/daffodil-external-router-driver-magento-2.4.2.js.map +0 -1
- package/fesm2015/daffodil-external-router-driver-magento.js.map +0 -1
- package/fesm2015/daffodil-external-router-driver-testing.js +0 -93
- package/fesm2015/daffodil-external-router-driver-testing.js.map +0 -1
- package/fesm2015/daffodil-external-router-driver.js.map +0 -1
- package/fesm2015/daffodil-external-router-routing.js.map +0 -1
- package/fesm2015/daffodil-external-router.js.map +0 -1
- package/routing/daffodil-external-router-routing.metadata.json +0 -1
@@ -0,0 +1,77 @@
|
|
1
|
+
import { Injectable, Inject, } from '@angular/core';
|
2
|
+
import { Router, } from '@angular/router';
|
3
|
+
import { of, } from 'rxjs';
|
4
|
+
import { catchError, map, switchMap, } from 'rxjs/operators';
|
5
|
+
import { DaffRoutingUriNormalizer } from '@daffodil/core/routing';
|
6
|
+
import { DaffExternalRouter, DAFF_EXTERNAL_ROUTER_CONFIG, } from '@daffodil/external-router';
|
7
|
+
import { DaffExternalRouterDriver, } from '@daffodil/external-router/driver';
|
8
|
+
import { DaffExternalRouterNotFoundError } from '../errors/not-found-error';
|
9
|
+
import { DaffExternalRouterPermanentRedirectError } from '../errors/permanent-redirect';
|
10
|
+
import { DaffExternalRouterTemporaryRedirectError } from '../errors/temporary-redirect';
|
11
|
+
import { processErrors } from '../processors/process-errors';
|
12
|
+
import { processRedirects } from '../processors/process-redirect';
|
13
|
+
import * as i0 from "@angular/core";
|
14
|
+
import * as i1 from "@daffodil/external-router";
|
15
|
+
import * as i2 from "@angular/router";
|
16
|
+
import * as i3 from "@daffodil/core/routing";
|
17
|
+
/**
|
18
|
+
* The DaffExternalRouterExistenceGuard is responsible for guarding the wildcard route
|
19
|
+
* of an Angular App and either navigating to a resolved route upon successful resolution
|
20
|
+
* or navigating to the configured route upon a failed resolution.
|
21
|
+
*/
|
22
|
+
export class DaffExternalRouterExistenceGuard {
|
23
|
+
constructor(driver, externalRouter, router, config, urlNormalizer) {
|
24
|
+
this.driver = driver;
|
25
|
+
this.externalRouter = externalRouter;
|
26
|
+
this.router = router;
|
27
|
+
this.config = config;
|
28
|
+
this.urlNormalizer = urlNormalizer;
|
29
|
+
}
|
30
|
+
canActivate(next, state) {
|
31
|
+
return this.driver.resolve(this.urlNormalizer.normalize(state.url)).pipe(map((resolvedRoute) => processErrors(resolvedRoute)), switchMap(resolvedRoute => {
|
32
|
+
this.externalRouter.add(resolvedRoute);
|
33
|
+
return of(resolvedRoute);
|
34
|
+
}), map((resolvedRoute) => processRedirects(resolvedRoute)),
|
35
|
+
// Note that we have to use state.url as we want to ensure that we keep any fragments or query strings.
|
36
|
+
// When we succeed, redirect to the new route, as config has changed since we init'd.
|
37
|
+
map(() => this.router.parseUrl(state.url)),
|
38
|
+
// When we fail, we need to process errors as dictated by the error type.
|
39
|
+
// Handle redirects
|
40
|
+
catchError(error => {
|
41
|
+
if (!(error instanceof DaffExternalRouterPermanentRedirectError) &&
|
42
|
+
!(error instanceof DaffExternalRouterTemporaryRedirectError)) {
|
43
|
+
throw error;
|
44
|
+
}
|
45
|
+
return of(this.router.parseUrl(error.redirectUrl));
|
46
|
+
}),
|
47
|
+
// Handle "404"
|
48
|
+
catchError((error) => {
|
49
|
+
if (!(error instanceof DaffExternalRouterNotFoundError)) {
|
50
|
+
throw error;
|
51
|
+
}
|
52
|
+
return of(this.router.parseUrl(this.config.notFoundResolutionPath));
|
53
|
+
}),
|
54
|
+
//Otherwise something went horribly wrong and we need to bail out.
|
55
|
+
catchError((error) => {
|
56
|
+
//TODO(damienwebdev): Add a logging system.
|
57
|
+
//This log is intentional until we have a better logging system in place.
|
58
|
+
console.log(error);
|
59
|
+
return of(this.router.parseUrl(this.config.failedResolutionPath));
|
60
|
+
}));
|
61
|
+
}
|
62
|
+
}
|
63
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterExistenceGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterExistenceGuard, deps: [{ token: DaffExternalRouterDriver }, { token: i1.DaffExternalRouter }, { token: i2.Router }, { token: DAFF_EXTERNAL_ROUTER_CONFIG }, { token: i3.DaffRoutingUriNormalizer }], target: i0.ɵɵFactoryTarget.Injectable });
|
64
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterExistenceGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterExistenceGuard, providedIn: 'root' });
|
65
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterExistenceGuard, decorators: [{
|
66
|
+
type: Injectable,
|
67
|
+
args: [{
|
68
|
+
providedIn: 'root',
|
69
|
+
}]
|
70
|
+
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
71
|
+
type: Inject,
|
72
|
+
args: [DaffExternalRouterDriver]
|
73
|
+
}] }, { type: i1.DaffExternalRouter }, { type: i2.Router }, { type: undefined, decorators: [{
|
74
|
+
type: Inject,
|
75
|
+
args: [DAFF_EXTERNAL_ROUTER_CONFIG]
|
76
|
+
}] }, { type: i3.DaffRoutingUriNormalizer }]; } });
|
77
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXhpc3RlbmNlLmd1YXJkLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vbGlicy9leHRlcm5h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YXJzZVVybCh0aGlzLmNvbmZpZy5ub3RGb3VuZFJlc29sdXRpb25QYXRoKSk7XG4gICAgICB9KSxcblxuICAgICAgLy9PdGhlcndpc2Ugc29tZXRoaW5nIHdlbnQgaG9ycmlibHkgd3JvbmcgYW5kIHdlIG5lZWQgdG8gYmFpbCBvdXQuXG4gICAgICBjYXRjaEVycm9yKChlcnJvcikgPT4ge1xuICAgICAgICAvL1RPRE8oZGFtaWVud2ViZGV2KTogQWRkIGEgbG9nZ2luZyBzeXN0ZW0uXG4gICAgICAgIC8vVGhpcyBsb2cgaXMgaW50ZW50aW9uYWwgdW50aWwgd2UgaGF2ZSBhIGJldHRlciBsb2dnaW5nIHN5c3RlbSBpbiBwbGFjZS5cbiAgICAgICAgY29uc29sZS5sb2coZXJyb3IpO1xuICAgICAgICByZXR1cm4gb2YodGhpcy5yb3V0ZXIucGFyc2VVcmwodGhpcy5jb25maWcuZmFpbGVkUmVzb2x1dGlvblBhdGgpKTtcbiAgICAgIH0pLFxuICAgICk7XG4gIH1cbn1cbiJdfQ==
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1,24 @@
|
|
1
|
+
import { DaffExternalRouterUnknownRouteTypeError } from '../errors/unknown-type';
|
2
|
+
/**
|
3
|
+
* Transforms a DaffExternallyResolvableUrl into an Angular Route.
|
4
|
+
*/
|
5
|
+
export const daffTransformResolvedRouteToRoute = (resolvedRoute, availableTypes) => {
|
6
|
+
const routeType = availableTypes
|
7
|
+
.filter(t => t.type === resolvedRoute.type)
|
8
|
+
.shift();
|
9
|
+
if (!routeType) {
|
10
|
+
throw new DaffExternalRouterUnknownRouteTypeError(`Unable to resolve the route '${resolvedRoute.url}'. Its type is '${resolvedRoute.type}' but a matching route wasn't found.`);
|
11
|
+
}
|
12
|
+
return {
|
13
|
+
route: {
|
14
|
+
path: resolvedRoute.url,
|
15
|
+
...routeType.route,
|
16
|
+
data: {
|
17
|
+
daffExternalRouteType: resolvedRoute.type,
|
18
|
+
...routeType.route.data,
|
19
|
+
},
|
20
|
+
},
|
21
|
+
insertionStrategy: routeType.insertionStrategy,
|
22
|
+
};
|
23
|
+
};
|
24
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzb2x2ZWQtcm91dGUtdG8tcm91dGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9saWJzL2V4dGVybmFsLXJvdXRlci9zcmMvdHJhbnNmb3JtL3Jlc29sdmVkLXJvdXRlLXRvLXJvdXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSx1Q0FBdUMsRUFBRSxNQUFNLHdCQUF3QixDQUFDO0FBS2pGOztHQUVHO0FBQ0gsTUFBTSxDQUFDLE1BQU0saUNBQWlDLEdBQUcsQ0FDL0MsYUFBMEMsRUFDMUMsY0FBbUMsRUFDcEIsRUFBRTtJQUNqQixNQUFNLFNBQVMsR0FBRyxjQUFjO1NBQzdCLE1BQU0sQ0FBQyxDQUFDLENBQUMsRUFBRSxDQUFDLENBQUMsQ0FBQyxJQUFJLEtBQUssYUFBYSxDQUFDLElBQUksQ0FBQztTQUMxQyxLQUFLLEVBQUUsQ0FBQztJQUNYLElBQUksQ0FBQyxTQUFTLEVBQUU7UUFDZCxNQUFNLElBQUksdUNBQXVDLENBQy9DLGdDQUFnQyxhQUFhLENBQUMsR0FBRyxtQkFBbUIsYUFBYSxDQUFDLElBQUksc0NBQXNDLENBQzdILENBQUM7S0FDSDtJQUVELE9BQU87UUFDTCxLQUFLLEVBQUU7WUFDTCxJQUFJLEVBQUUsYUFBYSxDQUFDLEdBQUc7WUFDdkIsR0FBRyxTQUFTLENBQUMsS0FBSztZQUNsQixJQUFJLEVBQUU7Z0JBQ0oscUJBQXFCLEVBQUUsYUFBYSxDQUFDLElBQUk7Z0JBQ3pDLEdBQUcsU0FBUyxDQUFDLEtBQUssQ0FBQy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vIHJlc29sdmUgdGhlIHJvdXRlICcke3Jlc29sdmVkUm91dGUudXJsfScuIEl0cyB0eXBlIGlzICcke3Jlc29sdmVkUm91dGUudHlwZX0nIGJ1dCBhIG1hdGNoaW5nIHJvdXRlIHdhc24ndCBmb3VuZC5gLFxuICAgICk7XG4gIH1cblxuICByZXR1cm4ge1xuICAgIHJvdXRlOiB7XG4gICAgICBwYXRoOiByZXNvbHZlZFJvdXRlLnVybCxcbiAgICAgIC4uLnJvdXRlVHlwZS5yb3V0ZSxcbiAgICAgIGRhdGE6IHtcbiAgICAgICAgZGFmZkV4dGVybmFsUm91dGVUeXBlOiByZXNvbHZlZFJvdXRlLnR5cGUsXG4gICAgICAgIC4uLnJvdXRlVHlwZS5yb3V0ZS5kYXRhLFxuICAgICAgfSxcbiAgICB9LFxuICAgIGluc2VydGlvblN0cmF0ZWd5OiByb3V0ZVR5cGUuaW5zZXJ0aW9uU3RyYXRlZ3ksXG4gIH07XG59O1xuIl19
|
@@ -1,10 +1,15 @@
|
|
1
1
|
import { ModuleWithProviders } from '@angular/core';
|
2
2
|
import { DaffExternalRouterConfiguration } from './config';
|
3
3
|
import { DaffTypeRoutePair } from './model/type-route-pair';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
import * as i1 from "@angular/common";
|
4
6
|
/**
|
5
7
|
* The external `DaffExternalRouterModule` allows you to configure the
|
6
8
|
* `@daffodil/external-router` package's behavior.
|
7
9
|
*/
|
8
10
|
export declare class DaffExternalRouterModule {
|
9
11
|
static forRoot(config: Partial<DaffExternalRouterConfiguration>, routes?: DaffTypeRoutePair[]): ModuleWithProviders<DaffExternalRouterModule>;
|
12
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DaffExternalRouterModule, never>;
|
13
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<DaffExternalRouterModule, never, [typeof i1.CommonModule], never>;
|
14
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<DaffExternalRouterModule>;
|
10
15
|
}
|
@@ -1,12 +1,12 @@
|
|
1
|
-
import
|
1
|
+
import * as i0 from '@angular/core';
|
2
|
+
import { InjectionToken, Injectable, Inject, inject, NgModule } from '@angular/core';
|
2
3
|
import { of } from 'rxjs';
|
3
4
|
import { daffUriTruncateQueryFragment, daffUriTruncateLeadingSlash } from '@daffodil/core/routing';
|
4
5
|
import { DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION, DaffExternalRouterDriver } from '@daffodil/external-router/driver';
|
5
6
|
import { CommonModule } from '@angular/common';
|
6
7
|
|
7
|
-
const ɵ0 = () => DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION;
|
8
8
|
const defaultConfig = {
|
9
|
-
resolver:
|
9
|
+
resolver: () => DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION,
|
10
10
|
};
|
11
11
|
/**
|
12
12
|
* The token used by Daffodil to hold the driver's configuration.
|
@@ -36,16 +36,19 @@ class DaffExternalRouterInMemoryDriver {
|
|
36
36
|
return of((resolvedUrl === null || resolvedUrl === void 0 ? void 0 : resolvedUrl.url) ? Object.assign(Object.assign({}, resolvedUrl), { url: daffUriTruncateLeadingSlash(resolvedUrl.url) }) : DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION);
|
37
37
|
}
|
38
38
|
}
|
39
|
-
/** @nocollapse */ DaffExternalRouterInMemoryDriver.ɵ
|
40
|
-
DaffExternalRouterInMemoryDriver
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
39
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterInMemoryDriver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterInMemoryDriver, deps: [{ token: DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG }], target: i0.ɵɵFactoryTarget.Injectable });
|
40
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterInMemoryDriver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterInMemoryDriver, providedIn: 'root' });
|
41
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterInMemoryDriver, decorators: [{
|
42
|
+
type: Injectable,
|
43
|
+
args: [{
|
44
|
+
providedIn: 'root',
|
45
|
+
}]
|
46
|
+
}], ctorParameters: function () {
|
47
|
+
return [{ type: undefined, decorators: [{
|
48
|
+
type: Inject,
|
49
|
+
args: [DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG]
|
50
|
+
}] }];
|
51
|
+
} });
|
49
52
|
|
50
53
|
/**
|
51
54
|
* The `DaffExternalRouterDriverInMemoryModule` is an importable NgModule that can
|
@@ -71,12 +74,16 @@ class DaffExternalRouterDriverInMemoryModule {
|
|
71
74
|
};
|
72
75
|
}
|
73
76
|
}
|
74
|
-
DaffExternalRouterDriverInMemoryModule
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
77
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverInMemoryModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverInMemoryModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
78
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverInMemoryModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverInMemoryModule, imports: [CommonModule] });
|
79
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverInMemoryModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverInMemoryModule, imports: [[CommonModule]] });
|
80
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverInMemoryModule, decorators: [{
|
81
|
+
type: NgModule,
|
82
|
+
args: [{
|
83
|
+
declarations: [],
|
84
|
+
imports: [CommonModule],
|
85
|
+
}]
|
86
|
+
}] });
|
80
87
|
|
81
88
|
/*
|
82
89
|
* Public API Surface of @daffodil/external-router/driver/in-memory
|
@@ -86,5 +93,5 @@ DaffExternalRouterDriverInMemoryModule.decorators = [
|
|
86
93
|
* Generated bundle index. Do not edit.
|
87
94
|
*/
|
88
95
|
|
89
|
-
export { DaffExternalRouterDriverInMemoryModule, DaffExternalRouterInMemoryDriver
|
90
|
-
//# sourceMappingURL=daffodil-external-router-driver-in-memory.
|
96
|
+
export { DaffExternalRouterDriverInMemoryModule, DaffExternalRouterInMemoryDriver };
|
97
|
+
//# sourceMappingURL=daffodil-external-router-driver-in-memory.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"daffodil-external-router-driver-in-memory.mjs","sources":["../../../libs/external-router/driver/in-memory/src/config.ts","../../../libs/external-router/driver/in-memory/src/in-memory.service.ts","../../../libs/external-router/driver/in-memory/src/in-memory.module.ts","../../../libs/external-router/driver/in-memory/src/public_api.ts","../../../libs/external-router/driver/in-memory/src/daffodil-external-router-driver-in-memory.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\nimport { DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION } from '@daffodil/external-router/driver';\n\n/**\n * A lookup for a URL.\n * Returns an {@link DaffExternallyResolvableUrl} or\n * {@link DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION} if the URL cannot be resolved\n */\nexport type DaffExternalRouterDriverInMemoryResolver = (url: string) => DaffExternallyResolvableUrl;\n\n/**\n * The configuration for the in-memory driver.\n */\nexport interface DaffExternalRouterDriverInMemoryConfig {\n\tresolver: DaffExternalRouterDriverInMemoryResolver;\n}\n\nconst defaultConfig: DaffExternalRouterDriverInMemoryConfig = {\n resolver: () => DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION,\n};\n\n/**\n * The token used by Daffodil to hold the driver's configuration.\n *\n * @docs-private\n */\nexport const DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG = new InjectionToken<\n\tDaffExternalRouterDriverInMemoryConfig\n>('DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG', {\n providedIn: 'root',\n factory: () => defaultConfig,\n});\n","import {\n Injectable,\n Inject,\n} from '@angular/core';\nimport {\n Observable,\n of,\n} from 'rxjs';\n\nimport {\n daffUriTruncateLeadingSlash,\n daffUriTruncateQueryFragment,\n} from '@daffodil/core/routing';\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\nimport {\n DaffExternalRouterDriverInterface,\n DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION,\n} from '@daffodil/external-router/driver';\n\nimport {\n DaffExternalRouterDriverInMemoryConfig,\n DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG,\n} from './config';\n\n/**\n * The DaffExternalRouterInMemoryDriver is responsible for resolving\n * a URL using the resolver in the provided configuration.\n *\n * @inheritdoc\n *\n * @see {@link DaffExternalRouterInMemoryDriver}\n */\n@Injectable({\n providedIn: 'root',\n})\nexport class DaffExternalRouterInMemoryDriver\nimplements DaffExternalRouterDriverInterface {\n constructor(\n\t\t@Inject(DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG)\n\t\tprivate configuration: DaffExternalRouterDriverInMemoryConfig,\n ) {}\n\n resolve(url: string): Observable<DaffExternallyResolvableUrl> {\n const truncatedUrl = daffUriTruncateQueryFragment(url);\n const resolvedUrl = this.configuration.resolver(truncatedUrl);\n\n return of(resolvedUrl?.url ? {\n ...resolvedUrl,\n url: daffUriTruncateLeadingSlash(resolvedUrl.url),\n } : DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION);\n }\n}\n","import { CommonModule } from '@angular/common';\nimport {\n NgModule,\n ModuleWithProviders,\n InjectionToken,\n inject,\n} from '@angular/core';\n\nimport { DaffExternalRouterDriver } from '@daffodil/external-router/driver';\n\nimport {\n DaffExternalRouterDriverInMemoryConfig,\n DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG,\n} from './config';\nimport { DaffExternalRouterInMemoryDriver } from './in-memory.service';\n\n/**\n * The `DaffExternalRouterDriverInMemoryModule` is an importable NgModule that can\n * be used to configure the {@link DaffExternalRouterInMemoryDriver}.\n */\n@NgModule({\n declarations: [],\n imports: [CommonModule],\n})\nexport class DaffExternalRouterDriverInMemoryModule {\n static forRoot(\n config: DaffExternalRouterDriverInMemoryConfig | InjectionToken<DaffExternalRouterDriverInMemoryConfig>,\n ): ModuleWithProviders<DaffExternalRouterDriverInMemoryModule> {\n return {\n ngModule: DaffExternalRouterDriverInMemoryModule,\n providers: [\n {\n provide: DaffExternalRouterDriver,\n useExisting: DaffExternalRouterInMemoryDriver,\n },\n {\n provide: DAFF_EXTERNAL_ROUTER_DRIVER_IN_MEMORY_CONFIG,\n // eslint-disable-next-line prefer-arrow/prefer-arrow-functions\n useFactory() {\n return config instanceof InjectionToken ? inject(config) : config;\n },\n },\n ],\n };\n }\n}\n","/*\n * Public API Surface of @daffodil/external-router/driver/in-memory\n */\n\nexport { DaffExternalRouterInMemoryDriver } from './in-memory.service';\nexport { DaffExternalRouterDriverInMemoryModule } from './in-memory.module';\n\nexport {\n DaffExternalRouterDriverInMemoryConfig,\n DaffExternalRouterDriverInMemoryResolver,\n} from './config';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAmBA,MAAM,aAAa,GAA2C;AAC5D,IAAA,QAAQ,EAAE,MAAM,yCAAyC;CAC1D,CAAC;AAEF;;;;AAIG;AACI,MAAM,4CAA4C,GAAG,IAAI,cAAc,CAE5E,8CAA8C,EAAE;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} from '@angular/core';
|
3
3
|
import { map } from 'rxjs/operators';
|
4
4
|
import { daffUriTruncateLeadingSlash, daffUriTruncateQueryFragment } from '@daffodil/core/routing';
|
5
|
+
import * as i1 from '@damienwebdev/apollo-angular';
|
6
|
+
import { gql } from '@damienwebdev/apollo-angular';
|
5
7
|
import { DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION, DaffExternalRouterDriver } from '@daffodil/external-router/driver';
|
6
8
|
import { magentoTransformRedirectToHttpCode } from '@daffodil/external-router/driver/magento';
|
7
9
|
import { CommonModule } from '@angular/common';
|
@@ -54,16 +56,14 @@ class DaffExternalRouterMagentoDriver {
|
|
54
56
|
.pipe(map(response => transformResolutionToResolvableUrlv241(response.data.urlResolver)));
|
55
57
|
}
|
56
58
|
}
|
57
|
-
/** @nocollapse */ DaffExternalRouterMagentoDriver.ɵ
|
58
|
-
DaffExternalRouterMagentoDriver
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
{ type: Apollo }
|
66
|
-
];
|
59
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterMagentoDriver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterMagentoDriver, deps: [{ token: i1.Apollo }], target: i0.ɵɵFactoryTarget.Injectable });
|
60
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterMagentoDriver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterMagentoDriver, providedIn: 'root' });
|
61
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterMagentoDriver, decorators: [{
|
62
|
+
type: Injectable,
|
63
|
+
args: [{
|
64
|
+
providedIn: 'root',
|
65
|
+
}]
|
66
|
+
}], ctorParameters: function () { return [{ type: i1.Apollo }]; } });
|
67
67
|
|
68
68
|
/**
|
69
69
|
* The module used to configure the {@link DaffExternalRouterDriver} for usage with Magento.
|
@@ -102,12 +102,16 @@ class DaffExternalRouterDriverMagentoModule {
|
|
102
102
|
};
|
103
103
|
}
|
104
104
|
}
|
105
|
-
DaffExternalRouterDriverMagentoModule
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
105
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverMagentoModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
106
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverMagentoModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, imports: [CommonModule] });
|
107
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverMagentoModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, imports: [[CommonModule]] });
|
108
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, decorators: [{
|
109
|
+
type: NgModule,
|
110
|
+
args: [{
|
111
|
+
declarations: [],
|
112
|
+
imports: [CommonModule],
|
113
|
+
}]
|
114
|
+
}] });
|
111
115
|
|
112
116
|
/*
|
113
117
|
* Public API Surface of @daffodil/external-router/driver/magento/2.4.1
|
@@ -117,5 +121,5 @@ DaffExternalRouterDriverMagentoModule.decorators = [
|
|
117
121
|
* Generated bundle index. Do not edit.
|
118
122
|
*/
|
119
123
|
|
120
|
-
export { DaffExternalRouterDriverMagentoModule, DaffExternalRouterMagentoDriver
|
121
|
-
//# sourceMappingURL=daffodil-external-router-driver-magento-2.4.1.
|
124
|
+
export { DaffExternalRouterDriverMagentoModule, DaffExternalRouterMagentoDriver };
|
125
|
+
//# sourceMappingURL=daffodil-external-router-driver-magento-2.4.1.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"daffodil-external-router-driver-magento-2.4.1.mjs","sources":["../../../libs/external-router/driver/magento/2.4.1/src/graphql/queries/resolve-url-v2.4.1.ts","../../../libs/external-router/driver/magento/2.4.1/src/transforms/resolution-to-resolvable-url.ts","../../../libs/external-router/driver/magento/2.4.1/src/magento.service.ts","../../../libs/external-router/driver/magento/2.4.1/src/magento.module.ts","../../../libs/external-router/driver/magento/2.4.1/src/public_api.ts","../../../libs/external-router/driver/magento/2.4.1/src/daffodil-external-router-driver-magento-2.4.1.ts"],"sourcesContent":["import { gql } from '@damienwebdev/apollo-angular';\n\nexport const DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME = 'MagentoResolveUrlv241';\n\n/**\n * This query retrieves a URL resolution from Magento and informs you about\n * what type of route the URL is.\n */\nexport const MagentoResolveUrlv241 = gql`\n\tquery ${DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME}($url: String!) {\n\t\turlResolver(url: $url) {\n\t\t\tid\n\t\t\trelative_url\n\t\t\tredirectCode\n\t\t\ttype\n\t\t}\n\t}\n`;\n","import {\n daffUriTruncateLeadingSlash,\n daffUriTruncateQueryFragment,\n} from '@daffodil/core/routing';\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\nimport { DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION } from '@daffodil/external-router/driver';\nimport {\n MagentoUrlResolver,\n magentoTransformRedirectToHttpCode,\n} from '@daffodil/external-router/driver/magento';\n\nexport const transformResolutionToResolvableUrlv241 = (\n resolution: MagentoUrlResolver,\n): DaffExternallyResolvableUrl => (resolution ? {\n id: resolution.id?.toString(),\n url: daffUriTruncateLeadingSlash(daffUriTruncateQueryFragment(resolution.relative_url)),\n type: resolution.type,\n code: magentoTransformRedirectToHttpCode(resolution.redirectCode),\n} : DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION);\n\n","import {\n Injectable,\n Inject,\n} from '@angular/core';\nimport { Apollo } from '@damienwebdev/apollo-angular';\nimport { Observable } from 'rxjs';\nimport { map } from 'rxjs/operators';\n\nimport { daffUriTruncateQueryFragment } from '@daffodil/core/routing';\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\nimport { DaffExternalRouterDriverInterface } from '@daffodil/external-router/driver';\nimport { MagentoUrlResolverResponse } from '@daffodil/external-router/driver/magento';\n\nimport { MagentoResolveUrlv241 } from './graphql/queries/resolve-url-v2.4.1';\nimport { transformResolutionToResolvableUrlv241 } from './transforms/resolution-to-resolvable-url';\n\n/**\n * The DaffExternalRouterMagentoDriver is responsible for translating an\n * arbitrary URI into a DaffExternallyResolvableUrl with Magento environments.\n *\n * @inheritdoc\n */\n@Injectable({\n providedIn: 'root',\n})\nexport class DaffExternalRouterMagentoDriver\nimplements DaffExternalRouterDriverInterface {\n constructor(private apollo: Apollo) {}\n\n resolve(url: string): Observable<DaffExternallyResolvableUrl> {\n return this.apollo\n .query<MagentoUrlResolverResponse>({\n query: MagentoResolveUrlv241,\n variables: {\n url: daffUriTruncateQueryFragment(url),\n },\n })\n .pipe(map(response => transformResolutionToResolvableUrlv241(response.data.urlResolver)));\n }\n}\n","import { CommonModule } from '@angular/common';\nimport {\n NgModule,\n ModuleWithProviders,\n} from '@angular/core';\n\nimport { DAFF_MAGENTO_CACHEABLE_OPERATIONS } from '@daffodil/driver/magento';\nimport { DaffExternalRouterDriver } from '@daffodil/external-router/driver';\n\nimport { DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME } from './graphql/queries/resolve-url-v2.4.1';\nimport { DaffExternalRouterMagentoDriver } from './magento.service';\n/**\n * The module used to configure the {@link DaffExternalRouterDriver} for usage with Magento.\n *\n * ```ts\n * @NgModule({\n * declarations: [],\n * imports: [\n * ...\n * DaffExternalRouterDriverMagentoModule.forRoot()\n * ],\n * })\n * export class AppModule{}\n * ```\n *\n * Note that this package depends upon ApolloClient, as the Magento driver uses GraphQl to make it's API calls.\n */\n@NgModule({\n declarations: [],\n imports: [CommonModule],\n})\nexport class DaffExternalRouterDriverMagentoModule {\n\n /**\n * Configures the package for the root injector.\n */\n static forRoot(): ModuleWithProviders<DaffExternalRouterDriverMagentoModule> {\n return {\n ngModule: DaffExternalRouterDriverMagentoModule,\n providers: [\n {\n provide: DaffExternalRouterDriver,\n useExisting: DaffExternalRouterMagentoDriver,\n },\n {\n provide: DAFF_MAGENTO_CACHEABLE_OPERATIONS,\n useValue: DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME,\n multi: true,\n },\n ],\n };\n }\n}\n","/*\n * Public API Surface of @daffodil/external-router/driver/magento/2.4.1\n */\n\nexport { DaffExternalRouterMagentoDriver } from './magento.service';\nexport { DaffExternalRouterDriverMagentoModule } from './magento.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAEO,MAAM,mCAAmC,GAAG,uBAAuB,CAAC;AAE3E;;;AAGG;AACI,MAAM,qBAAqB,GAAG,GAAG,CAAA,CAAA;SAC/B,mCAAmC,CAAA;;;;;;;;CAQ3C;;ACNM,MAAM,sCAAsC,GAAG,CACpD,UAA8B,KACC;;AAAC,IAAA,QAAC,UAAU,GAAG;AAC9C,QAAA,EAAE,EAAE,CAAA,EAAA,GAAA,UAAU,CAAC,EAAE,MAAA,IAAA,IAAA,EAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,EAAA,CAAE,QAAQ,EAAE;QAC7B,GAAG,EAAE,2BAA2B,CAAC,4BAA4B,CAAC,UAAU,CAAC,YAAY,CAAC,CAAC;QACvF,IAAI,EAAE,UAAU,CAAC,IAAI;AACrB,QAAA,IAAI,EAAE,kCAAkC,CAAC,UAAU,CAAC,YAAY,CAAC;AAClE,KAAA,GAAG,yCAAyC,EAAC;CAAA;;ACF9C;;;;;AAKG;MAIU,+BAA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AC1C,oBAAA,QAAQ,EAAE,mCAAmC;AAC7C,oBAAA,KAAK,EAAE,IAAI;AACZ,iBAAA;AACF,aAAA;SACF,CAAC;KACH;;wKApBU,qCAAqC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAArC,sCAAA,qCAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,qCAAqC,YAFtC,YAAY,CAAA,EAAA,CAAA,CAAA;yKAEX,qCAAqC,EAAA,OAAA,EAAA,CAFvC,CAAC,YAAY,CAAC,CAAA,EAAA,CAAA,CAAA;2FAEZ,qCAAqC,EAAA,UAAA,EAAA,CAAA;kBAJjD,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,EAAE;oBAChB,OAAO,EAAE,CAAC,YAAY,CAAC;iBACxB,CAAA;;;AC9BD;;AAEG;;ACFH;;AAEG;;;;"}
|
@@ -1,6 +1,8 @@
|
|
1
|
-
import
|
2
|
-
import {
|
1
|
+
import * as i0 from '@angular/core';
|
2
|
+
import { Injectable, NgModule } from '@angular/core';
|
3
3
|
import { map } from 'rxjs/operators';
|
4
|
+
import * as i1 from '@damienwebdev/apollo-angular';
|
5
|
+
import { gql } from '@damienwebdev/apollo-angular';
|
4
6
|
import { daffUriTruncateLeadingSlash, daffUriTruncateQueryFragment } from '@daffodil/core/routing';
|
5
7
|
import { DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION, DaffExternalRouterDriver } from '@daffodil/external-router/driver';
|
6
8
|
import { magentoTransformRedirectToHttpCode } from '@daffodil/external-router/driver/magento';
|
@@ -51,16 +53,14 @@ class DaffExternalRouterMagentoDriver {
|
|
51
53
|
.pipe(map(response => transformResolutionToResolvableUrlv242(response.data.urlResolver)));
|
52
54
|
}
|
53
55
|
}
|
54
|
-
/** @nocollapse */ DaffExternalRouterMagentoDriver.ɵ
|
55
|
-
DaffExternalRouterMagentoDriver
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
{ type: Apollo }
|
63
|
-
];
|
56
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterMagentoDriver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterMagentoDriver, deps: [{ token: i1.Apollo }], target: i0.ɵɵFactoryTarget.Injectable });
|
57
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterMagentoDriver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterMagentoDriver, providedIn: 'root' });
|
58
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterMagentoDriver, decorators: [{
|
59
|
+
type: Injectable,
|
60
|
+
args: [{
|
61
|
+
providedIn: 'root',
|
62
|
+
}]
|
63
|
+
}], ctorParameters: function () { return [{ type: i1.Apollo }]; } });
|
64
64
|
|
65
65
|
/**
|
66
66
|
* The module used to configure the {@link DaffExternalRouterDriver} for usage with Magento.
|
@@ -99,12 +99,16 @@ class DaffExternalRouterDriverMagentoModule {
|
|
99
99
|
};
|
100
100
|
}
|
101
101
|
}
|
102
|
-
DaffExternalRouterDriverMagentoModule
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
102
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverMagentoModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
103
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverMagentoModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, imports: [CommonModule] });
|
104
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverMagentoModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, imports: [[CommonModule]] });
|
105
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverMagentoModule, decorators: [{
|
106
|
+
type: NgModule,
|
107
|
+
args: [{
|
108
|
+
declarations: [],
|
109
|
+
imports: [CommonModule],
|
110
|
+
}]
|
111
|
+
}] });
|
108
112
|
|
109
113
|
/*
|
110
114
|
* Public API Surface of @daffodil/external-router/driver/magento/2.4.2
|
@@ -114,5 +118,5 @@ DaffExternalRouterDriverMagentoModule.decorators = [
|
|
114
118
|
* Generated bundle index. Do not edit.
|
115
119
|
*/
|
116
120
|
|
117
|
-
export { DaffExternalRouterDriverMagentoModule, DaffExternalRouterMagentoDriver
|
118
|
-
//# sourceMappingURL=daffodil-external-router-driver-magento-2.4.2.
|
121
|
+
export { DaffExternalRouterDriverMagentoModule, DaffExternalRouterMagentoDriver };
|
122
|
+
//# sourceMappingURL=daffodil-external-router-driver-magento-2.4.2.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"daffodil-external-router-driver-magento-2.4.2.mjs","sources":["../../../libs/external-router/driver/magento/2.4.2/src/graphql/queries/resolve-url-v2.4.2.ts","../../../libs/external-router/driver/magento/2.4.2/src/transforms/resolution-to-resolvable-url.ts","../../../libs/external-router/driver/magento/2.4.2/src/magento.service.ts","../../../libs/external-router/driver/magento/2.4.2/src/magento.module.ts","../../../libs/external-router/driver/magento/2.4.2/src/public_api.ts","../../../libs/external-router/driver/magento/2.4.2/src/daffodil-external-router-driver-magento-2.4.2.ts"],"sourcesContent":["import { gql } from '@damienwebdev/apollo-angular';\n\nexport const DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME = 'MagentoResolveUrlv242';\n\n/**\n * This query retrieves a URL resolution from Magento and informs you about\n * what type of route the URL is.\n */\nexport const MagentoResolveUrlv242 = gql`\n\tquery ${DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME}($url: String!) {\n\t\turlResolver(url: $url) {\n\t\t\tentity_uid\n\t\t\trelative_url\n\t\t\tredirectCode\n\t\t\ttype\n\t\t}\n\t}\n`;\n","import {\n daffUriTruncateLeadingSlash,\n daffUriTruncateQueryFragment,\n} from '@daffodil/core/routing';\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\nimport { DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION } from '@daffodil/external-router/driver';\nimport {\n MagentoUrlResolver,\n magentoTransformRedirectToHttpCode,\n} from '@daffodil/external-router/driver/magento';\n\n\nexport const transformResolutionToResolvableUrlv242 = (\n resolution: MagentoUrlResolver,\n): DaffExternallyResolvableUrl => (resolution ? {\n id: resolution.entity_uid,\n url: daffUriTruncateLeadingSlash(daffUriTruncateQueryFragment(resolution.relative_url)),\n type: resolution.type,\n code: magentoTransformRedirectToHttpCode(resolution.redirectCode),\n} : DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION);\n","import { Injectable } from '@angular/core';\nimport { Apollo } from '@damienwebdev/apollo-angular';\nimport { Observable } from 'rxjs';\nimport { map } from 'rxjs/operators';\n\n\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\nimport { DaffExternalRouterDriverInterface } from '@daffodil/external-router/driver';\nimport { MagentoUrlResolverResponse } from '@daffodil/external-router/driver/magento';\n\nimport { MagentoResolveUrlv242 } from './graphql/queries/resolve-url-v2.4.2';\nimport { transformResolutionToResolvableUrlv242 } from './transforms/resolution-to-resolvable-url';\n\n\n/**\n * The DaffExternalRouterMagentoDriver is responsible for translating an\n * arbitrary URI into a DaffExternallyResolvableUrl with Magento environments.\n *\n * @inheritdoc\n */\n@Injectable({\n providedIn: 'root',\n})\nexport class DaffExternalRouterMagentoDriver\nimplements DaffExternalRouterDriverInterface {\n constructor(\n\t\tprivate apollo: Apollo,\n ) {}\n\n resolve(url: string): Observable<DaffExternallyResolvableUrl> {\n return this.apollo\n .query<MagentoUrlResolverResponse>({\n query: MagentoResolveUrlv242,\n variables: {\n url,\n },\n })\n .pipe(map(response => transformResolutionToResolvableUrlv242(response.data.urlResolver)));\n }\n}\n","import { CommonModule } from '@angular/common';\nimport {\n NgModule,\n ModuleWithProviders,\n} from '@angular/core';\n\nimport { DAFF_MAGENTO_CACHEABLE_OPERATIONS } from '@daffodil/driver/magento';\nimport { DaffExternalRouterDriver } from '@daffodil/external-router/driver';\n\nimport { DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME } from './graphql/queries/resolve-url-v2.4.2';\nimport { DaffExternalRouterMagentoDriver } from './magento.service';\n\n/**\n * The module used to configure the {@link DaffExternalRouterDriver} for usage with Magento.\n *\n * ```ts\n * @NgModule({\n * declarations: [],\n * imports: [\n * ...\n * DaffExternalRouterDriverMagentoModule.forRoot()\n * ],\n * })\n * export class AppModule{}\n * ```\n *\n * Note that this package depends upon ApolloClient, as the Magento driver uses GraphQl to make it's API calls.\n */\n@NgModule({\n declarations: [],\n imports: [CommonModule],\n})\nexport class DaffExternalRouterDriverMagentoModule {\n\n /**\n * Configures the package for the root injector.\n */\n static forRoot(): ModuleWithProviders<DaffExternalRouterDriverMagentoModule> {\n return {\n ngModule: DaffExternalRouterDriverMagentoModule,\n providers: [\n {\n provide: DaffExternalRouterDriver,\n useExisting: DaffExternalRouterMagentoDriver,\n },\n {\n provide: DAFF_MAGENTO_CACHEABLE_OPERATIONS,\n useValue: DAFF_MAGENTO_RESOLVE_URL_QUERY_NAME,\n multi: true,\n },\n ],\n };\n }\n}\n","/*\n * Public API Surface of @daffodil/external-router/driver/magento/2.4.2\n */\n\nexport { DaffExternalRouterMagentoDriver } from './magento.service';\nexport { DaffExternalRouterDriverMagentoModule } from './magento.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAEO,MAAM,mCAAmC,GAAG,uBAAuB,CAAC;AAE3E;;;AAGG;AACI,MAAM,qBAAqB,GAAG,GAAG,CAAA,CAAA;SAC/B,mCAAmC,CAAA;;;;;;;;CAQ3C;;ACLM,MAAM,sCAAsC,GAAG,CACpD,UAA8B,MACG,UAAU,GAAG;IAC9C,EAAE,EAAE,UAAU,CAAC,UAAU;IACzB,GAAG,EAAE,2BAA2B,CAAC,4BAA4B,CAAC,UAAU,CAAC,YAAY,CAAC,CAAC;IACvF,IAAI,EAAE,UAAU,CAAC,IAAI;AACrB,IAAA,IAAI,EAAE,kCAAkC,CAAC,UAAU,CAAC,YAAY,CAAC;AAClE,CAAA,GAAG,yCAAyC,CAAC;;ACL9C;;;;;AAKG;MAIU,+BAA+B,CAAA;AAE1C,IAAA,WAAA,CACQ,MAAc,EAAA;AAAd,QAAA,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;KAClB;AAEJ,IAAA,OAAO,CAAC,GAAW,EAAA;QACjB,OAAO,IAAI,CAAC,MAAM;AACf,aAAA,KAAK,CAA6B;AACjC,YAAA,KAAK,EAAE,qBAAqB;AAC5B,YAAA,SAAS,EAAE;gBACT,GAAG;AACJ,aAAA;SACF,CAAC;AACD,aAAA,IAAI,CAAC,GAAG,CAAC,QAAQ,IAAI,sCAAsC,CAAC,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;KAC7F;;kKAfU,+BAA+B,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,MAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAA/B,sCAAA,+BAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,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AAEG;;;;"}
|
@@ -19,4 +19,4 @@ const magentoTransformRedirectToHttpCode = (code) => code === 0 ? 200 : code;
|
|
19
19
|
*/
|
20
20
|
|
21
21
|
export { MagentoUrlRewriteEntityTypeEnum, magentoTransformRedirectToHttpCode };
|
22
|
-
//# sourceMappingURL=daffodil-external-router-driver-magento.
|
22
|
+
//# sourceMappingURL=daffodil-external-router-driver-magento.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"daffodil-external-router-driver-magento.mjs","sources":["../../../libs/external-router/driver/magento/src/model/resolution-types.ts","../../../libs/external-router/driver/magento/src/transforms/redirect-to-http.ts","../../../libs/external-router/driver/magento/src/public_api.ts","../../../libs/external-router/driver/magento/src/daffodil-external-router-driver-magento.ts"],"sourcesContent":["export enum MagentoUrlRewriteEntityTypeEnum {\n\tPRODUCT = 'PRODUCT',\n\tCATEGORY = 'CATEGORY',\n\tCMS_PAGE = 'CMS_PAGE',\n}\n","/**\n * Transforms a Magento redirect code to the appropriate HTTP status code.\n */\nexport const magentoTransformRedirectToHttpCode = (code: number): number =>\n code === 0 ? 200 : code;\n","/*\n * Public API Surface of @daffodil/external-router/driver/magento\n */\n\nexport * from './model/public_api';\nexport * from './transforms/public_api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":"AAAY,IAAA,gCAIX;AAJD,CAAA,UAAY,+BAA+B,EAAA;AAC1C,IAAA,+BAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,+BAAA,CAAA,UAAA,CAAA,GAAA,UAAqB,CAAA;AACrB,IAAA,+BAAA,CAAA,UAAA,CAAA,GAAA,UAAqB,CAAA;AACtB,CAAC,EAJW,+BAA+B,KAA/B,+BAA+B,GAI1C,EAAA,CAAA,CAAA;;ACJD;;AAEG;MACU,kCAAkC,GAAG,CAAC,IAAY,KAC7D,IAAI,KAAK,CAAC,GAAG,GAAG,GAAG;;ACJrB;;AAEG;;ACFH;;AAEG;;;;"}
|
@@ -0,0 +1,101 @@
|
|
1
|
+
import * as i0 from '@angular/core';
|
2
|
+
import { InjectionToken, Injectable, Inject, NgModule } from '@angular/core';
|
3
|
+
import * as faker from '@faker-js/faker/locale/en_US';
|
4
|
+
import { throwError, of } from 'rxjs';
|
5
|
+
import { daffUriTruncateLeadingSlash, daffUriTruncateQueryFragment } from '@daffodil/core/routing';
|
6
|
+
import { CommonModule } from '@angular/common';
|
7
|
+
import { DaffExternalRouterDriver } from '@daffodil/external-router/driver';
|
8
|
+
|
9
|
+
/**
|
10
|
+
* The token used by Daffodil to hold the driver's configuration.
|
11
|
+
*
|
12
|
+
* @docs-private
|
13
|
+
*/
|
14
|
+
const DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG = new InjectionToken('DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG', {
|
15
|
+
providedIn: 'root',
|
16
|
+
factory: () => ({}),
|
17
|
+
});
|
18
|
+
|
19
|
+
/**
|
20
|
+
* The DaffExternalRouterTestingDriver is responsible for translating an
|
21
|
+
* arbitrary URI into a DaffExternallyResolvableUrl in testing environments.
|
22
|
+
*
|
23
|
+
* @inheritdoc
|
24
|
+
*
|
25
|
+
* @see {@link DaffExternalRouterTestingDriver}
|
26
|
+
*/
|
27
|
+
class DaffExternalRouterTestingDriver {
|
28
|
+
constructor(testingConfiguration = {}) {
|
29
|
+
this.testingConfiguration = testingConfiguration;
|
30
|
+
}
|
31
|
+
resolve(url) {
|
32
|
+
const truncatedUrl = daffUriTruncateLeadingSlash(daffUriTruncateQueryFragment(url));
|
33
|
+
if (!this.testingConfiguration[truncatedUrl]) {
|
34
|
+
return throwError(`\
|
35
|
+
The route '${truncatedUrl}' wasn't provided with a matching type by the testing driver. \
|
36
|
+
Did you configure the available route types with DaffExternalRouterDriverTestingModule.forRoot(config)`);
|
37
|
+
}
|
38
|
+
return of({
|
39
|
+
id: faker.datatype.uuid(),
|
40
|
+
url: truncatedUrl,
|
41
|
+
type: this.testingConfiguration[truncatedUrl],
|
42
|
+
code: 200,
|
43
|
+
});
|
44
|
+
}
|
45
|
+
}
|
46
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterTestingDriver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterTestingDriver, deps: [{ token: DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG }], target: i0.ɵɵFactoryTarget.Injectable });
|
47
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterTestingDriver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterTestingDriver, providedIn: 'root' });
|
48
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterTestingDriver, decorators: [{
|
49
|
+
type: Injectable,
|
50
|
+
args: [{
|
51
|
+
providedIn: 'root',
|
52
|
+
}]
|
53
|
+
}], ctorParameters: function () {
|
54
|
+
return [{ type: undefined, decorators: [{
|
55
|
+
type: Inject,
|
56
|
+
args: [DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG]
|
57
|
+
}] }];
|
58
|
+
} });
|
59
|
+
|
60
|
+
/**
|
61
|
+
* The `DaffExternalRouterDriverTestingModule` is an importable NgModule that can
|
62
|
+
* be used to configure the {@link DaffExternalRouterTestingDriver}.
|
63
|
+
*/
|
64
|
+
class DaffExternalRouterDriverTestingModule {
|
65
|
+
static forRoot(config) {
|
66
|
+
return {
|
67
|
+
ngModule: DaffExternalRouterDriverTestingModule,
|
68
|
+
providers: [
|
69
|
+
{
|
70
|
+
provide: DaffExternalRouterDriver,
|
71
|
+
useExisting: DaffExternalRouterTestingDriver,
|
72
|
+
},
|
73
|
+
{
|
74
|
+
provide: DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG,
|
75
|
+
useValue: config,
|
76
|
+
},
|
77
|
+
],
|
78
|
+
};
|
79
|
+
}
|
80
|
+
}
|
81
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
82
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverTestingModule, imports: [CommonModule] });
|
83
|
+
/** @nocollapse */ /** @nocollapse */ DaffExternalRouterDriverTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverTestingModule, imports: [[CommonModule]] });
|
84
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.0", ngImport: i0, type: DaffExternalRouterDriverTestingModule, decorators: [{
|
85
|
+
type: NgModule,
|
86
|
+
args: [{
|
87
|
+
declarations: [],
|
88
|
+
imports: [CommonModule],
|
89
|
+
}]
|
90
|
+
}] });
|
91
|
+
|
92
|
+
/*
|
93
|
+
* Public API Surface of @daffodil/external-router/driver/testing
|
94
|
+
*/
|
95
|
+
|
96
|
+
/**
|
97
|
+
* Generated bundle index. Do not edit.
|
98
|
+
*/
|
99
|
+
|
100
|
+
export { DaffExternalRouterDriverTestingModule, DaffExternalRouterTestingDriver };
|
101
|
+
//# sourceMappingURL=daffodil-external-router-driver-testing.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"daffodil-external-router-driver-testing.mjs","sources":["../../../libs/external-router/driver/testing/src/config.ts","../../../libs/external-router/driver/testing/src/testing.service.ts","../../../libs/external-router/driver/testing/src/testing.module.ts","../../../libs/external-router/driver/testing/src/public_api.ts","../../../libs/external-router/driver/testing/src/daffodil-external-router-driver-testing.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nimport { DaffExternalRouteType } from '@daffodil/external-router';\n\n/**\n * The configuration for the testing driver. It is a dictionary of \"url\": \"type\",\n * pairs, where the URL is a URL-safe routeable path, e.g. \"sweatshirts\" or \"t-shirts\"\n * and the type is a known type to your application, e.g. \"CATEGORY\".\n */\nexport interface DaffExternalRouterDriverTestingConfig {\n\t[url: string]: DaffExternalRouteType;\n}\n\n/**\n * The token used by Daffodil to hold the driver's configuration.\n *\n * @docs-private\n */\nexport const DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG = new InjectionToken<\n\tDaffExternalRouterDriverTestingConfig\n>('DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG', {\n providedIn: 'root',\n factory: () => ({}),\n});\n","import {\n Injectable,\n Inject,\n} from '@angular/core';\nimport * as faker from '@faker-js/faker/locale/en_US';\nimport {\n Observable,\n of,\n throwError,\n} from 'rxjs';\n\nimport {\n daffUriTruncateLeadingSlash,\n daffUriTruncateQueryFragment,\n} from '@daffodil/core/routing';\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\nimport { DaffExternalRouterDriverInterface } from '@daffodil/external-router/driver';\n\nimport {\n DaffExternalRouterDriverTestingConfig,\n DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG,\n} from './config';\n\n/**\n * The DaffExternalRouterTestingDriver is responsible for translating an\n * arbitrary URI into a DaffExternallyResolvableUrl in testing environments.\n *\n * @inheritdoc\n *\n * @see {@link DaffExternalRouterTestingDriver}\n */\n@Injectable({\n providedIn: 'root',\n})\nexport class DaffExternalRouterTestingDriver\nimplements DaffExternalRouterDriverInterface {\n constructor(\n\t\t@Inject(DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG)\n\t\tprivate testingConfiguration: DaffExternalRouterDriverTestingConfig = {},\n ) {}\n\n resolve(url: string): Observable<DaffExternallyResolvableUrl> {\n const truncatedUrl = daffUriTruncateLeadingSlash(daffUriTruncateQueryFragment(url));\n\n if (!this.testingConfiguration[truncatedUrl]) {\n return throwError(`\\\nThe route '${truncatedUrl}' wasn't provided with a matching type by the testing driver. \\\nDid you configure the available route types with DaffExternalRouterDriverTestingModule.forRoot(config)`);\n }\n\n return of({\n id: faker.datatype.uuid(),\n url: truncatedUrl,\n type: this.testingConfiguration[truncatedUrl],\n code: 200,\n });\n }\n}\n","import { CommonModule } from '@angular/common';\nimport {\n NgModule,\n ModuleWithProviders,\n} from '@angular/core';\n\nimport { DaffExternalRouterDriver } from '@daffodil/external-router/driver';\n\nimport {\n DaffExternalRouterDriverTestingConfig,\n DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG,\n} from './config';\nimport { DaffExternalRouterTestingDriver } from './testing.service';\n\n/**\n * The `DaffExternalRouterDriverTestingModule` is an importable NgModule that can\n * be used to configure the {@link DaffExternalRouterTestingDriver}.\n */\n@NgModule({\n declarations: [],\n imports: [CommonModule],\n})\nexport class DaffExternalRouterDriverTestingModule {\n static forRoot(\n config: DaffExternalRouterDriverTestingConfig,\n ): ModuleWithProviders<DaffExternalRouterDriverTestingModule> {\n return {\n ngModule: DaffExternalRouterDriverTestingModule,\n providers: [\n {\n provide: DaffExternalRouterDriver,\n useExisting: DaffExternalRouterTestingDriver,\n },\n {\n provide: DAFF_EXTERNAL_ROUTER_DRIVER_TESTING_CONFIG,\n useValue: config,\n },\n ],\n };\n }\n}\n","/*\n * Public API Surface of @daffodil/external-router/driver/testing\n */\n\nexport { DaffExternalRouterTestingDriver } from './testing.service';\nexport { DaffExternalRouterDriverTestingModule } from './testing.module';\n\nexport { DaffExternalRouterDriverTestingConfig } from './config';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAaA;;;;AAIG;AACI,MAAM,0CAA0C,GAAG,IAAI,cAAc,CAE1E,4CAA4C,EAAE;AAC9C,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,OAAO,EAAE,CAAC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.
|
30
|
+
//# sourceMappingURL=daffodil-external-router-driver.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"daffodil-external-router-driver.mjs","sources":["../../../libs/external-router/driver/src/interfaces/external-router-driver.interface.ts","../../../libs/external-router/driver/src/not-found-resolution.ts","../../../libs/external-router/driver/src/public_api.ts","../../../libs/external-router/driver/src/daffodil-external-router-driver.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\nimport { Observable } from 'rxjs';\n\nimport { DaffExternallyResolvableUrl } from '@daffodil/external-router';\n\n/**\n * The token for the `@daffodil/external-router` driver.\n */\nexport const DaffExternalRouterDriver = new InjectionToken<\n\tDaffExternalRouterDriverInterface\n>('DaffExternalRouterDriver');\n\n/**\n * The interface for a @daffodil/external-router driver.\n *\n * This driver is responsible for translating a URL into a Route consumable by\n * Daffodil.\n */\nexport interface DaffExternalRouterDriverInterface {\n /**\n * Resolves a URL with a platform.\n * Returns information about the type of URL.\n *\n * @param url The full URL path qualified with file extension and leading slash but without domain. i.e. /full/path/to/thing.html\n */\n\tresolve(url: string): Observable<DaffExternallyResolvableUrl>;\n}\n","import { DaffExternallyResolvableUrl } from '@daffodil/external-router';\n\n/**\n * When a driver fails to find a resolution, it should return a 404.\n * This const represents the standard \"Not Found\" resolution that a driver\n * should return. Drivers are not required to return this value, but may do so\n * if they would like.\n */\nexport const DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION: DaffExternallyResolvableUrl = {\n id: null,\n url: null,\n code: 404,\n type: null,\n};\n","/*\n * Public API Surface of @daffodil/external-router/driver\n */\n\nexport {\n DaffExternalRouterDriverInterface,\n DaffExternalRouterDriver,\n} from './interfaces/external-router-driver.interface';\nexport { DAFF_EXTERNAL_ROUTER_NOT_FOUND_RESOLUTION } from './not-found-resolution';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAKA;;AAEG;MACU,wBAAwB,GAAG,IAAI,cAAc,CAExD,0BAA0B;;ACR5B;;;;;AAKG;AACU,MAAA,yCAAyC,GAAgC;AACpF,IAAA,EAAE,EAAE,IAAI;AACR,IAAA,GAAG,EAAE,IAAI;AACT,IAAA,IAAI,EAAE,GAAG;AACT,IAAA,IAAI,EAAE,IAAI;;;ACZZ;;AAEG;;ACFH;;AAEG;;;;"}
|