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 04ee9ba to 3e101ac Compare May 21, 2024 12:52
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 3e101ac to 2b2790b Compare May 24, 2024 03:20
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 2b2790b to 70a080e Compare May 24, 2024 03:20
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 70a080e to 5536f2e Compare May 24, 2024 09:56
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 5536f2e to 52b547a Compare May 24, 2024 09:56
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 52b547a to 4aca065 Compare May 24, 2024 22:24
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 4aca065 to c8c2368 Compare May 24, 2024 22:24
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from c8c2368 to 17de530 Compare May 25, 2024 14:57
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 17de530 to 73aa7a0 Compare May 25, 2024 14:58
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 73aa7a0 to 5ac338c Compare May 28, 2024 13:54
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 5ac338c to 13ed5d5 Compare May 28, 2024 13:54
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 13ed5d5 to a7c1279 Compare May 29, 2024 19:08
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from a7c1279 to 57d3625 Compare May 29, 2024 19:09
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 57d3625 to c25cc91 Compare May 30, 2024 11:55
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from c25cc91 to b111ab8 Compare May 30, 2024 11:56
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from b111ab8 to b021395 Compare May 31, 2024 12:37
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from b021395 to 47e9723 Compare May 31, 2024 12:39
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 47e9723 to 651c8a3 Compare June 3, 2024 17:14
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 651c8a3 to 4661590 Compare June 3, 2024 17:15
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from 4661590 to fdd894a Compare June 4, 2024 04:46
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from fdd894a to e96b8f3 Compare June 4, 2024 04:46
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from e96b8f3 to 4104f5a Compare June 4, 2024 15:02
@github-actions github-actions bot force-pushed the renovate/major-react-dependencies branch from 4104f5a to c5b33a2 Compare June 4, 2024 15:02
@renovate renovate bot force-pushed the renovate/major-react-dependencies branch from c5b33a2 to 8c9051c Compare June 4, 2024 23:18
@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
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