@squiz/edge-dev-render-runtime-lib 2.0.0 → 2.1.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.
@@ -0,0 +1,3 @@
1
+ import { Controller } from 'tsoa';
2
+ export declare class BaseController extends Controller {
3
+ }
@@ -1,4 +1,4 @@
1
- import { Controller } from 'tsoa';
1
+ import { BaseController } from './BaseController';
2
2
  import { ManifestService, Manifest } from '@squiz/component-lib';
3
3
  import { type Request as ExpressRequest } from 'express';
4
4
  type ComponentMap = Record<string, {
@@ -8,7 +8,7 @@ type ComponentMap = Record<string, {
8
8
  previewKey: string | undefined;
9
9
  }[];
10
10
  }>;
11
- export declare class CoreController extends Controller {
11
+ export declare class CoreController extends BaseController {
12
12
  protected manifestService: ManifestService;
13
13
  constructor(manifestService: ManifestService);
14
14
  getSchemaVersion(version: string): Promise<any>;
@@ -1,11 +1,11 @@
1
- import { Controller } from 'tsoa';
1
+ import { BaseController } from './BaseController';
2
2
  import { type Request as ExpressRequest, type Response as ExpressResponse } from 'express';
3
3
  import { ComponentRunnerService } from '../../component-runner';
4
4
  import { ManifestService, ComponentFunctionService, ComponentSetService } from '@squiz/component-lib';
5
5
  import { RenderInputService, ComponentExecutionInput } from '../../RenderInputService';
6
6
  import { FunctionReturnTypes } from '../../component-runner/FunctionReturnTypes';
7
7
  import { ComponentPreviewService } from '../../PreviewComponentService';
8
- export declare class RenderController extends Controller {
8
+ export declare class RenderController extends BaseController {
9
9
  protected componentSetService: ComponentSetService;
10
10
  protected manifestService: ManifestService;
11
11
  protected componentFunctionService: ComponentFunctionService;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@squiz/edge-dev-render-runtime-lib",
3
- "version": "2.0.0",
3
+ "version": "2.1.1",
4
4
  "description": "Package of Edge rendering utilities for components in dev mode",
5
5
  "homepage": "",
6
6
  "license": "ISC",
@@ -16,14 +16,14 @@
16
16
  "@opentelemetry/api": "^1.6.0",
17
17
  "@opentelemetry/resources": "^1.17.1",
18
18
  "@opentelemetry/semantic-conventions": "^1.17.1",
19
- "@squiz/component-lib": "^1.66.1",
20
- "@squiz/component-logger-lib": "^1.67.0",
21
- "@squiz/component-web-api-lib": "^1.65.0",
22
- "@squiz/dx-common-lib": "^1.66.1",
23
- "@squiz/dx-json-schema-lib": "^1.65.0",
19
+ "@squiz/component-lib": "^1.78.1",
20
+ "@squiz/component-logger-lib": "^1.71.1",
21
+ "@squiz/component-web-api-lib": "^1.65.1",
22
+ "@squiz/dx-common-lib": "^1.68.3",
23
+ "@squiz/dx-json-schema-lib": "^1.76.1",
24
24
  "@squiz/dx-logger-lib": "^1.64.0",
25
- "@squiz/formatted-text-lib": "^1.64.0",
26
- "@squiz/runtime-sandbox-common": "^1.64.0",
25
+ "@squiz/formatted-text-lib": "^1.68.1",
26
+ "@squiz/runtime-sandbox-common": "^1.65.1",
27
27
  "compression": "1.7.4",
28
28
  "cors": "2.8.5",
29
29
  "dotenv": "16.0.3",
@@ -38,7 +38,7 @@
38
38
  "winston": "3.8.2"
39
39
  },
40
40
  "devDependencies": {
41
- "@squiz/runtime-sandbox-node": "^1.64.1",
41
+ "@squiz/runtime-sandbox-node": "^1.64.2",
42
42
  "@types/bunyan": "1.8.11",
43
43
  "@types/compression": "1.7.5",
44
44
  "@types/cors": "2.8.17",
@@ -1,19 +0,0 @@
1
- import { Controller } from 'tsoa';
2
- import { type Request as ExpressRequest, type Response as ExpressResponse } from 'express';
3
- import { ManifestModel, ManifestService, ComponentFunctionService, ComponentSetService, Manifest, Headers } from '@squiz/component-lib';
4
- import { MANIFEST_MODELS } from '@squiz/dx-json-schema-lib';
5
- import { ComponentRootUrlResolver } from '../../component-runner';
6
- export declare class DefinitionController extends Controller {
7
- protected componentSetService: ComponentSetService;
8
- protected manifestService: ManifestService;
9
- protected componentFunctionService: ComponentFunctionService;
10
- protected componentRootUrlResolver: ComponentRootUrlResolver;
11
- constructor(componentSetService: ComponentSetService, manifestService: ManifestService, componentFunctionService: ComponentFunctionService, componentRootUrlResolver: ComponentRootUrlResolver);
12
- getComponentVersionManifest(componentId: string, request: ExpressRequest, _previewKey?: string, _componentSet?: string): Promise<ManifestModel>;
13
- getDefaultFunctionDefinition(componentId: string, request: ExpressRequest, _previewKey?: string, _componentSet?: string): Promise<MANIFEST_MODELS.v1.ComponentFunction>;
14
- getGivenFunctionDefinition(componentId: string, functionName: string, request: ExpressRequest, _previewKey?: string, _componentSet?: string): Promise<MANIFEST_MODELS.v1.ComponentFunction>;
15
- private setHeadersFromComponentSet;
16
- protected setHeadersFromPreview(manifest: Manifest, _previewKey: string, functionName: string, response: ExpressResponse): void;
17
- protected setHeaders(headers: Headers, response: ExpressResponse): void;
18
- protected assertValidQueryParametersForDefinition(_previewKey: string | undefined, _componentSet: string | undefined): void;
19
- }
@@ -1,2 +0,0 @@
1
- import supertest from 'supertest';
2
- export declare function definitionRouteTests(request: () => supertest.SuperTest<supertest.Test>, _rootUrl?: string): void;