Skip to content

Commit 89a2c26

Browse files
authored
Revert "bump react version to react 19 (#578)" (#580)
This reverts commit 779152a.
1 parent 779152a commit 89a2c26

File tree

4 files changed

+717
-842
lines changed

4 files changed

+717
-842
lines changed

apps/plotly_examples/package.json

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@
66
"@babel/core": "^7.16.0",
77
"@fluentui/react-charting": "^5.25.0",
88
"@fluentui/react-charts": "0.0.0-nightly-20251024-0406.1",
9-
"@fluentui/react-components": "^9.72.2",
10-
"@fluentui/react-menu": "^9.20.1",
9+
"@fluentui/react-components": "^9.21.0",
1110
"@fluentui/react-portal-compat": "9.0.176",
1211
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.3",
1312
"@svgr/webpack": "^5.5.0",
@@ -46,10 +45,10 @@
4645
"postcss-normalize": "^10.0.1",
4746
"postcss-preset-env": "^7.0.1",
4847
"prompts": "^2.4.2",
49-
"react": "^19.0.0",
48+
"react": "^17.0.2",
5049
"react-app-polyfill": "^3.0.0",
5150
"react-dev-utils": "^12.0.1",
52-
"react-dom": "^19.0.0",
51+
"react-dom": "^17.0.2",
5352
"react-plotly.js": "^2.6.0",
5453
"react-refresh": "^0.11.0",
5554
"resolve": "^1.20.0",
@@ -94,15 +93,15 @@
9493
"devDependencies": {
9594
"@playwright/test": "^1.49.1",
9695
"@types/node": "^22.10.7",
97-
"@types/react": "^19.0.0",
98-
"@types/react-dom": "^19.0.0",
96+
"@types/react": "17.0.44",
97+
"@types/react-dom": "17.0.15",
9998
"parse-svg-path": "^0.1.2"
10099
},
101100
"resolutions": {
102-
"@types/react": "19.0.0",
103-
"@types/react-dom": "19.0.0",
104-
"react": "^19.0.0",
105-
"react-dom": "^19.0.0",
101+
"@types/react": "17.0.44",
102+
"@types/react-dom": "17.0.15",
103+
"react": "^17.0.2",
104+
"react-dom": "^17.0.2",
106105
"@fluentui/chart-utilities": "^1.1.35"
107106
},
108107
"jest": {

apps/plotly_examples/src/components/DeclarativeChart.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,8 @@ const DeclarativeChartBasicExample: React.FC<IDeclarativeChartProps> = () => {
9797
const [isJsonInputEnabled, toggleJsonInput] = React.useState<boolean>(false);
9898
const [jsonInputValue, setJsonInputValue] = React.useState<string>('');
9999

100-
const declarativeChartRef = React.useRef<IDeclarativeChart>(null!);
101-
const declarativeChartV9Ref = React.useRef<IDeclarativeChart>(null!);
100+
const declarativeChartRef = React.useRef<IDeclarativeChart>(null);
101+
const declarativeChartV9Ref = React.useRef<IDeclarativeChart>(null);
102102
let lastKnownValidLegends: string[] | undefined = selectedLegends;
103103

104104
React.useEffect(() => {
@@ -247,7 +247,7 @@ const DeclarativeChartBasicExample: React.FC<IDeclarativeChartProps> = () => {
247247
}
248248
};
249249

250-
const createDeclarativeChart = (): React.JSX.Element => {
250+
const createDeclarativeChart = (): JSX.Element => {
251251
const theme = getSelection("Theme", "Light");
252252
const isRTL = getSelection("RTL", "false") === "true";
253253
const uniqueKey = `${theme}_${isRTL}`;

apps/plotly_examples/src/index.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
import React from 'react';
2-
import { createRoot } from "react-dom/client";
2+
import ReactDOM from 'react-dom';
33
import App from './App';
44

5-
const root = createRoot(document.getElementById('root')!);
6-
root.render(
5+
ReactDOM.render(
76
<React.StrictMode>
87
<App />
9-
</React.StrictMode>
8+
</React.StrictMode>,
9+
document.getElementById('root')
1010
);

0 commit comments

Comments
 (0)