@uxf/data-grid 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/data-grid.js +4 -4
- package/data-grid.stories.js +1 -7
- package/index.d.ts +1 -1
- package/index.js +1 -1
- package/package.json +12 -10
- package/store/reducer.d.ts +1 -1
- package/tailwindui/body-cell/body-cell-boolean.js +1 -1
- package/tailwindui/body-cell/body-cell-date.js +1 -1
- package/tailwindui/body-cell/body-cell-datetime.js +1 -1
- package/tailwindui/body-cell/body-cell-email.js +1 -1
- package/tailwindui/body-cell/body-cell-phone.js +1 -1
- package/tailwindui/body-cell/body-cell-url.js +1 -1
- package/tailwindui/body-cell/index.js +3 -3
- package/tailwindui/components/action-cell-base.js +1 -1
- package/tailwindui/components/drawer.js +13 -13
- package/tailwindui/components/no-rows-fallback.js +1 -1
- package/tailwindui/components/pagination-rows-per-page-select.js +1 -1
- package/tailwindui/components/select-row-checkbox.js +1 -1
- package/tailwindui/components/selected-rows-toolbar.js +1 -1
- package/tailwindui/components/toolbar-control.js +4 -4
- package/tailwindui/components/toolbar-customs.js +1 -1
- package/tailwindui/components/toolbar-tabs.js +3 -3
- package/tailwindui/data-grid.d.ts +1 -1
- package/tailwindui/data-grid.js +1 -1
- package/tailwindui/filter-handler/bool-filter.js +1 -1
- package/tailwindui/filter-handler/boolean-filter.js +2 -2
- package/tailwindui/filter-handler/index.js +1 -1
- package/tailwindui/filter-handler/interval-filter.js +1 -1
- package/tailwindui/filter-handler/select-filter.js +1 -1
- package/tailwindui/filter-handler/text-filter.js +1 -1
- package/tailwindui/index.d.ts +1 -1
- package/tailwindui/index.js +1 -1
- package/tailwindui/ui.js +9 -9
- package/types/components.d.ts +3 -3
- package/types/data-grid-props.d.ts +3 -3
- package/types/index.d.ts +3 -3
- package/types/index.js +3 -3
- package/types/ui-components.d.ts +1 -1
package/data-grid.js
CHANGED
|
@@ -28,14 +28,14 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
29
|
exports.DataGrid = void 0;
|
|
30
30
|
const react_1 = __importStar(require("react"));
|
|
31
|
-
const reducer_1 = require("./store/reducer");
|
|
32
|
-
const utils_1 = require("./utils");
|
|
33
31
|
const react_data_grid_1 = __importDefault(require("react-data-grid"));
|
|
32
|
+
const use_rdg_visuals_1 = require("./hooks/use-rdg-visuals");
|
|
34
33
|
const useColumns_1 = require("./hooks/useColumns");
|
|
34
|
+
const actions_1 = require("./store/actions");
|
|
35
|
+
const reducer_1 = require("./store/reducer");
|
|
35
36
|
const footer_1 = require("./tailwindui/components/footer");
|
|
36
37
|
const show_1 = require("./tailwindui/show");
|
|
37
|
-
const
|
|
38
|
-
const use_rdg_visuals_1 = require("./hooks/use-rdg-visuals");
|
|
38
|
+
const utils_1 = require("./utils");
|
|
39
39
|
const defaultKeyExtractor = (r) => {
|
|
40
40
|
return r.id;
|
|
41
41
|
};
|
package/data-grid.stories.js
CHANGED
|
@@ -241,12 +241,6 @@ function Default() {
|
|
|
241
241
|
text: {},
|
|
242
242
|
bool: { width: 50 },
|
|
243
243
|
},
|
|
244
|
-
},
|
|
245
|
-
//rowClass={row => ["bg-success-100", "bg-warning-100", "bg-error-100", "bg-primary-100"][(row.id - 1) % 4]}
|
|
246
|
-
// customActions={[
|
|
247
|
-
// { label: "Do something", onClick: () => console.log("click") },
|
|
248
|
-
// { label: "Do something else", href: "https://www.uxf.cz", variant: "text" },
|
|
249
|
-
// ]}
|
|
250
|
-
debug: true })));
|
|
244
|
+
}, debug: true })));
|
|
251
245
|
}
|
|
252
246
|
exports.Default = Default;
|
package/index.d.ts
CHANGED
package/index.js
CHANGED
|
@@ -16,8 +16,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.encodeFilter = exports.decodeFilter = void 0;
|
|
18
18
|
__exportStar(require("./data-grid"), exports);
|
|
19
|
-
__exportStar(require("./types"), exports);
|
|
20
19
|
__exportStar(require("./hooks/useCallbackRef"), exports);
|
|
20
|
+
__exportStar(require("./types"), exports);
|
|
21
21
|
var utils_1 = require("./utils");
|
|
22
22
|
Object.defineProperty(exports, "decodeFilter", { enumerable: true, get: function () { return utils_1.decodeFilter; } });
|
|
23
23
|
Object.defineProperty(exports, "encodeFilter", { enumerable: true, get: function () { return utils_1.encodeFilter; } });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uxf/data-grid",
|
|
3
|
-
"version": "10.0.0-beta.
|
|
3
|
+
"version": "10.0.0-beta.80",
|
|
4
4
|
"description": "UXF DataGrid",
|
|
5
5
|
"homepage": "https://gitlab.com/uxf-npm/data-grid#readme",
|
|
6
6
|
"main": "index.js",
|
|
@@ -26,18 +26,20 @@
|
|
|
26
26
|
"test": "npm run-script typecheck",
|
|
27
27
|
"typecheck": "tsc --noEmit --skipLibCheck"
|
|
28
28
|
},
|
|
29
|
-
"
|
|
30
|
-
"
|
|
29
|
+
"dependencies": {
|
|
30
|
+
"@uxf/ui": "10.0.0-beta.80",
|
|
31
|
+
"dayjs": "1.11.10",
|
|
32
|
+
"react-data-grid": "7.0.0-beta.39"
|
|
31
33
|
},
|
|
32
34
|
"peerDependencies": {
|
|
33
|
-
"
|
|
34
|
-
"react": "
|
|
35
|
-
"react-dom": "^18.0.0",
|
|
36
|
-
"dayjs": "^1.11.7"
|
|
35
|
+
"react": ">=18.2.0",
|
|
36
|
+
"react-dom": ">=18.2.0"
|
|
37
37
|
},
|
|
38
|
-
"
|
|
39
|
-
"react
|
|
38
|
+
"devDependencies": {
|
|
39
|
+
"@types/react": "18.2.27",
|
|
40
|
+
"@types/react-dom": "18.2.12",
|
|
41
|
+
"react": "18.2.0",
|
|
42
|
+
"react-dom": "18.2.0"
|
|
40
43
|
},
|
|
41
|
-
"devDependencies": {},
|
|
42
44
|
"gitHead": "e4f21a15c3d50fb6614d70cdaf36685232de87e7"
|
|
43
45
|
}
|
package/store/reducer.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Reducer } from "react";
|
|
2
|
-
import {
|
|
2
|
+
import { DataGridState, Request, Schema } from "../types";
|
|
3
3
|
export declare const getInitialState: (schema: Schema<any>, init?: Request | string) => DataGridState;
|
|
4
4
|
export declare const reducer: Reducer<DataGridState, any>;
|
|
5
5
|
export declare const debugReducer: Reducer<DataGridState, any>;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.BodyCellBoolean = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const checkbox_1 = require("@uxf/ui/checkbox");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BodyCellBoolean = (props) => {
|
|
10
10
|
if (typeof props.value !== "boolean") {
|
|
11
11
|
return null;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.BodyCellDate = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const dayjs_1 = __importDefault(require("dayjs"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BodyCellDate = (props) => {
|
|
10
10
|
if (typeof props.value !== "string") {
|
|
11
11
|
return null;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.BodyCellDateTime = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const dayjs_1 = __importDefault(require("dayjs"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BodyCellDateTime = (props) => {
|
|
10
10
|
if (typeof props.value !== "string") {
|
|
11
11
|
return null;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.BodyCellEmail = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const text_link_1 = require("@uxf/ui/text-link");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BodyCellEmail = (props) => {
|
|
10
10
|
if (typeof props.value !== "string") {
|
|
11
11
|
return null;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.BodyCellPhone = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const text_link_1 = require("@uxf/ui/text-link");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BodyCellPhone = (props) => {
|
|
10
10
|
if (typeof props.value !== "string") {
|
|
11
11
|
return null;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.BodyCellUrl = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const text_link_1 = require("@uxf/ui/text-link");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BodyCellUrl = (props) => {
|
|
10
10
|
if (typeof props.value !== "string") {
|
|
11
11
|
return null;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.BodyCells = void 0;
|
|
4
|
-
const body_cell_default_1 = require("./body-cell-default");
|
|
5
4
|
const body_cell_boolean_1 = require("./body-cell-boolean");
|
|
6
5
|
const body_cell_date_1 = require("./body-cell-date");
|
|
7
6
|
const body_cell_datetime_1 = require("./body-cell-datetime");
|
|
8
|
-
const
|
|
9
|
-
const body_cell_to_many_1 = require("./body-cell-to-many");
|
|
7
|
+
const body_cell_default_1 = require("./body-cell-default");
|
|
10
8
|
const body_cell_email_1 = require("./body-cell-email");
|
|
11
9
|
const body_cell_phone_1 = require("./body-cell-phone");
|
|
10
|
+
const body_cell_to_many_1 = require("./body-cell-to-many");
|
|
11
|
+
const body_cell_to_one_1 = require("./body-cell-to-one");
|
|
12
12
|
const body_cell_url_1 = require("./body-cell-url");
|
|
13
13
|
exports.BodyCells = {
|
|
14
14
|
boolean: body_cell_boolean_1.BodyCellBoolean,
|
|
@@ -24,9 +24,9 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.ActionCellBase = exports.ActionCellWrapper = void 0;
|
|
27
|
-
const react_1 = __importStar(require("react"));
|
|
28
27
|
const button_1 = require("@uxf/ui/button");
|
|
29
28
|
const icon_1 = require("@uxf/ui/icon");
|
|
29
|
+
const react_1 = __importStar(require("react"));
|
|
30
30
|
const ActionCellWrapper = (props) => {
|
|
31
31
|
const innerRef = (0, react_1.useRef)(null);
|
|
32
32
|
(0, react_1.useEffect)(() => {
|
|
@@ -4,24 +4,24 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.Drawer = void 0;
|
|
7
|
-
const react_1 =
|
|
8
|
-
const icon_1 = require("@uxf/ui/icon");
|
|
9
|
-
const button_1 = require("@uxf/ui/button");
|
|
10
|
-
const react_2 = require("@floating-ui/react");
|
|
7
|
+
const react_1 = require("@floating-ui/react");
|
|
11
8
|
const useIsMounted_1 = require("@uxf/core/hooks/useIsMounted");
|
|
9
|
+
const button_1 = require("@uxf/ui/button");
|
|
10
|
+
const icon_1 = require("@uxf/ui/icon");
|
|
11
|
+
const react_2 = __importDefault(require("react"));
|
|
12
12
|
const Drawer = (props) => {
|
|
13
13
|
const isMounted = (0, useIsMounted_1.useIsMounted)();
|
|
14
14
|
if (!isMounted) {
|
|
15
15
|
return null;
|
|
16
16
|
}
|
|
17
|
-
return (
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
17
|
+
return (react_2.default.createElement(react_1.FloatingPortal, null,
|
|
18
|
+
react_2.default.createElement("div", { className: `uxf-data-grid__drawer uxf-data-grid__drawer--${props.open ? "open" : "closed"}` },
|
|
19
|
+
react_2.default.createElement("div", { className: `uxf-data-grid__drawer-body-wrapper ${props.open ? "uxf-data-grid__drawer-body-wrapper--open" : ""}` },
|
|
20
|
+
react_2.default.createElement("div", { className: "uxf-data-grid__drawer-body" },
|
|
21
|
+
react_2.default.createElement(button_1.Button, { isIconButton: true, onClick: props.onClose, variant: "text", className: "uxf-data-grid__drawer-close-button" },
|
|
22
|
+
react_2.default.createElement(icon_1.Icon, { name: "xmarkLarge" })),
|
|
23
|
+
react_2.default.createElement("header", { className: "uxf-data-grid__drawer-header" }, props.title),
|
|
24
|
+
react_2.default.createElement("div", { className: "uxf-data-grid__drawer-content" }, props.children))),
|
|
25
|
+
react_2.default.createElement("section", { className: "uxf-data-grid__drawer-backdrop", onClick: props.onClose }))));
|
|
26
26
|
};
|
|
27
27
|
exports.Drawer = Drawer;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.NoRowsFallback = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const icon_1 = require("@uxf/ui/icon");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const utils_1 = require("../../utils");
|
|
10
10
|
const NoRowsFallback = (props) => {
|
|
11
11
|
return (react_1.default.createElement("div", { className: (0, utils_1.cx)("uxf-data-grid__fallback", props.loading && "is-loading", props.error && "is-error") }, props.loading ? (react_1.default.createElement(react_1.default.Fragment, null, "Na\u010D\u00EDt\u00E1m...")) : props.error ? (react_1.default.createElement(react_1.default.Fragment, null,
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.PaginationRowsPerPageSelect = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const select_1 = require("@uxf/ui/select");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const PER_PAGE_OPTIONS = [
|
|
10
10
|
{ id: 10, label: "10" },
|
|
11
11
|
{ id: 25, label: "25" },
|
|
@@ -24,8 +24,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.SelectRowCheckbox = void 0;
|
|
27
|
-
const react_1 = __importStar(require("react"));
|
|
28
27
|
const checkbox_1 = require("@uxf/ui/checkbox");
|
|
28
|
+
const react_1 = __importStar(require("react"));
|
|
29
29
|
const SelectRowComponent = (props) => {
|
|
30
30
|
var _a;
|
|
31
31
|
const handleChange = (value, e) => {
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.SelectedRowsToolbar = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const button_1 = require("@uxf/ui/button");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const getText = (count) => {
|
|
10
10
|
if (count === 1) {
|
|
11
11
|
return "Vybrán 1 záznam";
|
|
@@ -24,15 +24,15 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.ToolbarControl = void 0;
|
|
27
|
-
const
|
|
27
|
+
const button_1 = require("@uxf/ui/button");
|
|
28
28
|
const icon_1 = require("@uxf/ui/icon");
|
|
29
29
|
const text_input_1 = require("@uxf/ui/text-input");
|
|
30
|
-
const button_1 = require("@uxf/ui/button");
|
|
31
|
-
const drawer_1 = require("./drawer");
|
|
32
30
|
const toggle_1 = require("@uxf/ui/toggle");
|
|
31
|
+
const react_1 = __importStar(require("react"));
|
|
33
32
|
const actions_1 = require("../../store/actions");
|
|
34
|
-
const show_1 = require("../show");
|
|
35
33
|
const utils_1 = require("../../utils");
|
|
34
|
+
const show_1 = require("../show");
|
|
35
|
+
const drawer_1 = require("./drawer");
|
|
36
36
|
function Filters(props) {
|
|
37
37
|
return (react_1.default.createElement("div", { className: "uxf-data-grid__filters" }, props.schema.filters.map((filter) => {
|
|
38
38
|
var _a, _b;
|
|
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.ToolbarCustoms = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const button_1 = require("@uxf/ui/button");
|
|
9
8
|
const button_list_1 = require("@uxf/ui/button-list");
|
|
9
|
+
const react_1 = __importDefault(require("react"));
|
|
10
10
|
const ToolbarCustoms = (props) => {
|
|
11
11
|
if (!props.buttons) {
|
|
12
12
|
return null;
|
|
@@ -4,12 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.ToolbarTabs = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
|
-
const show_1 = require("../show");
|
|
9
|
-
const utils_1 = require("../../utils");
|
|
10
7
|
const button_1 = require("@uxf/ui/button");
|
|
11
8
|
const icon_1 = require("@uxf/ui/icon");
|
|
12
9
|
const modal_service_1 = require("@uxf/ui/modal/modal-service");
|
|
10
|
+
const react_1 = __importDefault(require("react"));
|
|
11
|
+
const utils_1 = require("../../utils");
|
|
12
|
+
const show_1 = require("../show");
|
|
13
13
|
function Tab(props) {
|
|
14
14
|
return (react_1.default.createElement("button", { className: (0, utils_1.cx)("uxf-data-grid__toolbar-tab", props.isActive && "is-active"), onClick: props.onClick }, props.title));
|
|
15
15
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BaseGridType, DataGridBaseProps, UIComponents } from "../types";
|
|
2
1
|
import React from "react";
|
|
2
|
+
import { BaseGridType, DataGridBaseProps, UIComponents } from "../types";
|
|
3
3
|
export type DataGridProps<GridType extends BaseGridType, R> = DataGridBaseProps<GridType, R> & {
|
|
4
4
|
ui?: Partial<UIComponents<GridType, R>>;
|
|
5
5
|
};
|
package/tailwindui/data-grid.js
CHANGED
|
@@ -24,8 +24,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.DataGrid = void 0;
|
|
27
|
-
const data_grid_1 = require("../data-grid");
|
|
28
27
|
const react_1 = __importStar(require("react"));
|
|
28
|
+
const data_grid_1 = require("../data-grid");
|
|
29
29
|
const ui_1 = require("./ui");
|
|
30
30
|
const DataGrid = (props) => {
|
|
31
31
|
const ui = (0, react_1.useMemo)(() => {
|
|
@@ -3,9 +3,9 @@ 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 react_1 = __importDefault(require("react"));
|
|
7
6
|
const chip_1 = require("@uxf/ui/chip");
|
|
8
7
|
const select_1 = require("@uxf/ui/select");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BoolFilterHandler = {
|
|
10
10
|
input: (props) => (react_1.default.createElement(select_1.Select, { options: [
|
|
11
11
|
{ id: "", label: "Nerozhoduje" },
|
|
@@ -3,9 +3,9 @@ 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 react_1 = __importDefault(require("react"));
|
|
7
|
-
const chip_1 = require("@uxf/ui/chip");
|
|
8
6
|
const checkbox_input_1 = require("@uxf/ui/checkbox-input");
|
|
7
|
+
const chip_1 = require("@uxf/ui/chip");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const BooleanFilterHandler = {
|
|
10
10
|
input: (props) => (react_1.default.createElement(checkbox_input_1.CheckboxInput, { label: props.filter.label, value: props.value.value, onChange: (value) => props.onFilter({ ...props.value, value: value === true ? value : undefined }) })),
|
|
11
11
|
listItem: (props) => (react_1.default.createElement(chip_1.Chip, { onClose: props.onClear },
|
|
@@ -4,11 +4,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.defaultFilterHandlers = void 0;
|
|
7
|
-
const text_filter_1 = __importDefault(require("./text-filter"));
|
|
8
7
|
const bool_filter_1 = __importDefault(require("./bool-filter"));
|
|
9
8
|
const boolean_filter_1 = __importDefault(require("./boolean-filter"));
|
|
10
9
|
const interval_filter_1 = __importDefault(require("./interval-filter"));
|
|
11
10
|
const select_filter_1 = __importDefault(require("./select-filter"));
|
|
11
|
+
const text_filter_1 = __importDefault(require("./text-filter"));
|
|
12
12
|
exports.defaultFilterHandlers = {
|
|
13
13
|
text: text_filter_1.default,
|
|
14
14
|
string: text_filter_1.default,
|
|
@@ -3,9 +3,9 @@ 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 react_1 = __importDefault(require("react"));
|
|
7
6
|
const chip_1 = require("@uxf/ui/chip");
|
|
8
7
|
const text_input_1 = require("@uxf/ui/text-input");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const IntervalFilterHandler = {
|
|
10
10
|
input: (props) => {
|
|
11
11
|
const initializedValue = props.value.value &&
|
|
@@ -3,9 +3,9 @@ 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 react_1 = __importDefault(require("react"));
|
|
7
6
|
const chip_1 = require("@uxf/ui/chip");
|
|
8
7
|
const select_1 = require("@uxf/ui/select");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const SelectFilterHandler = {
|
|
10
10
|
input: (props) => {
|
|
11
11
|
var _a;
|
|
@@ -3,9 +3,9 @@ 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 react_1 = __importDefault(require("react"));
|
|
7
6
|
const chip_1 = require("@uxf/ui/chip");
|
|
8
7
|
const text_input_1 = require("@uxf/ui/text-input");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const TextFilterHandler = {
|
|
10
10
|
input: (props) => {
|
|
11
11
|
var _a;
|
package/tailwindui/index.d.ts
CHANGED
package/tailwindui/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("./data-grid"), exports);
|
|
18
17
|
__exportStar(require("./components/action-cell-base"), exports);
|
|
18
|
+
__exportStar(require("./data-grid"), exports);
|
|
19
19
|
__exportStar(require("./ui"), exports);
|
package/tailwindui/ui.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.UI = void 0;
|
|
4
|
+
const pagination_1 = require("@uxf/ui/pagination/pagination");
|
|
5
|
+
const body_cell_1 = require("./body-cell");
|
|
4
6
|
const action_cell_base_1 = require("./components/action-cell-base");
|
|
5
|
-
const no_rows_fallback_1 = require("./components/no-rows-fallback");
|
|
6
|
-
const linear_progress_1 = require("./components/linear-progress");
|
|
7
|
-
const toolbar_1 = require("./components/toolbar");
|
|
8
7
|
const container_1 = require("./components/container");
|
|
9
8
|
const filter_list_1 = require("./components/filter-list");
|
|
10
|
-
const
|
|
11
|
-
const
|
|
9
|
+
const linear_progress_1 = require("./components/linear-progress");
|
|
10
|
+
const no_rows_fallback_1 = require("./components/no-rows-fallback");
|
|
12
11
|
const pagination_counts_1 = require("./components/pagination-counts");
|
|
13
12
|
const pagination_rows_per_page_select_1 = require("./components/pagination-rows-per-page-select");
|
|
14
|
-
const
|
|
15
|
-
const
|
|
16
|
-
const
|
|
13
|
+
const select_row_checkbox_1 = require("./components/select-row-checkbox");
|
|
14
|
+
const selected_rows_toolbar_1 = require("./components/selected-rows-toolbar");
|
|
15
|
+
const toolbar_1 = require("./components/toolbar");
|
|
17
16
|
const toolbar_control_1 = require("./components/toolbar-control");
|
|
18
17
|
const toolbar_customs_1 = require("./components/toolbar-customs");
|
|
19
|
-
const
|
|
18
|
+
const toolbar_tabs_1 = require("./components/toolbar-tabs");
|
|
19
|
+
const filter_handler_1 = require("./filter-handler");
|
|
20
20
|
exports.UI = {
|
|
21
21
|
ActionCell: action_cell_base_1.ActionCellBase,
|
|
22
22
|
actionCellWidth: 128,
|
package/types/components.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import React, { ComponentType, FC, ReactElement, ReactNode } from "react";
|
|
2
|
-
import { BaseGridType, Columns, Filter, Filters, Schema } from "./schema";
|
|
3
|
-
import { RequestFilter, Response } from "./api";
|
|
4
1
|
import { PaginationProps } from "@uxf/ui/pagination/pagination";
|
|
2
|
+
import React, { ComponentType, FC, ReactElement, ReactNode } from "react";
|
|
5
3
|
import { RenderCheckboxProps } from "react-data-grid";
|
|
4
|
+
import { RequestFilter, Response } from "./api";
|
|
6
5
|
import { ChangeHiddenColumnsHandler, CsvDownloadHandler } from "./core";
|
|
6
|
+
import { BaseGridType, Columns, Filter, Filters, Schema } from "./schema";
|
|
7
7
|
import { DataGridState } from "./state";
|
|
8
8
|
/**
|
|
9
9
|
* Action cell
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { BaseGridType, Schema } from "./schema";
|
|
2
1
|
import { MutableRefObject, ReactNode } from "react";
|
|
3
|
-
import { Request } from "./api";
|
|
4
2
|
import { DataGridProps as RDGProps } from "react-data-grid";
|
|
3
|
+
import { Request } from "./api";
|
|
5
4
|
import { ToolbarCustomsProps } from "./components";
|
|
6
|
-
import { UIComponents } from "./ui-components";
|
|
7
5
|
import { CallbackRef, ChangeHiddenColumnsHandler, Config, CsvDownloadHandler, KeyExtractor, Loader } from "./core";
|
|
6
|
+
import { BaseGridType, Schema } from "./schema";
|
|
7
|
+
import { UIComponents } from "./ui-components";
|
|
8
8
|
export type DataGridBaseProps<GridType extends BaseGridType, R> = {
|
|
9
9
|
callbackRef?: MutableRefObject<CallbackRef | undefined>;
|
|
10
10
|
schema: Schema<GridType>;
|
package/types/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export * from "./core";
|
|
2
1
|
export * from "./api";
|
|
3
|
-
export * from "./schema";
|
|
4
2
|
export * from "./components";
|
|
5
|
-
export * from "./
|
|
3
|
+
export * from "./core";
|
|
6
4
|
export * from "./data-grid-props";
|
|
5
|
+
export * from "./schema";
|
|
6
|
+
export * from "./state";
|
|
7
7
|
export * from "./ui-components";
|
package/types/index.js
CHANGED
|
@@ -14,10 +14,10 @@ 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("./core"), exports);
|
|
18
17
|
__exportStar(require("./api"), exports);
|
|
19
|
-
__exportStar(require("./schema"), exports);
|
|
20
18
|
__exportStar(require("./components"), exports);
|
|
21
|
-
__exportStar(require("./
|
|
19
|
+
__exportStar(require("./core"), exports);
|
|
22
20
|
__exportStar(require("./data-grid-props"), exports);
|
|
21
|
+
__exportStar(require("./schema"), exports);
|
|
22
|
+
__exportStar(require("./state"), exports);
|
|
23
23
|
__exportStar(require("./ui-components"), exports);
|
package/types/ui-components.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BaseGridType } from "./schema";
|
|
2
1
|
import { ActionCellComponent, BodyCellComponents, ContainerComponent, FilterHandlers, FilterListComponent, LinearProgressComponent, NoRowsFallbackComponent, PaginationComponent, PaginationCountsComponent, PaginationRowsPerPageSelectComponent, SelectedRowsToolbarActionsComponent, SelectedRowsToolbarComponent, SelectRowCheckboxComponent, ToolbarComponent, ToolbarControlComponent, ToolbarCustomsComponent, ToolbarTabsComponent } from "./components";
|
|
2
|
+
import { BaseGridType } from "./schema";
|
|
3
3
|
export type ActionCellWithRequiredWidth<R> = {
|
|
4
4
|
ActionCell?: ActionCellComponent<R>;
|
|
5
5
|
actionCellWidth: number;
|