@uxf/cms 11.122.4 → 11.123.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/api/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { FileResponse } from "@uxf/core/types";
|
|
2
2
|
import { Schema } from "@uxf/data-grid";
|
|
3
|
+
import { AxiosPromise } from "axios";
|
|
3
4
|
export type VisibilityLevel = "PUBLIC" | "PUBLIC_WITHOUT_SITEMAP" | "PRIVATE";
|
|
4
5
|
export interface ContentSeoResponse {
|
|
5
6
|
name: string | null;
|
|
@@ -124,41 +125,41 @@ export interface UserConfigResponse<T> {
|
|
|
124
125
|
export interface UserConfigBagResponse {
|
|
125
126
|
[name: string]: UserConfigResponse<any>;
|
|
126
127
|
}
|
|
127
|
-
export declare function contentGet(ctx: any, contentId: number):
|
|
128
|
-
export declare function contentCreate(ctx: any, content: ContentRequestBody):
|
|
129
|
-
export declare function contentUpdate(ctx: any, contentId: number, content: ContentRequestBody):
|
|
130
|
-
export declare function dataGridSchemaGet(ctx: any, gridName: string):
|
|
128
|
+
export declare function contentGet(ctx: any, contentId: number): AxiosPromise<ContentResponse>;
|
|
129
|
+
export declare function contentCreate(ctx: any, content: ContentRequestBody): AxiosPromise<ContentResponse>;
|
|
130
|
+
export declare function contentUpdate(ctx: any, contentId: number, content: ContentRequestBody): AxiosPromise<ContentResponse>;
|
|
131
|
+
export declare function dataGridSchemaGet(ctx: any, gridName: string): AxiosPromise<Schema<any>>;
|
|
131
132
|
export declare const dataGridAutocompleteGet: (ctx: any, gridName: string, filterName: string, text: string) => Promise<{
|
|
132
133
|
value: number;
|
|
133
134
|
label: string;
|
|
134
135
|
}[]>;
|
|
135
136
|
export declare function forgottenPassword(ctx: any, email: string, cms?: boolean): Promise<void>;
|
|
136
137
|
export declare function getLoggedUser(ctx?: any): Promise<UserResponse>;
|
|
137
|
-
export declare function getEntityMetaSchemas(ctx: any):
|
|
138
|
+
export declare function getEntityMetaSchemas(ctx: any): AxiosPromise<EntityMetaSchemasResponse>;
|
|
138
139
|
export declare function getFormSchema(ctx: any, path: {
|
|
139
140
|
entityAlias: string;
|
|
140
|
-
}):
|
|
141
|
+
}): AxiosPromise<FormSchemaResponse>;
|
|
141
142
|
export declare function getFormValues(ctx: any, path: {
|
|
142
143
|
entityAlias: string;
|
|
143
144
|
id: number;
|
|
144
|
-
}):
|
|
145
|
-
export declare function login(ctx: any, body: LoginRequestBody):
|
|
145
|
+
}): AxiosPromise<any>;
|
|
146
|
+
export declare function login(ctx: any, body: LoginRequestBody): AxiosPromise<LoginResponse>;
|
|
146
147
|
export declare function autocomplete(ctx: any, path: {
|
|
147
148
|
name: string;
|
|
148
149
|
}, query: {
|
|
149
150
|
term: string;
|
|
150
151
|
limit?: number;
|
|
151
|
-
}):
|
|
152
|
+
}): AxiosPromise<AutocompleteResultResponse[]>;
|
|
152
153
|
export declare function saveFormValues<T extends Record<string, any>>(ctx: any, path: {
|
|
153
154
|
entityAlias: string;
|
|
154
155
|
id?: number | null;
|
|
155
|
-
}, body: T):
|
|
156
|
+
}, body: T): AxiosPromise<T>;
|
|
156
157
|
export declare function removeEntity(ctx: any, path: {
|
|
157
158
|
entityAlias: string;
|
|
158
159
|
id: number;
|
|
159
|
-
}):
|
|
160
|
-
export declare function userConfigSave(name: string, data: any):
|
|
161
|
-
export declare function userConfigGetAll(ctx: any):
|
|
160
|
+
}): AxiosPromise<undefined>;
|
|
161
|
+
export declare function userConfigSave(name: string, data: any): AxiosPromise<UserConfigBagResponse>;
|
|
162
|
+
export declare function userConfigGetAll(ctx: any): AxiosPromise<UserConfigBagResponse>;
|
|
162
163
|
export declare function userConfigGet<T>(ctx: any, name: string, defaultValue?: T): Promise<T | undefined>;
|
|
163
164
|
/**
|
|
164
165
|
* @deprecated use import { uploadFile } from "@uxf/core/api/upload-file" or createUploadHandler
|
|
@@ -57,7 +57,12 @@ function ContentBuilder(props) {
|
|
|
57
57
|
return (react_1.default.createElement(content_builder_root_1.ContentBuilderRoot, { formApi: props.formApi, id: (_a = props.id) !== null && _a !== void 0 ? _a : generatedId, onSubmit: props.onSubmit },
|
|
58
58
|
react_1.default.createElement(content_builder_header_1.ContentBuilderHeader, { title: (_b = props.title) !== null && _b !== void 0 ? _b : t("uxf-cms-content-builder:settings.default-title") }),
|
|
59
59
|
react_1.default.createElement(content_builder_body_1.ContentBuilderBody, null,
|
|
60
|
-
react_1.default.createElement(content_builder_1.ContentField, { contentComponents: props.ContentComponents,
|
|
60
|
+
react_1.default.createElement(content_builder_1.ContentField, { contentComponents: props.ContentComponents,
|
|
61
|
+
// react-hook-form 7.85 přidalo do Control člen `_options.validate`, který je
|
|
62
|
+
// kontravariantní v TFieldValues, takže konkrétní Control<ContentBuilderFormData>
|
|
63
|
+
// už není přiřaditelný do volného Control<any>, na kterém stojí celý
|
|
64
|
+
// content-builder plumbing (ContentProps, FormContent, FormRootFields).
|
|
65
|
+
control: props.formApi.control, name: "content" }),
|
|
61
66
|
react_1.default.createElement(content_builder_sidebar_1.ContentBuilderSidebar, { title: t("uxf-cms-content-builder:settings.settings") },
|
|
62
67
|
react_1.default.createElement(tabs_1.Tabs, { onChange: setActiveTab, value: activeTab },
|
|
63
68
|
react_1.default.createElement(tabs_1.Tabs.Panel, { isAlwaysMounted: true, label: t("uxf-cms-content-builder:settings.basic"), name: TabName.Basic },
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { AxiosRequestConfig } from "axios";
|
|
1
|
+
import axios, { AxiosRequestConfig } from "axios";
|
|
2
2
|
export declare function createAxiosInstance(baseURL: string, requestConfig?: AxiosRequestConfig): {
|
|
3
|
-
axiosInstance:
|
|
4
|
-
axiosRequest: <Response>(ctx: any, url: string, method:
|
|
5
|
-
useAxiosRequest: <Response extends Record<string, any> | boolean, RequestBody extends Record<string, any> | null, RequestQuery extends Record<string, any> | null, RequestPath extends Record<string, any> | null>(url: string, method:
|
|
3
|
+
axiosInstance: axios.AxiosInstance;
|
|
4
|
+
axiosRequest: <Response>(ctx: any, url: string, method: axios.Method, body: object | null, query: object | null) => Promise<axios.AxiosResponse<Response, any, {}, any>>;
|
|
5
|
+
useAxiosRequest: <Response extends Record<string, any> | boolean, RequestBody extends Record<string, any> | null, RequestQuery extends Record<string, any> | null, RequestPath extends Record<string, any> | null>(url: string, method: axios.Method, config: import("./types").RequestConfig<RequestBody, RequestQuery, RequestPath>) => [import("axios-hooks").ResponseValues<Response, any, any>, import("./types").Execute<Response, RequestBody, RequestQuery, RequestPath>];
|
|
6
6
|
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { AxiosInstance, AxiosRequestConfig, Method } from "axios";
|
|
2
2
|
/** @deprecated use swr */
|
|
3
|
-
export declare const createAxiosRequest: (baseURL: string, axiosInstance: AxiosInstance, requestConfig: AxiosRequestConfig) => <Response>(ctx: any, url: string, method: Method, body: object | null, query: object | null) => Promise<import("axios").AxiosResponse<Response, any, {}>>;
|
|
3
|
+
export declare const createAxiosRequest: (baseURL: string, axiosInstance: AxiosInstance, requestConfig: AxiosRequestConfig) => <Response>(ctx: any, url: string, method: Method, body: object | null, query: object | null) => Promise<import("axios").AxiosResponse<Response, any, {}, any>>;
|
|
@@ -41,8 +41,8 @@ export declare function useSubMenu(options: SubMenuOptions): {
|
|
|
41
41
|
getReferenceProps: (userProps?: React.HTMLProps<Element>) => Record<string, unknown>;
|
|
42
42
|
getFloatingProps: (userProps?: React.HTMLProps<HTMLElement>) => Record<string, unknown>;
|
|
43
43
|
getItemProps: (userProps?: Omit<React.HTMLProps<HTMLElement>, "selected" | "active"> & {
|
|
44
|
-
active?: boolean;
|
|
45
|
-
selected?: boolean;
|
|
44
|
+
active?: boolean | undefined;
|
|
45
|
+
selected?: boolean | undefined;
|
|
46
46
|
}) => Record<string, unknown>;
|
|
47
47
|
open: boolean;
|
|
48
48
|
setOpen: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uxf/cms",
|
|
3
|
-
"version": "11.
|
|
3
|
+
"version": "11.123.0",
|
|
4
4
|
"description": "UXF Cms",
|
|
5
5
|
"author": "UXFans <dev@uxf.cz>",
|
|
6
6
|
"homepage": "https://gitlab.com/uxf-npm/cms#readme",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"build": "tsc -P tsconfig.json",
|
|
23
23
|
"tw-tokens:check": "tsx ../ui/scripts/generate-tw-tokens.js --mode=\"check\" --twConfig=\"./utils/tailwind.config.js\" --outputPath=\"./ui/tw-tokens/\"",
|
|
24
24
|
"tw-tokens:gen": "tsx ../ui/scripts/generate-tw-tokens.js --twConfig=\"./utils/tailwind.config.js\" --outputPath=\"./ui/tw-tokens/\"",
|
|
25
|
-
"typecheck": "tsc --noEmit
|
|
25
|
+
"typecheck": "tsc --noEmit"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"es6-error": "4.1.1"
|
|
@@ -31,45 +31,45 @@
|
|
|
31
31
|
"@dnd-kit/core": "^6.3.1",
|
|
32
32
|
"@dnd-kit/sortable": "^10.0.0",
|
|
33
33
|
"@dnd-kit/utilities": "^3.2.2",
|
|
34
|
-
"@floating-ui/react": "^0.27.
|
|
35
|
-
"@uxf/core": "11.
|
|
36
|
-
"@uxf/core-react": "11.
|
|
37
|
-
"@uxf/data-grid": "11.
|
|
38
|
-
"@uxf/form": "11.
|
|
39
|
-
"@uxf/router": "11.
|
|
40
|
-
"@uxf/styles": "11.
|
|
41
|
-
"@uxf/ui": "11.
|
|
42
|
-
"@uxf/wysiwyg": "11.
|
|
43
|
-
"axios": "^1.
|
|
34
|
+
"@floating-ui/react": "^0.27.20",
|
|
35
|
+
"@uxf/core": "11.123.0",
|
|
36
|
+
"@uxf/core-react": "11.123.0",
|
|
37
|
+
"@uxf/data-grid": "11.123.0",
|
|
38
|
+
"@uxf/form": "11.123.0",
|
|
39
|
+
"@uxf/router": "11.123.0",
|
|
40
|
+
"@uxf/styles": "11.123.0",
|
|
41
|
+
"@uxf/ui": "11.123.0",
|
|
42
|
+
"@uxf/wysiwyg": "11.123.0",
|
|
43
|
+
"axios": "^1.19.0",
|
|
44
44
|
"axios-hooks": "^5.1.1",
|
|
45
45
|
"next": ">=13.2.0",
|
|
46
46
|
"react": ">=18.2.0",
|
|
47
47
|
"react-dom": ">=18.2.0",
|
|
48
|
-
"react-hook-form": "^7.
|
|
49
|
-
"swr": "^2.
|
|
48
|
+
"react-hook-form": "^7.85.0",
|
|
49
|
+
"swr": "^2.5.0"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"@dnd-kit/core": "^6.3.1",
|
|
53
53
|
"@dnd-kit/sortable": "^10.0.0",
|
|
54
54
|
"@dnd-kit/utilities": "^3.2.2",
|
|
55
|
-
"@floating-ui/react": "^0.27.
|
|
55
|
+
"@floating-ui/react": "^0.27.20",
|
|
56
56
|
"@types/node": "24",
|
|
57
|
-
"@types/react": "18.3.
|
|
57
|
+
"@types/react": "18.3.31",
|
|
58
58
|
"@types/react-dom": "18.3.7",
|
|
59
|
-
"@uxf/core": "11.
|
|
60
|
-
"@uxf/core-react": "11.
|
|
61
|
-
"@uxf/data-grid": "11.
|
|
62
|
-
"@uxf/form": "11.
|
|
63
|
-
"@uxf/router": "11.
|
|
64
|
-
"@uxf/styles": "11.
|
|
65
|
-
"@uxf/ui": "11.
|
|
66
|
-
"@uxf/wysiwyg": "11.
|
|
67
|
-
"axios": "^1.
|
|
59
|
+
"@uxf/core": "11.123.0",
|
|
60
|
+
"@uxf/core-react": "11.123.0",
|
|
61
|
+
"@uxf/data-grid": "11.123.0",
|
|
62
|
+
"@uxf/form": "11.123.0",
|
|
63
|
+
"@uxf/router": "11.123.0",
|
|
64
|
+
"@uxf/styles": "11.123.0",
|
|
65
|
+
"@uxf/ui": "11.123.0",
|
|
66
|
+
"@uxf/wysiwyg": "11.123.0",
|
|
67
|
+
"axios": "^1.19.0",
|
|
68
68
|
"axios-hooks": "^5.1.1",
|
|
69
|
-
"next": "16.
|
|
69
|
+
"next": "16.3.0",
|
|
70
70
|
"react": "18.3.1",
|
|
71
71
|
"react-dom": "18.3.1",
|
|
72
|
-
"react-hook-form": "^7.
|
|
73
|
-
"swr": "^2.
|
|
72
|
+
"react-hook-form": "^7.85.0",
|
|
73
|
+
"swr": "^2.5.0"
|
|
74
74
|
}
|
|
75
75
|
}
|