@lokalise/harmony 1.11.1 → 1.12.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/harmony.cjs +1 -1
- package/dist/harmony.mjs +346 -318
- package/dist/types/src/features/publicApi/hooks/useListProjectLanguagesQuery.d.ts +16 -0
- package/dist/types/src/features/publicApi/hooks/useListProjectsQuery.d.ts +1 -1
- package/dist/types/src/features/publicApi/languages.d.ts +48 -0
- package/dist/types/src/features/publicApi/node.d.ts +2 -1
- package/dist/types/src/features/publicApi/projects.d.ts +2 -2
- package/dist/types/src/features/publicApi/types/languageTypes.d.ts +68 -0
- package/dist/types/src/features/publicApi/types/projectTypes.d.ts +2 -2
- package/package.json +1 -1
@@ -0,0 +1,16 @@
|
|
1
|
+
import { ListProjectLanguagesResponse } from '../types/languageTypes';
|
2
|
+
import { ApiQueryOverrides } from '../../../utils/types/apiQueryOverrides';
|
3
|
+
import { Wretch } from 'wretch/types';
|
4
|
+
export declare const listProjectLanguagesKey: {
|
5
|
+
projectIdKey: (projectId: string) => readonly ["listProjectLanguages", string];
|
6
|
+
};
|
7
|
+
export declare function useListProjectLanguagesQuery<T>(wretchClient: Wretch<T>, overrides: ApiQueryOverrides<ListProjectLanguagesResponse, typeof listProjectLanguagesKey>): import('@tanstack/react-query').UseQueryResult<{
|
8
|
+
languages: {
|
9
|
+
lang_id: number;
|
10
|
+
lang_iso: string;
|
11
|
+
lang_name: string;
|
12
|
+
is_rtl: boolean;
|
13
|
+
plural_forms: (string | undefined)[];
|
14
|
+
}[];
|
15
|
+
projectId: string;
|
16
|
+
}, undefined>;
|
@@ -34,7 +34,7 @@ export declare function useListProjectsQuery<T>(wretchClient: Wretch<T>, overrid
|
|
34
34
|
created_by_email: string;
|
35
35
|
base_language_id: number;
|
36
36
|
base_language_iso: string;
|
37
|
-
}
|
37
|
+
} & {
|
38
38
|
settings?: {
|
39
39
|
per_platform_key_names: boolean;
|
40
40
|
reviewing: boolean;
|
@@ -0,0 +1,48 @@
|
|
1
|
+
export declare const listProjectLanguages: import('@lokalise/universal-ts-utils/node').GetRouteDefinition<{
|
2
|
+
projectId: string;
|
3
|
+
}, import('zod').ZodObject<{
|
4
|
+
projectId: import('zod').ZodString;
|
5
|
+
languages: import('zod').ZodArray<import('zod').ZodObject<{
|
6
|
+
lang_id: import('zod').ZodNumber;
|
7
|
+
lang_iso: import('zod').ZodString;
|
8
|
+
lang_name: import('zod').ZodString;
|
9
|
+
is_rtl: import('zod').ZodBoolean;
|
10
|
+
plural_forms: import('zod').ZodArray<import('zod').ZodOptional<import('zod').ZodString>, "many">;
|
11
|
+
}, "strip", import('zod').ZodTypeAny, {
|
12
|
+
lang_id: number;
|
13
|
+
lang_iso: string;
|
14
|
+
lang_name: string;
|
15
|
+
is_rtl: boolean;
|
16
|
+
plural_forms: (string | undefined)[];
|
17
|
+
}, {
|
18
|
+
lang_id: number;
|
19
|
+
lang_iso: string;
|
20
|
+
lang_name: string;
|
21
|
+
is_rtl: boolean;
|
22
|
+
plural_forms: (string | undefined)[];
|
23
|
+
}>, "many">;
|
24
|
+
}, "strip", import('zod').ZodTypeAny, {
|
25
|
+
languages: {
|
26
|
+
lang_id: number;
|
27
|
+
lang_iso: string;
|
28
|
+
lang_name: string;
|
29
|
+
is_rtl: boolean;
|
30
|
+
plural_forms: (string | undefined)[];
|
31
|
+
}[];
|
32
|
+
projectId: string;
|
33
|
+
}, {
|
34
|
+
languages: {
|
35
|
+
lang_id: number;
|
36
|
+
lang_iso: string;
|
37
|
+
lang_name: string;
|
38
|
+
is_rtl: boolean;
|
39
|
+
plural_forms: (string | undefined)[];
|
40
|
+
}[];
|
41
|
+
projectId: string;
|
42
|
+
}>, import('zod').ZodObject<{
|
43
|
+
projectId: import('zod').ZodString;
|
44
|
+
}, "strip", import('zod').ZodTypeAny, {
|
45
|
+
projectId: string;
|
46
|
+
}, {
|
47
|
+
projectId: string;
|
48
|
+
}>, undefined, undefined, false, false>;
|
@@ -2,7 +2,7 @@ export * from './contributors';
|
|
2
2
|
export * from './projects';
|
3
3
|
export * from './teamUsers';
|
4
4
|
export * from './userToken';
|
5
|
-
export type { LanguageStatistics, LanguageIso } from './types/languageTypes';
|
5
|
+
export type { LanguageStatistics, LanguageIso, Language, ListProjectLanguagesResponse, } from './types/languageTypes';
|
6
6
|
export type { Project, ProjectQaIssues, ProjectType, ProjectSettings } from './types/projectTypes';
|
7
7
|
export type { TeamRole } from './types/teamRoleTypes';
|
8
8
|
export type { Contributor, ContributorLanguage } from './types/contributorTypes';
|
@@ -11,6 +11,7 @@ export type { AuthenticatedRequestHeader, JwtToken } from './types/userTokenType
|
|
11
11
|
export * from './hooks/useCreateProjectMutation';
|
12
12
|
export * from './hooks/useGetTeamUsersQuery';
|
13
13
|
export * from './hooks/useGetUserTokenQuery';
|
14
|
+
export * from './hooks/useListProjectLanguagesQuery';
|
14
15
|
export * from './hooks/useListProjectsQuery';
|
15
16
|
export * from './hooks/useRetrieveContributorQuery';
|
16
17
|
export * from './hooks/useRetrieveProjectQuery';
|
@@ -335,7 +335,7 @@ export declare const createProject: import('@lokalise/universal-ts-utils/node').
|
|
335
335
|
/**
|
336
336
|
* Public API router definition for listing all projects
|
337
337
|
*/
|
338
|
-
export declare const listProjects: import('@lokalise/universal-ts-utils/node').GetRouteDefinition<never, import('zod').ZodArray<import('zod').
|
338
|
+
export declare const listProjects: import('@lokalise/universal-ts-utils/node').GetRouteDefinition<never, import('zod').ZodArray<import('zod').ZodIntersection<import('zod').ZodObject<Omit<{
|
339
339
|
project_id: import('zod').ZodString;
|
340
340
|
uuid: import('zod').ZodString;
|
341
341
|
project_type: import('zod').ZodUnion<[import('zod').ZodLiteral<"localization_files">, import('zod').ZodLiteral<"paged_documents">, import('zod').ZodLiteral<"marketing">]>;
|
@@ -801,7 +801,7 @@ export declare const listProjects: import('@lokalise/universal-ts-utils/node').G
|
|
801
801
|
unbalanced_brackets: number;
|
802
802
|
};
|
803
803
|
} | undefined;
|
804
|
-
}
|
804
|
+
}>>, "many">, undefined, import('zod').ZodObject<{
|
805
805
|
project_type: import('zod').ZodOptional<import('zod').ZodUnion<[import('zod').ZodLiteral<"localization_files">, import('zod').ZodLiteral<"paged_documents">, import('zod').ZodLiteral<"marketing">]>>;
|
806
806
|
filter_team_id: import('zod').ZodOptional<import('zod').ZodNumber>;
|
807
807
|
filter_names: import('zod').ZodOptional<import('zod').ZodString>;
|
@@ -27,3 +27,71 @@ export declare const LANGUAGE_STATISTICS_SCHEMA: z.ZodObject<{
|
|
27
27
|
words_to_do: number;
|
28
28
|
}>;
|
29
29
|
export type LanguageStatistics = z.infer<typeof LANGUAGE_STATISTICS_SCHEMA>;
|
30
|
+
export declare const LIST_PROJECT_LANGUAGES_PATH_PARAMS_SCHEMA: z.ZodObject<{
|
31
|
+
projectId: z.ZodString;
|
32
|
+
}, "strip", z.ZodTypeAny, {
|
33
|
+
projectId: string;
|
34
|
+
}, {
|
35
|
+
projectId: string;
|
36
|
+
}>;
|
37
|
+
export declare const LANGUAGE_SCHEMA: z.ZodObject<{
|
38
|
+
lang_id: z.ZodNumber;
|
39
|
+
lang_iso: z.ZodString;
|
40
|
+
lang_name: z.ZodString;
|
41
|
+
is_rtl: z.ZodBoolean;
|
42
|
+
plural_forms: z.ZodArray<z.ZodOptional<z.ZodString>, "many">;
|
43
|
+
}, "strip", z.ZodTypeAny, {
|
44
|
+
lang_id: number;
|
45
|
+
lang_iso: string;
|
46
|
+
lang_name: string;
|
47
|
+
is_rtl: boolean;
|
48
|
+
plural_forms: (string | undefined)[];
|
49
|
+
}, {
|
50
|
+
lang_id: number;
|
51
|
+
lang_iso: string;
|
52
|
+
lang_name: string;
|
53
|
+
is_rtl: boolean;
|
54
|
+
plural_forms: (string | undefined)[];
|
55
|
+
}>;
|
56
|
+
export type Language = z.infer<typeof LANGUAGE_SCHEMA>;
|
57
|
+
export declare const LIST_PROJECT_LANGUAGES_RESPONSE_SCHEMA: z.ZodObject<{
|
58
|
+
projectId: z.ZodString;
|
59
|
+
languages: z.ZodArray<z.ZodObject<{
|
60
|
+
lang_id: z.ZodNumber;
|
61
|
+
lang_iso: z.ZodString;
|
62
|
+
lang_name: z.ZodString;
|
63
|
+
is_rtl: z.ZodBoolean;
|
64
|
+
plural_forms: z.ZodArray<z.ZodOptional<z.ZodString>, "many">;
|
65
|
+
}, "strip", z.ZodTypeAny, {
|
66
|
+
lang_id: number;
|
67
|
+
lang_iso: string;
|
68
|
+
lang_name: string;
|
69
|
+
is_rtl: boolean;
|
70
|
+
plural_forms: (string | undefined)[];
|
71
|
+
}, {
|
72
|
+
lang_id: number;
|
73
|
+
lang_iso: string;
|
74
|
+
lang_name: string;
|
75
|
+
is_rtl: boolean;
|
76
|
+
plural_forms: (string | undefined)[];
|
77
|
+
}>, "many">;
|
78
|
+
}, "strip", z.ZodTypeAny, {
|
79
|
+
languages: {
|
80
|
+
lang_id: number;
|
81
|
+
lang_iso: string;
|
82
|
+
lang_name: string;
|
83
|
+
is_rtl: boolean;
|
84
|
+
plural_forms: (string | undefined)[];
|
85
|
+
}[];
|
86
|
+
projectId: string;
|
87
|
+
}, {
|
88
|
+
languages: {
|
89
|
+
lang_id: number;
|
90
|
+
lang_iso: string;
|
91
|
+
lang_name: string;
|
92
|
+
is_rtl: boolean;
|
93
|
+
plural_forms: (string | undefined)[];
|
94
|
+
}[];
|
95
|
+
projectId: string;
|
96
|
+
}>;
|
97
|
+
export type ListProjectLanguagesResponse = z.infer<typeof LIST_PROJECT_LANGUAGES_RESPONSE_SCHEMA>;
|
@@ -584,7 +584,7 @@ export declare const LIST_PROJECTS_REQUEST_QUERY_SCHEMA: z.ZodObject<{
|
|
584
584
|
limit?: number | undefined;
|
585
585
|
}>;
|
586
586
|
export type ListProjectsRequestQuery = z.infer<typeof LIST_PROJECTS_REQUEST_QUERY_SCHEMA>;
|
587
|
-
export declare const LIST_PROJECTS_SUCCESS_RESPONSE_BODY: z.ZodArray<z.
|
587
|
+
export declare const LIST_PROJECTS_SUCCESS_RESPONSE_BODY: z.ZodArray<z.ZodIntersection<z.ZodObject<Omit<{
|
588
588
|
project_id: z.ZodString;
|
589
589
|
uuid: z.ZodString;
|
590
590
|
project_type: z.ZodUnion<[z.ZodLiteral<"localization_files">, z.ZodLiteral<"paged_documents">, z.ZodLiteral<"marketing">]>;
|
@@ -1050,7 +1050,7 @@ export declare const LIST_PROJECTS_SUCCESS_RESPONSE_BODY: z.ZodArray<z.ZodUnion<
|
|
1050
1050
|
unbalanced_brackets: number;
|
1051
1051
|
};
|
1052
1052
|
} | undefined;
|
1053
|
-
}
|
1053
|
+
}>>, "many">;
|
1054
1054
|
export type ListProjectsSuccessResponseBody = z.infer<typeof LIST_PROJECTS_SUCCESS_RESPONSE_BODY>;
|
1055
1055
|
export declare const RETRIEVE_PROJECT_REQUEST_QUERY_SCHEMA: z.ZodObject<{
|
1056
1056
|
project_id: z.ZodString;
|