@easyedu/js-lsm-api 1.87.0 → 1.88.0

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/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # @easyedu/js-lsm-api@1.87.0
1
+ # @easyedu/js-lsm-api@1.88.0
2
2
 
3
3
  A TypeScript SDK client for the sbzw93t49b.execute-api.us-east-2.amazonaws.com API.
4
4
 
@@ -764,7 +764,7 @@ and is automatically generated by the
764
764
  [OpenAPI Generator](https://openapi-generator.tech) project:
765
765
 
766
766
  - API version: `1.0.0`
767
- - Package version: `1.87.0`
767
+ - Package version: `1.88.0`
768
768
  - Generator version: `7.22.0`
769
769
  - Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
770
770
 
@@ -20,7 +20,19 @@ import type { CertificateCanvasVerificationQrElement } from './CertificateCanvas
20
20
  * A constrained certificate-canvas-v1 element.
21
21
  * @export
22
22
  */
23
- export type CertificateCanvasElement = CertificateCanvasImageElement | CertificateCanvasLineElement | CertificateCanvasPortalLogoElement | CertificateCanvasShapeElement | CertificateCanvasTextElement | CertificateCanvasVerificationQrElement;
23
+ export type CertificateCanvasElement = {
24
+ type: 'image';
25
+ } & CertificateCanvasImageElement | {
26
+ type: 'line';
27
+ } & CertificateCanvasLineElement | {
28
+ type: 'portal_logo';
29
+ } & CertificateCanvasPortalLogoElement | {
30
+ type: 'shape';
31
+ } & CertificateCanvasShapeElement | {
32
+ type: 'text';
33
+ } & CertificateCanvasTextElement | {
34
+ type: 'verification_qr';
35
+ } & CertificateCanvasVerificationQrElement;
24
36
  export declare function CertificateCanvasElementFromJSON(json: any): CertificateCanvasElement;
25
37
  export declare function CertificateCanvasElementFromJSONTyped(json: any, ignoreDiscriminator: boolean): CertificateCanvasElement;
26
38
  export declare function CertificateCanvasElementToJSON(json: any): any;
@@ -11,12 +11,12 @@
11
11
  * https://openapi-generator.tech
12
12
  * Do not edit the class manually.
13
13
  */
14
- import { instanceOfCertificateCanvasImageElement, CertificateCanvasImageElementFromJSONTyped, CertificateCanvasImageElementToJSON, } from './CertificateCanvasImageElement';
15
- import { instanceOfCertificateCanvasLineElement, CertificateCanvasLineElementFromJSONTyped, CertificateCanvasLineElementToJSON, } from './CertificateCanvasLineElement';
16
- import { instanceOfCertificateCanvasPortalLogoElement, CertificateCanvasPortalLogoElementFromJSONTyped, CertificateCanvasPortalLogoElementToJSON, } from './CertificateCanvasPortalLogoElement';
17
- import { instanceOfCertificateCanvasShapeElement, CertificateCanvasShapeElementFromJSONTyped, CertificateCanvasShapeElementToJSON, } from './CertificateCanvasShapeElement';
18
- import { instanceOfCertificateCanvasTextElement, CertificateCanvasTextElementFromJSONTyped, CertificateCanvasTextElementToJSON, } from './CertificateCanvasTextElement';
19
- import { instanceOfCertificateCanvasVerificationQrElement, CertificateCanvasVerificationQrElementFromJSONTyped, CertificateCanvasVerificationQrElementToJSON, } from './CertificateCanvasVerificationQrElement';
14
+ import { CertificateCanvasImageElementFromJSONTyped, CertificateCanvasImageElementToJSON, } from './CertificateCanvasImageElement';
15
+ import { CertificateCanvasLineElementFromJSONTyped, CertificateCanvasLineElementToJSON, } from './CertificateCanvasLineElement';
16
+ import { CertificateCanvasPortalLogoElementFromJSONTyped, CertificateCanvasPortalLogoElementToJSON, } from './CertificateCanvasPortalLogoElement';
17
+ import { CertificateCanvasShapeElementFromJSONTyped, CertificateCanvasShapeElementToJSON, } from './CertificateCanvasShapeElement';
18
+ import { CertificateCanvasTextElementFromJSONTyped, CertificateCanvasTextElementToJSON, } from './CertificateCanvasTextElement';
19
+ import { CertificateCanvasVerificationQrElementFromJSONTyped, CertificateCanvasVerificationQrElementToJSON, } from './CertificateCanvasVerificationQrElement';
20
20
  export function CertificateCanvasElementFromJSON(json) {
21
21
  return CertificateCanvasElementFromJSONTyped(json, false);
22
22
  }
@@ -24,28 +24,22 @@ export function CertificateCanvasElementFromJSONTyped(json, ignoreDiscriminator)
24
24
  if (json == null) {
25
25
  return json;
26
26
  }
27
- if (typeof json !== 'object') {
28
- return json;
29
- }
30
- if (instanceOfCertificateCanvasImageElement(json)) {
31
- return CertificateCanvasImageElementFromJSONTyped(json, true);
32
- }
33
- if (instanceOfCertificateCanvasLineElement(json)) {
34
- return CertificateCanvasLineElementFromJSONTyped(json, true);
35
- }
36
- if (instanceOfCertificateCanvasPortalLogoElement(json)) {
37
- return CertificateCanvasPortalLogoElementFromJSONTyped(json, true);
38
- }
39
- if (instanceOfCertificateCanvasShapeElement(json)) {
40
- return CertificateCanvasShapeElementFromJSONTyped(json, true);
41
- }
42
- if (instanceOfCertificateCanvasTextElement(json)) {
43
- return CertificateCanvasTextElementFromJSONTyped(json, true);
44
- }
45
- if (instanceOfCertificateCanvasVerificationQrElement(json)) {
46
- return CertificateCanvasVerificationQrElementFromJSONTyped(json, true);
27
+ switch (json['type']) {
28
+ case 'image':
29
+ return Object.assign({}, CertificateCanvasImageElementFromJSONTyped(json, true), { type: 'image' });
30
+ case 'line':
31
+ return Object.assign({}, CertificateCanvasLineElementFromJSONTyped(json, true), { type: 'line' });
32
+ case 'portal_logo':
33
+ return Object.assign({}, CertificateCanvasPortalLogoElementFromJSONTyped(json, true), { type: 'portal_logo' });
34
+ case 'shape':
35
+ return Object.assign({}, CertificateCanvasShapeElementFromJSONTyped(json, true), { type: 'shape' });
36
+ case 'text':
37
+ return Object.assign({}, CertificateCanvasTextElementFromJSONTyped(json, true), { type: 'text' });
38
+ case 'verification_qr':
39
+ return Object.assign({}, CertificateCanvasVerificationQrElementFromJSONTyped(json, true), { type: 'verification_qr' });
40
+ default:
41
+ return json;
47
42
  }
48
- return {};
49
43
  }
50
44
  export function CertificateCanvasElementToJSON(json) {
51
45
  return CertificateCanvasElementToJSONTyped(json, false);
@@ -54,26 +48,20 @@ export function CertificateCanvasElementToJSONTyped(value, ignoreDiscriminator =
54
48
  if (value == null) {
55
49
  return value;
56
50
  }
57
- if (typeof value !== 'object') {
58
- return value;
59
- }
60
- if (instanceOfCertificateCanvasImageElement(value)) {
61
- return CertificateCanvasImageElementToJSON(value);
62
- }
63
- if (instanceOfCertificateCanvasLineElement(value)) {
64
- return CertificateCanvasLineElementToJSON(value);
65
- }
66
- if (instanceOfCertificateCanvasPortalLogoElement(value)) {
67
- return CertificateCanvasPortalLogoElementToJSON(value);
68
- }
69
- if (instanceOfCertificateCanvasShapeElement(value)) {
70
- return CertificateCanvasShapeElementToJSON(value);
71
- }
72
- if (instanceOfCertificateCanvasTextElement(value)) {
73
- return CertificateCanvasTextElementToJSON(value);
74
- }
75
- if (instanceOfCertificateCanvasVerificationQrElement(value)) {
76
- return CertificateCanvasVerificationQrElementToJSON(value);
51
+ switch (value['type']) {
52
+ case 'image':
53
+ return Object.assign({}, CertificateCanvasImageElementToJSON(value), { type: 'image' });
54
+ case 'line':
55
+ return Object.assign({}, CertificateCanvasLineElementToJSON(value), { type: 'line' });
56
+ case 'portal_logo':
57
+ return Object.assign({}, CertificateCanvasPortalLogoElementToJSON(value), { type: 'portal_logo' });
58
+ case 'shape':
59
+ return Object.assign({}, CertificateCanvasShapeElementToJSON(value), { type: 'shape' });
60
+ case 'text':
61
+ return Object.assign({}, CertificateCanvasTextElementToJSON(value), { type: 'text' });
62
+ case 'verification_qr':
63
+ return Object.assign({}, CertificateCanvasVerificationQrElementToJSON(value), { type: 'verification_qr' });
64
+ default:
65
+ return value;
77
66
  }
78
- return {};
79
67
  }
@@ -20,7 +20,19 @@ import type { CertificateCanvasVerificationQrElement } from './CertificateCanvas
20
20
  * A constrained certificate-canvas-v1 element.
21
21
  * @export
22
22
  */
23
- export type CertificateCanvasElement = CertificateCanvasImageElement | CertificateCanvasLineElement | CertificateCanvasPortalLogoElement | CertificateCanvasShapeElement | CertificateCanvasTextElement | CertificateCanvasVerificationQrElement;
23
+ export type CertificateCanvasElement = {
24
+ type: 'image';
25
+ } & CertificateCanvasImageElement | {
26
+ type: 'line';
27
+ } & CertificateCanvasLineElement | {
28
+ type: 'portal_logo';
29
+ } & CertificateCanvasPortalLogoElement | {
30
+ type: 'shape';
31
+ } & CertificateCanvasShapeElement | {
32
+ type: 'text';
33
+ } & CertificateCanvasTextElement | {
34
+ type: 'verification_qr';
35
+ } & CertificateCanvasVerificationQrElement;
24
36
  export declare function CertificateCanvasElementFromJSON(json: any): CertificateCanvasElement;
25
37
  export declare function CertificateCanvasElementFromJSONTyped(json: any, ignoreDiscriminator: boolean): CertificateCanvasElement;
26
38
  export declare function CertificateCanvasElementToJSON(json: any): any;
@@ -30,28 +30,22 @@ function CertificateCanvasElementFromJSONTyped(json, ignoreDiscriminator) {
30
30
  if (json == null) {
31
31
  return json;
32
32
  }
33
- if (typeof json !== 'object') {
34
- return json;
35
- }
36
- if ((0, CertificateCanvasImageElement_1.instanceOfCertificateCanvasImageElement)(json)) {
37
- return (0, CertificateCanvasImageElement_1.CertificateCanvasImageElementFromJSONTyped)(json, true);
38
- }
39
- if ((0, CertificateCanvasLineElement_1.instanceOfCertificateCanvasLineElement)(json)) {
40
- return (0, CertificateCanvasLineElement_1.CertificateCanvasLineElementFromJSONTyped)(json, true);
41
- }
42
- if ((0, CertificateCanvasPortalLogoElement_1.instanceOfCertificateCanvasPortalLogoElement)(json)) {
43
- return (0, CertificateCanvasPortalLogoElement_1.CertificateCanvasPortalLogoElementFromJSONTyped)(json, true);
44
- }
45
- if ((0, CertificateCanvasShapeElement_1.instanceOfCertificateCanvasShapeElement)(json)) {
46
- return (0, CertificateCanvasShapeElement_1.CertificateCanvasShapeElementFromJSONTyped)(json, true);
47
- }
48
- if ((0, CertificateCanvasTextElement_1.instanceOfCertificateCanvasTextElement)(json)) {
49
- return (0, CertificateCanvasTextElement_1.CertificateCanvasTextElementFromJSONTyped)(json, true);
50
- }
51
- if ((0, CertificateCanvasVerificationQrElement_1.instanceOfCertificateCanvasVerificationQrElement)(json)) {
52
- return (0, CertificateCanvasVerificationQrElement_1.CertificateCanvasVerificationQrElementFromJSONTyped)(json, true);
33
+ switch (json['type']) {
34
+ case 'image':
35
+ return Object.assign({}, (0, CertificateCanvasImageElement_1.CertificateCanvasImageElementFromJSONTyped)(json, true), { type: 'image' });
36
+ case 'line':
37
+ return Object.assign({}, (0, CertificateCanvasLineElement_1.CertificateCanvasLineElementFromJSONTyped)(json, true), { type: 'line' });
38
+ case 'portal_logo':
39
+ return Object.assign({}, (0, CertificateCanvasPortalLogoElement_1.CertificateCanvasPortalLogoElementFromJSONTyped)(json, true), { type: 'portal_logo' });
40
+ case 'shape':
41
+ return Object.assign({}, (0, CertificateCanvasShapeElement_1.CertificateCanvasShapeElementFromJSONTyped)(json, true), { type: 'shape' });
42
+ case 'text':
43
+ return Object.assign({}, (0, CertificateCanvasTextElement_1.CertificateCanvasTextElementFromJSONTyped)(json, true), { type: 'text' });
44
+ case 'verification_qr':
45
+ return Object.assign({}, (0, CertificateCanvasVerificationQrElement_1.CertificateCanvasVerificationQrElementFromJSONTyped)(json, true), { type: 'verification_qr' });
46
+ default:
47
+ return json;
53
48
  }
54
- return {};
55
49
  }
56
50
  function CertificateCanvasElementToJSON(json) {
57
51
  return CertificateCanvasElementToJSONTyped(json, false);
@@ -60,26 +54,20 @@ function CertificateCanvasElementToJSONTyped(value, ignoreDiscriminator = false)
60
54
  if (value == null) {
61
55
  return value;
62
56
  }
63
- if (typeof value !== 'object') {
64
- return value;
65
- }
66
- if ((0, CertificateCanvasImageElement_1.instanceOfCertificateCanvasImageElement)(value)) {
67
- return (0, CertificateCanvasImageElement_1.CertificateCanvasImageElementToJSON)(value);
68
- }
69
- if ((0, CertificateCanvasLineElement_1.instanceOfCertificateCanvasLineElement)(value)) {
70
- return (0, CertificateCanvasLineElement_1.CertificateCanvasLineElementToJSON)(value);
71
- }
72
- if ((0, CertificateCanvasPortalLogoElement_1.instanceOfCertificateCanvasPortalLogoElement)(value)) {
73
- return (0, CertificateCanvasPortalLogoElement_1.CertificateCanvasPortalLogoElementToJSON)(value);
74
- }
75
- if ((0, CertificateCanvasShapeElement_1.instanceOfCertificateCanvasShapeElement)(value)) {
76
- return (0, CertificateCanvasShapeElement_1.CertificateCanvasShapeElementToJSON)(value);
77
- }
78
- if ((0, CertificateCanvasTextElement_1.instanceOfCertificateCanvasTextElement)(value)) {
79
- return (0, CertificateCanvasTextElement_1.CertificateCanvasTextElementToJSON)(value);
80
- }
81
- if ((0, CertificateCanvasVerificationQrElement_1.instanceOfCertificateCanvasVerificationQrElement)(value)) {
82
- return (0, CertificateCanvasVerificationQrElement_1.CertificateCanvasVerificationQrElementToJSON)(value);
57
+ switch (value['type']) {
58
+ case 'image':
59
+ return Object.assign({}, (0, CertificateCanvasImageElement_1.CertificateCanvasImageElementToJSON)(value), { type: 'image' });
60
+ case 'line':
61
+ return Object.assign({}, (0, CertificateCanvasLineElement_1.CertificateCanvasLineElementToJSON)(value), { type: 'line' });
62
+ case 'portal_logo':
63
+ return Object.assign({}, (0, CertificateCanvasPortalLogoElement_1.CertificateCanvasPortalLogoElementToJSON)(value), { type: 'portal_logo' });
64
+ case 'shape':
65
+ return Object.assign({}, (0, CertificateCanvasShapeElement_1.CertificateCanvasShapeElementToJSON)(value), { type: 'shape' });
66
+ case 'text':
67
+ return Object.assign({}, (0, CertificateCanvasTextElement_1.CertificateCanvasTextElementToJSON)(value), { type: 'text' });
68
+ case 'verification_qr':
69
+ return Object.assign({}, (0, CertificateCanvasVerificationQrElement_1.CertificateCanvasVerificationQrElementToJSON)(value), { type: 'verification_qr' });
70
+ default:
71
+ return value;
83
72
  }
84
- return {};
85
73
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easyedu/js-lsm-api",
3
- "version": "1.87.0",
3
+ "version": "1.88.0",
4
4
  "description": "OpenAPI client for @easyedu/js-lsm-api",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -60,7 +60,7 @@ import {
60
60
  * A constrained certificate-canvas-v1 element.
61
61
  * @export
62
62
  */
63
- export type CertificateCanvasElement = CertificateCanvasImageElement | CertificateCanvasLineElement | CertificateCanvasPortalLogoElement | CertificateCanvasShapeElement | CertificateCanvasTextElement | CertificateCanvasVerificationQrElement;
63
+ export type CertificateCanvasElement = { type: 'image' } & CertificateCanvasImageElement | { type: 'line' } & CertificateCanvasLineElement | { type: 'portal_logo' } & CertificateCanvasPortalLogoElement | { type: 'shape' } & CertificateCanvasShapeElement | { type: 'text' } & CertificateCanvasTextElement | { type: 'verification_qr' } & CertificateCanvasVerificationQrElement;
64
64
 
65
65
  export function CertificateCanvasElementFromJSON(json: any): CertificateCanvasElement {
66
66
  return CertificateCanvasElementFromJSONTyped(json, false);
@@ -70,28 +70,22 @@ export function CertificateCanvasElementFromJSONTyped(json: any, ignoreDiscrimin
70
70
  if (json == null) {
71
71
  return json;
72
72
  }
73
- if (typeof json !== 'object') {
74
- return json;
75
- }
76
- if (instanceOfCertificateCanvasImageElement(json)) {
77
- return CertificateCanvasImageElementFromJSONTyped(json, true);
78
- }
79
- if (instanceOfCertificateCanvasLineElement(json)) {
80
- return CertificateCanvasLineElementFromJSONTyped(json, true);
81
- }
82
- if (instanceOfCertificateCanvasPortalLogoElement(json)) {
83
- return CertificateCanvasPortalLogoElementFromJSONTyped(json, true);
84
- }
85
- if (instanceOfCertificateCanvasShapeElement(json)) {
86
- return CertificateCanvasShapeElementFromJSONTyped(json, true);
87
- }
88
- if (instanceOfCertificateCanvasTextElement(json)) {
89
- return CertificateCanvasTextElementFromJSONTyped(json, true);
90
- }
91
- if (instanceOfCertificateCanvasVerificationQrElement(json)) {
92
- return CertificateCanvasVerificationQrElementFromJSONTyped(json, true);
73
+ switch (json['type']) {
74
+ case 'image':
75
+ return Object.assign({}, CertificateCanvasImageElementFromJSONTyped(json, true), { type: 'image' } as const);
76
+ case 'line':
77
+ return Object.assign({}, CertificateCanvasLineElementFromJSONTyped(json, true), { type: 'line' } as const);
78
+ case 'portal_logo':
79
+ return Object.assign({}, CertificateCanvasPortalLogoElementFromJSONTyped(json, true), { type: 'portal_logo' } as const);
80
+ case 'shape':
81
+ return Object.assign({}, CertificateCanvasShapeElementFromJSONTyped(json, true), { type: 'shape' } as const);
82
+ case 'text':
83
+ return Object.assign({}, CertificateCanvasTextElementFromJSONTyped(json, true), { type: 'text' } as const);
84
+ case 'verification_qr':
85
+ return Object.assign({}, CertificateCanvasVerificationQrElementFromJSONTyped(json, true), { type: 'verification_qr' } as const);
86
+ default:
87
+ return json;
93
88
  }
94
- return {} as any;
95
89
  }
96
90
 
97
91
  export function CertificateCanvasElementToJSON(json: any): any {
@@ -102,27 +96,21 @@ export function CertificateCanvasElementToJSONTyped(value?: CertificateCanvasEle
102
96
  if (value == null) {
103
97
  return value;
104
98
  }
105
- if (typeof value !== 'object') {
106
- return value;
107
- }
108
- if (instanceOfCertificateCanvasImageElement(value)) {
109
- return CertificateCanvasImageElementToJSON(value as CertificateCanvasImageElement);
110
- }
111
- if (instanceOfCertificateCanvasLineElement(value)) {
112
- return CertificateCanvasLineElementToJSON(value as CertificateCanvasLineElement);
113
- }
114
- if (instanceOfCertificateCanvasPortalLogoElement(value)) {
115
- return CertificateCanvasPortalLogoElementToJSON(value as CertificateCanvasPortalLogoElement);
116
- }
117
- if (instanceOfCertificateCanvasShapeElement(value)) {
118
- return CertificateCanvasShapeElementToJSON(value as CertificateCanvasShapeElement);
119
- }
120
- if (instanceOfCertificateCanvasTextElement(value)) {
121
- return CertificateCanvasTextElementToJSON(value as CertificateCanvasTextElement);
122
- }
123
- if (instanceOfCertificateCanvasVerificationQrElement(value)) {
124
- return CertificateCanvasVerificationQrElementToJSON(value as CertificateCanvasVerificationQrElement);
99
+ switch (value['type']) {
100
+ case 'image':
101
+ return Object.assign({}, CertificateCanvasImageElementToJSON(value), { type: 'image' } as const);
102
+ case 'line':
103
+ return Object.assign({}, CertificateCanvasLineElementToJSON(value), { type: 'line' } as const);
104
+ case 'portal_logo':
105
+ return Object.assign({}, CertificateCanvasPortalLogoElementToJSON(value), { type: 'portal_logo' } as const);
106
+ case 'shape':
107
+ return Object.assign({}, CertificateCanvasShapeElementToJSON(value), { type: 'shape' } as const);
108
+ case 'text':
109
+ return Object.assign({}, CertificateCanvasTextElementToJSON(value), { type: 'text' } as const);
110
+ case 'verification_qr':
111
+ return Object.assign({}, CertificateCanvasVerificationQrElementToJSON(value), { type: 'verification_qr' } as const);
112
+ default:
113
+ return value;
125
114
  }
126
- return {};
127
115
  }
128
116