fui-material 2.6.9 → 2.6.11
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/f-ui-kit.es.js +30 -17
- package/dist/f-ui-kit.es.js.map +1 -1
- package/dist/f-ui-kit.umd.js +2 -2
- package/dist/f-ui-kit.umd.js.map +1 -1
- package/dist/index.css +1 -1
- package/dist/types/material/FPagination/hooks/usePagination.d.ts +1 -1
- package/dist/types/material/TableComponents/FTableRow/FTableRow.d.ts +9 -3
- package/package.json +2 -2
package/dist/f-ui-kit.es.js
CHANGED
|
@@ -702,25 +702,26 @@ const FPaper = ({
|
|
|
702
702
|
}
|
|
703
703
|
);
|
|
704
704
|
};
|
|
705
|
-
const bordered = "
|
|
706
|
-
const left$1 = "
|
|
707
|
-
const center = "
|
|
708
|
-
const right = "
|
|
705
|
+
const bordered = "_bordered_ld5gh_18";
|
|
706
|
+
const left$1 = "_left_ld5gh_40";
|
|
707
|
+
const center = "_center_ld5gh_43";
|
|
708
|
+
const right = "_right_ld5gh_46";
|
|
709
709
|
const styles$s = {
|
|
710
|
-
"f-table-component": "_f-table-
|
|
711
|
-
"f-table-component__table": "_f-table-
|
|
710
|
+
"f-table-component": "_f-table-component_ld5gh_1",
|
|
711
|
+
"f-table-component__table": "_f-table-component__table_ld5gh_7",
|
|
712
712
|
bordered,
|
|
713
|
-
"bordered-half": "_bordered-
|
|
714
|
-
"f-table-component__table_header": "_f-table-
|
|
715
|
-
"is-sticky": "_is-
|
|
716
|
-
"f-table-component__table_header-cell": "_f-table-component__table_header-
|
|
713
|
+
"bordered-half": "_bordered-half_ld5gh_22",
|
|
714
|
+
"f-table-component__table_header": "_f-table-component__table_header_ld5gh_25",
|
|
715
|
+
"is-sticky": "_is-sticky_ld5gh_29",
|
|
716
|
+
"f-table-component__table_header-cell": "_f-table-component__table_header-cell_ld5gh_37",
|
|
717
717
|
left: left$1,
|
|
718
718
|
center,
|
|
719
719
|
right,
|
|
720
|
-
"f-table-component__table_body": "_f-table-
|
|
721
|
-
"f-table-component__table_row": "_f-table-
|
|
722
|
-
"f-table-
|
|
723
|
-
"f-table-
|
|
720
|
+
"f-table-component__table_body": "_f-table-component__table_body_ld5gh_65",
|
|
721
|
+
"f-table-component__table_row": "_f-table-component__table_row_ld5gh_68",
|
|
722
|
+
"f-table-component__table_row_no-hover": "_f-table-component__table_row_no-hover_ld5gh_68",
|
|
723
|
+
"f-table-component__table_body-cell": "_f-table-component__table_body-cell_ld5gh_81",
|
|
724
|
+
"f-table-component__table_footer": "_f-table-component__table_footer_ld5gh_97"
|
|
724
725
|
};
|
|
725
726
|
const FTableHead = ({
|
|
726
727
|
st,
|
|
@@ -912,14 +913,26 @@ const FTableRow = ({
|
|
|
912
913
|
st,
|
|
913
914
|
children,
|
|
914
915
|
textAlignment,
|
|
916
|
+
disableHover = false,
|
|
917
|
+
// По умолчанию ховер включен
|
|
915
918
|
...props
|
|
916
919
|
}) => {
|
|
920
|
+
const rowClasses = [
|
|
921
|
+
styles$s["f-table-component__table_row"],
|
|
922
|
+
props.className || ""
|
|
923
|
+
];
|
|
924
|
+
if (disableHover) {
|
|
925
|
+
rowClasses.push(styles$s["f-table-component__table_row_no-hover"]);
|
|
926
|
+
}
|
|
927
|
+
if (textAlignment !== void 0) {
|
|
928
|
+
rowClasses.push(styles$s[textAlignment]);
|
|
929
|
+
}
|
|
917
930
|
return /* @__PURE__ */ jsx(
|
|
918
931
|
"tr",
|
|
919
932
|
{
|
|
920
933
|
style: st,
|
|
921
934
|
...props,
|
|
922
|
-
className:
|
|
935
|
+
className: rowClasses.join(" ").trim(),
|
|
923
936
|
children
|
|
924
937
|
}
|
|
925
938
|
);
|
|
@@ -1252,7 +1265,7 @@ const usePagination = ({
|
|
|
1252
1265
|
}) => {
|
|
1253
1266
|
const paginationRange = useMemo(() => {
|
|
1254
1267
|
const totalPageCount = Math.ceil(totalCount / pageSize);
|
|
1255
|
-
const totalPageNumbers = siblingCount + 5;
|
|
1268
|
+
const totalPageNumbers = siblingCount * 2 + 5;
|
|
1256
1269
|
if (totalPageNumbers >= totalPageCount) {
|
|
1257
1270
|
return range(1, totalPageCount);
|
|
1258
1271
|
}
|
|
@@ -1282,7 +1295,7 @@ const usePagination = ({
|
|
|
1282
1295
|
const middleRange = range(leftSiblingIndex, rightSiblingIndex);
|
|
1283
1296
|
return [firstPageIndex, DOTS, ...middleRange, DOTS, lastPageIndex];
|
|
1284
1297
|
}
|
|
1285
|
-
return
|
|
1298
|
+
return range(1, totalPageCount);
|
|
1286
1299
|
}, [totalCount, pageSize, siblingCount, currentPage]);
|
|
1287
1300
|
return paginationRange;
|
|
1288
1301
|
};
|