@synerise/ds-table-new 1.1.0 → 1.1.2

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/CHANGELOG.md CHANGED
@@ -3,6 +3,20 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [1.1.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-table-new@1.1.1...@synerise/ds-table-new@1.1.2) (2026-05-04)
7
+
8
+ ### Bug Fixes
9
+
10
+ - add exports field to all component packages for correct ESM detection ([6eccfde](https://github.com/Synerise/synerise-design/commit/6eccfde8f2dd73c59860793231fbd7bcd61813b4))
11
+ - **table-new:** fix layout and horizontal scroll choppyness in safari ([754e032](https://github.com/Synerise/synerise-design/commit/754e032dbf0315684d19c8a7b4d867bd6409f523))
12
+ - **table-new:** update legacyColumnConfigAdapter to handle dots in dataIndex ([6e8e7f4](https://github.com/Synerise/synerise-design/commit/6e8e7f43394e637ea3d5aca8b4ba9d4021408359))
13
+
14
+ ## [1.1.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-table-new@1.1.0...@synerise/ds-table-new@1.1.1) (2026-04-29)
15
+
16
+ ### Bug Fixes
17
+
18
+ - **table-new:** prevent premature column width calculation ([66bf51b](https://github.com/Synerise/synerise-design/commit/66bf51b62df73cff602eadeda4342520f7a7a1d1))
19
+
6
20
  # [1.1.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-table-new@1.0.6...@synerise/ds-table-new@1.1.0) (2026-04-28)
7
21
 
8
22
  ### Features
@@ -1,4 +1,4 @@
1
- import { PaginationProps } from 'antd/lib/pagination';
1
+ import { PaginationProps } from 'antd';
2
2
  import { HTMLAttributes, MouseEvent, MutableRefObject, ReactElement, ReactNode, RefObject } from 'react';
3
3
  import { SearchInputProps } from '@synerise/ds-search';
4
4
  import { TooltipProps } from '@synerise/ds-tooltip';
@@ -8,7 +8,7 @@ const Tr = /* @__PURE__ */ styled.tr.withConfig({
8
8
  const TBody = /* @__PURE__ */ styled.tbody.withConfig({
9
9
  displayName: "TableBodystyles__TBody",
10
10
  componentId: "sc-1dty8xx-1"
11
- })(["position:relative;"]);
11
+ })(["position:relative;display:block;"]);
12
12
  export {
13
13
  TBody,
14
14
  Tr
@@ -44,7 +44,10 @@ const useColumnSizing = ({
44
44
  return;
45
45
  }
46
46
  if (wrapperRef.current) {
47
- calc(getContentWidth(wrapperRef.current));
47
+ const width = getContentWidth(wrapperRef.current);
48
+ if (width > 0) {
49
+ calc(width);
50
+ }
48
51
  }
49
52
  }, [enabled, calc, getContentWidth, wrapperRef]);
50
53
  useResizeObserver(wrapperRef, resizeHandler);
@@ -6,9 +6,13 @@ const useScrollSync = (refs) => {
6
6
  return;
7
7
  }
8
8
  const scrollHandler = (event) => {
9
+ const source = event.target;
10
+ const {
11
+ scrollLeft
12
+ } = source;
9
13
  nodes.forEach((elem) => {
10
- if (elem !== event.currentTarget) {
11
- elem.scrollLeft = event.currentTarget?.scrollLeft;
14
+ if (elem !== source && elem.scrollLeft !== scrollLeft) {
15
+ elem.scrollLeft = scrollLeft;
12
16
  }
13
17
  });
14
18
  };
@@ -70,8 +70,17 @@ const legacyColumnConfigAdapter = (columns) => {
70
70
  multiSortOrder,
71
71
  ...sortingConfig
72
72
  } = getSortingConfig(column.sorter);
73
+ const accessorConfig = Array.isArray(column.dataIndex) ? {
74
+ id: column.dataIndex.join("."),
75
+ accessorFn: (row) => column.dataIndex.reduce((acc, k) => acc?.[k], row)
76
+ } : typeof column.dataIndex === "string" && column.dataIndex.includes(".") ? {
77
+ id: column.dataIndex,
78
+ accessorFn: (row) => row[column.dataIndex]
79
+ } : {
80
+ accessorKey: `${column.dataIndex}`
81
+ };
73
82
  return {
74
- accessorKey: `${column.dataIndex}`,
83
+ ...accessorConfig,
75
84
  header: () => {
76
85
  return typeof column.title === "function" ? column.title({}) : column.title;
77
86
  },
package/package.json CHANGED
@@ -1,10 +1,19 @@
1
1
  {
2
2
  "name": "@synerise/ds-table-new",
3
- "version": "1.1.0",
3
+ "version": "1.1.2",
4
4
  "description": "TableNew UI Component for the Synerise Design System",
5
5
  "license": "ISC",
6
6
  "repository": "Synerise/synerise-design",
7
7
  "main": "dist/index.js",
8
+ "exports": {
9
+ ".": {
10
+ "types": "./dist/index.d.ts",
11
+ "import": "./dist/index.js",
12
+ "default": "./dist/index.js"
13
+ },
14
+ "./dist/*.js": "./dist/*.js",
15
+ "./dist/*": "./dist/*.js"
16
+ },
8
17
  "files": [
9
18
  "/dist",
10
19
  "CHANGELOG.md",
@@ -34,28 +43,28 @@
34
43
  "types": "dist/index.d.ts",
35
44
  "dependencies": {
36
45
  "@floating-ui/react": "^0.27.16",
37
- "@synerise/ds-badge": "^1.0.50",
38
- "@synerise/ds-button": "^1.5.24",
39
- "@synerise/ds-checkbox": "^1.2.27",
40
- "@synerise/ds-copy-icon": "^1.2.8",
41
- "@synerise/ds-dropdown": "^1.3.9",
42
- "@synerise/ds-flag": "^1.0.10",
43
- "@synerise/ds-icon": "^1.17.1",
44
- "@synerise/ds-inline-alert": "^1.1.20",
45
- "@synerise/ds-input": "^1.7.4",
46
- "@synerise/ds-input-number": "^1.2.41",
47
- "@synerise/ds-loader": "^1.0.15",
48
- "@synerise/ds-modal": "^1.4.8",
49
- "@synerise/ds-pagination": "^1.0.59",
50
- "@synerise/ds-result": "^1.0.55",
51
- "@synerise/ds-scrollbar": "^1.3.2",
52
- "@synerise/ds-search": "^1.5.18",
53
- "@synerise/ds-skeleton": "^1.0.51",
54
- "@synerise/ds-tag": "^1.4.24",
55
- "@synerise/ds-tags": "^1.5.35",
56
- "@synerise/ds-tooltip": "^1.4.16",
57
- "@synerise/ds-typography": "^1.1.19",
58
- "@synerise/ds-utils": "^1.8.0",
46
+ "@synerise/ds-badge": "^1.0.52",
47
+ "@synerise/ds-button": "^1.5.26",
48
+ "@synerise/ds-checkbox": "^1.2.29",
49
+ "@synerise/ds-copy-icon": "^1.2.10",
50
+ "@synerise/ds-dropdown": "^1.3.11",
51
+ "@synerise/ds-flag": "^1.0.11",
52
+ "@synerise/ds-icon": "^1.17.3",
53
+ "@synerise/ds-inline-alert": "^1.1.22",
54
+ "@synerise/ds-input": "^1.7.6",
55
+ "@synerise/ds-input-number": "^1.2.43",
56
+ "@synerise/ds-loader": "^1.0.16",
57
+ "@synerise/ds-modal": "^1.4.10",
58
+ "@synerise/ds-pagination": "^1.0.61",
59
+ "@synerise/ds-result": "^1.0.57",
60
+ "@synerise/ds-scrollbar": "^1.3.4",
61
+ "@synerise/ds-search": "^1.5.20",
62
+ "@synerise/ds-skeleton": "^1.0.53",
63
+ "@synerise/ds-tag": "^1.4.26",
64
+ "@synerise/ds-tags": "^1.5.37",
65
+ "@synerise/ds-tooltip": "^1.4.18",
66
+ "@synerise/ds-typography": "^1.1.21",
67
+ "@synerise/ds-utils": "^1.8.1",
59
68
  "@tanstack/react-table": "^8.21.3",
60
69
  "@tanstack/react-virtual": "^3.13.12",
61
70
  "unit-to-px": "^1.0.5",
@@ -71,5 +80,5 @@
71
80
  "react-intl": ">= 3.12.0 <= 6.8",
72
81
  "styled-components": "^5.3.3"
73
82
  },
74
- "gitHead": "25cf79a6df348141419f397813e4f6a5533deb5f"
83
+ "gitHead": "c5eee882509cbeb4544cb45939620881b829d4d9"
75
84
  }