componenteshospitais 4.0.3 → 4.0.4

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/cjs/index.js CHANGED
@@ -16374,7 +16374,7 @@ var styles$2 = {"tableContainer":"tableStandard-module_tableContainer__W2g84","t
16374
16374
  styleInject(css_248z$2);
16375
16375
 
16376
16376
  var TableStandard = function (_a) {
16377
- var dados = _a.dados, onRowClick = _a.onRowClick, _b = _a.idColumn, idColumn = _b === void 0 ? 'id' : _b, onActionClick = _a.onActionClick, onDownloadClick = _a.onDownloadClick, onViewClick = _a.onViewClick, _c = _a.showActionColumn, showActionColumn = _c === void 0 ? false : _c, _d = _a.showDownloadButton, showDownloadButton = _d === void 0 ? false : _d, _e = _a.showExcelDownloadButton, showExcelDownloadButton = _e === void 0 ? false : _e, _f = _a.showViewButton, showViewButton = _f === void 0 ? false : _f, _g = _a.cor, cor = _g === void 0 ? false : _g, _h = _a.numeroPaginas, numeroPaginas = _h === void 0 ? 10 : _h, empresa = _a.empresa, _j = _a.paginacao, paginacao = _j === void 0 ? true : _j, borderRadius = _a.borderRadius, borderColor = _a.borderColor, cellsPadding = _a.cellsPadding, cellSpacing = _a.cellSpacing, _k = _a.linhasZebradas, linhasZebradas = _k === void 0 ? false : _k, _l = _a.hiddenColumns, hiddenColumns = _l === void 0 ? [] : _l, _m = _a.currentPage, currentPage = _m === void 0 ? 1 : _m, onPageChange = _a.onPageChange, _o = _a.showTrash, showTrash = _o === void 0 ? false : _o, onTrashClick = _a.onTrashClick, minWidth = _a.minWidth;
16377
+ var dados = _a.dados, onRowClick = _a.onRowClick, _b = _a.idColumn, idColumn = _b === void 0 ? 'id' : _b, onActionClick = _a.onActionClick, onDownloadClick = _a.onDownloadClick, onViewClick = _a.onViewClick, _c = _a.showActionColumn, showActionColumn = _c === void 0 ? false : _c, _d = _a.showDownloadButton, showDownloadButton = _d === void 0 ? false : _d, _e = _a.showExcelDownloadButton, showExcelDownloadButton = _e === void 0 ? false : _e, _f = _a.showViewButton, showViewButton = _f === void 0 ? false : _f, _g = _a.cor, cor = _g === void 0 ? false : _g, _h = _a.numeroPaginas, numeroPaginas = _h === void 0 ? 10 : _h, empresa = _a.empresa, _j = _a.paginacao, paginacao = _j === void 0 ? true : _j, borderRadius = _a.borderRadius, borderColor = _a.borderColor, cellsPadding = _a.cellsPadding, cellSpacing = _a.cellSpacing, _k = _a.linhasZebradas, linhasZebradas = _k === void 0 ? false : _k, _l = _a.hiddenColumns, hiddenColumns = _l === void 0 ? [] : _l, _m = _a.currentPage, currentPage = _m === void 0 ? 1 : _m, onPageChange = _a.onPageChange, _o = _a.showTrash, showTrash = _o === void 0 ? false : _o, onTrashClick = _a.onTrashClick, minWidth = _a.minWidth, minHeight = _a.minHeight;
16378
16378
  var _p = React.useState(null), selectedRow = _p[0], setSelectedRow = _p[1];
16379
16379
  var _q = React.useState(currentPage), localPage = _q[0], setLocalPage = _q[1];
16380
16380
  React.useEffect(function () {
@@ -16415,7 +16415,7 @@ var TableStandard = function (_a) {
16415
16415
  for (var i = 1; i <= Math.ceil(dados.length / numeroPaginas); i++) {
16416
16416
  pageNumbers.push(i);
16417
16417
  }
16418
- return (React.createElement("div", { className: styles$2.tableResponsive },
16418
+ return (React.createElement("div", { className: styles$2.tableResponsive, style: { minHeight: minHeight ? minHeight : '' } },
16419
16419
  React.createElement("div", { style: { minWidth: minWidth ? "".concat(minWidth, "px") : '' }, className: empresaClass },
16420
16420
  showExcelDownloadButton && (React.createElement("div", { className: styles$2.excelWrapper },
16421
16421
  React.createElement("button", { onClick: handleDownloadClick, className: styles$2.downloadButton, type: 'button' },
package/dist/esm/index.js CHANGED
@@ -16372,7 +16372,7 @@ var styles$2 = {"tableContainer":"tableStandard-module_tableContainer__W2g84","t
16372
16372
  styleInject(css_248z$2);
16373
16373
 
16374
16374
  var TableStandard = function (_a) {
16375
- var dados = _a.dados, onRowClick = _a.onRowClick, _b = _a.idColumn, idColumn = _b === void 0 ? 'id' : _b, onActionClick = _a.onActionClick, onDownloadClick = _a.onDownloadClick, onViewClick = _a.onViewClick, _c = _a.showActionColumn, showActionColumn = _c === void 0 ? false : _c, _d = _a.showDownloadButton, showDownloadButton = _d === void 0 ? false : _d, _e = _a.showExcelDownloadButton, showExcelDownloadButton = _e === void 0 ? false : _e, _f = _a.showViewButton, showViewButton = _f === void 0 ? false : _f, _g = _a.cor, cor = _g === void 0 ? false : _g, _h = _a.numeroPaginas, numeroPaginas = _h === void 0 ? 10 : _h, empresa = _a.empresa, _j = _a.paginacao, paginacao = _j === void 0 ? true : _j, borderRadius = _a.borderRadius, borderColor = _a.borderColor, cellsPadding = _a.cellsPadding, cellSpacing = _a.cellSpacing, _k = _a.linhasZebradas, linhasZebradas = _k === void 0 ? false : _k, _l = _a.hiddenColumns, hiddenColumns = _l === void 0 ? [] : _l, _m = _a.currentPage, currentPage = _m === void 0 ? 1 : _m, onPageChange = _a.onPageChange, _o = _a.showTrash, showTrash = _o === void 0 ? false : _o, onTrashClick = _a.onTrashClick, minWidth = _a.minWidth;
16375
+ var dados = _a.dados, onRowClick = _a.onRowClick, _b = _a.idColumn, idColumn = _b === void 0 ? 'id' : _b, onActionClick = _a.onActionClick, onDownloadClick = _a.onDownloadClick, onViewClick = _a.onViewClick, _c = _a.showActionColumn, showActionColumn = _c === void 0 ? false : _c, _d = _a.showDownloadButton, showDownloadButton = _d === void 0 ? false : _d, _e = _a.showExcelDownloadButton, showExcelDownloadButton = _e === void 0 ? false : _e, _f = _a.showViewButton, showViewButton = _f === void 0 ? false : _f, _g = _a.cor, cor = _g === void 0 ? false : _g, _h = _a.numeroPaginas, numeroPaginas = _h === void 0 ? 10 : _h, empresa = _a.empresa, _j = _a.paginacao, paginacao = _j === void 0 ? true : _j, borderRadius = _a.borderRadius, borderColor = _a.borderColor, cellsPadding = _a.cellsPadding, cellSpacing = _a.cellSpacing, _k = _a.linhasZebradas, linhasZebradas = _k === void 0 ? false : _k, _l = _a.hiddenColumns, hiddenColumns = _l === void 0 ? [] : _l, _m = _a.currentPage, currentPage = _m === void 0 ? 1 : _m, onPageChange = _a.onPageChange, _o = _a.showTrash, showTrash = _o === void 0 ? false : _o, onTrashClick = _a.onTrashClick, minWidth = _a.minWidth, minHeight = _a.minHeight;
16376
16376
  var _p = useState(null), selectedRow = _p[0], setSelectedRow = _p[1];
16377
16377
  var _q = useState(currentPage), localPage = _q[0], setLocalPage = _q[1];
16378
16378
  useEffect(function () {
@@ -16413,7 +16413,7 @@ var TableStandard = function (_a) {
16413
16413
  for (var i = 1; i <= Math.ceil(dados.length / numeroPaginas); i++) {
16414
16414
  pageNumbers.push(i);
16415
16415
  }
16416
- return (React.createElement("div", { className: styles$2.tableResponsive },
16416
+ return (React.createElement("div", { className: styles$2.tableResponsive, style: { minHeight: minHeight ? minHeight : '' } },
16417
16417
  React.createElement("div", { style: { minWidth: minWidth ? "".concat(minWidth, "px") : '' }, className: empresaClass },
16418
16418
  showExcelDownloadButton && (React.createElement("div", { className: styles$2.excelWrapper },
16419
16419
  React.createElement("button", { onClick: handleDownloadClick, className: styles$2.downloadButton, type: 'button' },
@@ -28,6 +28,7 @@ export interface TableStandardProps {
28
28
  showTrash?: boolean;
29
29
  onTrashClick?: (rowId: string) => void;
30
30
  minWidth?: string;
31
+ minHeight?: string;
31
32
  }
32
33
  declare const TableStandard: React.FC<TableStandardProps>;
33
34
  export default TableStandard;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import type { StoryObj } from '@storybook/react';
3
2
  declare const meta: {
4
3
  title: string;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import type { StoryObj } from '@storybook/react';
3
2
  declare const meta: {
4
3
  title: string;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import type { StoryObj } from '@storybook/react';
3
2
  declare const meta: {
4
3
  title: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "componenteshospitais",
3
- "version": "4.0.3",
3
+ "version": "4.0.4",
4
4
  "main": "dist/cjs/index.js",
5
5
  "module": "dist/esm/index.js",
6
6
  "types": "dist/types/index.d.ts",
@@ -33,6 +33,7 @@ export interface TableStandardProps {
33
33
  showTrash?: boolean;
34
34
  onTrashClick?: (rowId: string) => void;
35
35
  minWidth?: string;
36
+ minHeight?: string;
36
37
  }
37
38
 
38
39
  const TableStandard: React.FC<TableStandardProps> = ({
@@ -60,7 +61,8 @@ const TableStandard: React.FC<TableStandardProps> = ({
60
61
  onPageChange,
61
62
  showTrash = false,
62
63
  onTrashClick,
63
- minWidth
64
+ minWidth,
65
+ minHeight
64
66
  }) => {
65
67
  const [selectedRow, setSelectedRow] = useState<string | null>(null);
66
68
  const [localPage, setLocalPage] = useState(currentPage);
@@ -112,7 +114,7 @@ const TableStandard: React.FC<TableStandardProps> = ({
112
114
  }
113
115
 
114
116
  return (
115
- <div className={styles.tableResponsive}>
117
+ <div className={styles.tableResponsive} style={{minHeight: minHeight ? minHeight : ''}}>
116
118
  <div style={{minWidth: minWidth ? `${minWidth}px` : ''}} className={empresaClass}>
117
119
  {showExcelDownloadButton && (
118
120
  <div className={styles.excelWrapper}>