@levo-so/core 0.1.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.
- package/dist/LevoClient.d.ts +23 -0
- package/dist/chunk-QJSKNLTV.js +9 -0
- package/dist/chunk-ZLLCLSGE.js +8 -0
- package/dist/constants/collection/defaultByKind.d.ts +3 -0
- package/dist/constants/collection/defaultByKind.d.ts.map +1 -0
- package/dist/constants/collection/fieldInterfaceFormat.d.ts +3 -0
- package/dist/constants/collection/fieldInterfaceFormat.d.ts.map +1 -0
- package/dist/constants/collection/fieldInterfaces.d.ts +3 -0
- package/dist/constants/collection/fieldInterfaces.d.ts.map +1 -0
- package/dist/constants/collection/fieldKind.d.ts +25 -0
- package/dist/constants/collection/fieldKind.d.ts.map +1 -0
- package/dist/constants/index.d.ts +7 -0
- package/dist/constants/index.d.ts.map +1 -0
- package/dist/constants/media.d.ts +3 -0
- package/dist/constants/media.d.ts.map +1 -0
- package/dist/constants/oauthProvider.d.ts +3 -0
- package/dist/constants/oauthProvider.d.ts.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.js +261 -0
- package/dist/plugins/LevoAudience.d.ts +21 -0
- package/dist/plugins/LevoAudience.d.ts.map +1 -0
- package/dist/plugins/LevoAudience.js +362 -0
- package/dist/plugins/LevoBlog.d.ts +8 -0
- package/dist/plugins/LevoBlog.d.ts.map +1 -0
- package/dist/plugins/LevoBlog.js +21 -0
- package/dist/plugins/LevoCollection.d.ts +24 -0
- package/dist/plugins/LevoCollection.d.ts.map +1 -0
- package/dist/plugins/LevoCollection.js +49 -0
- package/dist/plugins/LevoLogger.d.ts +8 -0
- package/dist/plugins/LevoLogger.d.ts.map +1 -0
- package/dist/plugins/LevoLogger.js +23 -0
- package/dist/plugins/LevoMedia.d.ts +9 -0
- package/dist/plugins/LevoMedia.d.ts.map +1 -0
- package/dist/plugins/LevoMedia.js +13 -0
- package/dist/plugins/LevoMembership.d.ts +40 -0
- package/dist/plugins/LevoMembership.d.ts.map +1 -0
- package/dist/plugins/LevoMembership.js +167 -0
- package/dist/plugins/LevoPlugin.d.ts +6 -0
- package/dist/plugins/LevoPlugin.d.ts.map +1 -0
- package/dist/plugins/LevoPlugin.js +1 -0
- package/dist/types/audience.d.ts +35 -0
- package/dist/types/audience.d.ts.map +1 -0
- package/dist/types/blog/author.d.ts +30 -0
- package/dist/types/blog/author.d.ts.map +1 -0
- package/dist/types/blog/blogClient.d.ts +51 -0
- package/dist/types/blog/blogClient.d.ts.map +1 -0
- package/dist/types/blog/category.d.ts +20 -0
- package/dist/types/blog/category.d.ts.map +1 -0
- package/dist/types/blog/index.d.ts +71 -0
- package/dist/types/blog/index.d.ts.map +1 -0
- package/dist/types/blog/post.d.ts +63 -0
- package/dist/types/blog/post.d.ts.map +1 -0
- package/dist/types/blog/tag.d.ts +19 -0
- package/dist/types/blog/tag.d.ts.map +1 -0
- package/dist/types/collection/collectionView.d.ts +35 -0
- package/dist/types/collection/collectionView.d.ts.map +1 -0
- package/dist/types/collection/draft.d.ts +9 -0
- package/dist/types/collection/draft.d.ts.map +1 -0
- package/dist/types/collection/index.d.ts +7 -0
- package/dist/types/collection/index.d.ts.map +1 -0
- package/dist/types/collection/lemaCollection.d.ts +33 -0
- package/dist/types/collection/lemaCollection.d.ts.map +1 -0
- package/dist/types/collection/lemaField.d.ts +35 -0
- package/dist/types/collection/lemaField.d.ts.map +1 -0
- package/dist/types/collection/lemaSection.d.ts +6 -0
- package/dist/types/collection/lemaSection.d.ts.map +1 -0
- package/dist/types/collection/relation.d.ts +11 -0
- package/dist/types/collection/relation.d.ts.map +1 -0
- package/dist/types/emoji.d.ts +21 -0
- package/dist/types/emoji.d.ts.map +1 -0
- package/dist/types/index.d.ts +11 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/levo-query.d.ts +48 -0
- package/dist/types/levo-query.d.ts.map +1 -0
- package/dist/types/media.d.ts +34 -0
- package/dist/types/media.d.ts.map +1 -0
- package/dist/types/membership/index.d.ts +193 -0
- package/dist/types/membership/index.d.ts.map +1 -0
- package/dist/types/query.d.ts +65 -0
- package/dist/types/query.d.ts.map +1 -0
- package/dist/types/schema/field.d.ts +27 -0
- package/dist/types/schema/field.d.ts.map +1 -0
- package/dist/types/schema/index.d.ts +3 -0
- package/dist/types/schema/index.d.ts.map +1 -0
- package/dist/types/schema/schema.d.ts +29 -0
- package/dist/types/schema/schema.d.ts.map +1 -0
- package/dist/types/utils.d.ts +8 -0
- package/dist/types/utils.d.ts.map +1 -0
- package/dist/utils/LevoMembershipError.d.ts +8 -0
- package/dist/utils/LevoMembershipError.d.ts.map +1 -0
- package/dist/utils/createSrcSet.d.ts +5 -0
- package/dist/utils/createSrcSet.d.ts.map +1 -0
- package/dist/utils/formatImagePath.d.ts +3 -0
- package/dist/utils/formatImagePath.d.ts.map +1 -0
- package/dist/utils/getUserProperties.d.ts +7 -0
- package/dist/utils/getUserProperties.d.ts.map +1 -0
- package/dist/utils/isIncognito.d.ts +9 -0
- package/dist/utils/isIncognito.d.ts.map +1 -0
- package/package.json +70 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lemaSection.d.ts","sourceRoot":"","sources":["../../../src/types/collection/lemaSection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C,MAAM,WAAW,YAAa,SAAQ,IAAI,CAAC,QAAQ,EAAE,QAAQ,CAAC;IAC5D,MAAM,EAAE,UAAU,EAAE,CAAC;CACtB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export type ILemaCollectionRelationship = "o2m" | "m2o" | "o2o" | "m2m";
|
|
2
|
+
export type ILemaRelationOnDelete = "CASCADE" | "SET_NULL" | "RESTRICT";
|
|
3
|
+
export type ILemaRelation = {
|
|
4
|
+
relationship: ILemaCollectionRelationship | string;
|
|
5
|
+
related_field: string;
|
|
6
|
+
related_collection_key: string;
|
|
7
|
+
field: string;
|
|
8
|
+
collection_key: string;
|
|
9
|
+
on_delete?: ILemaRelationOnDelete;
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=relation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"relation.d.ts","sourceRoot":"","sources":["../../../src/types/collection/relation.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,2BAA2B,GAAG,KAAK,GAAG,KAAK,GAAG,KAAK,GAAG,KAAK,CAAC;AAExE,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,CAAC;AAExE,MAAM,MAAM,aAAa,GAAG;IAC1B,YAAY,EAAE,2BAA2B,GAAG,MAAM,CAAC;IACnD,aAAa,EAAE,MAAM,CAAC;IACtB,sBAAsB,EAAE,MAAM,CAAC;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,CAAC;IACvB,SAAS,CAAC,EAAE,qBAAqB,CAAC;CACnC,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { IMediaObject } from "./media";
|
|
2
|
+
export interface IEmojiData {
|
|
3
|
+
label: string;
|
|
4
|
+
tags?: string[];
|
|
5
|
+
unicode: string;
|
|
6
|
+
}
|
|
7
|
+
export interface IIconData {
|
|
8
|
+
label: string;
|
|
9
|
+
tags?: string[];
|
|
10
|
+
componentName: string;
|
|
11
|
+
}
|
|
12
|
+
export interface IIconCat {
|
|
13
|
+
name: string;
|
|
14
|
+
slug: string;
|
|
15
|
+
emojis: IEmojiData[] | IIconData[];
|
|
16
|
+
}
|
|
17
|
+
export interface IIcon {
|
|
18
|
+
kind: "emoji" | "custom" | "icon";
|
|
19
|
+
data: IEmojiData | IMediaObject | IIconData;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=emoji.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"emoji.d.ts","sourceRoot":"","sources":["../../src/types/emoji.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAE5C,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;CACjB;AACD,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,UAAU,EAAE,GAAG,SAAS,EAAE,CAAC;CACpC;AAED,MAAM,WAAW,KAAK;IACpB,IAAI,EAAE,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAC;IAClC,IAAI,EAAE,UAAU,GAAG,YAAY,GAAG,SAAS,CAAC;CAC7C"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from "./blog";
|
|
2
|
+
export * from "./collection";
|
|
3
|
+
export * from "./membership";
|
|
4
|
+
export * from "./schema";
|
|
5
|
+
export * from "./audience";
|
|
6
|
+
export * from "./emoji";
|
|
7
|
+
export * from "./levo-query";
|
|
8
|
+
export * from "./media";
|
|
9
|
+
export * from "./query";
|
|
10
|
+
export * from "./utils";
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
type FieldType = string | number | Date | boolean | null;
|
|
2
|
+
type ComparableFieldType = number | Date;
|
|
3
|
+
interface IFilterOperator {
|
|
4
|
+
equals?: FieldType;
|
|
5
|
+
not?: FieldType;
|
|
6
|
+
in?: FieldType[];
|
|
7
|
+
not_in?: FieldType[];
|
|
8
|
+
gt?: ComparableFieldType;
|
|
9
|
+
gte?: ComparableFieldType;
|
|
10
|
+
lt?: ComparableFieldType;
|
|
11
|
+
lte?: ComparableFieldType;
|
|
12
|
+
contains?: string;
|
|
13
|
+
not_contains?: string;
|
|
14
|
+
starts_with?: string;
|
|
15
|
+
not_starts_with?: string;
|
|
16
|
+
ends_with?: string;
|
|
17
|
+
not_ends_with?: string;
|
|
18
|
+
empty?: boolean;
|
|
19
|
+
has?: Record<string, FieldType>;
|
|
20
|
+
}
|
|
21
|
+
type LogicalFilter = {
|
|
22
|
+
AND: Filter[];
|
|
23
|
+
OR?: undefined;
|
|
24
|
+
} | {
|
|
25
|
+
OR: Filter[];
|
|
26
|
+
AND?: undefined;
|
|
27
|
+
};
|
|
28
|
+
type FieldFilter = Record<string, IFilterOperator | FieldType>;
|
|
29
|
+
type Filter = LogicalFilter | FieldFilter;
|
|
30
|
+
export declare namespace LevoQuery {
|
|
31
|
+
type Select = Record<string, boolean>;
|
|
32
|
+
type Sort = Record<string, "asc" | "desc">;
|
|
33
|
+
type Pagination = {
|
|
34
|
+
page: number;
|
|
35
|
+
limit: number;
|
|
36
|
+
};
|
|
37
|
+
type Include = Record<string, true | Pick<FindQuery, "select" | "where" | "sort" | "include" | "limit">>;
|
|
38
|
+
type Where = Filter;
|
|
39
|
+
type FindQuery = Partial<Pagination & {
|
|
40
|
+
select: Select;
|
|
41
|
+
where: Where;
|
|
42
|
+
sort: Sort;
|
|
43
|
+
include: Include;
|
|
44
|
+
search: string;
|
|
45
|
+
}>;
|
|
46
|
+
}
|
|
47
|
+
export {};
|
|
48
|
+
//# sourceMappingURL=levo-query.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"levo-query.d.ts","sourceRoot":"","sources":["../../src/types/levo-query.ts"],"names":[],"mappings":"AAAA,KAAK,SAAS,GAAG,MAAM,GAAG,MAAM,GAAG,IAAI,GAAG,OAAO,GAAG,IAAI,CAAC;AAEzD,KAAK,mBAAmB,GAAG,MAAM,GAAG,IAAI,CAAC;AAEzC,UAAU,eAAe;IACvB,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,GAAG,CAAC,EAAE,SAAS,CAAC;IAChB,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC;IACjB,MAAM,CAAC,EAAE,SAAS,EAAE,CAAC;IACrB,EAAE,CAAC,EAAE,mBAAmB,CAAC;IACzB,GAAG,CAAC,EAAE,mBAAmB,CAAC;IAC1B,EAAE,CAAC,EAAE,mBAAmB,CAAC;IACzB,GAAG,CAAC,EAAE,mBAAmB,CAAC;IAC1B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;CACjC;AAED,KAAK,aAAa,GACd;IACE,GAAG,EAAE,MAAM,EAAE,CAAC;IACd,EAAE,CAAC,EAAE,SAAS,CAAC;CAChB,GACD;IACE,EAAE,EAAE,MAAM,EAAE,CAAC;IACb,GAAG,CAAC,EAAE,SAAS,CAAC;CACjB,CAAC;AAEN,KAAK,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,eAAe,GAAG,SAAS,CAAC,CAAC;AAE/D,KAAK,MAAM,GAAG,aAAa,GAAG,WAAW,CAAC;AAE1C,yBAAiB,SAAS,CAAC;IACzB,KAAY,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAE7C,KAAY,IAAI,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,GAAG,MAAM,CAAC,CAAC;IAElD,KAAY,UAAU,GAAG;QACvB,IAAI,EAAE,MAAM,CAAC;QACb,KAAK,EAAE,MAAM,CAAC;KACf,CAAC;IAEF,KAAY,OAAO,GAAG,MAAM,CAC1B,MAAM,EACN,IAAI,GAAG,IAAI,CAAC,SAAS,EAAE,QAAQ,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,CAAC,CAC1E,CAAC;IAEF,KAAY,KAAK,GAAG,MAAM,CAAC;IAE3B,KAAY,SAAS,GAAG,OAAO,CAC7B,UAAU,GAAG;QACX,MAAM,EAAE,MAAM,CAAC;QACf,KAAK,EAAE,KAAK,CAAC;QACb,IAAI,EAAE,IAAI,CAAC;QACX,OAAO,EAAE,OAAO,CAAC;QACjB,MAAM,EAAE,MAAM,CAAC;KAChB,CACF,CAAC;CACH"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { MediaKindList } from "../constants/media";
|
|
2
|
+
export interface IMedia {
|
|
3
|
+
id: string;
|
|
4
|
+
workspace_id: string;
|
|
5
|
+
filename: string;
|
|
6
|
+
kind: (typeof MediaKindList)[number];
|
|
7
|
+
location: string;
|
|
8
|
+
path: string;
|
|
9
|
+
srcset?: {
|
|
10
|
+
"320": string;
|
|
11
|
+
"640": string;
|
|
12
|
+
"750": string;
|
|
13
|
+
"828": string;
|
|
14
|
+
"1080": string;
|
|
15
|
+
"1200": string;
|
|
16
|
+
"1920": string;
|
|
17
|
+
path: string;
|
|
18
|
+
};
|
|
19
|
+
description: string;
|
|
20
|
+
metadata: {
|
|
21
|
+
encoding?: string;
|
|
22
|
+
mimetype: string;
|
|
23
|
+
size: number;
|
|
24
|
+
etag?: string;
|
|
25
|
+
};
|
|
26
|
+
created_at?: Date;
|
|
27
|
+
created_by?: string;
|
|
28
|
+
updated_at?: Date;
|
|
29
|
+
updated_by?: string;
|
|
30
|
+
}
|
|
31
|
+
export type IMediaObject = Pick<IMedia, "id" | "location" | "srcset" | "kind"> & {
|
|
32
|
+
mimetype: IMedia["metadata"]["mimetype"];
|
|
33
|
+
};
|
|
34
|
+
//# sourceMappingURL=media.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"media.d.ts","sourceRoot":"","sources":["../../src/types/media.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAExD,MAAM,WAAW,MAAM;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC;IACrC,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE;QACP,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,MAAM,CAAC;QACd,MAAM,EAAE,MAAM,CAAC;QACf,MAAM,EAAE,MAAM,CAAC;QACf,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;KACd,CAAC;IACF,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE;QACR,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,QAAQ,EAAE,MAAM,CAAC;QACjB,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,CAAC,EAAE,MAAM,CAAC;KACf,CAAC;IACF,UAAU,CAAC,EAAE,IAAI,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,IAAI,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,MAAM,YAAY,GAAG,IAAI,CAC7B,MAAM,EACN,IAAI,GAAG,UAAU,GAAG,QAAQ,GAAG,MAAM,CACtC,GAAG;IACF,QAAQ,EAAE,MAAM,CAAC,UAAU,CAAC,CAAC,UAAU,CAAC,CAAC;CAC1C,CAAC"}
|
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
import type { IMediaObject } from "../media";
|
|
2
|
+
import type { IResponseSingle } from "../query";
|
|
3
|
+
import type { LevoOAuthProviderList } from "../../constants/oauthProvider";
|
|
4
|
+
export declare namespace ILevoMembership {
|
|
5
|
+
interface sub_account_oauth_credentials {
|
|
6
|
+
provider: string;
|
|
7
|
+
oauth_id: string;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* The account object of the member
|
|
11
|
+
*/
|
|
12
|
+
export interface Account {
|
|
13
|
+
_id: string;
|
|
14
|
+
first_name: string | null;
|
|
15
|
+
last_name: string | null;
|
|
16
|
+
slug: string;
|
|
17
|
+
username: string;
|
|
18
|
+
email: string;
|
|
19
|
+
display_email: string;
|
|
20
|
+
reducted_email: string;
|
|
21
|
+
email_verified: boolean;
|
|
22
|
+
mobile: string | null;
|
|
23
|
+
reducted_mobile: string | null;
|
|
24
|
+
mobile_verified: boolean;
|
|
25
|
+
profile_picture: IMediaObject | null;
|
|
26
|
+
oauth_credentials: sub_account_oauth_credentials[];
|
|
27
|
+
account_locked_at: Date | string | null;
|
|
28
|
+
credentials_expired_at: Date | string | null;
|
|
29
|
+
deactivated_at: Date | string | null;
|
|
30
|
+
last_access_at: Date | string | null;
|
|
31
|
+
flagged_at: Date | string | null;
|
|
32
|
+
created_at: Date | string;
|
|
33
|
+
updated_at: Date | string;
|
|
34
|
+
deleted_at: Date | string | null;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* the otp object with its code and content
|
|
38
|
+
*/
|
|
39
|
+
export interface Otp {
|
|
40
|
+
/**
|
|
41
|
+
* the ID of the Otp
|
|
42
|
+
*/
|
|
43
|
+
_id: string;
|
|
44
|
+
/**
|
|
45
|
+
* the email or mobile number to send the Otp to
|
|
46
|
+
*/
|
|
47
|
+
content: string;
|
|
48
|
+
/**
|
|
49
|
+
* the Otp code received in email or sms
|
|
50
|
+
*/
|
|
51
|
+
code: string;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* The list of URLs for OAuth providers to redirect to
|
|
55
|
+
* This can be used in the OAuth Buttons like "Continue with Google" etc.
|
|
56
|
+
*
|
|
57
|
+
* @example
|
|
58
|
+
* ```javascript
|
|
59
|
+
* {
|
|
60
|
+
* "google": 'https://platform-api.levo.so/v1/membership/auth/oauth/google?redirect_uri=https://example.com&workspace=my-workspace',
|
|
61
|
+
* "microsoft": 'https://platform-api.levo.so/v1/membership/auth/oauth/microsoft?redirect_uri=https://example.com&workspace=my-workspace',
|
|
62
|
+
* "linkedin": 'https://platform-api.levo.so/v1/membership/auth/oauth/linkedin?redirect_uri=https://example.com&workspace=my-workspace'
|
|
63
|
+
* }
|
|
64
|
+
* ```
|
|
65
|
+
*/
|
|
66
|
+
export type OAuthURLList = Record<(typeof LevoOAuthProviderList)[number], string | null>;
|
|
67
|
+
export namespace Request {
|
|
68
|
+
/**
|
|
69
|
+
*
|
|
70
|
+
* `content` - the email or mobile number to send the Otp to
|
|
71
|
+
*
|
|
72
|
+
* @example
|
|
73
|
+
* ```json
|
|
74
|
+
* {
|
|
75
|
+
* "content": "example@mailinator.com",
|
|
76
|
+
* "redirect_uri": "https://example.com/protected-page"
|
|
77
|
+
* }
|
|
78
|
+
* ```
|
|
79
|
+
*/
|
|
80
|
+
type RequestMagicLink = Pick<Otp, "content"> & {
|
|
81
|
+
redirect_uri?: string;
|
|
82
|
+
};
|
|
83
|
+
/**
|
|
84
|
+
*
|
|
85
|
+
* `content` - the email or mobile number to send the Otp to
|
|
86
|
+
*
|
|
87
|
+
* @example
|
|
88
|
+
* ```json
|
|
89
|
+
* {
|
|
90
|
+
* "content": "example@mailinator.com"
|
|
91
|
+
* }
|
|
92
|
+
* ```
|
|
93
|
+
*/
|
|
94
|
+
type RequestOtp = Pick<Otp, "content">;
|
|
95
|
+
/**
|
|
96
|
+
* `content` - the email or mobile number to send the Otp to
|
|
97
|
+
*
|
|
98
|
+
* `code` - the Otp code received in email or sms
|
|
99
|
+
*
|
|
100
|
+
* @example
|
|
101
|
+
* ```json
|
|
102
|
+
* {
|
|
103
|
+
* "content": "example@mailinator.com",
|
|
104
|
+
* "code": "1234"
|
|
105
|
+
* }
|
|
106
|
+
* ```
|
|
107
|
+
*/
|
|
108
|
+
type SignInWithOtp = Pick<Otp, "content" | "code">;
|
|
109
|
+
/**
|
|
110
|
+
* `email` - the email of the account
|
|
111
|
+
*
|
|
112
|
+
* `password` - the password of the account
|
|
113
|
+
*
|
|
114
|
+
* @example
|
|
115
|
+
* ```json
|
|
116
|
+
* {
|
|
117
|
+
* "email": "example@mailinator.com",
|
|
118
|
+
* "password": "strongpasswordhere"
|
|
119
|
+
* }
|
|
120
|
+
* ```
|
|
121
|
+
*/
|
|
122
|
+
type SignInWithPassword = {
|
|
123
|
+
email: Account["email"];
|
|
124
|
+
password: string;
|
|
125
|
+
};
|
|
126
|
+
/**
|
|
127
|
+
* @property {string | null} [first_name] - the first name of the account
|
|
128
|
+
* @property {string | null} [last_name] - the last name of the account
|
|
129
|
+
* @property {string} email - the email of the account
|
|
130
|
+
* @property {string} password - the password of the account
|
|
131
|
+
*
|
|
132
|
+
* @example
|
|
133
|
+
* ```json
|
|
134
|
+
* {
|
|
135
|
+
* "email": "example@mailinator.com",
|
|
136
|
+
* "password": "strongpasswordhere"
|
|
137
|
+
* }
|
|
138
|
+
* ```
|
|
139
|
+
* @example
|
|
140
|
+
* ```json
|
|
141
|
+
* {
|
|
142
|
+
* "first_name": "John",
|
|
143
|
+
* "last_name": "Doe",
|
|
144
|
+
* "email": "example@mailinator.com",
|
|
145
|
+
* "password": "strongpasswordhere"
|
|
146
|
+
* }
|
|
147
|
+
* ```
|
|
148
|
+
* @example
|
|
149
|
+
* ```json
|
|
150
|
+
* {
|
|
151
|
+
* "first_name": null,
|
|
152
|
+
* "last_name": null,
|
|
153
|
+
* "email": "example@mailinator.com",
|
|
154
|
+
* "password": "strongpasswordhere"
|
|
155
|
+
* }
|
|
156
|
+
* ```
|
|
157
|
+
*/
|
|
158
|
+
type SignUpWithPassword = Partial<Pick<Account, "first_name" | "last_name">> & Pick<Account, "email"> & {
|
|
159
|
+
password: string;
|
|
160
|
+
};
|
|
161
|
+
/**
|
|
162
|
+
* @property {string | null} [first_name] - the first name of the account (optional)
|
|
163
|
+
* @property {string | null} [last_name] - the last name of the account (optional)
|
|
164
|
+
* @property {string} [username] - the username of the account (optional)
|
|
165
|
+
* @property {IMediaObject} [profile_picture] - the profile picture object for the account (optional)
|
|
166
|
+
*/
|
|
167
|
+
type UpdateMe = Partial<Pick<Account, "first_name" | "last_name" | "profile_picture" | "username">>;
|
|
168
|
+
}
|
|
169
|
+
export namespace Response {
|
|
170
|
+
type Error = {
|
|
171
|
+
status: false;
|
|
172
|
+
content: {
|
|
173
|
+
message: string;
|
|
174
|
+
description: string;
|
|
175
|
+
code: string;
|
|
176
|
+
status: string;
|
|
177
|
+
title: string;
|
|
178
|
+
type: string;
|
|
179
|
+
};
|
|
180
|
+
};
|
|
181
|
+
type ListOAuthURLs = IResponseSingle<ILevoMembership.OAuthURLList>;
|
|
182
|
+
type SignOut = IResponseSingle<ILevoMembership.Account>;
|
|
183
|
+
type GetMe = IResponseSingle<ILevoMembership.Account>;
|
|
184
|
+
type RequestOtp = IResponseSingle<Pick<ILevoMembership.Otp, "_id" | "content">>;
|
|
185
|
+
type RequestMagicLink = IResponseSingle<Pick<ILevoMembership.Otp, "_id" | "content">>;
|
|
186
|
+
type SignInWithOtp = IResponseSingle<ILevoMembership.Account>;
|
|
187
|
+
type SignInWithPassword = IResponseSingle<ILevoMembership.Account>;
|
|
188
|
+
type SignUpWithPassword = IResponseSingle<ILevoMembership.Account>;
|
|
189
|
+
type UpdateMe = IResponseSingle<ILevoMembership.Account>;
|
|
190
|
+
}
|
|
191
|
+
export {};
|
|
192
|
+
}
|
|
193
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/membership/index.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
export interface IMeta {
|
|
2
|
+
total: number;
|
|
3
|
+
filter_count: number;
|
|
4
|
+
pages: number;
|
|
5
|
+
}
|
|
6
|
+
export interface IResponseMultiple<T = Record<string, unknown>> {
|
|
7
|
+
status: boolean;
|
|
8
|
+
content: {
|
|
9
|
+
meta: IMeta;
|
|
10
|
+
data: T[];
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
export interface IResponseMultipleV2<T = Record<string, unknown>> {
|
|
14
|
+
status: true;
|
|
15
|
+
content: {
|
|
16
|
+
meta: {
|
|
17
|
+
total: number;
|
|
18
|
+
pages: number;
|
|
19
|
+
};
|
|
20
|
+
data: T[];
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
export interface IResponseSingle<T = Record<string, unknown>, Meta = any> {
|
|
24
|
+
status: boolean;
|
|
25
|
+
content: {
|
|
26
|
+
data: T;
|
|
27
|
+
meta: Meta;
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
export interface IResponseMyCategory<T = Record<string, unknown>> {
|
|
31
|
+
status: boolean;
|
|
32
|
+
content: {
|
|
33
|
+
data: T[];
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
export type IResponseError<T = Record<string, unknown>> = {
|
|
37
|
+
status: false;
|
|
38
|
+
errors?: T[];
|
|
39
|
+
content?: {
|
|
40
|
+
status: number;
|
|
41
|
+
code: string;
|
|
42
|
+
title: string;
|
|
43
|
+
description: string;
|
|
44
|
+
type: string;
|
|
45
|
+
"request-id": string;
|
|
46
|
+
} & T;
|
|
47
|
+
};
|
|
48
|
+
export type IFilter = Record<string, unknown>;
|
|
49
|
+
export type IErrorParams = {
|
|
50
|
+
message: string;
|
|
51
|
+
param: string;
|
|
52
|
+
};
|
|
53
|
+
export interface IErrorMessage {
|
|
54
|
+
status: boolean;
|
|
55
|
+
content: {
|
|
56
|
+
status: number;
|
|
57
|
+
code: string;
|
|
58
|
+
title: string;
|
|
59
|
+
description: string;
|
|
60
|
+
type: string;
|
|
61
|
+
"request-id"?: string;
|
|
62
|
+
errors?: IErrorParams[];
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
//# sourceMappingURL=query.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../../src/types/query.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,KAAK;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;IACrB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,iBAAiB,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC5D,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE;QACP,IAAI,EAAE,KAAK,CAAC;QACZ,IAAI,EAAE,CAAC,EAAE,CAAC;KACX,CAAC;CACH;AAED,MAAM,WAAW,mBAAmB,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC9D,MAAM,EAAE,IAAI,CAAC;IACb,OAAO,EAAE;QACP,IAAI,EAAE;YACJ,KAAK,EAAE,MAAM,CAAC;YACd,KAAK,EAAE,MAAM,CAAC;SACf,CAAC;QACF,IAAI,EAAE,CAAC,EAAE,CAAC;KACX,CAAC;CACH;AAED,MAAM,WAAW,eAAe,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,GAAG,GAAG;IACtE,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE;QACP,IAAI,EAAE,CAAC,CAAC;QACR,IAAI,EAAE,IAAI,CAAC;KACZ,CAAC;CACH;AAED,MAAM,WAAW,mBAAmB,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC9D,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE;QACP,IAAI,EAAE,CAAC,EAAE,CAAC;KACX,CAAC;CACH;AAED,MAAM,MAAM,cAAc,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI;IACxD,MAAM,EAAE,KAAK,CAAC;IACd,MAAM,CAAC,EAAE,CAAC,EAAE,CAAC;IACb,OAAO,CAAC,EAAE;QACR,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;QACb,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;QACpB,IAAI,EAAE,MAAM,CAAC;QACb,YAAY,EAAE,MAAM,CAAC;KACtB,GAAG,CAAC,CAAC;CACP,CAAC;AAEF,MAAM,MAAM,OAAO,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAE9C,MAAM,MAAM,YAAY,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAE9D,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE;QACP,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;QACb,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;QACpB,IAAI,EAAE,MAAM,CAAC;QACb,YAAY,CAAC,EAAE,MAAM,CAAC;QACtB,MAAM,CAAC,EAAE,YAAY,EAAE,CAAC;KACzB,CAAC;CACH"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { FieldKindList } from "../../constants";
|
|
2
|
+
export interface IField {
|
|
3
|
+
id: string;
|
|
4
|
+
key: string;
|
|
5
|
+
kind: (typeof FieldKindList)[number];
|
|
6
|
+
field_interface: string;
|
|
7
|
+
label: string;
|
|
8
|
+
helper_text?: string;
|
|
9
|
+
default_value?: any;
|
|
10
|
+
readonly?: boolean;
|
|
11
|
+
fields?: IField[];
|
|
12
|
+
options?: Record<string, any>;
|
|
13
|
+
hidden?: boolean;
|
|
14
|
+
editable?: boolean;
|
|
15
|
+
required?: boolean;
|
|
16
|
+
unique?: boolean;
|
|
17
|
+
min?: string | number | null;
|
|
18
|
+
max?: string | number | null;
|
|
19
|
+
formats?: string[];
|
|
20
|
+
values?: any[];
|
|
21
|
+
created_at?: string;
|
|
22
|
+
updated_at?: string;
|
|
23
|
+
}
|
|
24
|
+
export interface IFieldUpdate extends Omit<IField, "fields"> {
|
|
25
|
+
fields: Partial<IField>[];
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=field.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"field.d.ts","sourceRoot":"","sources":["../../../src/types/schema/field.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAErD,MAAM,WAAW,MAAM;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC;IACrC,eAAe,EAAE,MAAM,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;IAEd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,aAAa,CAAC,EAAE,GAAG,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC9B,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAC7B,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,MAAM,CAAC,EAAE,GAAG,EAAE,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,YAAa,SAAQ,IAAI,CAAC,MAAM,EAAE,QAAQ,CAAC;IAC1D,MAAM,EAAE,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC;CAC3B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/types/schema/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { IIcon } from "../emoji";
|
|
2
|
+
import type { IField } from "./field";
|
|
3
|
+
export interface ISchema {
|
|
4
|
+
id: string;
|
|
5
|
+
name: string;
|
|
6
|
+
description: string;
|
|
7
|
+
key: string;
|
|
8
|
+
sections: ISection[];
|
|
9
|
+
title_field: string;
|
|
10
|
+
cover_image_field?: string;
|
|
11
|
+
icon: null | IIcon;
|
|
12
|
+
created_at?: string;
|
|
13
|
+
module_name?: string;
|
|
14
|
+
views?: ICollectionViews[];
|
|
15
|
+
}
|
|
16
|
+
export interface ICollectionViews {
|
|
17
|
+
id: string;
|
|
18
|
+
slug: string;
|
|
19
|
+
title: string;
|
|
20
|
+
}
|
|
21
|
+
export interface ISection {
|
|
22
|
+
id: string;
|
|
23
|
+
label: string;
|
|
24
|
+
key: string;
|
|
25
|
+
helper_text: string;
|
|
26
|
+
hidden: boolean;
|
|
27
|
+
fields: IField[];
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/types/schema/schema.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AACtC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEtC,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,QAAQ,EAAE,CAAC;IACrB,WAAW,EAAE,MAAM,CAAC;IACpB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,IAAI,EAAE,IAAI,GAAG,KAAK,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,gBAAgB,EAAE,CAAC;CAC5B;AAED,MAAM,WAAW,gBAAgB;IAC/B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,OAAO,CAAC;IAChB,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export type Prettify<T> = {
|
|
2
|
+
[K in keyof T]: T[K];
|
|
3
|
+
};
|
|
4
|
+
export type Mandatory<T, K extends keyof T> = Prettify<Pick<T, K> & Partial<Omit<T, K>>>;
|
|
5
|
+
export type DeepPartial<T> = {
|
|
6
|
+
[P in keyof T]?: T[P] extends object ? DeepPartial<T[P]> : T[P];
|
|
7
|
+
};
|
|
8
|
+
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/types/utils.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,QAAQ,CAAC,CAAC,IAAI;KACvB,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,SAAS,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,IAAI,QAAQ,CACpD,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CACjC,CAAC;AAEF,MAAM,MAAM,WAAW,CAAC,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAChE,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ILevoMembership } from "../types/membership";
|
|
2
|
+
export declare class LevoMembershipError extends Error {
|
|
3
|
+
code: string;
|
|
4
|
+
title: string;
|
|
5
|
+
message: string;
|
|
6
|
+
constructor(data: ILevoMembership.Response.Error["content"]);
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=LevoMembershipError.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LevoMembershipError.d.ts","sourceRoot":"","sources":["../../src/utils/LevoMembershipError.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAE3D,qBAAa,mBAAoB,SAAQ,KAAK;IAC5C,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;gBAEJ,IAAI,EAAE,eAAe,CAAC,QAAQ,CAAC,KAAK,CAAC,SAAS,CAAC;CAQ5D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createSrcSet.d.ts","sourceRoot":"","sources":["../../src/utils/createSrcSet.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY,eAAgB;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;CAAE,KAAG,MAKpE,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatImagePath.d.ts","sourceRoot":"","sources":["../../src/utils/formatImagePath.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,eAAe,WAAY,MAAM,WAY7C,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getUserProperties.d.ts","sourceRoot":"","sources":["../../src/utils/getUserProperties.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,iBAAiB;;;;;cAsC7B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isIncognito.d.ts","sourceRoot":"","sources":["../../src/utils/isIncognito.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,QAAA,MAAM,WAAW,QAAO,OAAO,CAAC;IAC9B,SAAS,EAAE,OAAO,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;CACrB,CAuOG,CAAC;AAEL,eAAe,WAAW,CAAC"}
|