@uxf/cms 10.0.0-beta.79 → 10.0.0-beta.80
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/config/container.d.ts +3 -3
- package/deprecated/api/api-client.js +1 -1
- package/deprecated/hoc/with-authenticate.js +3 -3
- package/deprecated/redux/configure-store.js +2 -2
- package/deprecated/redux/entities/actions.d.ts +1 -1
- package/deprecated/redux/entities/index.d.ts +1 -1
- package/deprecated/redux/entities/index.js +1 -1
- package/deprecated/redux/entities/selectors.d.ts +1 -1
- package/deprecated/redux/index.d.ts +2 -2
- package/deprecated/redux/index.js +4 -4
- package/deprecated/redux/types.d.ts +1 -1
- package/deprecated/redux/user/index.d.ts +1 -1
- package/deprecated/redux/user/index.js +1 -1
- package/forms/change-password-form/change-password-form.js +2 -2
- package/forms/components/wysiwyg-input/wysiwyg-input.d.ts +2 -2
- package/forms/components/wysiwyg-input/wysiwyg-input.js +2 -2
- package/forms/forgotten-password-form/forgotten-password-form.js +1 -1
- package/forms/invite-user-form/invite-user-form.js +1 -1
- package/forms/login-form/login-form.js +1 -1
- package/lib/api/create-use-axios-request.js +1 -1
- package/lib/layout/breadcrumbs.js +2 -2
- package/lib/layout/index.d.ts +1 -1
- package/lib/layout/index.js +1 -1
- package/lib/layout/layout.js +3 -3
- package/lib/layout/sidebar.js +3 -3
- package/lib/login-layout/login-layout.js +1 -1
- package/lib/menu/factory.d.ts +1 -1
- package/lib/menu/index.d.ts +3 -3
- package/lib/menu/index.js +3 -3
- package/lib/menu/mobile-bar.js +4 -4
- package/lib/menu/model.d.ts +4 -4
- package/lib/menu/types.d.ts +1 -1
- package/lib/menu/ui/list-item/list-item.js +3 -3
- package/lib/menu/ui/list-item/types.d.ts +1 -1
- package/lib/menu/ui/menu-item.js +1 -1
- package/lib/menu/ui/menu-super-section-item.js +1 -1
- package/lib/menu/ui/menu.js +1 -1
- package/lib/menu/ui/sub-menu/sub-menu-item.js +1 -1
- package/lib/menu/ui/sub-menu/sub-menu-mobile.js +4 -4
- package/lib/menu/ui/sub-menu/sub-menu.js +4 -4
- package/lib/menu/ui/sub-menu/use-sub-menu.d.ts +14 -6
- package/lib/menu/ui/sub-menu/use-sub-menu.js +16 -16
- package/lib/menu/ui/user-menu.js +3 -3
- package/package.json +34 -49
- package/pages/change-password-page/change-password-page.js +1 -1
- package/pages/change-password-page/types.d.ts +1 -1
- package/pages/content-builder/components/form-content.d.ts +1 -1
- package/pages/content-builder/components/form-content.js +4 -4
- package/pages/content-builder/components/form-root-fields.d.ts +1 -1
- package/pages/content-builder/components/form-root-fields.js +2 -2
- package/pages/content-builder/components/form.d.ts +2 -2
- package/pages/content-builder/components/form.js +4 -4
- package/pages/content-builder/components/header.js +2 -2
- package/pages/content-builder/content/feature-section.d.ts +1 -1
- package/pages/content-builder/content/feature-section.js +4 -4
- package/pages/content-builder/content/gallery.d.ts +1 -1
- package/pages/content-builder/content/gallery.js +2 -2
- package/pages/content-builder/content/hero-section.js +1 -1
- package/pages/content-builder/content/people.d.ts +1 -1
- package/pages/content-builder/content/people.js +5 -5
- package/pages/content-builder/content/wysiwyg.d.ts +2 -2
- package/pages/content-builder/content/wysiwyg.js +1 -1
- package/pages/content-builder/content-builder-page.js +4 -4
- package/pages/content-builder/content-field.d.ts +1 -1
- package/pages/content-builder/content-field.js +6 -6
- package/pages/content-builder/content-header.d.ts +1 -1
- package/pages/content-builder/content-header.js +5 -5
- package/pages/content-builder/hooks/use-sortable.js +1 -1
- package/pages/content-builder/index.d.ts +2 -2
- package/pages/content-builder/index.js +2 -2
- package/pages/content-builder/mapper.d.ts +1 -1
- package/pages/content-builder/types.d.ts +2 -2
- package/pages/form-page/base-field.js +14 -14
- package/pages/form-page/field-array.js +2 -2
- package/pages/form-page/form-page.d.ts +2 -1
- package/pages/form-page/form-page.js +7 -7
- package/pages/form-page/form.d.ts +2 -2
- package/pages/form-page/form.js +2 -2
- package/pages/form-page/index.d.ts +3 -3
- package/pages/form-page/index.js +3 -3
- package/pages/form-page/types.d.ts +1 -1
- package/pages/grid-page/grid-page.js +4 -4
- package/pages/grid-page/types.d.ts +2 -2
- package/pages/invite-user-page/types.d.ts +1 -1
- package/pages/login-page/login-page.js +1 -1
- package/pages/renew-password-page/types.d.ts +1 -1
- package/ui/copy-to-clipboard-button/copy-to-clipboard-button.js +2 -2
- package/ui/tw-tokens/tw-colors.d.ts +283 -282
- package/ui/tw-tokens/tw-colors.js +283 -282
- package/ui/tw-tokens/tw-line-height.d.ts +8 -8
- package/ui/tw-tokens/tw-line-height.js +8 -8
- package/ui/tw-tokens/tw-spacing.d.ts +34 -34
- package/ui/tw-tokens/tw-spacing.js +34 -34
- package/ui/tw-tokens/tw-z-index.d.ts +8 -7
- package/ui/tw-tokens/tw-z-index.js +8 -7
- package/ui/widget/index.d.ts +1 -1
- package/ui/widget/index.js +1 -1
- package/ui/widget/types.d.ts +1 -1
package/config/container.d.ts
CHANGED
@@ -1,8 +1,8 @@
|
|
1
|
-
import {
|
1
|
+
import { FunctionParametersGenerator } from "@uxf/router";
|
2
2
|
import { NextPageContext } from "next";
|
3
|
-
import UserResponse, { FileResponse } from "../api";
|
4
3
|
import { LinkProps } from "next/link";
|
5
|
-
import {
|
4
|
+
import { ReactNode } from "react";
|
5
|
+
import UserResponse, { FileResponse } from "../api";
|
6
6
|
export interface NotificationServiceInterface {
|
7
7
|
info: (message: ReactNode) => void;
|
8
8
|
success: (message: ReactNode) => void;
|
@@ -3,10 +3,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
const axios_1 = __importDefault(require("axios"));
|
6
7
|
const ForbiddenError_1 = require("../../errors/ForbiddenError");
|
7
8
|
const NetworkError_1 = require("../../errors/NetworkError");
|
8
9
|
const UnauthorizedError_1 = require("../../errors/UnauthorizedError");
|
9
|
-
const axios_1 = __importDefault(require("axios"));
|
10
10
|
const getClient = (options = {}) => {
|
11
11
|
const client = axios_1.default.create(options);
|
12
12
|
// Add a request interceptor
|
@@ -27,12 +27,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
27
27
|
};
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
29
29
|
exports.withAuthenticate = void 0;
|
30
|
-
const
|
30
|
+
const react_1 = __importStar(require("react"));
|
31
31
|
const api_1 = require("../../api");
|
32
|
+
const config_1 = require("../../config");
|
33
|
+
const UnauthorizedError_1 = require("../../errors/UnauthorizedError");
|
32
34
|
const user_1 = require("../redux/user");
|
33
|
-
const react_1 = __importStar(require("react"));
|
34
35
|
const cms_authorizator_1 = __importDefault(require("../security/cms-authorizator"));
|
35
|
-
const config_1 = require("../../config");
|
36
36
|
// TODO component any
|
37
37
|
const withAuthenticate = (config) => (Component) => {
|
38
38
|
var _a;
|
@@ -4,13 +4,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.initializeStore = void 0;
|
7
|
+
const extension_1 = require("@redux-devtools/extension");
|
7
8
|
const redux_1 = require("redux");
|
8
|
-
const redux_devtools_extension_1 = require("redux-devtools-extension");
|
9
9
|
const reducer_1 = __importDefault(require("../redux/entities/reducer"));
|
10
10
|
const reducer_2 = __importDefault(require("../redux/user/reducer"));
|
11
11
|
// TODO: create root reducer to have possibility reset store on logout...
|
12
12
|
const initializeStore = (initialState = {}) => (0, redux_1.createStore)((0, redux_1.combineReducers)({
|
13
13
|
entities: reducer_1.default,
|
14
14
|
user: reducer_2.default,
|
15
|
-
}), initialState, (0,
|
15
|
+
}), initialState, (0, extension_1.composeWithDevTools)((0, redux_1.applyMiddleware)()));
|
16
16
|
exports.initializeStore = initializeStore;
|
@@ -1,7 +1,7 @@
|
|
1
|
+
import { Schema } from "@uxf/data-grid";
|
1
2
|
import { EntityMetaSchema } from "../../../api";
|
2
3
|
import { EntityFormSchema } from "../../types/form";
|
3
4
|
import { ActionsUnion } from "../redux-helper";
|
4
|
-
import { Schema } from "@uxf/data-grid";
|
5
5
|
export interface IState {
|
6
6
|
meta: Record<string, EntityMetaSchema>;
|
7
7
|
form: Record<string, EntityFormSchema>;
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
15
|
};
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
__exportStar(require("./selectors"), exports);
|
18
17
|
__exportStar(require("./actions"), exports);
|
18
|
+
__exportStar(require("./selectors"), exports);
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { Schema } from "@uxf/data-grid";
|
2
2
|
import { EntityMetaSchema } from "../../../api";
|
3
|
-
import { IReduxState } from "../types";
|
4
3
|
import { EntityFormSchema } from "../../types/form";
|
4
|
+
import { IReduxState } from "../types";
|
5
5
|
export declare const metaSchemaExistsSelector: (state: IReduxState) => boolean;
|
6
6
|
export declare const metaSchemaSelector: (entityAlias: string) => (state: IReduxState) => EntityMetaSchema;
|
7
7
|
export declare const gridSchemaExistsSelector: (entityAlias: string) => (state: IReduxState) => boolean;
|
@@ -14,9 +14,9 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
15
|
};
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
exports.
|
18
|
-
var with_redux_store_1 = require("./with-redux-store");
|
19
|
-
Object.defineProperty(exports, "withReduxStore", { enumerable: true, get: function () { return with_redux_store_1.withReduxStore; } });
|
20
|
-
__exportStar(require("./types"), exports);
|
17
|
+
exports.withReduxStore = exports.useSelector = void 0;
|
21
18
|
var react_redux_1 = require("react-redux");
|
22
19
|
Object.defineProperty(exports, "useSelector", { enumerable: true, get: function () { return react_redux_1.useSelector; } });
|
20
|
+
__exportStar(require("./types"), exports);
|
21
|
+
var with_redux_store_1 = require("./with-redux-store");
|
22
|
+
Object.defineProperty(exports, "withReduxStore", { enumerable: true, get: function () { return with_redux_store_1.withReduxStore; } });
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { ActionTypes as EntitiesActionTypes, IState as IEntitiesState } from "../redux/entities/actions";
|
2
|
-
import {
|
2
|
+
import { IState as IUserState, ActionTypes as UserActionTypes } from "../redux/user/actions";
|
3
3
|
export interface IReduxState {
|
4
4
|
entities: IEntitiesState;
|
5
5
|
user: IUserState;
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
15
|
};
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
__exportStar(require("./selectors"), exports);
|
18
17
|
__exportStar(require("./actions"), exports);
|
18
|
+
__exportStar(require("./selectors"), exports);
|
@@ -4,12 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.ChangePasswordForm = void 0;
|
7
|
-
const react_1 = __importDefault(require("react"));
|
8
7
|
const form_1 = require("@uxf/form/form");
|
9
8
|
const text_input_1 = require("@uxf/form/text-input");
|
10
9
|
const button_1 = require("@uxf/ui/button");
|
11
|
-
const
|
10
|
+
const react_1 = __importDefault(require("react"));
|
12
11
|
const react_hook_form_1 = require("react-hook-form");
|
12
|
+
const widget_1 = require("../../ui/widget");
|
13
13
|
const ChangePasswordForm = (props) => {
|
14
14
|
// eslint-disable-next-line react/destructuring-assignment
|
15
15
|
const { defaultValues, ...formProps } = props;
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import { FormControlProps } from "@uxf/ui/types";
|
2
2
|
import { WysiwygContent, WysiwygPlugin } from "@uxf/wysiwyg";
|
3
3
|
import { CreateAllPluginsOptions } from "@uxf/wysiwyg/create-all-plugins-with-ui";
|
4
|
+
import { WysiwygRecursivePlugin } from "@uxf/wysiwyg/types";
|
5
|
+
import { WysiwygEditorProps } from "@uxf/wysiwyg/wysiwyg-editor";
|
4
6
|
import React, { KeyboardEventHandler, ReactNode } from "react";
|
5
7
|
import { FieldValues, UseControllerProps } from "react-hook-form";
|
6
|
-
import { WysiwygEditorProps } from "@uxf/wysiwyg/wysiwyg-editor";
|
7
|
-
import { WysiwygRecursivePlugin } from "@uxf/wysiwyg/types";
|
8
8
|
export type UIWysiwygInputProps = FormControlProps<WysiwygContent, HTMLDivElement> & {
|
9
9
|
allPluginsOptions?: CreateAllPluginsOptions;
|
10
10
|
autoComplete?: string;
|
@@ -27,13 +27,13 @@ exports.WysiwygInput = void 0;
|
|
27
27
|
const classes_1 = require("@uxf/core/constants/classes");
|
28
28
|
const useInputFocus_1 = require("@uxf/core/hooks/useInputFocus");
|
29
29
|
const cx_1 = require("@uxf/core/utils/cx");
|
30
|
+
const file_1 = require("@uxf/core/utils/file");
|
31
|
+
const form_component_1 = require("@uxf/ui/form-component");
|
30
32
|
const wysiwyg_1 = require("@uxf/wysiwyg");
|
31
33
|
const create_all_plugins_with_ui_1 = require("@uxf/wysiwyg/create-all-plugins-with-ui");
|
32
34
|
const react_1 = __importStar(require("react"));
|
33
35
|
const react_hook_form_1 = require("react-hook-form");
|
34
|
-
const file_1 = require("@uxf/core/utils/file");
|
35
36
|
const api_1 = require("../../../api");
|
36
|
-
const form_component_1 = require("@uxf/ui/form-component");
|
37
37
|
function WysiwygInput(props) {
|
38
38
|
var _a, _b, _c, _d, _e;
|
39
39
|
const { field, fieldState } = (0, react_hook_form_1.useController)({
|
@@ -27,8 +27,8 @@ exports.ForgottenPasswordForm = void 0;
|
|
27
27
|
const form_1 = require("@uxf/form/form");
|
28
28
|
const text_input_1 = require("@uxf/form/text-input");
|
29
29
|
const button_1 = require("@uxf/ui/button");
|
30
|
-
const react_1 = __importStar(require("react"));
|
31
30
|
const text_link_1 = require("@uxf/ui/text-link");
|
31
|
+
const react_1 = __importStar(require("react"));
|
32
32
|
const react_hook_form_1 = require("react-hook-form");
|
33
33
|
const ForgottenPasswordForm = (props) => {
|
34
34
|
// eslint-disable-next-line react/destructuring-assignment
|
@@ -11,8 +11,8 @@ const multi_combobox_1 = require("@uxf/form/multi-combobox");
|
|
11
11
|
const text_input_1 = require("@uxf/form/text-input");
|
12
12
|
const button_1 = require("@uxf/ui/button");
|
13
13
|
const react_1 = __importDefault(require("react"));
|
14
|
-
const widget_1 = require("../../ui/widget");
|
15
14
|
const react_hook_form_1 = require("react-hook-form");
|
15
|
+
const widget_1 = require("../../ui/widget");
|
16
16
|
const InviteUserForm = (props) => {
|
17
17
|
// eslint-disable-next-line react/destructuring-assignment
|
18
18
|
const { defaultValues, ...formProps } = props;
|
@@ -24,11 +24,11 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
24
24
|
};
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
26
26
|
exports.LoginForm = void 0;
|
27
|
-
const react_1 = __importStar(require("react"));
|
28
27
|
const form_1 = require("@uxf/form/form");
|
29
28
|
const text_input_1 = require("@uxf/form/text-input");
|
30
29
|
const button_1 = require("@uxf/ui/button");
|
31
30
|
const text_link_1 = require("@uxf/ui/text-link");
|
31
|
+
const react_1 = __importStar(require("react"));
|
32
32
|
const react_hook_form_1 = require("react-hook-form");
|
33
33
|
const LoginForm = (props) => {
|
34
34
|
// eslint-disable-next-line react/destructuring-assignment
|
@@ -2,9 +2,9 @@
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
exports.createUseAxiosRequest = void 0;
|
4
4
|
const axios_hooks_1 = require("axios-hooks");
|
5
|
+
const react_1 = require("react");
|
5
6
|
// eslint-disable-next-line import/no-cycle
|
6
7
|
const config_1 = require("../../config");
|
7
|
-
const react_1 = require("react");
|
8
8
|
const createUseAxiosRequest = (axiosInstance, requestConfig) => {
|
9
9
|
const useAxios = (0, axios_hooks_1.makeUseAxios)({
|
10
10
|
axios: axiosInstance,
|
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.Breadcrumbs = void 0;
|
7
|
-
const react_1 = __importDefault(require("react"));
|
8
|
-
const link_1 = __importDefault(require("next/link"));
|
9
7
|
const icon_1 = require("@uxf/ui/icon");
|
8
|
+
const link_1 = __importDefault(require("next/link"));
|
9
|
+
const react_1 = __importDefault(require("react"));
|
10
10
|
const Breadcrumbs = (props) => {
|
11
11
|
if (props.items.length === 0) {
|
12
12
|
return null;
|
package/lib/layout/index.d.ts
CHANGED
package/lib/layout/index.js
CHANGED
@@ -14,6 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
15
|
};
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
__exportStar(require("./layout"), exports);
|
18
17
|
__exportStar(require("./breadcrumbs"), exports);
|
18
|
+
__exportStar(require("./layout"), exports);
|
19
19
|
__exportStar(require("./types"), exports);
|
package/lib/layout/layout.js
CHANGED
@@ -5,14 +5,14 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5
5
|
};
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
7
7
|
exports.Layout = void 0;
|
8
|
+
const loader_1 = require("@uxf/ui/loader/loader");
|
8
9
|
const head_1 = __importDefault(require("next/head"));
|
9
10
|
const react_1 = __importDefault(require("react"));
|
10
11
|
const config_1 = require("../../config");
|
11
|
-
const sidebar_1 = require("./sidebar");
|
12
|
-
const styles_1 = require("./styles");
|
13
12
|
const breadcrumbs_1 = require("./breadcrumbs");
|
14
|
-
const loader_1 = require("@uxf/ui/loader/loader");
|
15
13
|
const layout_container_1 = require("./layout-container");
|
14
|
+
const sidebar_1 = require("./sidebar");
|
15
|
+
const styles_1 = require("./styles");
|
16
16
|
const Layout = (props) => {
|
17
17
|
var _a, _b;
|
18
18
|
return (react_1.default.createElement(react_1.default.Fragment, null,
|
package/lib/layout/sidebar.js
CHANGED
@@ -25,11 +25,11 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
26
26
|
exports.Sidebar = void 0;
|
27
27
|
const react_1 = __importStar(require("react"));
|
28
|
+
const tw_screens_1 = require("../../ui/tw-tokens/tw-screens");
|
28
29
|
const menu_1 = require("../menu");
|
29
|
-
const styles_1 = require("./styles");
|
30
|
-
const user_menu_1 = require("../menu/ui/user-menu");
|
31
30
|
const mobile_bar_1 = require("../menu/mobile-bar");
|
32
|
-
const
|
31
|
+
const user_menu_1 = require("../menu/ui/user-menu");
|
32
|
+
const styles_1 = require("./styles");
|
33
33
|
const uxfLogo = (react_1.default.createElement("svg", { width: "134", height: "30", viewBox: "0 0 179 40" },
|
34
34
|
react_1.default.createElement("path", { fill: "#FFF", fillRule: "evenodd", d: "M33.563 12.874a9.103 9.103 0 0 0 0-12.874L20.69 12.874l.107.105a9.103 9.103 0 0 0 12.766-.105Zm-20.69-6.437a9.103 9.103 0 0 1 .106 12.766l-.105.107L0 6.437a9.103 9.103 0 0 1 12.874 0ZM40 33.563 27.127 20.69l-.106.107a9.103 9.103 0 0 0 12.98 12.766Zm-20.69-6.437-.107-.105A9.103 9.103 0 0 0 6.437 40l12.874-12.874Z", clipRule: "evenodd" }),
|
35
35
|
react_1.default.createElement("path", { fill: "#FFF", fillRule: "evenodd", d: "m84.325 7.295 5.133 8.675h.199l5.158-8.675h6.078l-7.768 12.727 7.942 12.727h-6.19l-5.22-8.687h-.199l-5.22 8.687h-6.165l7.967-12.727-7.818-12.727h6.103Zm-24.194 0v16.07c0 .97.214 1.832.64 2.586a4.58 4.58 0 0 0 1.809 1.777c.779.431 1.686.647 2.722.647 1.044 0 1.953-.216 2.728-.647a4.591 4.591 0 0 0 1.802-1.777c.427-.754.64-1.616.64-2.585V7.296h5.382v16.53c0 1.856-.441 3.48-1.324 4.872-.882 1.392-2.115 2.475-3.697 3.25-1.583.775-3.426 1.162-5.531 1.162-2.113 0-3.96-.387-5.543-1.162-1.583-.775-2.813-1.858-3.692-3.25-.878-1.392-1.317-3.016-1.317-4.872V7.296h5.381ZM170.25 13.41c2.411 0 4.311.51 5.698 1.529 1.388 1.019 2.198 2.407 2.43 4.164l-4.847.298a2.555 2.555 0 0 0-.534-1.125 2.942 2.942 0 0 0-1.075-.808c-.444-.203-.972-.304-1.585-.304-.821 0-1.512.172-2.076.515-.563.344-.845.802-.845 1.374 0 .456.182.84.547 1.156.364.315.99.567 1.877.758l3.455.696c1.856.381 3.24.994 4.151 1.84.912.845 1.367 1.955 1.367 3.33 0 1.252-.366 2.35-1.1 3.294-.733.945-1.736 1.68-3.007 2.206-1.272.526-2.737.79-4.394.79-2.527 0-4.539-.529-6.034-1.585-1.496-1.057-2.372-2.496-2.629-4.32l5.208-.273c.157.77.538 1.357 1.143 1.759.605.402 1.38.603 2.324.603.928 0 1.676-.18 2.244-.54.567-.361.855-.827.864-1.4-.009-.48-.212-.875-.609-1.186-.398-.31-1.011-.55-1.84-.715l-3.306-.659c-1.864-.372-3.25-1.019-4.157-1.938-.908-.92-1.361-2.093-1.361-3.518 0-1.226.333-2.283 1-3.17.667-.886 1.608-1.57 2.821-2.05 1.214-.48 2.637-.72 4.27-.72Zm-36.686.373a12.285 12.285 0 0 0-3.051-.373c-1.525 0-2.865.23-4.021.69-1.156.46-2.098 1.114-2.827 1.964-.73.849-1.219 1.854-1.467 3.014l4.897.397c.182-.63.555-1.153 1.119-1.572.563-.418 1.321-.627 2.274-.627.903 0 1.601.215 2.094.646.493.43.74 1.04.74 1.827v.075c0 .405-.153.712-.46.92-.307.206-.8.362-1.479.465-.68.104-1.574.214-2.685.33-.944.09-1.845.248-2.703.472a7.698 7.698 0 0 0-2.293.994 4.727 4.727 0 0 0-1.591 1.74c-.39.721-.584 1.612-.584 2.673 0 1.259.275 2.31.826 3.15a5.147 5.147 0 0 0 2.256 1.902c.953.427 2.038.64 3.257.64.944 0 1.777-.126 2.498-.38a5.55 5.55 0 0 0 1.852-1.055 5.31 5.31 0 0 0 1.23-1.573h.149v2.648h5.022V19.873c0-1.135-.22-2.11-.659-2.927a5.655 5.655 0 0 0-1.796-2.007 8.039 8.039 0 0 0-2.598-1.156Zm-13.424-2.05V7.294h-16.853v25.454h5.381V22.235h10.354v-4.438h-10.354v-6.065h11.472Zm32.603 1.677c1.326 0 2.482.29 3.468.87.986.58 1.753 1.407 2.3 2.48.546 1.073.82 2.35.82 3.834V32.75h-5.295V21.539c.008-1.169-.29-2.082-.895-2.74-.605-.66-1.437-.989-2.498-.989-.713 0-1.34.153-1.883.46a3.166 3.166 0 0 0-1.268 1.336c-.302.584-.458 1.286-.466 2.107V32.75h-5.295V13.659h5.047v3.368H147a5.358 5.358 0 0 1 2.126-2.641c.994-.65 2.2-.976 3.616-.976Zm-20.061 10.782c.286-.087.512-.184.678-.292v2.026c0 .671-.17 1.272-.51 1.802-.34.53-.808.951-1.404 1.262-.597.31-1.285.466-2.064.466-.812 0-1.481-.189-2.007-.566-.526-.377-.789-.925-.789-1.646 0-.497.128-.914.385-1.25.257-.335.617-.602 1.082-.801a6.547 6.547 0 0 1 1.628-.435l.969-.143a24.15 24.15 0 0 0 1.069-.186c.356-.071.677-.15.963-.237Z", clipRule: "evenodd" })));
|
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.LoginLayout = void 0;
|
7
|
+
const paper_1 = require("@uxf/ui/paper/paper");
|
7
8
|
const head_1 = __importDefault(require("next/head"));
|
8
9
|
const react_1 = __importDefault(require("react"));
|
9
|
-
const paper_1 = require("@uxf/ui/paper/paper");
|
10
10
|
const LoginLayout = (props) => {
|
11
11
|
return (react_1.default.createElement("div", { className: "uxf-cms-login-layout" },
|
12
12
|
react_1.default.createElement(head_1.default, null,
|
package/lib/menu/factory.d.ts
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
import { MenuItem, UserMenuData } from "./model";
|
2
1
|
import { IconName } from "@uxf/ui/icon/types";
|
3
2
|
import { ReactElement, ReactNode } from "react";
|
3
|
+
import { MenuItem, UserMenuData } from "./model";
|
4
4
|
export declare function createCustomContent(title: string, content: ReactNode): MenuItem;
|
5
5
|
export declare function createSuperSection(title: string, children?: MenuItem[]): MenuItem;
|
6
6
|
export declare function createSection(title: string, icon?: IconName, children?: MenuItem[]): MenuItem;
|
package/lib/menu/index.d.ts
CHANGED
package/lib/menu/index.js
CHANGED
@@ -14,8 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
15
|
};
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
__exportStar(require("./
|
18
|
-
__exportStar(require("./ui/menu-item"), exports);
|
17
|
+
__exportStar(require("./active-item-resolver"), exports);
|
19
18
|
__exportStar(require("./factory"), exports);
|
20
19
|
__exportStar(require("./types"), exports);
|
21
|
-
__exportStar(require("./
|
20
|
+
__exportStar(require("./ui/menu"), exports);
|
21
|
+
__exportStar(require("./ui/menu-item"), exports);
|
package/lib/menu/mobile-bar.js
CHANGED
@@ -4,14 +4,14 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.MobileBar = void 0;
|
7
|
-
const
|
8
|
-
const link_1 = __importDefault(require("next/link"));
|
7
|
+
const cx_1 = require("@uxf/core/utils/cx");
|
9
8
|
const icon_1 = require("@uxf/ui/icon");
|
10
|
-
const
|
9
|
+
const link_1 = __importDefault(require("next/link"));
|
10
|
+
const react_1 = __importDefault(require("react"));
|
11
11
|
const config_1 = require("../../config");
|
12
12
|
const avatar_1 = require("../../ui/avatar");
|
13
|
-
const cx_1 = require("@uxf/core/utils/cx");
|
14
13
|
const get_avatar_user_letters_1 = require("../../ui/avatar/get-avatar-user-letters");
|
14
|
+
const sub_menu_mobile_1 = require("./ui/sub-menu/sub-menu-mobile");
|
15
15
|
const MobileBar = (props) => {
|
16
16
|
const useLoggedUser = config_1.container.get("useLoggedUser");
|
17
17
|
const loggedUser = useLoggedUser();
|
package/lib/menu/model.d.ts
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
import {
|
2
|
-
import { Resolver } from "./types";
|
3
|
-
import { NextRouter } from "next/router";
|
1
|
+
import { ImageSource } from "@uxf/core/utils/resizer";
|
4
2
|
import { IconName } from "@uxf/ui/icon/types";
|
3
|
+
import { NextRouter } from "next/router";
|
5
4
|
import { ReactElement, ReactNode } from "react";
|
6
|
-
import {
|
5
|
+
import { LoggedUser } from "../../config/container";
|
6
|
+
import { Resolver } from "./types";
|
7
7
|
type ItemType = "custom" | "super-section" | "section" | "link";
|
8
8
|
export type UserMenuData = {
|
9
9
|
avatar?: ImageSource;
|
package/lib/menu/types.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
|
-
import { MenuItem } from "./model";
|
2
1
|
import { NextRouter } from "next/router";
|
2
|
+
import { MenuItem } from "./model";
|
3
3
|
export type RouterResolver = (router: NextRouter, activeRoute: string) => boolean;
|
4
4
|
export type Resolver = (item: MenuItem) => RouterResolver;
|
5
5
|
export type MenuConfiguration = MenuItem[];
|
@@ -4,12 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.ListItem = void 0;
|
7
|
-
const
|
7
|
+
const classes_1 = require("@uxf/core/constants/classes");
|
8
8
|
const icon_1 = require("@uxf/ui/icon");
|
9
9
|
const link_1 = __importDefault(require("next/link"));
|
10
|
-
const
|
10
|
+
const react_1 = __importDefault(require("react"));
|
11
11
|
const config_1 = require("../../../../config");
|
12
|
-
const
|
12
|
+
const sub_menu_1 = require("../sub-menu/sub-menu");
|
13
13
|
const ListItem = (props) => {
|
14
14
|
var _a, _b, _c, _d;
|
15
15
|
const hasSubMenu = !!((_a = props.subMenu) === null || _a === void 0 ? void 0 : _a.length);
|
package/lib/menu/ui/menu-item.js
CHANGED
@@ -24,10 +24,10 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
24
24
|
};
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
26
26
|
exports.MenuItem = void 0;
|
27
|
+
const router_1 = require("next/router");
|
27
28
|
const react_1 = __importStar(require("react"));
|
28
29
|
const config_1 = require("../../../config");
|
29
30
|
const list_item_1 = require("./list-item");
|
30
|
-
const router_1 = require("next/router");
|
31
31
|
const MenuItem = (props) => {
|
32
32
|
var _a, _b, _c, _d;
|
33
33
|
const router = (0, router_1.useRouter)();
|
@@ -26,8 +26,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.MenuSuperSectionItem = void 0;
|
27
27
|
const react_1 = __importStar(require("react"));
|
28
28
|
const config_1 = require("../../../config");
|
29
|
-
const menu_item_1 = require("./menu-item");
|
30
29
|
const menu_custom_item_1 = require("./menu-custom-item");
|
30
|
+
const menu_item_1 = require("./menu-item");
|
31
31
|
const MenuSuperSectionItem = (props) => {
|
32
32
|
const useLoggedUser = config_1.container.get("useLoggedUser");
|
33
33
|
const loggedUser = useLoggedUser();
|
package/lib/menu/ui/menu.js
CHANGED
@@ -25,8 +25,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
26
26
|
exports.Menu = void 0;
|
27
27
|
const react_1 = __importStar(require("react"));
|
28
|
-
const menu_item_1 = require("./menu-item");
|
29
28
|
const menu_custom_item_1 = require("./menu-custom-item");
|
29
|
+
const menu_item_1 = require("./menu-item");
|
30
30
|
const menu_super_section_item_1 = require("./menu-super-section-item");
|
31
31
|
const Menu = (props) => {
|
32
32
|
return (react_1.default.createElement("div", { className: "uxf-cms-menu" }, props.menu.map((item, index) => (react_1.default.createElement(react_1.Fragment, { key: index },
|
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.SubMenuItem = void 0;
|
7
|
+
const link_1 = __importDefault(require("next/link"));
|
7
8
|
const react_1 = __importDefault(require("react"));
|
8
9
|
const config_1 = require("../../../../config");
|
9
|
-
const link_1 = __importDefault(require("next/link"));
|
10
10
|
const SubMenuItem = (props) => {
|
11
11
|
var _a;
|
12
12
|
const useLoggedUser = config_1.container.get("useLoggedUser");
|
@@ -24,12 +24,11 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
24
24
|
};
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
26
26
|
exports.SubMenuMobile = void 0;
|
27
|
-
const react_1 = __importStar(require("react"));
|
28
|
-
const forwardRef_1 = require("@uxf/core/utils/forwardRef");
|
29
|
-
const use_sub_menu_1 = require("./use-sub-menu");
|
30
27
|
const composeRefs_1 = require("@uxf/core/utils/composeRefs");
|
28
|
+
const react_1 = __importStar(require("react"));
|
31
29
|
const sub_menu_item_1 = require("./sub-menu-item");
|
32
|
-
|
30
|
+
const use_sub_menu_1 = require("./use-sub-menu");
|
31
|
+
exports.SubMenuMobile = (0, react_1.forwardRef)(({ children, content, title }, ref) => {
|
33
32
|
const subMenu = (0, use_sub_menu_1.useSubMenu)({ isMobile: true });
|
34
33
|
const stableRef = (0, react_1.useMemo)(() => (0, composeRefs_1.composeRefs)(ref, subMenu.refs.setReference, children.ref), [ref, subMenu.refs.setReference, children]);
|
35
34
|
return (react_1.default.createElement(react_1.default.Fragment, null,
|
@@ -46,3 +45,4 @@ exports.SubMenuMobile = (0, forwardRef_1.forwardRef)("SubMenuMobile", ({ childre
|
|
46
45
|
react_1.default.createElement("div", { className: "uxf-cms-sub-menu__title" }, title),
|
47
46
|
content.map((item, index) => (react_1.default.createElement(sub_menu_item_1.SubMenuItem, { key: index, item: item })))))));
|
48
47
|
});
|
48
|
+
exports.SubMenuMobile.displayName = "SubMenuMobile";
|
@@ -24,12 +24,11 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
24
24
|
};
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
26
26
|
exports.SubMenu = void 0;
|
27
|
-
const react_1 = __importStar(require("react"));
|
28
|
-
const forwardRef_1 = require("@uxf/core/utils/forwardRef");
|
29
|
-
const use_sub_menu_1 = require("./use-sub-menu");
|
30
27
|
const composeRefs_1 = require("@uxf/core/utils/composeRefs");
|
28
|
+
const react_1 = __importStar(require("react"));
|
31
29
|
const sub_menu_item_1 = require("./sub-menu-item");
|
32
|
-
|
30
|
+
const use_sub_menu_1 = require("./use-sub-menu");
|
31
|
+
exports.SubMenu = (0, react_1.forwardRef)(({ children, content }, ref) => {
|
33
32
|
const subMenu = (0, use_sub_menu_1.useSubMenu)({ isMobile: false });
|
34
33
|
const stableRef = (0, react_1.useMemo)(() => (0, composeRefs_1.composeRefs)(ref, subMenu.refs.setReference, children.ref), [ref, subMenu.refs.setReference, children]);
|
35
34
|
return (react_1.default.createElement("div", { className: "uxf-cms-sub-menu" },
|
@@ -44,3 +43,4 @@ exports.SubMenu = (0, forwardRef_1.forwardRef)("SubMenu", ({ children, content }
|
|
44
43
|
className: "uxf-cms-sidebar__scrollbar uxf-cms-sub-menu__wrapper",
|
45
44
|
}) }, content.map((item, index) => (react_1.default.createElement(sub_menu_item_1.SubMenuItem, { key: index, item: item })))))));
|
46
45
|
});
|
46
|
+
exports.SubMenu.displayName = "SubMenu";
|
@@ -8,18 +8,30 @@ export declare function useSubMenu(options: SubMenuOptions): {
|
|
8
8
|
middlewareData: import("@floating-ui/core").MiddlewareData;
|
9
9
|
x: number;
|
10
10
|
y: number;
|
11
|
+
isPositioned: boolean;
|
11
12
|
update: () => void;
|
13
|
+
floatingStyles: import("react").CSSProperties;
|
14
|
+
refs: {
|
15
|
+
reference: import("react").MutableRefObject<import("@floating-ui/react-dom").ReferenceType | null>;
|
16
|
+
floating: import("react").MutableRefObject<HTMLElement | null>;
|
17
|
+
setReference: (node: import("@floating-ui/react-dom").ReferenceType | null) => void;
|
18
|
+
setFloating: (node: HTMLElement | null) => void;
|
19
|
+
} & import("@floating-ui/react").ExtendedRefs<import("@floating-ui/react").ReferenceType>;
|
20
|
+
elements: {
|
21
|
+
reference: import("@floating-ui/react-dom").ReferenceType | null;
|
22
|
+
floating: HTMLElement | null;
|
23
|
+
} & import("@floating-ui/react").ExtendedElements<import("@floating-ui/react").ReferenceType>;
|
12
24
|
context: {
|
13
25
|
x: number;
|
14
26
|
y: number;
|
15
27
|
placement: import("@floating-ui/utils").Placement;
|
16
28
|
strategy: import("@floating-ui/utils").Strategy;
|
17
29
|
middlewareData: import("@floating-ui/core").MiddlewareData;
|
18
|
-
update: () => void;
|
19
30
|
isPositioned: boolean;
|
31
|
+
update: () => void;
|
20
32
|
floatingStyles: import("react").CSSProperties;
|
21
33
|
open: boolean;
|
22
|
-
onOpenChange: (open: boolean) => void;
|
34
|
+
onOpenChange: (open: boolean, event?: Event | undefined) => void;
|
23
35
|
events: import("@floating-ui/react").FloatingEvents;
|
24
36
|
dataRef: import("react").MutableRefObject<import("@floating-ui/react").ContextData>;
|
25
37
|
nodeId: string | undefined;
|
@@ -27,10 +39,6 @@ export declare function useSubMenu(options: SubMenuOptions): {
|
|
27
39
|
refs: import("@floating-ui/react").ExtendedRefs<import("@floating-ui/react").ReferenceType>;
|
28
40
|
elements: import("@floating-ui/react").ExtendedElements<import("@floating-ui/react").ReferenceType>;
|
29
41
|
};
|
30
|
-
refs: import("@floating-ui/react").ExtendedRefs<import("@floating-ui/react").ReferenceType>;
|
31
|
-
elements: import("@floating-ui/react").ExtendedElements<import("@floating-ui/react").ReferenceType>;
|
32
|
-
isPositioned: boolean;
|
33
|
-
floatingStyles: import("react").CSSProperties;
|
34
42
|
getReferenceProps: (userProps?: import("react").HTMLProps<Element> | undefined) => Record<string, unknown>;
|
35
43
|
getFloatingProps: (userProps?: import("react").HTMLProps<HTMLElement> | undefined) => Record<string, unknown>;
|
36
44
|
getItemProps: (userProps?: import("react").HTMLProps<HTMLElement> | undefined) => Record<string, unknown>;
|
@@ -1,16 +1,16 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
exports.useSubMenu = void 0;
|
4
|
-
const react_1 = require("react");
|
5
|
-
const react_2 = require("
|
4
|
+
const react_1 = require("@floating-ui/react");
|
5
|
+
const react_2 = require("react");
|
6
6
|
function useSubMenu(options) {
|
7
|
-
const [open, setOpen] = (0,
|
8
|
-
const data = (0,
|
7
|
+
const [open, setOpen] = (0, react_2.useState)(false);
|
8
|
+
const data = (0, react_1.useFloating)({
|
9
9
|
middleware: [
|
10
|
-
(0,
|
11
|
-
(0,
|
12
|
-
(0,
|
13
|
-
(0,
|
10
|
+
(0, react_1.offset)(options.isMobile ? 12 : 16),
|
11
|
+
(0, react_1.flip)(),
|
12
|
+
(0, react_1.shift)({ padding: 8 }),
|
13
|
+
(0, react_1.size)({
|
14
14
|
apply({ availableHeight, elements }) {
|
15
15
|
Object.assign(elements.floating.style, {
|
16
16
|
maxHeight: Math.max(240, availableHeight) + "px",
|
@@ -21,22 +21,22 @@ function useSubMenu(options) {
|
|
21
21
|
onOpenChange: setOpen,
|
22
22
|
open,
|
23
23
|
placement: options.isMobile ? "top" : "right-start",
|
24
|
-
whileElementsMounted: (reference, floating, update) => (0,
|
24
|
+
whileElementsMounted: (reference, floating, update) => (0, react_1.autoUpdate)(reference, floating, update, {
|
25
25
|
elementResize: typeof ResizeObserver !== "undefined",
|
26
26
|
}),
|
27
27
|
});
|
28
28
|
const context = data.context;
|
29
|
-
const hover = (0,
|
29
|
+
const hover = (0, react_1.useHover)(context, {
|
30
30
|
move: false,
|
31
31
|
delay: 200,
|
32
|
-
handleClose: (0,
|
32
|
+
handleClose: (0, react_1.safePolygon)(),
|
33
33
|
enabled: !options.isMobile,
|
34
34
|
});
|
35
|
-
const click = (0,
|
36
|
-
const focus = (0,
|
37
|
-
const dismiss = (0,
|
38
|
-
const interactions = (0,
|
39
|
-
return (0,
|
35
|
+
const click = (0, react_1.useClick)(context, { enabled: !!options.isMobile });
|
36
|
+
const focus = (0, react_1.useFocus)(context);
|
37
|
+
const dismiss = (0, react_1.useDismiss)(context);
|
38
|
+
const interactions = (0, react_1.useInteractions)([hover, click, focus, dismiss]);
|
39
|
+
return (0, react_2.useMemo)(() => ({
|
40
40
|
open,
|
41
41
|
setOpen,
|
42
42
|
...interactions,
|