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

build(deps): Bump react-dom and @types/react-dom #1826

Merged
merged 3 commits into from
Apr 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 13 additions & 13 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"react": "^18.2.0",
"react-avatar-editor": "^13.0.2",
"react-beautiful-dnd": "^13.1.1",
"react-dom": "^18.2.0",
"react-dom": "^18.3.1",
"react-dropzone": "^14.2.3",
"react-error-boundary": "^4.0.13",
"react-helmet-async": "^2.0.4",
Expand Down Expand Up @@ -98,7 +98,7 @@
"@types/jest": "^29.5.12",
"@types/js-cookie": "^3.0.6",
"@types/react": "^18.2.78",
"@types/react-dom": "^18.2.24",
"@types/react-dom": "^18.3.0",
"@typescript-eslint/parser": "^7.6.0",
"depcheck": "^1.4.7",
"eslint-config-prettier": "^9.1.0",
Expand Down
3 changes: 1 addition & 2 deletions src/account/components/AccountProfile.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,9 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, within } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import { when } from 'jest-when';
import _ from 'lodash/fp';
import { act } from 'react-dom/test-utils';
import { useNavigate, useParams, useSearchParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
3 changes: 1 addition & 2 deletions src/contact/ContactForm.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { render, screen } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import _ from 'lodash/fp';
import { act } from 'react-dom/test-utils';

import { useScript } from 'custom-hooks';

Expand Down
3 changes: 1 addition & 2 deletions src/group/components/GroupForm.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useNavigate, useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
3 changes: 1 addition & 2 deletions src/group/components/GroupList.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useSearchParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';
import useMediaQuery from '@mui/material/useMediaQuery';
Expand Down
3 changes: 1 addition & 2 deletions src/group/membership/components/GroupMembers.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import _ from 'lodash/fp';
import { act } from 'react-dom/test-utils';
import { useNavigate, useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';
import { GROUP_TYPES_WITH_REDIRECTS } from 'tests/constants';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import MapboxDraw from '@mapbox/mapbox-gl-draw';
import { act } from 'react-dom/test-utils';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import MapboxDraw from '@mapbox/mapbox-gl-draw';
import { act } from 'react-dom/test-utils';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
3 changes: 1 addition & 2 deletions src/landscape/components/LandscapeForm/KeyInfoNew.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
3 changes: 1 addition & 2 deletions src/landscape/components/LandscapeForm/KeyInfoUpdate.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import AvatarEditor from 'react-avatar-editor';
import { act } from 'react-dom/test-utils';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
3 changes: 1 addition & 2 deletions src/landscape/components/LandscapeForm/ProfileUpdate.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';

Expand Down
3 changes: 1 addition & 2 deletions src/landscape/components/LandscapeList.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useSearchParams } from 'react-router-dom';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';
import { mockTerrasoAPIrequestGraphQL } from 'tests/apiUtils';
Expand Down
3 changes: 1 addition & 2 deletions src/landscape/membership/components/LandscapeMembers.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, waitFor, within } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import _ from 'lodash/fp';
import { act } from 'react-dom/test-utils';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';
import { mockTerrasoAPIrequestGraphQL } from 'tests/apiUtils';
import useMediaQuery from '@mui/material/useMediaQuery';
Expand Down
3 changes: 1 addition & 2 deletions src/layout/AppBar.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import Cookies from 'js-cookie';
import { act } from 'react-dom/test-utils';
import { useLocation, useNavigate } from 'react-router-dom';
import useMediaQuery from '@mui/material/useMediaQuery';

Expand Down
3 changes: 1 addition & 2 deletions src/localization/components/LocalePicker.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen, within } from 'tests/utils';
import React from 'react';
import React, { act } from 'react';
import _ from 'lodash/fp';
import { act } from 'react-dom/test-utils';
import * as terrasoApi from 'terraso-client-shared/terrasoApi/api';
import useMediaQuery from '@mui/material/useMediaQuery';

Expand Down
2 changes: 1 addition & 1 deletion src/localization/i18n.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { render, screen } from 'tests/utils';
import { act } from 'react-dom/test-utils';
import { act } from 'react';
import { useTranslation } from 'react-i18next';

import i18n from 'localization/i18n';
Expand Down
3 changes: 1 addition & 2 deletions src/navigation/components/Navigation.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
import { fireEvent, render, screen } from 'tests/utils';
import React from 'react';
import { act } from 'react-dom/test-utils';
import React, { act } from 'react';
import { useLocation } from 'react-router-dom';

import Navigation from 'navigation/components/Navigation';
Expand Down
2 changes: 1 addition & 1 deletion src/tests/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@ import React from 'react';
// import for side effects to ensure config happens before running tests
import 'config';

import { act } from 'react';
import {
waitFor as baseWaitFor,
cleanup,
render as rtlRender,
} from '@testing-library/react';
import { axe, toHaveNoViolations } from 'jest-axe';
import { act } from 'react-dom/test-utils';
import createStore from 'terrasoApi/store';

import AppWrappers from 'layout/AppWrappers';
Expand Down
Loading