Skip to content

Commit

Permalink
chore(deps-dev): bump @types/react from 17.0.53 to 18.0.28 (#952)
Browse files Browse the repository at this point in the history
* chore(deps-dev): bump @types/react from 17.0.53 to 18.0.28

Bumps [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react) from 17.0.53 to 18.0.28.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: "@types/react"
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>

* Update package.json

* Update useCellRender.ts

* Update valueUtil.tsx

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: lijianan <[email protected]>
  • Loading branch information
dependabot[bot] and li-jia-nan authored Dec 1, 2023
1 parent 32ff755 commit 820a097
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^12.1.5",
"@types/enzyme": "^3.10.5",
"@types/react": "^18.0.28",
"@types/jest": "^29.5.0",
"@types/react": "^17.0.35",
"@types/react-dom": "^18.0.5",
"@types/responselike": "^1.0.0",
"@types/styled-components": "^5.1.32",
Expand Down
2 changes: 1 addition & 1 deletion src/Cell/useCellRender.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export default function useCellRender<RecordType>(
? dataIndex
: [dataIndex];

const value: Record<string, unknown> | React.ReactNode = getValue(record, path);
const value: React.ReactNode = getValue(record, path);

// Customize render node
let returnChildNode = value;
Expand Down
6 changes: 3 additions & 3 deletions src/utils/valueUtil.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@ interface GetColumnKeyColumn {

export function getColumnsKey(columns: readonly GetColumnKeyColumn[]) {
const columnKeys: React.Key[] = [];
const keys: Record<React.Key, boolean> = {};
const keys: Record<PropertyKey, boolean> = {};

columns.forEach(column => {
const { key, dataIndex } = column || {};

let mergedKey = key || toArray(dataIndex).join('-') || INTERNAL_KEY_PREFIX;
while (keys[mergedKey]) {
while (keys[mergedKey as string]) {
mergedKey = `${mergedKey}_next`;
}
keys[mergedKey] = true;
keys[mergedKey as string] = true;

columnKeys.push(mergedKey);
});
Expand Down

1 comment on commit 820a097

@vercel
Copy link

@vercel vercel bot commented on 820a097 Dec 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

table – ./

table-git-master-react-component.vercel.app
table-react-component.vercel.app

Please sign in to comment.