@helpdice/ui 1.2.1 → 1.2.3

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/index.js CHANGED
@@ -42244,8 +42244,10 @@ var TableCell = function TableCell(_ref) {
42244
42244
  var shouldBeRenderElement = column.renderHandler(currentRowValue, row, rowIndex);
42245
42245
  return /*#__PURE__*/React.createElement("td", {
42246
42246
  style: _objectSpread2({
42247
+ fontSize: "".concat(column === null || column === undefined ? undefined : column.fontSize),
42247
42248
  textAlign: "".concat(column === null || column === undefined ? undefined : column.align, " !important"),
42248
- p: 0,
42249
+ paddingLeft: '0.3rem',
42250
+ paddingRight: '0.3rem',
42249
42251
  color: "".concat(column === null || column === undefined ? undefined : column.color),
42250
42252
  whiteSpace: column !== null && column !== undefined && column.noWrap ? 'nowrap' : 'normal'
42251
42253
  }, currentRowValue === null || currentRowValue === undefined ? undefined : currentRowValue.style),
@@ -42432,6 +42434,10 @@ var TableColumn = function TableColumn(columnProps) {
42432
42434
  width = _ref.width,
42433
42435
  filter = _ref.filter,
42434
42436
  options = _ref.options,
42437
+ noWrap = _ref.noWrap,
42438
+ align = _ref.align,
42439
+ _ref$fontSize = _ref.fontSize,
42440
+ fontSize = _ref$fontSize === undefined ? 'smaller' : _ref$fontSize,
42435
42441
  _ref$className = _ref.className,
42436
42442
  className = _ref$className === undefined ? '' : _ref$className,
42437
42443
  renderHandler = _ref.render;
@@ -42445,13 +42451,16 @@ var TableColumn = function TableColumn(columnProps) {
42445
42451
  updateColumn({
42446
42452
  label: children || label,
42447
42453
  filter: filter,
42454
+ noWrap: noWrap,
42448
42455
  options: options,
42449
42456
  prop: safeProp,
42450
42457
  width: width,
42458
+ align: align,
42459
+ fontSize: fontSize,
42451
42460
  className: className,
42452
42461
  renderHandler: function renderHandler() {}
42453
42462
  });
42454
- }, [children, filter, options, label, prop, width, className, renderHandler]);
42463
+ }, [children, noWrap, fontSize, align, filter, options, label, prop, width, className, renderHandler]);
42455
42464
  return null;
42456
42465
  };
42457
42466
  TableColumn.displayName = 'TableColumn';
@@ -42868,10 +42877,13 @@ function DataTable(_ref) {
42868
42877
  }
42869
42878
  }, COLUMNS.map(function (column, index) {
42870
42879
  return /*#__PURE__*/React.createElement(Table.Column, {
42880
+ fontSize: column === null || column === undefined ? undefined : column.fontSize,
42871
42881
  key: "".concat(column.id, "-").concat(index),
42872
42882
  prop: column.id,
42873
42883
  label: column.name,
42874
- filter: column.filter
42884
+ filter: column === null || column === undefined ? undefined : column.filter,
42885
+ noWrap: column === null || column === undefined ? undefined : column.noWrap,
42886
+ align: column === null || column === undefined ? undefined : column.align
42875
42887
  });
42876
42888
  })))));
42877
42889
  }
@@ -19989,8 +19989,10 @@ var TableCell = function TableCell(_ref) {
19989
19989
  var shouldBeRenderElement = column.renderHandler(currentRowValue, row, rowIndex);
19990
19990
  return /*#__PURE__*/React.createElement("td", {
19991
19991
  style: _objectSpread2({
19992
+ fontSize: "".concat(column === null || column === undefined ? undefined : column.fontSize),
19992
19993
  textAlign: "".concat(column === null || column === undefined ? undefined : column.align, " !important"),
19993
- p: 0,
19994
+ paddingLeft: '0.3rem',
19995
+ paddingRight: '0.3rem',
19994
19996
  color: "".concat(column === null || column === undefined ? undefined : column.color),
19995
19997
  whiteSpace: column !== null && column !== undefined && column.noWrap ? 'nowrap' : 'normal'
19996
19998
  }, currentRowValue === null || currentRowValue === undefined ? undefined : currentRowValue.style),
@@ -20220,6 +20222,10 @@ var TableColumn = function TableColumn(columnProps) {
20220
20222
  width = _ref.width,
20221
20223
  filter = _ref.filter,
20222
20224
  options = _ref.options,
20225
+ noWrap = _ref.noWrap,
20226
+ align = _ref.align,
20227
+ _ref$fontSize = _ref.fontSize,
20228
+ fontSize = _ref$fontSize === undefined ? 'smaller' : _ref$fontSize,
20223
20229
  _ref$className = _ref.className,
20224
20230
  className = _ref$className === undefined ? '' : _ref$className,
20225
20231
  renderHandler = _ref.render;
@@ -20233,13 +20239,16 @@ var TableColumn = function TableColumn(columnProps) {
20233
20239
  updateColumn({
20234
20240
  label: children || label,
20235
20241
  filter: filter,
20242
+ noWrap: noWrap,
20236
20243
  options: options,
20237
20244
  prop: safeProp,
20238
20245
  width: width,
20246
+ align: align,
20247
+ fontSize: fontSize,
20239
20248
  className: className,
20240
20249
  renderHandler: function renderHandler() {}
20241
20250
  });
20242
- }, [children, filter, options, label, prop, width, className, renderHandler]);
20251
+ }, [children, noWrap, fontSize, align, filter, options, label, prop, width, className, renderHandler]);
20243
20252
  return null;
20244
20253
  };
