@idscan/onboarding 2.7.5 → 2.8.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.
Files changed (63) hide show
  1. package/dist/Wrapper.css +1 -0
  2. package/dist/custom_types/custom.d.ts +20 -0
  3. package/dist/networks/Blur-chunk.js +1 -1
  4. package/dist/networks/Bubble-chunk.js +1 -1
  5. package/dist/networks/Face-chunk.js +1 -1
  6. package/dist/networks/GeneralTypeDetectionYolo-chunk.js +1 -1
  7. package/dist/networks/MRZ-chunk.js +1 -1
  8. package/dist/networks/PDF-chunk.js +1 -1
  9. package/dist/networks/ZXing-chunk.js +1 -1
  10. package/dist/{@types/src → src}/@types/Api/Requests.d.ts +1 -1
  11. package/dist/{@types/src → src}/@types/Api/Responses.d.ts +2 -2
  12. package/dist/{@types/src → src}/@types/Data.d.ts +4 -4
  13. package/dist/{@types/src → src}/@types/Step.d.ts +1 -1
  14. package/dist/{@types/src → src}/Wrapper.d.ts +0 -2
  15. package/dist/{@types/src → src}/config.d.ts +4 -4
  16. package/dist/{@types/src → src}/errors/ConfigError.d.ts +1 -1
  17. package/dist/{@types/src → src}/errors/FaceAuthorizationError.d.ts +1 -1
  18. package/dist/{@types/src → src}/errors/HttpError.d.ts +1 -1
  19. package/dist/{@types/src → src}/errors/NotValidApplicant.d.ts +1 -1
  20. package/dist/{@types/src → src}/errors/RequestTimeoutError.d.ts +1 -1
  21. package/dist/{@types/src → src}/errors/ValidationError.d.ts +1 -1
  22. package/dist/{@types/src → src}/helpers/fingerPrint.d.ts +1 -1
  23. package/dist/{@types/src → src}/helpers/requestModelCheckers.d.ts +2 -2
  24. package/dist/{@types/src → src}/helpers/utils.d.ts +1 -1
  25. package/dist/src/mocks/validation.json.d.ts +9 -0
  26. package/dist/{@types/src → src}/modules/Lib.d.ts +3 -3
  27. package/dist/{@types/src → src}/modules/QRCodeModal.d.ts +1 -1
  28. package/dist/{@types/src → src}/modules/Validation.d.ts +1 -1
  29. package/dist/{@types/src → src}/modules/ValidationModal.d.ts +1 -1
  30. package/dist/vite.config.d.ts +2 -0
  31. package/dist/wrapper.es.js +2 -0
  32. package/dist/wrapper.es.js.map +1 -0
  33. package/dist/wrapper.umd.js +2 -0
  34. package/dist/wrapper.umd.js.map +1 -0
  35. package/package.json +15 -35
  36. package/readme.md +4 -0
  37. package/dist/@types/Fingerprinting/src/@types/Data.d.ts +0 -10
  38. package/dist/@types/Fingerprinting/src/main.d.ts +0 -29
  39. package/dist/@types/Fingerprinting/src/modules/batteryInfo.d.ts +0 -7
  40. package/dist/@types/Fingerprinting/src/modules/browserInfo.d.ts +0 -20
  41. package/dist/@types/Fingerprinting/src/modules/canvasInfo.d.ts +0 -1
  42. package/dist/@types/Fingerprinting/src/modules/connectionInfo.d.ts +0 -9
  43. package/dist/@types/Fingerprinting/src/modules/fontsInfo.d.ts +0 -3
  44. package/dist/@types/Fingerprinting/src/modules/html5Info.d.ts +0 -8
  45. package/dist/@types/Fingerprinting/src/modules/ipWebRTCInfo.d.ts +0 -1
  46. package/dist/@types/Fingerprinting/src/modules/screenInfo.d.ts +0 -14
  47. package/dist/@types/Fingerprinting/src/modules/timeZoneInfo.d.ts +0 -1
  48. package/dist/@types/Fingerprinting/src/modules/videoCodecsInfo.d.ts +0 -1
  49. package/dist/@types/Fingerprinting/src/modules/webGLInfo.d.ts +0 -10
  50. package/dist/@types/Fingerprinting/src/utils/sha256.d.ts +0 -2
  51. package/dist/@types/src/helpers/styleInject.d.ts +0 -1
  52. package/dist/js/wrapper.js +0 -1
  53. /package/dist/{@types/src → src}/@types/IDVCTypes.d.ts +0 -0
  54. /package/dist/{@types/src → src}/@types/enums.d.ts +0 -0
  55. /package/dist/{@types/src → src}/entry.d.ts +0 -0
  56. /package/dist/{@types/src → src}/errors/WrapperError.d.ts +0 -0
  57. /package/dist/{@types/src → src}/helpers/mobileChecker.d.ts +0 -0
  58. /package/dist/{@types/src → src}/helpers/typeGuard.d.ts +0 -0
  59. /package/dist/{@types/src → src}/helpers/validators.d.ts +0 -0
  60. /package/dist/{@types/src → src}/mocks/defaultValues.d.ts +0 -0
  61. /package/dist/{@types/src → src}/modules/Api.d.ts +0 -0
  62. /package/dist/{@types/src → src}/modules/ConsentForm.d.ts +0 -0
  63. /package/dist/{@types/src → src}/modules/Modal.d.ts +0 -0
