Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update react dependencies (major) #1094

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Oct 19, 2022

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@testing-library/react 13.4.0 -> 16.0.0 age adoption passing confidence
react-data-table-component 6.11.8 -> 7.6.2 age adoption passing confidence
react-helmet-async 1.3.0 -> 2.0.5 age adoption passing confidence

Release Notes

testing-library/react-testing-library (@​testing-library/react)

v16.0.0

Compare Source

Features
  • Move @testing-library/dom and @types/react-dom to peer dependencies (#​1305) (a4744fa)
BREAKING CHANGES
  • @testing-library/dom was moved to a peer dependency and needs to be explicitly installed. This reduces the chance of having conflicting versions of @testing-library/dom installed that frequently caused bugs when used with @testing-library/user-event. We will also be able to allow new versions of @testing-library/dom being used without a SemVer major release of @testing-library/react by just widening the peer dependency.
    @types/react-dom needs to be installed if you're typechecking files using @testing-library/react.

Co-authored-by: Matan Borenkraout matanbobi@gmail.com

v15.0.7

Compare Source

v15.0.6

Compare Source

v15.0.5

Compare Source

v15.0.4

Compare Source

v15.0.3

Compare Source

Bug Fixes
  • Don't raise TypeScript errors when hydating document (#​1304) (067d0c6)

v15.0.2

Compare Source

v15.0.1

Compare Source

v15.0.0

Compare Source

v14.3.1

Compare Source

Bug Fixes

v14.3.0

Compare Source

v14.2.2

Compare Source

v14.2.1

Compare Source

Bug Fixes
  • Update types to support all possible react component return values (#​1272) (55e79c2)

v14.2.0

Compare Source

Features
  • add reactStrictMode option to enable strict mode render (#​1241) (0880eba)

v14.1.2

Compare Source

Bug Fixes

v14.1.1

Compare Source

Bug Fixes

v14.1.0

Compare Source

Features

v14.0.0

Compare Source

Bug Fixes
Features
BREAKING CHANGES
jbetancur/react-data-table-component (react-data-table-component)

v7.6.2

Compare Source

What's Changed

Full Changelog: jbetancur/react-data-table-component@v7.6.1...v7.6.2

v7.6.1

Compare Source

What's Changed

Full Changelog: jbetancur/react-data-table-component@v7.6.0...v7.6.1

v7.6.0

Compare Source

What's Changed

New Contributors

Full Changelog: jbetancur/react-data-table-component@v7.5.4...v7.6.0

v7.5.4

Compare Source

Fixes #​1154 - thank you @​HendrikPetertje !

v7.5.3

Compare Source

Fixes

  • #​1076 className should now pass to responsiveWrapper

v7.5.2

Compare Source

Fixes

  • fixes infinite re-render when using setState or useState hooks within onSort

v7.5.1

Compare Source

Features

  • #​1047 adds sorted columns as a 3rd prop for onSort

v7.5.0

Compare Source

Features

v7.4.7

Compare Source

v7.4.6

Compare Source

Bug Fixes

  • #​975 using custom a custom theme name should no longer cause TypeScript to complain

Maintenance

  • Update deprecated deps
  • Update deps

v7.4.5

Compare Source

🥃 Features 🥃

  • #​945 selectableRowsSingle should now work with selectableRowSelected, however if you have more than one match only the first match will be selected.

v7.4.4

Compare Source

🥃 Features 🥃

  • Expose ExpanderComponentProps TypeScript type. You can now:
type DataRow = {
....
};

const ExpandedComponent: React.FC<ExpanderComponentProps<DataRow>> = ({ data }) => {
	return <pre>{JSON.stringify(data, null, 2)}</pre>;
};

// or

function ExpandedComponent({ data }: ExpanderComponentProps<DataRow>): JSX.Element {
	return <pre>{JSON.stringify(data, null, 2)}</pre>;
}

v7.4.3

Compare Source

🐞 Fixes 🐞

  • #​937 fixes TypeError: Attempting to change configurable attribute of unconfigurable on the data prop for certain use cases

v7.4.2

Compare Source

🐞 Fixes 🐞

  • #​930 when using onSelectedRowsChange no longer causes infinite loop when updating table data within onSelectedRowsChange
  • #​934 fixed expandableRowsComponent types

v7.4.1

Compare Source

🐞 Fixes 🐞

  • createTheme no longer requires an inherited theme

v7.4.0

Compare Source

🥃 Features 🥃

  • lodash.orderBy has been removed and replaced with native sorting. lodash was a bit heavy weight as a dependency (the bundle should be smaller now) and slower than native sort in some of our performance tests (basically negligible). If you want really miss the lodash.orderBy sorting behavior you can install lodash yourself and use sortFunction to re-implement orderBy.

🐞 Fixes 🐞

  • #​933 when using createTheme you may now specify one of the default themes to inherit from. This is useful if you only need to tweak a thing or 2 in each theme. See the custom theming for more details

v7.3.1

Compare Source

🐞 Fixes 🐞

  • #​922 context menu should now be visible when selecting rows

v7.3.0

Compare Source

🥃 New Features 🥃

  • Column titles will now display a built in tooltip (using the title attribute) when a column is in a ellipses state
    • This will be negated when you pass a component into a column name.

🐞 Fixes 🐞

  • Fixes an issue where sort direction would default if data changes. Sort behavior should now be preserved
  • Fixes a spacing issue in columns titles

v7.2.1

Compare Source

🐞 Fixes 🐞

  • #​919 No longer apply css styles when column.name is a component

v7.2.0

Compare Source

🐞 Fixes 🐞

  • This releases fixes type inference where passing your Data type/interface was conflicting with an internal typing TableRow. This should no longer be the case.

v7.1.0

Compare Source

🥃 New Features 🥃

v7.0.2

Compare Source

🐞 Fixes 🐞

  • #​906 fixes "Could not find a declaration file for module 'react-data-table-component'"

v7.0.1

Compare Source

🐞 Bug Fixes 🐞

  • setting defaultSortFieldId now works properly
  • added back alias for IDataTableRow (which is now TableRow to make migrating from v6 to v7 easier

🥃 New Features 🥃

  • allow importing TableRow type

📜 Documentation 📜

  • fixes some documentation issues
  • adds typescript docs
  • adds pattern docs

🏡 Housekeeping 🏡

  • refactor to naming of components
  • internal tweaks to types
  • refactored sorting styles to be more customizable where possible

TypeScript Projects with React Data Table

React Data Table is built with TypeScript so typings are buit in. Let's implement React Data Table in a TypeScript project:

First, we'll need to define our data type (or interface):

import DataTable, { TableColumn } from 'react-data-table-component';

type DataRow {
	title: string;
	director: string;
	year: string;
}

Alternatively, if you want to define DataRow as an interface you will need to extend the built in TableRow type:

import DataTable, { TableColumn, TableRow } from 'react-data-table-component';

interface DataRow extends TableRow {
	title: string;
	director: string;
	year: string;
}

Next, we can create our columns. TableColumn is an interface representing a column definition that takes a generic parameter. By passing TableColumn<DataRow>[] we now have access to our dataRow props on any property in our table columns for any propery that accesses our data:

const columns: TableColumn<DataRow>[] = [
	{
		name: 'Title',
		selector: row => row.title,
	},
	{
		name: 'Director',
		selector: row => row.director,
	},
	{
		name: 'Year',
		selector: row => row.year,
	},
];

Finally, we can implement our TypeScript component that uses DataTable:

function MyComponent(): JSX.Element {
	return <DataTable columns={columns} data={data} />;
}

Alternatively, if you prefer using React.FC:

const MyComponent: React.FC = () => {
	return <DataTable columns={columns} data={data} />;
};

Putting it all together:

import DataTable, { TableColumn } from 'react-data-table-component';

type DataRow {
	title: string;
	director: string;
	year: string;
}

const columns: TableColumn<DataRow>[] = [
	{
		name: 'Title',
		selector: row => row.title,
	},
	{
		name: 'Director',
		selector: row => row.director,
	},
	{
		name: 'Year',
		selector: row => row.year,
	},
];

function MyComponent(): JSX.Element {
	return <DataTable columns={columns} data={data} />;
}

export default MyComponent;

v7.0.0

Compare Source

After several long months Version 7.0.0 is now available. The most notable change is that RDT 7 has been ported over to TypeScript which as it turns out resolved a number of bugs both unknown and long standing. This however, introduced some breaking changes to the API which are noted below. Also RDT v7 introduces several new features such as draggable columns, single row selection and the ability to pass props to expander components as well as vastly improved documentation.

Thank you all for your patience and to those that contributed PR's and/or feedback!

🔥 🔥 BREAKING CHANGES 🔥 🔥

  • expandableRowsComponent no longer accepts JSX and must now be passed in as a function/class. e.g.:
    GOOD:
    expandableRowsComponent={MyExpander}
    BAD:
    expandableRowsComponent={<MyExpander />}
  • sortFunction prop signature has changed, This was necessary because RDT is moving to function only selectors which are more flexible and performant. Additionally, this allows the API user greater control over how they sort. See the README for details Custom Sort Function.
  • defaultSortfField is now defaultSortFieldId where you use a column ID instead of a name.
    If you do not assign an id to each of your column definitions RDT will add a number based id starting with 1,2,3,...
  • overflowY and overflowYOffset have been removed from the API as they were problematic when using fixedHeader. These were originally created to deal menu overlays that did not use dynamic positioning - causing a menu to be truncated at the bottom of the table. Most UI libraries should support dynamically positioned menus, but in any case this is no longer the responsibility of RDT to manage.
  • TypeScript targets have been upgraded to es6 from es5. This might cause issues with older browsers "possibly" IE 11. RDT has not supported IE11 in the past and will not in the future.

🥃 🥃 New Features 🥃 🥃

  • Draggable column reordering is now available! See the Columns section in the Docs for details.
  • Single row selection feature is now available via a new prop selectableRowsSingle . If you want to change the built in checkbox to a radio button you can pass selectableRowsComponentProps={{ type: 'radio' }} or pass in your own custom/ui library Radio button using both selectableRowsComponent and selectableRowsComponentProps
  • Added a new prop: expandableRowsComponentProps now allows you to pass extra props to your custom expandableRowsComponent.

🐞 🐞 Fixes 🐞 🐞

  • fixedHeader scroll bar no longer offsets table columns. Note that fixedHeader relies on browsers that support sticky positioning.
  • Cleanup of stale sorting logic and CSS styles
  • TableHeadRow is no longer disabled when in a loading state. Instead, each TableCol is disabled from sorting
  • fixes a potential performance issue with large data sets and conditionalCells and conditionalRows
  • sortServer should now disable internal sorting as it did in v6
  • column centering show now work for both cells and cols
  • update peerDependencies for React 17
  • when using fixedHeader only show scroll bars when needed
  • fixes pagination select dropdown icon which was overlapping on larger numbers (e.g. 100, 1000 etc)
  • fixes double horizontal bar in some browsers. Thanks @​HoangNguyen17193
  • you can now override fontWeight when using custom styles in headCells
  • fixes broken data table document not defined when using nextjs and pagination
  • if the columns prop is changed it should now re-render DataTable.
  • fixed an issue where using pre selected rows, unchecking a row and then and sorting would reset pre selects, this should no longer happen
  • There was a bug when using sortFunction and pagination together would result in broken sorting. This is now fixed.

📜📜 Documentation 📜📜

  • Documentation has been vastly improved. If you have ideas for additions or fixes please submit a PR!
  • The original plan was to do a custom documentation site, however, given some time constraints it was decided stick with storybook and implement some of it's newer features.

👋 👋 Deprecations 👋 👋

  • string selectors will display a console warning on non prod builds recommended you migrate to function selectors. This change is rather painless: selector: 'name' becomes selector: row => row.name. This not only allows for typing but also no longer requires an expensive regex/reduce function to loop through a row to "get' the prop
staylor/react-helmet-async (react-helmet-async)

v2.0.5

Compare Source

v2.0.4

Compare Source

v2.0.3

Compare Source

v2.0.2

Compare Source

v2.0.1

Compare Source

v2.0.0

Compare Source


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@github-actions
Copy link

github-actions bot commented Oct 19, 2022

🦙 MegaLinter status: ✅ SUCCESS

Descriptor Linter Files Fixed Errors Elapsed time
✅ EDITORCONFIG editorconfig-checker 2 0 0.01s
✅ JSON eslint-plugin-jsonc 1 0 0 0.92s
✅ JSON jsonlint 1 0 0.26s
✅ JSON npm-package-json-lint yes no 0.65s
✅ JSON prettier 1 0 0 0.34s
✅ JSON v8r 1 0 5.37s
✅ REPOSITORY checkov yes no 40.62s
✅ REPOSITORY git_diff yes no 0.02s
✅ REPOSITORY grype yes no 12.51s
✅ REPOSITORY trivy-sbom yes no 3.12s
✅ REPOSITORY trufflehog yes no 134.58s

See detailed report in MegaLinter reports
Set VALIDATE_ALL_CODEBASE: true in mega-linter.yml to validate all sources, not only the diff

MegaLinter is graciously provided by OX Security

@renovate renovate bot force-pushed the renovate/major-react-dependencies branch 20 times, most recently from 22ce80f to 5a681b4 Compare October 27, 2022 16:39
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch 9 times, most recently from ca1783f to 639cd7f Compare November 4, 2022 08:46
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 8c9051c to 9175695 Compare June 4, 2024 23:18
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 9175695 to 2aeb1d4 Compare June 6, 2024 04:43
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 2aeb1d4 to 63ec362 Compare June 6, 2024 04:43
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 63ec362 to fad9a9d Compare June 7, 2024 15:15
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from fad9a9d to 0e45555 Compare June 7, 2024 15:16
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 0e45555 to dbe4b9e Compare June 12, 2024 04:15
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from dbe4b9e to 81027cb Compare June 12, 2024 04:16
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 81027cb to 24503fd Compare June 19, 2024 12:20
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 24503fd to 1b77b5c Compare June 19, 2024 12:20
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 1b77b5c to ba67868 Compare June 19, 2024 12:31
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from ba67868 to a003bb7 Compare June 19, 2024 12:31
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from a003bb7 to 5a265bf Compare June 20, 2024 00:00
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 5a265bf to 5969e40 Compare June 20, 2024 00:01
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 5969e40 to 5f7476d Compare June 20, 2024 12:40
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 5f7476d to 27c6b36 Compare June 20, 2024 12:40
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 27c6b36 to ad7cc14 Compare June 21, 2024 19:42
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from ad7cc14 to a996bfe Compare June 21, 2024 19:42
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from a996bfe to 17eb8c3 Compare July 3, 2024 22:42
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 17eb8c3 to a9bb5c1 Compare July 3, 2024 22:43
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from a9bb5c1 to d837edf Compare July 3, 2024 22:47
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from d837edf to 9467aa3 Compare July 3, 2024 22:48
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 9467aa3 to 79eb8d7 Compare July 3, 2024 22:54
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 79eb8d7 to f6e024b Compare July 3, 2024 22:54
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from f6e024b to 1bfe3e7 Compare July 4, 2024 12:06
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 1bfe3e7 to 02afa86 Compare July 4, 2024 12:06
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 02afa86 to dc73db3 Compare July 4, 2024 19:18
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from dc73db3 to 63dc3ed Compare July 4, 2024 19:18
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 63dc3ed to 163467f Compare July 6, 2024 07:55
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 163467f to c0b22ff Compare July 6, 2024 07:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

0 participants