Skip to content

Commit

Permalink
add react 18 as a peerDependency option, upgrade to it in devDependen…
Browse files Browse the repository at this point in the history
…cies and update CSS output in tests
  • Loading branch information
Ben Briggs committed Sep 10, 2022
1 parent fce77c1 commit 06b2043
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 17 deletions.
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
"license": "Apache-2.0",
"peerDependencies": {
"draft-js": ">=0.7.0",
"react": "^15.0.2 || ^16.0.0-rc || ^16.0.0 || ^17.0.0",
"react-dom": "^15.0.2 || ^16.0.0-rc || ^16.0.0 || ^17.0.0"
"react": "^15.0.2 || ^16.0.0-rc || ^16.0.0 || ^17.0.0 || ^18.0.0",
"react-dom": "^15.0.2 || ^16.0.0-rc || ^16.0.0 || ^17.0.0 || ^18.0.0"
},
"dependencies": {
"@babel/runtime": "^7.5.5",
Expand All @@ -63,8 +63,8 @@
"jasmine": "^2.2.0",
"jest": "^24.8.0",
"prettier": "^1.8.2",
"react": "^15.4.2",
"react-dom": "^15.4.2",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"rimraf": "2.5.4",
"webpack": "^4.35.3",
"webpack-nano": "^0.6.2"
Expand Down
2 changes: 1 addition & 1 deletion test/spec/convertFromHTML-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ describe('convertFromHTML', () => {
});

it('converts custom inline styles', () => {
const html = '<p><span style="font-family:Test;">test font</span></p>';
const html = '<p><span style="font-family:Test">test font</span></p>';
const contentState = toContentState(html);
const styles = contentState.getFirstBlock().getInlineStyleAt(0);
expect(styles.size).toBe(1);
Expand Down
2 changes: 1 addition & 1 deletion test/spec/convertToHTML-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -831,7 +831,7 @@ describe('convertToHTML', () => {
},
})(contentState);

expect(html).toBe('<p style="text-align:right;">test</p>');
expect(html).toBe('<p style="text-align:right">test</p>');
});

it('uses JSX for block HTML when passing a middleware function', () => {
Expand Down
28 changes: 17 additions & 11 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2491,7 +2491,7 @@ fb-watchman@^2.0.0:
dependencies:
bser "^2.0.0"

fbjs@^0.8.1, fbjs@^0.8.3, fbjs@^0.8.4:
fbjs@^0.8.3:
version "0.8.9"
resolved "https://registry.yarnpkg.com/fbjs/-/fbjs-0.8.9.tgz#180247fbd347dcc9004517b904f865400a0c8f14"
dependencies:
Expand Down Expand Up @@ -4766,26 +4766,25 @@ rc@^1.2.7:
minimist "^1.2.0"
strip-json-comments "~2.0.1"

react-dom@^15.4.2:
version "15.4.2"
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-15.4.2.tgz#015363f05b0a1fd52ae9efdd3a0060d90695208f"
react-dom@^18.0.0:
version "18.2.0"
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-18.2.0.tgz#22aaf38708db2674ed9ada224ca4aa708d821e3d"
integrity sha512-6IMTriUmvsjHUjNtEDudZfuDQUoWXVxKHhlEGSk81n4YFS+r/Kl99wXiwlVXtPBtJenozv2P+hxDsw9eA7Xo6g==
dependencies:
fbjs "^0.8.1"
loose-envify "^1.1.0"
object-assign "^4.1.0"
scheduler "^0.23.0"

react-is@^16.8.4:
version "16.8.6"
resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.8.6.tgz#5bbc1e2d29141c9fbdfed456343fe2bc430a6a16"
integrity sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA==

react@^15.4.2:
version "15.4.2"
resolved "https://registry.yarnpkg.com/react/-/react-15.4.2.tgz#41f7991b26185392ba9bae96c8889e7e018397ef"
react@^18.0.0:
version "18.2.0"
resolved "https://registry.yarnpkg.com/react/-/react-18.2.0.tgz#555bd98592883255fa00de14f1151a917b5d77d5"
integrity sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==
dependencies:
fbjs "^0.8.4"
loose-envify "^1.1.0"
object-assign "^4.1.0"

read-pkg-up@^4.0.0:
version "4.0.0"
Expand Down Expand Up @@ -5121,6 +5120,13 @@ sax@^1.2.4:
resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9"
integrity sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==

scheduler@^0.23.0:
version "0.23.0"
resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.23.0.tgz#ba8041afc3d30eb206a487b6b384002e4e61fdfe"
integrity sha512-CtuThmgHNg7zIZWAXi3AsyIzA3n4xx7aNyjwC2VJldO2LMVDhFK+63xGqq6CsJH4rTAt6/M+N4GhZiDYPx9eUw==
dependencies:
loose-envify "^1.1.0"

schema-utils@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-1.0.0.tgz#0b79a93204d7b600d4b2850d1f66c2a34951c770"
Expand Down

0 comments on commit 06b2043

Please sign in to comment.