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

preparing react18 #2584

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft
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
6 changes: 3 additions & 3 deletions packages/@coorpacademy-app-review/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,13 @@
},
"peerDependencies": {
"lodash": "^4.17.21",
"react": "^17.0.2"
"react": "^18.2.0"
},
"devDependencies": {
"@coorpacademy/css-modules-require-hook": "3.0.0",
"@coorpacademy/eslint-plugin-coorpacademy": "^11.0.0",
"@coorpacademy/webpack-config": "12.0.1",
"@testing-library/react": "^12.1.5",
"@testing-library/react": "^13.4.0",
"@types/lodash": "^4.14.182",
"@typescript-eslint/eslint-plugin": "^5.28.0",
"@typescript-eslint/parser": "^5.28.0",
Expand All @@ -66,7 +66,7 @@
"eslint-plugin-react-hooks": "^4.6.0",
"html-webpack-plugin": "^5.5.0",
"nock": "^13.2.9",
"react-dom": "^17.0.2",
"react-dom": "^18.2.0",
"ts-loader": "^9.4.1",
"ts-node": "^10.9.1",
"typescript": "^4.7.4",
Expand Down
18 changes: 10 additions & 8 deletions packages/@coorpacademy-components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"typecheck": "tsc --noEmit true"
},
"engines": {
"node": ">=12.22.12"
"node": ">=16.15.0"
},
"contributors": [
"Arthur Weber <[email protected]>",
Expand All @@ -56,11 +56,12 @@
"Soualmi Djamel <[email protected]>"
],
"dependencies": {
"@cfaester/enzyme-adapter-react-18": "^0.6.0",
"@coorpacademy/nova-icons": "4.1.2",
"@coorpacademy/react-native-animation": "1.0.2",
"@jwplayer/jwplayer-react": "^1.1.0",
"@types/react": "^17.0.50",
"@types/react-dom": "^17.0.17",
"@types/react": "^18.0.0",
"@types/react-dom": "^18.0.0",
"autoprefixer": "^10.4.12",
"classnames": "^2.3.2",
"css-color-function": "^1.3.3",
Expand All @@ -81,7 +82,7 @@
"react-tooltip": "^4.2.6"
},
"peerDependencies": {
"react": "^17.0.2"
"react": "^18.2.0"
},
"devDependencies": {
"@babel/cli": "^7.18.10",
Expand Down Expand Up @@ -116,8 +117,8 @@
"@storybook/builder-webpack5": "^6.5.12",
"@storybook/manager-webpack5": "^6.5.12",
"@storybook/react": "^6.5.12",
"@testing-library/react": "12.1.5",
"@testing-library/react-native": "^10.1.1",
"@testing-library/react": "13.4.0",
"@testing-library/react-native": "^11.5.0",
"@types/react-native": "~0.68.7",
"@typescript-eslint/eslint-plugin": "^5.39.0",
"@typescript-eslint/parser": "^5.39.0",
Expand All @@ -142,12 +143,13 @@
"nyc": "^15.1.0",
"postcss-loader": "^7.0.1",
"prop-types": "15.7.2",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-native": "^0.68.2",
"react-native-linear-gradient": "^2.6.2",
"react-native-modal": "11.5.6",
"react-native-render-html": "^6.3.4",
"react-test-renderer": "18.0.0",
"rxjs": "^6.5.5",
"style-loader": "^3.3.1",
"stylelint-config-standard": "^28.0.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {shallow, mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {omit, replace} from 'lodash/fp';
import style from '../style.css'; // eslint-disable-line css-modules/no-unused-class
import InputHtml from '..';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {shallow, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {omit} from 'lodash/fp';
import InputTextarea from '..';
import defaultFixture from './fixtures/default';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,13 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import delay from 'delay';
import {render, cleanup} from '@testing-library/react';
import {render} from '@testing-library/react';
import LottieWrapper, {fetchAndLoadAnimation} from '..';
import starFixture from './fixtures/default';
import controlsFixture from './fixtures/controls';

browserEnv();

test.afterEach(cleanup);

test('should update && load the animation, should clean up after unmount', async t => {
const {container, rerender} = render(<LottieWrapper {...starFixture.props} />);

Expand All @@ -22,7 +20,6 @@ test('should update && load the animation, should clean up after unmount', async

const wrapper = container.querySelectorAll('[data-name="default-lottie"]');
t.truthy(wrapper);

t.pass();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {shallow, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import Select from '..';
import defaultFixture from './fixtures/default';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import React from 'react';
import {mount, configure} from 'enzyme';
import cloneDeep from 'lodash/fp/cloneDeep';
import noop from 'lodash/fp/noop';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import Select from '..';
import playerFixture from './fixtures/player';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import React from 'react';
import PropTypes from 'prop-types';
import {mount, shallow, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {noop} from 'lodash/fp';
import AnimationScheduler, {AnimationAdapter} from '..';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {shallow, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {toString as _toString} from 'lodash/fp';
import Animation, {LINEAR} from '..';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import Swapper, {safeCancelAnimationFrame} from '..';

browserEnv({pretendToBeVisual: true});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import React from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {noop} from 'lodash/fp';
import Transition from '..';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {once} from 'lodash/fp';
import Audio from '..';
import defaultFixture from './fixtures/default';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {once} from 'lodash/fp';
import BrandCreateForm from '..';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import {identity} from 'lodash/fp';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import BulletPointMenuButton from '..';
import defaultFixture from './fixtures/default';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {set, unset, pipe} from 'lodash/fp';
import {wrappingComponent} from '../../../test/helpers/render-component';
import Card from '..';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {times} from 'lodash/fp';
import {wrappingComponent} from '../../../../test/helpers/render-component';
import Card from '../../../card/test/fixtures/default';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {replace} from 'lodash/fp';
import {Overlay} from '../overlay';
import style from '../style.css'; // eslint-disable-line css-modules/no-unused-class
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import React from 'react';
import {replace} from 'lodash/fp';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {wrappingComponent} from '../../../test/helpers/render-component';
import style from '../style.css'; // eslint-disable-line css-modules/no-unused-class
import uploadReportStyle from '../upload-report.css'; // eslint-disable-line css-modules/no-unused-class
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import {set} from 'lodash/fp';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {wrappingComponent} from '../../../test/helpers/render-component';
import SetupSections from '..';
// eslint-disable-next-line css-modules/no-unused-class
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {wrappingComponent} from '../../../test/helpers/render-component';
import ExternalContentButton from '..';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import ExternalContentViewer from '..';
import podcastFixture from './fixtures/podcast';
import podcastYoutubeFixture from './fixtures/youtube-podcast';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import Filters from '..';

browserEnv();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {set} from 'lodash/fp';
import {wrappingComponent} from '../../../test/helpers/render-component';
import Go1Banner from '..';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {set} from 'lodash/fp';
import {wrappingComponent} from '../../../test/helpers/render-component';
import Hero from '..';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {shallow, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import Popin from '..';
import props from './fixtures/assistance';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import React from 'react';
import {shallow, mount, configure} from 'enzyme';
import {identity} from 'lodash/fp';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import FreeText from '..';
import defaultFixture from './fixtures/default';
import withValueFixture from './fixtures/with-value';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import React from 'react';
import {shallow, configure} from 'enzyme';
import {identity} from 'lodash/fp';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import QCMImage from '..';
import defaultFixture from './fixtures/default';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import React from 'react';
import {shallow, mount, configure} from 'enzyme';
import {identity} from 'lodash/fp';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import Qcm from '..';
import defaultFixture from './fixtures/default';
import noAriaLabelFixture from './fixtures/no-selected';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {configure, shallow} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import Template from '..';
import fixture from './fixtures/default';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import {JWPLAYER_SCRIPT_URL} from '../../../util/constants';
import ResourcePlayer from '..';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import ScopeTabs from '..';
import fixture from './fixtures/without-status';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {shallow, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import SearchForm from '..';

browserEnv();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import browserEnv from 'browser-env';
import flatten from 'lodash/fp/flatten';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import SelectMultiple, {useChoices} from '..';
import defaultFixture from './fixtures/checked';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import SkillCard from '..';
import customSkillFixture from './fixtures/custom-skill';
import noAriaLabelsFixtures from './fixtures/no-aria-labels';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import test from 'ava';
import browserEnv from 'browser-env';
import React from 'react';
import {mount, configure} from 'enzyme';
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
import Adapter from '@cfaester/enzyme-adapter-react-18';
import VideoIframe from '..';

browserEnv();
Expand Down
Loading