auth-vir 1.3.2 → 2.0.1

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 (59) hide show
  1. package/README.md +27 -18
  2. package/dist/auth-client/backend-auth.client.d.ts +177 -0
  3. package/dist/auth-client/backend-auth.client.js +232 -0
  4. package/dist/auth-client/frontend-auth.client.d.ts +65 -0
  5. package/dist/auth-client/frontend-auth.client.js +108 -0
  6. package/dist/auth.d.ts +32 -46
  7. package/dist/auth.js +36 -36
  8. package/dist/cookie.d.ts +15 -4
  9. package/dist/cookie.js +16 -4
  10. package/dist/csrf-token.d.ts +113 -3
  11. package/dist/csrf-token.js +101 -5
  12. package/dist/generated/browser.d.ts +9 -0
  13. package/dist/generated/browser.js +16 -0
  14. package/dist/generated/client.d.ts +26 -0
  15. package/dist/generated/client.js +31 -0
  16. package/dist/generated/commonInputTypes.d.ts +122 -0
  17. package/dist/generated/commonInputTypes.js +1 -0
  18. package/dist/generated/enums.d.ts +1 -0
  19. package/dist/generated/enums.js +9 -0
  20. package/dist/generated/internal/class.d.ts +126 -0
  21. package/dist/generated/internal/class.js +84 -0
  22. package/dist/generated/internal/prismaNamespace.d.ts +544 -0
  23. package/dist/generated/internal/prismaNamespace.js +101 -0
  24. package/dist/generated/internal/prismaNamespaceBrowser.d.ts +75 -0
  25. package/dist/generated/internal/prismaNamespaceBrowser.js +69 -0
  26. package/dist/generated/models/User.d.ts +983 -0
  27. package/dist/generated/models/User.js +1 -0
  28. package/dist/generated/models.d.ts +2 -0
  29. package/dist/generated/models.js +1 -0
  30. package/dist/generated/shapes.gen.d.ts +8 -0
  31. package/dist/generated/shapes.gen.js +11 -0
  32. package/dist/headers.d.ts +20 -0
  33. package/dist/headers.js +33 -0
  34. package/dist/index.d.ts +3 -0
  35. package/dist/index.js +3 -0
  36. package/dist/jwt/jwt.d.ts +11 -2
  37. package/dist/jwt/jwt.js +14 -3
  38. package/dist/jwt/user-jwt.d.ts +8 -8
  39. package/dist/jwt/user-jwt.js +12 -9
  40. package/package.json +12 -7
  41. package/src/auth-client/backend-auth.client.ts +500 -0
  42. package/src/auth-client/frontend-auth.client.ts +183 -0
  43. package/src/auth.ts +99 -77
  44. package/src/cookie.ts +20 -8
  45. package/src/csrf-token.ts +196 -5
  46. package/src/generated/browser.ts +23 -0
  47. package/src/generated/client.ts +47 -0
  48. package/src/generated/commonInputTypes.ts +147 -0
  49. package/src/generated/enums.ts +14 -0
  50. package/src/generated/internal/class.ts +236 -0
  51. package/src/generated/internal/prismaNamespace.ts +761 -0
  52. package/src/generated/internal/prismaNamespaceBrowser.ts +102 -0
  53. package/src/generated/models/User.ts +1135 -0
  54. package/src/generated/models.ts +11 -0
  55. package/src/generated/shapes.gen.ts +15 -0
  56. package/src/headers.ts +35 -0
  57. package/src/index.ts +3 -0
  58. package/src/jwt/jwt.ts +34 -5
  59. package/src/jwt/user-jwt.ts +21 -12