20245
20254
  TableColumn.displayName = 'TableColumn';
@@ -31460,10 +31469,13 @@ function DataTable(_ref) {
31460
31469
  }
31461
31470
  }, COLUMNS.map(function (column, index) {
31462
31471
  return /*#__PURE__*/React.createElement(Table.Column, {
31472
+ fontSize: column === null || column === undefined ? undefined : column.fontSize,
31463
31473
  key: "".concat(column.id, "-").concat(index),
31464
31474
  prop: column.id,
31465
31475
  label: column.name,
31466
- filter: column.filter
31476
+ filter: column === null || column === undefined ? undefined : column.filter,
31477
+ noWrap: column === null || column === undefined ? undefined : column.noWrap,
31478
+ align: column === null || column === undefined ? undefined : column.align
31467
31479
  });
31468
31480
  })))));
31469
31481
  }
@@ -7,6 +7,9 @@ export type TableColumnProps<TableDataItem extends TableDataItemBase> = {
7
7
  width?: number;
8
8
  options?: any[];
9
9
  className?: string;
10
+ noWrap?: boolean;
11
+ align?: string;
12
+ fontSize?: string | number;
10
13
  render?: TableColumnRender<TableDataItem>;
11
14
  };
12
15
  declare const TableColumn: {
@@ -11,6 +11,7 @@ export type TableAbstractColumn<TableDataItem> = {
11
11
  align?: string;
12
12
  color?: string;
13
13
  noWrap?: boolean;
14
+ fontSize?: string | number;
14
15
  options?: any[];
15
16
  renderHandler: TableColumnRender<TableDataItemBase>;
16
17
  };
@@ -321,10 +321,13 @@ function DataTable(_ref) {
321
321
  }
322
322
  }, COLUMNS.map(function (column, index) {
323
323
  return /*#__PURE__*/React.createElement(Table.Column, {
324
+ fontSize: column === null || column === void 0 ? void 0 : column.fontSize,
324
325
  key: "".concat(column.id, "-").concat(index),
325
326
  prop: column.id,
326
327
  label: column.name,
327
- filter: column.filter
328
+ filter: column === null || column === void 0 ? void 0 : column.filter,
329
+ noWrap: column === null || column === void 0 ? void 0 : column.noWrap,
330
+ align: column === null || column === void 0 ? void 0 : column.align
328
331
  });
329
332
  })))));
330
333
  }
@@ -13,8 +13,10 @@ var TableCell = function TableCell(_ref) {
13
13
  var shouldBeRenderElement = column.renderHandler(currentRowValue, row, rowIndex);
14
14
  return /*#__PURE__*/React.createElement("td", {
15
15
  style: _extends({
16
+ fontSize: "".concat(column === null || column === void 0 ? void 0 : column.fontSize),
16
17
  textAlign: "".concat(column === null || column === void 0 ? void 0 : column.align, " !important"),
17
- p: 0,
18
+ paddingLeft: '0.3rem',
19
+ paddingRight: '0.3rem',
18
20
  color: "".concat(column === null || column === void 0 ? void 0 : column.color),
19
21
  whiteSpace: column !== null && column !== void 0 && column.noWrap ? 'nowrap' : 'normal'
20
22
  }, currentRowValue === null || currentRowValue === void 0 ? void 0 : currentRowValue.style),
@@ -7,6 +7,9 @@ export type TableColumnProps<TableDataItem extends TableDataItemBase> = {
7
7
  width?: number;
8
8
  options?: any[];
9
9
  className?: string;
10
+ noWrap?: boolean;
11
+ align?: string;
12
+ fontSize?: string | number;
10
13
  render?: TableColumnRender<TableDataItem>;
11
14
  };
12
15
  declare const TableColumn: {
@@ -11,6 +11,10 @@ var TableColumn = function TableColumn(columnProps) {
11
11
  width = _ref.width,
12
12
  filter = _ref.filter,
13
13
  options = _ref.options,
14
+ noWrap = _ref.noWrap,
15
+ align = _ref.align,
16
+ _ref$fontSize = _ref.fontSize,
17
+ fontSize = _ref$fontSize === void 0 ? 'smaller' : _ref$fontSize,
14
18
  _ref$className = _ref.className,
15
19
  className = _ref$className === void 0 ? '' : _ref$className,
16
20
  renderHandler = _ref.render;
@@ -24,13 +28,16 @@ var TableColumn = function TableColumn(columnProps) {
24
28
  updateColumn({
25
29
  label: children || label,
26
30
  filter: filter,
31
+ noWrap: noWrap,
27
32
  options: options,
28
33
  prop: safeProp,
29
34
  width: width,
35
+ align: align,
36
+ fontSize: fontSize,
30
37
  className: className,
31
38
  renderHandler: function renderHandler() {}
32
39
  });
33
- }, [children, filter, options, label, prop, width, className, renderHandler]);
40
+ }, [children, noWrap, fontSize, align, filter, options, label, prop, width, className, renderHandler]);
34
41
  return null;
35
42
  };
36
43
  TableColumn.displayName = 'TableColumn';
@@ -11,6 +11,7 @@ export type TableAbstractColumn<TableDataItem> = {
11
11
  align?: string;
12
12
  color?: string;
13
13
  noWrap?: boolean;
14
+ fontSize?: string | number;
14
15
  options?: any[];
15
16
  renderHandler: TableColumnRender<TableDataItemBase>;
16
17
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@helpdice/ui",
3
- "version": "1.2.1",
3
+ "version": "1.2.3",
4
4
  "main": "dist/index.js",
5
5
  "types": "esm/index.d.ts",
6
6
  "unpkg": "dist/index.min.js",