@incodetech/core 2.0.0-alpha.2 → 2.0.0-alpha.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/OpenViduLogger-BdPfiZO6.esm.js +3 -0
- package/dist/OpenViduLogger-CQyDxBvM.esm.js +803 -0
- package/dist/{addEvent-1Mi5CEiq.esm.js → addEvent-9v4w5iO-.esm.js} +1 -1
- package/dist/email.d.ts +1 -1
- package/dist/email.esm.js +2 -2
- package/dist/{endpoints-D_pUMaqA.esm.js → endpoints-Dn1t57hJ.esm.js} +8 -3
- package/dist/flow.d.ts +3 -3
- package/dist/flow.esm.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.esm.js +2 -2
- package/dist/{lib-CyIAFRfr.esm.js → lib-Bu9XGMBW.esm.js} +1 -800
- package/dist/{permissionServices-CVR0Pq38.esm.js → permissionServices-CCpxd8le.esm.js} +1 -1
- package/dist/phone.d.ts +1 -1
- package/dist/phone.esm.js +2 -2
- package/dist/selfie.d.ts +5 -4
- package/dist/selfie.esm.js +27 -10
- package/package.json +4 -1
- package/.turbo/turbo-build.log +0 -33
- package/.turbo/turbo-coverage.log +0 -22
- package/.turbo/turbo-format.log +0 -6
- package/.turbo/turbo-lint$colon$fix.log +0 -77
- package/.turbo/turbo-lint.log +0 -95
- package/.turbo/turbo-test.log +0 -870
- package/.turbo/turbo-typecheck.log +0 -5
- package/coverage/base.css +0 -224
- package/coverage/block-navigation.js +0 -87
- package/coverage/favicon.png +0 -0
- package/coverage/index.html +0 -221
- package/coverage/prettify.css +0 -1
- package/coverage/prettify.js +0 -2
- package/coverage/sort-arrow-sprite.png +0 -0
- package/coverage/sorter.js +0 -210
- package/coverage/src/camera/cameraService.ts.html +0 -580
- package/coverage/src/camera/cameraServices.ts.html +0 -163
- package/coverage/src/camera/cameraStateMachine.ts.html +0 -877
- package/coverage/src/camera/index.html +0 -146
- package/coverage/src/email/emailActor.ts.html +0 -130
- package/coverage/src/email/emailManager.ts.html +0 -1366
- package/coverage/src/email/emailStateMachine.ts.html +0 -1186
- package/coverage/src/email/index.html +0 -146
- package/coverage/src/flow/flowActor.ts.html +0 -124
- package/coverage/src/flow/flowAnalyzer.ts.html +0 -196
- package/coverage/src/flow/flowManager.ts.html +0 -790
- package/coverage/src/flow/flowServices.ts.html +0 -124
- package/coverage/src/flow/flowStateMachine.ts.html +0 -631
- package/coverage/src/flow/index.html +0 -221
- package/coverage/src/flow/moduleLoader.ts.html +0 -304
- package/coverage/src/flow/orchestratedFlowManager.ts.html +0 -778
- package/coverage/src/flow/orchestratedFlowStateMachine.ts.html +0 -1060
- package/coverage/src/http/api.ts.html +0 -355
- package/coverage/src/http/endpoints.ts.html +0 -136
- package/coverage/src/http/index.html +0 -131
- package/coverage/src/index.html +0 -116
- package/coverage/src/phone/index.html +0 -146
- package/coverage/src/phone/phoneActor.ts.html +0 -130
- package/coverage/src/phone/phoneManager.ts.html +0 -1459
- package/coverage/src/phone/phoneStateMachine.ts.html +0 -1351
- package/coverage/src/recordings/index.html +0 -116
- package/coverage/src/recordings/recordingsRepository.ts.html +0 -229
- package/coverage/src/selfie/index.html +0 -191
- package/coverage/src/selfie/selfieActor.ts.html +0 -136
- package/coverage/src/selfie/selfieErrorUtils.ts.html +0 -283
- package/coverage/src/selfie/selfieManager.ts.html +0 -988
- package/coverage/src/selfie/selfieStateMachine.ts.html +0 -2497
- package/coverage/src/selfie/selfieUploadService.ts.html +0 -328
- package/coverage/src/selfie/types.ts.html +0 -394
- package/coverage/src/setup.ts.html +0 -598
- package/src/camera/cameraActor.ts +0 -21
- package/src/camera/cameraService.test.ts +0 -437
- package/src/camera/cameraService.ts +0 -165
- package/src/camera/cameraServices.test.ts +0 -66
- package/src/camera/cameraServices.ts +0 -26
- package/src/camera/cameraStateMachine.test.ts +0 -602
- package/src/camera/cameraStateMachine.ts +0 -264
- package/src/camera/index.ts +0 -5
- package/src/camera/types.ts +0 -17
- package/src/device/getBrowser.ts +0 -31
- package/src/device/getDeviceClass.ts +0 -29
- package/src/device/index.ts +0 -2
- package/src/email/__mocks__/emailMocks.ts +0 -59
- package/src/email/emailActor.ts +0 -15
- package/src/email/emailManager.test.ts +0 -573
- package/src/email/emailManager.ts +0 -427
- package/src/email/emailServices.ts +0 -66
- package/src/email/emailStateMachine.test.ts +0 -741
- package/src/email/emailStateMachine.ts +0 -367
- package/src/email/index.ts +0 -39
- package/src/email/types.ts +0 -60
- package/src/events/addEvent.ts +0 -20
- package/src/events/types.ts +0 -7
- package/src/flow/__mocks__/flowMocks.ts +0 -84
- package/src/flow/flowActor.ts +0 -13
- package/src/flow/flowAnalyzer.test.ts +0 -266
- package/src/flow/flowAnalyzer.ts +0 -37
- package/src/flow/flowCompletionService.ts +0 -21
- package/src/flow/flowManager.test.ts +0 -560
- package/src/flow/flowManager.ts +0 -235
- package/src/flow/flowServices.test.ts +0 -109
- package/src/flow/flowServices.ts +0 -13
- package/src/flow/flowStateMachine.test.ts +0 -334
- package/src/flow/flowStateMachine.ts +0 -182
- package/src/flow/index.ts +0 -21
- package/src/flow/moduleLoader.test.ts +0 -136
- package/src/flow/moduleLoader.ts +0 -73
- package/src/flow/orchestratedFlowManager.test.ts +0 -240
- package/src/flow/orchestratedFlowManager.ts +0 -231
- package/src/flow/orchestratedFlowStateMachine.test.ts +0 -199
- package/src/flow/orchestratedFlowStateMachine.ts +0 -325
- package/src/flow/types.ts +0 -434
- package/src/http/__mocks__/api.ts +0 -88
- package/src/http/api.test.ts +0 -231
- package/src/http/api.ts +0 -90
- package/src/http/endpoints.ts +0 -17
- package/src/index.ts +0 -33
- package/src/permissions/index.ts +0 -2
- package/src/permissions/permissionServices.ts +0 -31
- package/src/permissions/types.ts +0 -3
- package/src/phone/__mocks__/phoneMocks.ts +0 -71
- package/src/phone/index.ts +0 -39
- package/src/phone/phoneActor.ts +0 -15
- package/src/phone/phoneManager.test.ts +0 -393
- package/src/phone/phoneManager.ts +0 -458
- package/src/phone/phoneServices.ts +0 -98
- package/src/phone/phoneStateMachine.test.ts +0 -918
- package/src/phone/phoneStateMachine.ts +0 -422
- package/src/phone/types.ts +0 -83
- package/src/recordings/recordingsRepository.test.ts +0 -87
- package/src/recordings/recordingsRepository.ts +0 -48
- package/src/recordings/streamingEvents.ts +0 -10
- package/src/selfie/__mocks__/selfieMocks.ts +0 -26
- package/src/selfie/index.ts +0 -14
- package/src/selfie/selfieActor.ts +0 -17
- package/src/selfie/selfieErrorUtils.test.ts +0 -116
- package/src/selfie/selfieErrorUtils.ts +0 -66
- package/src/selfie/selfieManager.test.ts +0 -297
- package/src/selfie/selfieManager.ts +0 -301
- package/src/selfie/selfieServices.ts +0 -362
- package/src/selfie/selfieStateMachine.test.ts +0 -283
- package/src/selfie/selfieStateMachine.ts +0 -804
- package/src/selfie/selfieUploadService.test.ts +0 -90
- package/src/selfie/selfieUploadService.ts +0 -81
- package/src/selfie/types.ts +0 -103
- package/src/session/index.ts +0 -5
- package/src/session/sessionService.ts +0 -78
- package/src/setup.test.ts +0 -61
- package/src/setup.ts +0 -171
- package/tsconfig.json +0 -13
- package/tsdown.config.ts +0 -22
- package/vitest.config.ts +0 -37
- package/vitest.setup.ts +0 -135
- /package/dist/{Manager-6BwbaI_H.d.ts → Manager-BGfxEmyv.d.ts} +0 -0
- /package/dist/{StateMachine-7c1gcu94.d.ts → StateMachine-DRE1oH2B.d.ts} +0 -0
- /package/dist/{types-tq1ypYSL.d.ts → types-kWlqshfM.d.ts} +0 -0
- /package/dist/{warmup-Dr7OcFND.d.ts → warmup-CEJTfxQr.d.ts} +0 -0
package/vitest.setup.ts
DELETED
|
@@ -1,135 +0,0 @@
|
|
|
1
|
-
// Polyfill ImageData for Node.js test environment
|
|
2
|
-
export {};
|
|
3
|
-
|
|
4
|
-
if (typeof ImageData === 'undefined') {
|
|
5
|
-
globalThis.ImageData = class ImageData {
|
|
6
|
-
data: Uint8ClampedArray;
|
|
7
|
-
width: number;
|
|
8
|
-
height: number;
|
|
9
|
-
|
|
10
|
-
constructor(width: number, height: number);
|
|
11
|
-
constructor(data: Uint8ClampedArray, width: number, height?: number);
|
|
12
|
-
constructor(
|
|
13
|
-
widthOrData: number | Uint8ClampedArray,
|
|
14
|
-
heightOrWidth?: number,
|
|
15
|
-
height?: number,
|
|
16
|
-
) {
|
|
17
|
-
if (typeof widthOrData === 'number') {
|
|
18
|
-
this.width = widthOrData;
|
|
19
|
-
this.height = heightOrWidth ?? widthOrData;
|
|
20
|
-
this.data = new Uint8ClampedArray(this.width * this.height * 4);
|
|
21
|
-
} else {
|
|
22
|
-
this.data = widthOrData;
|
|
23
|
-
this.width = heightOrWidth ?? 0;
|
|
24
|
-
this.height = height ?? 0;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
} as typeof ImageData;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
// Polyfill DOM APIs for Node.js test environment
|
|
31
|
-
if (typeof document === 'undefined') {
|
|
32
|
-
const { JSDOM } = await import('jsdom');
|
|
33
|
-
|
|
34
|
-
const dom = new JSDOM('<!DOCTYPE html><html><body></body></html>', {
|
|
35
|
-
url: 'http://localhost',
|
|
36
|
-
pretendToBeVisual: true,
|
|
37
|
-
resources: 'usable',
|
|
38
|
-
});
|
|
39
|
-
|
|
40
|
-
globalThis.document = dom.window.document;
|
|
41
|
-
globalThis.window = dom.window as unknown as Window & typeof globalThis;
|
|
42
|
-
|
|
43
|
-
// Mock navigator.permissions for testing
|
|
44
|
-
// Use a simple function that can be replaced in tests
|
|
45
|
-
let permissionState: 'granted' | 'denied' | 'prompt' = 'prompt';
|
|
46
|
-
const mockPermissions = {
|
|
47
|
-
query: async () => ({ state: permissionState }),
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
Object.defineProperty(globalThis, 'navigator', {
|
|
51
|
-
value: {
|
|
52
|
-
...dom.window.navigator,
|
|
53
|
-
permissions: mockPermissions,
|
|
54
|
-
},
|
|
55
|
-
writable: true,
|
|
56
|
-
configurable: true,
|
|
57
|
-
});
|
|
58
|
-
|
|
59
|
-
// Export setter for test control
|
|
60
|
-
(
|
|
61
|
-
globalThis as {
|
|
62
|
-
__setPermissionState?: (state: 'granted' | 'denied' | 'prompt') => void;
|
|
63
|
-
}
|
|
64
|
-
).__setPermissionState = (state) => {
|
|
65
|
-
permissionState = state;
|
|
66
|
-
};
|
|
67
|
-
|
|
68
|
-
globalThis.HTMLVideoElement = dom.window.HTMLVideoElement;
|
|
69
|
-
globalThis.HTMLCanvasElement = dom.window.HTMLCanvasElement;
|
|
70
|
-
Object.defineProperty(globalThis.HTMLCanvasElement.prototype, 'getContext', {
|
|
71
|
-
value: () =>
|
|
72
|
-
({
|
|
73
|
-
drawImage: () => {},
|
|
74
|
-
getImageData: () => new ImageData(1, 1),
|
|
75
|
-
putImageData: () => {},
|
|
76
|
-
clearRect: () => {},
|
|
77
|
-
}) as unknown as CanvasRenderingContext2D,
|
|
78
|
-
configurable: true,
|
|
79
|
-
});
|
|
80
|
-
|
|
81
|
-
if (!('HTMLMediaElement' in globalThis)) {
|
|
82
|
-
(
|
|
83
|
-
globalThis as { HTMLMediaElement: typeof dom.window.HTMLMediaElement }
|
|
84
|
-
).HTMLMediaElement = dom.window.HTMLMediaElement;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
Object.defineProperty(globalThis.HTMLMediaElement.prototype, 'play', {
|
|
88
|
-
value: () => Promise.resolve(),
|
|
89
|
-
configurable: true,
|
|
90
|
-
});
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
// Polyfill window for Node.js test environment
|
|
94
|
-
if (typeof window === 'undefined') {
|
|
95
|
-
(globalThis as { window: typeof globalThis }).window =
|
|
96
|
-
globalThis as typeof window;
|
|
97
|
-
(
|
|
98
|
-
globalThis as unknown as { window: { wasmArrayBuffer: null } }
|
|
99
|
-
).window.wasmArrayBuffer = null;
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
// Polyfill MediaStream for Node.js test environment
|
|
103
|
-
if (typeof MediaStream === 'undefined') {
|
|
104
|
-
class MockMediaStream {
|
|
105
|
-
id = 'mock-stream-id';
|
|
106
|
-
active = true;
|
|
107
|
-
getVideoTracks() {
|
|
108
|
-
return [];
|
|
109
|
-
}
|
|
110
|
-
getAudioTracks() {
|
|
111
|
-
return [];
|
|
112
|
-
}
|
|
113
|
-
getTracks() {
|
|
114
|
-
return [];
|
|
115
|
-
}
|
|
116
|
-
getTrackById() {
|
|
117
|
-
return null;
|
|
118
|
-
}
|
|
119
|
-
addTrack() {}
|
|
120
|
-
removeTrack() {}
|
|
121
|
-
clone() {
|
|
122
|
-
return new MockMediaStream();
|
|
123
|
-
}
|
|
124
|
-
addEventListener() {}
|
|
125
|
-
removeEventListener() {}
|
|
126
|
-
dispatchEvent() {
|
|
127
|
-
return true;
|
|
128
|
-
}
|
|
129
|
-
onaddtrack = null;
|
|
130
|
-
onremovetrack = null;
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
(globalThis as unknown as { MediaStream: typeof MediaStream }).MediaStream =
|
|
134
|
-
MockMediaStream as unknown as typeof MediaStream;
|
|
135
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|