@vroskus/library-social 1.0.23 → 1.0.26
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/index.d.ts +2 -2
- package/dist/index.js +6 -6
- package/package.json +16 -15
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { AxiosInstance } from 'axios';
|
|
2
2
|
import type { $SocialPayload, $Config as Config } from './types';
|
|
3
3
|
export * from './types';
|
|
4
4
|
declare class Social<C extends Config> {
|
|
5
5
|
#private;
|
|
6
|
-
connection:
|
|
6
|
+
connection: AxiosInstance;
|
|
7
7
|
constructor({ mock, timeout, }: C);
|
|
8
8
|
authenticateFacebook(token: string): Promise<$SocialPayload>;
|
|
9
9
|
authenticateGoogle(token: string): Promise<$SocialPayload>;
|
package/dist/index.js
CHANGED
|
@@ -37,12 +37,12 @@ const axios_mock_adapter_1 = __importDefault(require("axios-mock-adapter"));
|
|
|
37
37
|
const library_validator_1 = require("@vroskus/library-validator");
|
|
38
38
|
const mocks_1 = require("./mocks");
|
|
39
39
|
__exportStar(require("./types"), exports);
|
|
40
|
-
const socialPayloadSchema =
|
|
41
|
-
Email: library_validator_1.
|
|
42
|
-
EmailVerified: library_validator_1.
|
|
43
|
-
Name: library_validator_1.
|
|
44
|
-
PictureUrl: library_validator_1.
|
|
45
|
-
Uid: library_validator_1.
|
|
40
|
+
const socialPayloadSchema = library_validator_1.z.object({
|
|
41
|
+
Email: library_validator_1.z.string(),
|
|
42
|
+
EmailVerified: library_validator_1.z.boolean(),
|
|
43
|
+
Name: library_validator_1.z.string(),
|
|
44
|
+
PictureUrl: library_validator_1.z.string().nullable(),
|
|
45
|
+
Uid: library_validator_1.z.string(),
|
|
46
46
|
});
|
|
47
47
|
const successStatus = 200;
|
|
48
48
|
class Social {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vroskus/library-social",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.26",
|
|
4
4
|
"description": "Social",
|
|
5
5
|
"author": "Vilius Roškus <vilius@regattas.eu>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -15,29 +15,30 @@
|
|
|
15
15
|
],
|
|
16
16
|
"scripts": {
|
|
17
17
|
"build": "tsc",
|
|
18
|
-
"test": "npm run test:eslint && npm run test:e2e",
|
|
18
|
+
"test": "npm run test:eslint && npm run test:type && npm run test:e2e",
|
|
19
19
|
"test:eslint": "eslint src test --fix",
|
|
20
|
+
"test:type": "tsc",
|
|
20
21
|
"test:e2e": "npm run test:e2e:run && npm run test:e2e:post",
|
|
21
22
|
"test:e2e:run": "jest --ci --colors",
|
|
22
23
|
"test:e2e:post": "jest-coverage-thresholds-bumper"
|
|
23
24
|
},
|
|
24
25
|
"dependencies": {
|
|
25
|
-
"@vroskus/library-validator": "^
|
|
26
|
-
"axios": "^1.
|
|
26
|
+
"@vroskus/library-validator": "^2.0.1",
|
|
27
|
+
"axios": "^1.13.2",
|
|
27
28
|
"axios-mock-adapter": "^2.1.0"
|
|
28
29
|
},
|
|
29
30
|
"devDependencies": {
|
|
30
31
|
"@types/axios": "^0.14.4",
|
|
31
|
-
"@types/jest": "^
|
|
32
|
-
"@types/node": "^
|
|
33
|
-
"@
|
|
34
|
-
"
|
|
35
|
-
"express": "^5.1
|
|
36
|
-
"jest": "^
|
|
32
|
+
"@types/jest": "^30.0.0",
|
|
33
|
+
"@types/node": "^25.0.9",
|
|
34
|
+
"@types/supertest": "^6.0.3",
|
|
35
|
+
"@vroskus/eslint-config": "^1.0.30",
|
|
36
|
+
"express": "^5.2.1",
|
|
37
|
+
"jest": "^30.2.0",
|
|
37
38
|
"jest-coverage-thresholds-bumper": "^1.1.0",
|
|
38
|
-
"supertest": "^7.
|
|
39
|
-
"ts-jest": "^29.
|
|
40
|
-
"typescript": "^5.
|
|
39
|
+
"supertest": "^7.2.2",
|
|
40
|
+
"ts-jest": "^29.4.6",
|
|
41
|
+
"typescript": "^5.9.3"
|
|
41
42
|
},
|
|
42
43
|
"jest": {
|
|
43
44
|
"preset": "ts-jest",
|
|
@@ -53,9 +54,9 @@
|
|
|
53
54
|
"coverageThreshold": {
|
|
54
55
|
"global": {
|
|
55
56
|
"branches": 50.76,
|
|
56
|
-
"functions":
|
|
57
|
+
"functions": 76.19,
|
|
57
58
|
"lines": 88.23,
|
|
58
|
-
"statements": 76.
|
|
59
|
+
"statements": 76.25
|
|
59
60
|
}
|
|
60
61
|
}
|
|
61
62
|
}
|