@ansible/ansible-ui-framework 0.0.226 → 0.0.227
Sign up to get free protection for your applications and to get access to all the features.
- package/cjs/PagePagination.js +4 -2
- package/mjs/PagePagination.js +4 -4
- package/package.json +1 -1
package/cjs/PagePagination.js
CHANGED
@@ -21,8 +21,10 @@ function PagePagination(props) {
|
|
21
21
|
var setPage = props.setPage, setPerPage = props.setPerPage;
|
22
22
|
var onSetPage = (0, react_1.useCallback)(function (_event, page) { return setPage(page); }, [setPage]);
|
23
23
|
var onPerPageSelect = (0, react_1.useCallback)(function (_event, perPage) { return setPerPage(perPage); }, [setPerPage]);
|
24
|
-
var
|
24
|
+
var compact = !(0, useBreakPoint_1.useBreakpoint)('sm');
|
25
25
|
var settings = (0, Settings_1.useSettings)();
|
26
|
-
return ((0, jsx_runtime_1.jsx)(react_core_1.Pagination, { variant: react_core_1.PaginationVariant.bottom, itemCount: props.itemCount, page: props.page, perPage: props.perPage, onSetPage: onSetPage, onPerPageSelect: onPerPageSelect, style: __assign(__assign({}, props.style), { borderTop: 'thin solid var(--pf-global--BorderColor--100)', boxShadow: 'none', zIndex: 301,
|
26
|
+
return ((0, jsx_runtime_1.jsx)(react_core_1.Pagination, { variant: react_core_1.PaginationVariant.bottom, itemCount: props.itemCount, page: props.page, perPage: props.perPage, onSetPage: onSetPage, onPerPageSelect: onPerPageSelect, style: __assign(__assign({}, props.style), { borderTop: 'thin solid var(--pf-global--BorderColor--100)', boxShadow: 'none', zIndex: 301,
|
27
|
+
// marginTop: -1,
|
28
|
+
paddingTop: compact ? 6 : undefined, paddingBottom: compact ? 6 : undefined, backgroundColor: settings.theme === 'dark' ? 'var(--pf-global--BackgroundColor--300)' : undefined }) }));
|
27
29
|
}
|
28
30
|
exports.PagePagination = PagePagination;
|
package/mjs/PagePagination.js
CHANGED
@@ -7,16 +7,16 @@ export function PagePagination(props) {
|
|
7
7
|
const { setPage, setPerPage } = props;
|
8
8
|
const onSetPage = useCallback((_event, page) => setPage(page), [setPage]);
|
9
9
|
const onPerPageSelect = useCallback((_event, perPage) => setPerPage(perPage), [setPerPage]);
|
10
|
-
const
|
10
|
+
const compact = !useBreakpoint('sm');
|
11
11
|
const settings = useSettings();
|
12
12
|
return (_jsx(Pagination, { variant: PaginationVariant.bottom, itemCount: props.itemCount, page: props.page, perPage: props.perPage, onSetPage: onSetPage, onPerPageSelect: onPerPageSelect, style: {
|
13
13
|
...props.style,
|
14
14
|
borderTop: 'thin solid var(--pf-global--BorderColor--100)',
|
15
15
|
boxShadow: 'none',
|
16
16
|
zIndex: 301,
|
17
|
-
marginTop: -1,
|
18
|
-
paddingTop:
|
19
|
-
paddingBottom:
|
17
|
+
// marginTop: -1,
|
18
|
+
paddingTop: compact ? 6 : undefined,
|
19
|
+
paddingBottom: compact ? 6 : undefined,
|
20
20
|
backgroundColor: settings.theme === 'dark' ? 'var(--pf-global--BackgroundColor--300)' : undefined,
|
21
21
|
} }));
|
22
22
|
}
|
package/package.json
CHANGED