package/package.json CHANGED
@@ -1,9 +1,11 @@
1
1
  {
2
2
  "name": "@idscan/onboarding",
3
- "version": "2.7.5",
3
+ "version": "2.8.0",
4
4
  "description": "Wrapper of the IDVC library for DIVE Online.",
5
- "main": "dist/js/wrapper.js",
6
- "types": "dist/@types/src/Wrapper.d.ts",
5
+ "main": "dist/wrapper.umd.js",
6
+ "module": "dist/wrapper.es.js",
7
+ "type": "module",
8
+ "types": "dist/src/Wrapper.d.ts",
7
9
  "files": [
8
10
  "dist/**",
9
11
  ".npmignore",
@@ -12,57 +14,35 @@
12
14
  "README.md"
13
15
  ],
14
16
  "scripts": {
15
- "start": "webpack serve --mode development",
16
- "build": "webpack build --mode development --progress --stats-children",
17
- "prod": "webpack build --mode production --progress --stats-children",
17
+ "start": "vite",
18
+ "build": "vite build",
19
+ "prod": "vite build --mode production",
18
20
  "pack": "npm pack",
19
21
  "patch": "npm version patch",
20
22
  "minor": "npm version minor"
21
23
  },
22
24
  "dependencies": {
23
- "@idscan/idvc2": "3.6.0",
24
- "core-js": "^3.30.0",
25
+ "@idscan/idvc2": "3.8.0",
25
26
  "qrcode": "^1.5.1",
26
27
  "regenerator-runtime": "^0.13.11"
27
28
  },
28
29
  "devDependencies": {
29
- "@babel/core": "^7.16.0",
30
- "@babel/eslint-parser": "^7.16.3",
31
- "@babel/plugin-proposal-class-properties": "^7.16.0",
32
- "@babel/plugin-proposal-optional-chaining": "^7.16.0",
33
- "@babel/plugin-proposal-private-methods": "^7.16.0",
34
- "@babel/plugin-syntax-dynamic-import": "^7.8.3",
35
- "@babel/plugin-syntax-optional-chaining": "^7.8.3",
36
- "@babel/plugin-transform-runtime": "^7.16.4",
37
- "@babel/preset-env": "^7.16.4",
38
- "@babel/preset-typescript": "^7.18.6",
39
30
  "@types/qrcode": "^1.5.0",
40
31
  "@typescript-eslint/eslint-plugin": "^5.49.0",
41
32
  "@typescript-eslint/parser": "^5.49.0",
42
- "babel-loader": "^8.2.3",
43
- "babel-plugin-transform-object-hasown": "^1.1.0",
44
- "babel-plugin-transform-runtime": "^6.23.0",
45
- "copy-webpack-plugin": "^9.1.0",
46
- "css-loader": "^6.5.1",
47
33
  "eslint": "^7.25.0",
48
34
  "eslint-config-airbnb": "^18.2.1",
49
35
  "eslint-config-airbnb-base": "^14.2.1",
50
36
  "eslint-config-airbnb-typescript": "^17.0.0",
51
37
  "eslint-plugin-import": "^2.22.1",
52
- "eslint-webpack-plugin": "^3.1.1",
53
- "html-loader": "^3.0.1",
54
- "html-webpack-plugin": "^5.5.0",
55
- "mini-css-extract-plugin": "^2.4.5",
56
- "raw-loader": "^4.0.2",
57
38
  "sass": "^1.43.5",
58
- "sass-loader": "^12.3.0",
59
- "style-loader": "^3.3.1",
60
- "terser-webpack-plugin": "^5.3.10",
61
- "ts-loader": "^9.4.2",
62
39
  "typescript": "^5.0.4",
63
- "webpack": "^5.81.0",
64
- "webpack-cli": "^5.0.1",
65
- "webpack-dev-server": "^4.11.1"
40
+ "vite-plugin-dts": "^4.5.4",
41
+ "vite-plugin-eslint": "^1.8.1",
42
+ "vite-plugin-lib-inject-css": "^2.2.2",
43
+ "vite-plugin-mkcert": "^1.17.9",
44
+ "vite-plugin-static-copy": "^3.1.4",
45
+ "vite-plugin-string": "^1.2.3"
66
46
  },
67
47
  "author": "IDScan.net",
68
48
  "license": "Apache-2.0",
package/readme.md CHANGED
@@ -179,6 +179,10 @@ btn.addEventListener('click', () => {
179
179
 
180
180
  ## Version history
181
181
 
182
+ - **2.8.0**
183
+ - fix: Simplified list handling logic by avoiding enumeration of single-item lists
184
+ - chore: Migrated to Vite to modernize the build process
185
+
182
186
  - **2.7.5**
183
187
  - fix: change default config
184
188
 
@@ -1,10 +0,0 @@
1
- export type SHA256String = string;
2
- export type BASE64String = string;
3
- export interface IFontSize {
4
- width: number;
5
- height: number;
6
- }
7
- export type FontOffsetSizes = Record<string, IFontSize>;
8
- export type Context = WebGLRenderingContext | WebGL2RenderingContext;
9
- export type PrecisionType = 'LOW_FLOAT' | 'MEDIUM_FLOAT' | 'HIGH_FLOAT';
10
- export type PrecisionFormat = Record<PrecisionType, WebGLShaderPrecisionFormat> | Record<string, any>;
@@ -1,29 +0,0 @@
1
- import getBrowserInfo from './modules/browserInfo';
2
- import getScreenResolutionInfo from './modules/screenInfo';
3
- import getBatteryInfo from './modules/batteryInfo';
4
- import getConnectionInfo from './modules/connectionInfo';
5
- import getCanvasInfo from './modules/canvasInfo';
6
- import getFontsInfo from './modules/fontsInfo';
7
- import getIpWebRTCInfo from './modules/ipWebRTCInfo';
8
- import getHTML5Info from './modules/html5Info';
9
- import getVideoCodecsInfo from './modules/videoCodecsInfo';
10
- import getTimeZoneInfo from './modules/timeZoneInfo';
11
- import getWebGLInfo from './modules/webGLInfo';
12
- import decrypt from './utils/sha256';
13
- declare const Fingerprint: {
14
- browserInfo: typeof getBrowserInfo;
15
- screenInfo: typeof getScreenResolutionInfo;
16
- batteryInfo: typeof getBatteryInfo;
17
- connectionInfo: typeof getConnectionInfo;
18
- canvasInfo: typeof getCanvasInfo;
19
- fontsInfo: typeof getFontsInfo;
20
- ipWebRTCInfo: typeof getIpWebRTCInfo;
21
- HTML5Info: typeof getHTML5Info;
22
- videoCodecsInfo: typeof getVideoCodecsInfo;
23
- timeZoneInfo: typeof getTimeZoneInfo;
24
- webGLInfo: typeof getWebGLInfo;
25
- utils: {
26
- sha256: typeof decrypt;
27
- };
28
- };
29
- export default Fingerprint;
@@ -1,7 +0,0 @@
1
- export interface IBattery {
2
- charging: boolean;
3
- chargingTime: number;
4
- dischargingTime: number;
5
- level: number;
6
- }
7
- export default function getBatteryInfo(): Promise<IBattery | Record<string, never>>;
@@ -1,20 +0,0 @@
1
- export interface InternationalizationInfo {
2
- locale: string;
3
- calendar: string;
4
- numberingSystem: string;
5
- weekInfo: string;
6
- collations: string;
7
- }
8
- export interface INavigatorInfo {
9
- userAgent: string;
10
- cookieEnabled: boolean;
11
- platform: string;
12
- hardwareConcurrency: number;
13
- languages: readonly string[];
14
- }
15
- export default function getBrowserInfo(): Promise<{
16
- internationalizationInfo: Record<string, never> | InternationalizationInfo;
17
- navigatorInfo: INavigatorInfo;
18
- availableNavigatorApiInfo: Record<string, never> | Record<string, boolean>;
19
- additionalApiInfo: Record<string, never> | Record<string, boolean>;
20
- }>;
@@ -1 +0,0 @@
1
- export default function getCanvasInfo(): Promise<string>;
@@ -1,9 +0,0 @@
1
- export interface IConnection {
2
- effectiveType: 'slow-2g' | '2g' | '3g' | '4g';
3
- downlink: number;
4
- rtt: number;
5
- saveData: boolean;
6
- type: 'bluetooth' | 'cellular' | 'ethernet' | 'none' | 'wifi' | 'wimax' | 'other' | 'unknown';
7
- downlinkMax: number;
8
- }
9
- export default function getConnectionInfo(): Promise<IConnection | Record<string, never>>;
@@ -1,3 +0,0 @@
1
- export default function getFontsInfo(): Promise<{
2
- availableFontsInfo: boolean[];
3
- }>;
@@ -1,8 +0,0 @@
1
- export default function getHTML5Info(): Promise<{
2
- audioInfo: Record<string, boolean>;
3
- availableAPIInfo: Record<string, boolean>;
4
- inputInfo: {
5
- inputTypes: Record<string, boolean>;
6
- inputAvailableAttributes: Record<string, boolean>;
7
- };
8
- }>;
@@ -1 +0,0 @@
1
- export default function getIp(): Promise<string>;
@@ -1,14 +0,0 @@
1
- export default function getScreenResolutionInfo(): Promise<{
2
- width: number;
3
- height: number;
4
- availWidth: number;
5
- availHeight: number;
6
- colorDepth: number;
7
- pixelDepth: number;
8
- orientationAngle: number;
9
- orientationType: OrientationType;
10
- innerWidth: number;
11
- innerHeight: number;
12
- outerWidth: number;
13
- outerHeight: number;
14
- }>;
@@ -1 +0,0 @@
1
- export default function getTimeZoneInfo(): Promise<string>;
@@ -1 +0,0 @@
1
- export default function getVideoCodecsInfo(): Promise<Record<string, string>>;
@@ -1,10 +0,0 @@
1
- export default function getWebGLInfo(): Promise<{
2
- webGL: {
3
- result: {};
4
- errors: {};
5
- };
6
- webGL2: {
7
- result: {};
8
- errors: {};
9
- };
10
- }>;
@@ -1,2 +0,0 @@
1
- import { SHA256String } from '../@types/Data';
2
- export default function decrypt(text?: string): Promise<SHA256String>;
@@ -1 +0,0 @@
1
- export declare const applyStyles: (scssString: string) => void;