@@ -0,0 +1,75 @@
1
+ import * as runtime from "@prisma/client/runtime/index-browser";
2
+ export type * from '../models.js';
3
+ export type * from './prismaNamespace.js';
4
+ export declare const Decimal: typeof runtime.Decimal;
5
+ export declare const NullTypes: {
6
+ DbNull: (new (secret: never) => typeof runtime.objectEnumValues.instances.DbNull);
7
+ JsonNull: (new (secret: never) => typeof runtime.objectEnumValues.instances.JsonNull);
8
+ AnyNull: (new (secret: never) => typeof runtime.objectEnumValues.instances.AnyNull);
9
+ };
10
+ /**
11
+ * Helper for filtering JSON entries that have `null` on the database (empty on the db)
12
+ *
13
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
14
+ */
15
+ export declare const DbNull: {
16
+ "__#private@#private": any;
17
+ _getNamespace(): string;
18
+ _getName(): string;
19
+ toString(): string;
20
+ };
21
+ /**
22
+ * Helper for filtering JSON entries that have JSON `null` values (not empty on the db)
23
+ *
24
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
25
+ */
26
+ export declare const JsonNull: {
27
+ "__#private@#private": any;
28
+ _getNamespace(): string;
29
+ _getName(): string;
30
+ toString(): string;
31
+ };
32
+ /**
33
+ * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull`
34
+ *
35
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
36
+ */
37
+ export declare const AnyNull: {
38
+ "__#private@#private": any;
39
+ _getNamespace(): string;
40
+ _getName(): string;
41
+ toString(): string;
42
+ };
43
+ export declare const ModelName: {
44
+ readonly User: "User";
45
+ };
46
+ export type ModelName = (typeof ModelName)[keyof typeof ModelName];
47
+ export declare const TransactionIsolationLevel: {
48
+ readonly ReadUncommitted: "ReadUncommitted";
49
+ readonly ReadCommitted: "ReadCommitted";
50
+ readonly RepeatableRead: "RepeatableRead";
51
+ readonly Serializable: "Serializable";
52
+ };
53
+ export type TransactionIsolationLevel = (typeof TransactionIsolationLevel)[keyof typeof TransactionIsolationLevel];
54
+ export declare const UserScalarFieldEnum: {
55
+ readonly id: "id";
56
+ readonly createdAt: "createdAt";
57
+ readonly updatedAt: "updatedAt";
58
+ readonly name: "name";
59
+ };
60
+ export type UserScalarFieldEnum = (typeof UserScalarFieldEnum)[keyof typeof UserScalarFieldEnum];
61
+ export declare const RelationLoadStrategy: {
62
+ readonly query: "query";
63
+ readonly join: "join";
64
+ };
65
+ export type RelationLoadStrategy = (typeof RelationLoadStrategy)[keyof typeof RelationLoadStrategy];
66
+ export declare const SortOrder: {
67
+ readonly asc: "asc";
68
+ readonly desc: "desc";
69
+ };
70
+ export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder];
71
+ export declare const QueryMode: {
72
+ readonly default: "default";
73
+ readonly insensitive: "insensitive";
74
+ };
75
+ export type QueryMode = (typeof QueryMode)[keyof typeof QueryMode];
@@ -0,0 +1,69 @@
1
+ /* !!! This is code generated by Prisma. Do not edit directly. !!! */
2
+ /* eslint-disable */
3
+ // @ts-nocheck
4
+ /*
5
+ * WARNING: This is an internal file that is subject to change!
6
+ *
7
+ * 🛑 Under no circumstances should you import this file directly! 🛑
8
+ *
9
+ * All exports from this file are wrapped under a `Prisma` namespace object in the browser.ts file.
10
+ * While this enables partial backward compatibility, it is not part of the stable public API.
11
+ *
12
+ * If you are looking for your Models, Enums, and Input Types, please import them from the respective
13
+ * model files in the `model` directory!
14
+ */
15
+ import * as runtime from "@prisma/client/runtime/index-browser";
16
+ export const Decimal = runtime.Decimal;
17
+ export const NullTypes = {
18
+ DbNull: runtime.objectEnumValues.classes.DbNull,
19
+ JsonNull: runtime.objectEnumValues.classes.JsonNull,
20
+ AnyNull: runtime.objectEnumValues.classes.AnyNull,
21
+ };
22
+ /**
23
+ * Helper for filtering JSON entries that have `null` on the database (empty on the db)
24
+ *
25
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
26
+ */
27
+ export const DbNull = runtime.objectEnumValues.instances.DbNull;
28
+ /**
29
+ * Helper for filtering JSON entries that have JSON `null` values (not empty on the db)
30
+ *
31
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
32
+ */
33
+ export const JsonNull = runtime.objectEnumValues.instances.JsonNull;
34
+ /**
35
+ * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull`
36
+ *
37
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
38
+ */
39
+ export const AnyNull = runtime.objectEnumValues.instances.AnyNull;
40
+ export const ModelName = {
41
+ User: 'User'
42
+ };
43
+ /*
44
+ * Enums
45
+ */
46
+ export const TransactionIsolationLevel = runtime.makeStrictEnum({
47
+ ReadUncommitted: 'ReadUncommitted',
48
+ ReadCommitted: 'ReadCommitted',
49
+ RepeatableRead: 'RepeatableRead',
50
+ Serializable: 'Serializable'
51
+ });
52
+ export const UserScalarFieldEnum = {
53
+ id: 'id',
54
+ createdAt: 'createdAt',
55
+ updatedAt: 'updatedAt',
56
+ name: 'name'
57
+ };
58
+ export const RelationLoadStrategy = {
59
+ query: 'query',
60
+ join: 'join'
61
+ };
62
+ export const SortOrder = {
63
+ asc: 'asc',
64
+ desc: 'desc'
65
+ };
66
+ export const QueryMode = {
67
+ default: 'default',
68
+ insensitive: 'insensitive'
69
+ };