@aeriajs/builtins 0.0.217 → 0.0.219
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/collections/user/activate.d.ts +10 -13
- package/dist/collections/user/activate.js +12 -9
- package/dist/collections/user/activate.mjs +17 -13
- package/dist/collections/user/createAccount.d.ts +5 -0
- package/dist/collections/user/description.d.ts +5 -0
- package/dist/collections/user/description.js +5 -0
- package/dist/collections/user/description.mjs +5 -0
- package/dist/collections/user/getActivationLink.d.ts +5 -1
- package/dist/collections/user/getActivationLink.js +13 -4
- package/dist/collections/user/getActivationLink.mjs +13 -4
- package/dist/collections/user/getCurrentUser.d.ts +5 -0
- package/dist/collections/user/getInfo.d.ts +5 -3
- package/dist/collections/user/getInfo.js +6 -12
- package/dist/collections/user/getInfo.mjs +8 -14
- package/dist/collections/user/getRedefinePasswordLink.d.ts +59 -0
- package/dist/collections/user/getRedefinePasswordLink.js +31 -0
- package/dist/collections/user/getRedefinePasswordLink.mjs +28 -0
- package/dist/collections/user/index.d.ts +127 -3
- package/dist/collections/user/index.js +13 -1
- package/dist/collections/user/index.mjs +15 -3
- package/dist/collections/user/redefinePassword.d.ts +41 -0
- package/dist/collections/user/redefinePassword.js +70 -0
- package/dist/collections/user/redefinePassword.mjs +69 -0
- package/dist/index.d.ts +127 -3
- package/package.json +18 -18
package/dist/index.d.ts
CHANGED
|
@@ -545,6 +545,11 @@ export declare const collections: {
|
|
|
545
545
|
readonly fetchItem: true;
|
|
546
546
|
};
|
|
547
547
|
};
|
|
548
|
+
readonly copyRedefinePasswordLink: {
|
|
549
|
+
readonly label: "copy_redefine_password_link";
|
|
550
|
+
readonly icon: "link";
|
|
551
|
+
readonly translate: true;
|
|
552
|
+
};
|
|
548
553
|
readonly copyActivationLink: {
|
|
549
554
|
readonly label: "copy_activation_link";
|
|
550
555
|
readonly icon: "link";
|
|
@@ -646,6 +651,11 @@ export declare const collections: {
|
|
|
646
651
|
readonly fetchItem: true;
|
|
647
652
|
};
|
|
648
653
|
};
|
|
654
|
+
readonly copyRedefinePasswordLink: {
|
|
655
|
+
readonly label: "copy_redefine_password_link";
|
|
656
|
+
readonly icon: "link";
|
|
657
|
+
readonly translate: true;
|
|
658
|
+
};
|
|
649
659
|
readonly copyActivationLink: {
|
|
650
660
|
readonly label: "copy_activation_link";
|
|
651
661
|
readonly icon: "link";
|
|
@@ -744,7 +754,9 @@ export declare const collections: {
|
|
|
744
754
|
httpStatus: import("@aeriajs/types").HTTPStatus.Unauthorized;
|
|
745
755
|
}>>;
|
|
746
756
|
readonly activate: (payload: {
|
|
747
|
-
password
|
|
757
|
+
password?: string;
|
|
758
|
+
userId?: string;
|
|
759
|
+
token?: string;
|
|
748
760
|
}, context: Omit<import("@aeriajs/types").Context, "token">) => Promise<import("@aeriajs/types").GenericResponse | import("@aeriajs/types").Result.Error<{
|
|
749
761
|
readonly code: import("./collections/user/activate.js").ActivationError.InvalidLink;
|
|
750
762
|
} & {
|
|
@@ -757,6 +769,10 @@ export declare const collections: {
|
|
|
757
769
|
readonly code: import("./collections/user/activate.js").ActivationError.AlreadyActiveUser;
|
|
758
770
|
} & {
|
|
759
771
|
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
772
|
+
}> | import("@aeriajs/types").Result.Error<{
|
|
773
|
+
readonly code: import("./collections/user/activate.js").ActivationError.InvalidToken;
|
|
774
|
+
} & {
|
|
775
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.Unauthorized;
|
|
760
776
|
}> | import("@aeriajs/types").Result.Error<{
|
|
761
777
|
readonly code: import("@aeriajs/types").ACError.MalformedInput;
|
|
762
778
|
} & {
|
|
@@ -849,6 +865,11 @@ export declare const collections: {
|
|
|
849
865
|
readonly fetchItem: true;
|
|
850
866
|
};
|
|
851
867
|
};
|
|
868
|
+
readonly copyRedefinePasswordLink: {
|
|
869
|
+
readonly label: "copy_redefine_password_link";
|
|
870
|
+
readonly icon: "link";
|
|
871
|
+
readonly translate: true;
|
|
872
|
+
};
|
|
852
873
|
readonly copyActivationLink: {
|
|
853
874
|
readonly label: "copy_activation_link";
|
|
854
875
|
readonly icon: "link";
|
|
@@ -958,6 +979,11 @@ export declare const collections: {
|
|
|
958
979
|
readonly fetchItem: true;
|
|
959
980
|
};
|
|
960
981
|
};
|
|
982
|
+
readonly copyRedefinePasswordLink: {
|
|
983
|
+
readonly label: "copy_redefine_password_link";
|
|
984
|
+
readonly icon: "link";
|
|
985
|
+
readonly translate: true;
|
|
986
|
+
};
|
|
961
987
|
readonly copyActivationLink: {
|
|
962
988
|
readonly label: "copy_activation_link";
|
|
963
989
|
readonly icon: "link";
|
|
@@ -990,15 +1016,16 @@ export declare const collections: {
|
|
|
990
1016
|
} & {
|
|
991
1017
|
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
992
1018
|
}> | import("@aeriajs/types").Result.Error<{
|
|
993
|
-
readonly code: import("./collections/user/getInfo.js").ActivationError.
|
|
1019
|
+
readonly code: import("./collections/user/getInfo.js").ActivationError.InvalidToken;
|
|
994
1020
|
} & {
|
|
995
|
-
httpStatus: import("@aeriajs/types").HTTPStatus.
|
|
1021
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.Unauthorized;
|
|
996
1022
|
}> | {
|
|
997
1023
|
readonly _tag: "Result";
|
|
998
1024
|
readonly error: undefined;
|
|
999
1025
|
readonly result: {
|
|
1000
1026
|
readonly name: string;
|
|
1001
1027
|
readonly email: string;
|
|
1028
|
+
readonly active: boolean | undefined;
|
|
1002
1029
|
};
|
|
1003
1030
|
}>;
|
|
1004
1031
|
readonly getCurrentUser: (payload: undefined, context: Omit<import("@aeriajs/types").Context, "token">) => Promise<{
|
|
@@ -1095,6 +1122,11 @@ export declare const collections: {
|
|
|
1095
1122
|
readonly fetchItem: true;
|
|
1096
1123
|
};
|
|
1097
1124
|
};
|
|
1125
|
+
readonly copyRedefinePasswordLink: {
|
|
1126
|
+
readonly label: "copy_redefine_password_link";
|
|
1127
|
+
readonly icon: "link";
|
|
1128
|
+
readonly translate: true;
|
|
1129
|
+
};
|
|
1098
1130
|
readonly copyActivationLink: {
|
|
1099
1131
|
readonly label: "copy_activation_link";
|
|
1100
1132
|
readonly icon: "link";
|
|
@@ -1161,6 +1193,10 @@ export declare const collections: {
|
|
|
1161
1193
|
}, never>>;
|
|
1162
1194
|
readonly result: undefined;
|
|
1163
1195
|
} | import("@aeriajs/types").Result.Error<{
|
|
1196
|
+
readonly code: import("./collections/user/activate.js").ActivationError.InvalidLink;
|
|
1197
|
+
} & {
|
|
1198
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.BadRequest;
|
|
1199
|
+
}> | import("@aeriajs/types").Result.Error<{
|
|
1164
1200
|
readonly code: import("./collections/user/activate.js").ActivationError.AlreadyActiveUser;
|
|
1165
1201
|
} & {
|
|
1166
1202
|
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
@@ -1171,6 +1207,92 @@ export declare const collections: {
|
|
|
1171
1207
|
readonly url: string;
|
|
1172
1208
|
};
|
|
1173
1209
|
}>;
|
|
1210
|
+
readonly getRedefinePasswordLink: (payload: {
|
|
1211
|
+
userId: import("mongodb").ObjectId | string;
|
|
1212
|
+
}, context: Omit<import("@aeriajs/types").Context, "token">) => Promise<{
|
|
1213
|
+
readonly _tag: "Error";
|
|
1214
|
+
readonly error: Pick<{} & Omit<Readonly<import("@aeriajs/types").FilterReadonlyProperties<{
|
|
1215
|
+
readonly httpStatus: {
|
|
1216
|
+
readonly enum: [import("@aeriajs/types").HTTPStatus.Forbidden, import("@aeriajs/types").HTTPStatus.NotFound, import("@aeriajs/types").HTTPStatus.BadRequest];
|
|
1217
|
+
};
|
|
1218
|
+
readonly code: {
|
|
1219
|
+
readonly enum: [import("@aeriajs/types").ACError.ResourceNotFound, import("@aeriajs/types").ACError.OwnershipError, import("@aeriajs/types").ACError.InsecureOperator, import("@aeriajs/types").ACError.MalformedInput];
|
|
1220
|
+
};
|
|
1221
|
+
readonly message: {
|
|
1222
|
+
readonly type: "string";
|
|
1223
|
+
};
|
|
1224
|
+
readonly details: {
|
|
1225
|
+
readonly type: "object";
|
|
1226
|
+
readonly additionalProperties: true;
|
|
1227
|
+
};
|
|
1228
|
+
}>> & {
|
|
1229
|
+
code: import("@aeriajs/types").ACError.OwnershipError | import("@aeriajs/types").ACError.ResourceNotFound | import("@aeriajs/types").ACError.InsecureOperator | import("@aeriajs/types").ACError.MalformedInput;
|
|
1230
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.BadRequest | import("@aeriajs/types").HTTPStatus.Forbidden | import("@aeriajs/types").HTTPStatus.NotFound;
|
|
1231
|
+
message: string;
|
|
1232
|
+
details: any;
|
|
1233
|
+
}, never>, "code" | "httpStatus"> & Partial<{} & Omit<Readonly<import("@aeriajs/types").FilterReadonlyProperties<{
|
|
1234
|
+
readonly httpStatus: {
|
|
1235
|
+
readonly enum: [import("@aeriajs/types").HTTPStatus.Forbidden, import("@aeriajs/types").HTTPStatus.NotFound, import("@aeriajs/types").HTTPStatus.BadRequest];
|
|
1236
|
+
};
|
|
1237
|
+
readonly code: {
|
|
1238
|
+
readonly enum: [import("@aeriajs/types").ACError.ResourceNotFound, import("@aeriajs/types").ACError.OwnershipError, import("@aeriajs/types").ACError.InsecureOperator, import("@aeriajs/types").ACError.MalformedInput];
|
|
1239
|
+
};
|
|
1240
|
+
readonly message: {
|
|
1241
|
+
readonly type: "string";
|
|
1242
|
+
};
|
|
1243
|
+
readonly details: {
|
|
1244
|
+
readonly type: "object";
|
|
1245
|
+
readonly additionalProperties: true;
|
|
1246
|
+
};
|
|
1247
|
+
}>> & {
|
|
1248
|
+
code: import("@aeriajs/types").ACError.OwnershipError | import("@aeriajs/types").ACError.ResourceNotFound | import("@aeriajs/types").ACError.InsecureOperator | import("@aeriajs/types").ACError.MalformedInput;
|
|
1249
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.BadRequest | import("@aeriajs/types").HTTPStatus.Forbidden | import("@aeriajs/types").HTTPStatus.NotFound;
|
|
1250
|
+
message: string;
|
|
1251
|
+
details: any;
|
|
1252
|
+
}, never>>;
|
|
1253
|
+
readonly result: undefined;
|
|
1254
|
+
} | import("@aeriajs/types").Result.Error<{
|
|
1255
|
+
readonly code: import("./collections/user/redefinePassword.js").ActivationError.UserNotActive;
|
|
1256
|
+
} & {
|
|
1257
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
1258
|
+
}> | {
|
|
1259
|
+
readonly _tag: "Result";
|
|
1260
|
+
readonly error: undefined;
|
|
1261
|
+
readonly result: {
|
|
1262
|
+
readonly url: string;
|
|
1263
|
+
};
|
|
1264
|
+
}>;
|
|
1265
|
+
readonly redefinePassword: (payload: {
|
|
1266
|
+
password?: string;
|
|
1267
|
+
userId?: string;
|
|
1268
|
+
token?: string;
|
|
1269
|
+
}, context: Omit<import("@aeriajs/types").Context, "token">) => Promise<import("@aeriajs/types").Result.Error<{
|
|
1270
|
+
readonly code: import("./collections/user/redefinePassword.js").ActivationError.InvalidLink;
|
|
1271
|
+
} & {
|
|
1272
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
1273
|
+
}> | import("@aeriajs/types").Result.Error<{
|
|
1274
|
+
readonly code: import("./collections/user/redefinePassword.js").ActivationError.UserNotFound;
|
|
1275
|
+
} & {
|
|
1276
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.NotFound;
|
|
1277
|
+
}> | import("@aeriajs/types").Result.Error<{
|
|
1278
|
+
readonly code: import("./collections/user/redefinePassword.js").ActivationError.UserNotActive;
|
|
1279
|
+
} & {
|
|
1280
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.Forbidden;
|
|
1281
|
+
}> | import("@aeriajs/types").Result.Error<{
|
|
1282
|
+
readonly code: import("./collections/user/redefinePassword.js").ActivationError.InvalidToken;
|
|
1283
|
+
} & {
|
|
1284
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.Unauthorized;
|
|
1285
|
+
}> | import("@aeriajs/types").Result.Error<{
|
|
1286
|
+
readonly code: import("@aeriajs/types").ACError.MalformedInput;
|
|
1287
|
+
} & {
|
|
1288
|
+
httpStatus: import("@aeriajs/types").HTTPStatus.UnprocessableContent;
|
|
1289
|
+
}> | {
|
|
1290
|
+
readonly _tag: "Result";
|
|
1291
|
+
readonly error: undefined;
|
|
1292
|
+
readonly result: {
|
|
1293
|
+
readonly userId: import("mongodb").ObjectId;
|
|
1294
|
+
};
|
|
1295
|
+
}>;
|
|
1174
1296
|
};
|
|
1175
1297
|
contracts: {
|
|
1176
1298
|
readonly get?: import("@aeriajs/types").Contract | undefined;
|
|
@@ -1185,6 +1307,8 @@ export declare const collections: {
|
|
|
1185
1307
|
readonly getInfo?: import("@aeriajs/types").Contract | undefined;
|
|
1186
1308
|
readonly getCurrentUser?: import("@aeriajs/types").Contract | undefined;
|
|
1187
1309
|
readonly getActivationLink?: import("@aeriajs/types").Contract | undefined;
|
|
1310
|
+
readonly getRedefinePasswordLink?: import("@aeriajs/types").Contract | undefined;
|
|
1311
|
+
readonly redefinePassword?: import("@aeriajs/types").Contract | undefined;
|
|
1188
1312
|
};
|
|
1189
1313
|
};
|
|
1190
1314
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aeriajs/builtins",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.219",
|
|
4
4
|
"description": "## Installation",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -8,6 +8,16 @@
|
|
|
8
8
|
"publishConfig": {
|
|
9
9
|
"access": "public"
|
|
10
10
|
},
|
|
11
|
+
"scripts": {
|
|
12
|
+
"test": "echo skipping",
|
|
13
|
+
"lint": "eslint .",
|
|
14
|
+
"lint:fix": "eslint . --fix",
|
|
15
|
+
"build": "pnpm build:cjs && pnpm build:esm",
|
|
16
|
+
"build:cjs": "tsc",
|
|
17
|
+
"build:esm": "esbuild './src/**/*.ts' --outdir=dist --out-extension:.js=.mjs && pnpm build:esm-transform",
|
|
18
|
+
"build:esm-transform": "pnpm -w esm-transform $PWD/dist",
|
|
19
|
+
"write-icons": "pnpm -w write-icons"
|
|
20
|
+
},
|
|
11
21
|
"keywords": [],
|
|
12
22
|
"author": "",
|
|
13
23
|
"license": "ISC",
|
|
@@ -36,8 +46,8 @@
|
|
|
36
46
|
"bcrypt": "^5.1.1"
|
|
37
47
|
},
|
|
38
48
|
"devDependencies": {
|
|
39
|
-
"@aeriajs/core": "link:../core",
|
|
40
49
|
"@aeriajs/common": "link:../common",
|
|
50
|
+
"@aeriajs/core": "link:../core",
|
|
41
51
|
"@aeriajs/entrypoint": "link:../entrypoint",
|
|
42
52
|
"@aeriajs/types": "link:../types",
|
|
43
53
|
"@aeriajs/validation": "link:../validation",
|
|
@@ -45,20 +55,10 @@
|
|
|
45
55
|
"mongodb": "^6.5.0"
|
|
46
56
|
},
|
|
47
57
|
"peerDependencies": {
|
|
48
|
-
"@aeriajs/core": "^0.0.
|
|
49
|
-
"@aeriajs/common": "^0.0.
|
|
50
|
-
"@aeriajs/entrypoint": "^0.0.
|
|
51
|
-
"@aeriajs/types": "^0.0.
|
|
52
|
-
"@aeriajs/validation": "^0.0.
|
|
53
|
-
},
|
|
54
|
-
"scripts": {
|
|
55
|
-
"test": "echo skipping",
|
|
56
|
-
"lint": "eslint .",
|
|
57
|
-
"lint:fix": "eslint . --fix",
|
|
58
|
-
"build": "pnpm build:cjs && pnpm build:esm",
|
|
59
|
-
"build:cjs": "tsc",
|
|
60
|
-
"build:esm": "esbuild './src/**/*.ts' --outdir=dist --out-extension:.js=.mjs && pnpm build:esm-transform",
|
|
61
|
-
"build:esm-transform": "pnpm -w esm-transform $PWD/dist",
|
|
62
|
-
"write-icons": "pnpm -w write-icons"
|
|
58
|
+
"@aeriajs/core": "^0.0.219",
|
|
59
|
+
"@aeriajs/common": "^0.0.127",
|
|
60
|
+
"@aeriajs/entrypoint": "^0.0.130",
|
|
61
|
+
"@aeriajs/types": "^0.0.109",
|
|
62
|
+
"@aeriajs/validation": "^0.0.142"
|
|
63
63
|
}
|
|
64
|
-
}
|
|
64
|
+
}
|