|
@@ -23,15 +23,15 @@ export default function HomePage() {
|
|
|
|
|
|
const graphInfo = data?.result?.graph || {};
|
|
|
const pageSetting = {
|
|
|
- backgroundColor: graphInfo.backgroundColor || pageState.backgroundColor,
|
|
|
- width: graphInfo.width || pageState.width,
|
|
|
- height: graphInfo.height || pageState.height,
|
|
|
- grid: graphInfo.grid || pageState.grid,
|
|
|
- gridSize: graphInfo.gridSize || pageState.gridSize,
|
|
|
- jumpOver: graphInfo.jumpover || pageState.jumpOver,
|
|
|
- printLine: graphInfo.printLine || pageState.printLine,
|
|
|
- showWatermark: graphInfo.showWatermark || pageState.showWatermark,
|
|
|
- watermarkText: graphInfo.watermarkText || pageState.watermarkText,
|
|
|
+ backgroundColor: graphInfo.backgroundColor ?? pageState.backgroundColor,
|
|
|
+ width: graphInfo.width ?? pageState.width,
|
|
|
+ height: graphInfo.height ?? pageState.height,
|
|
|
+ grid: graphInfo.grid ?? pageState.grid,
|
|
|
+ gridSize: graphInfo.gridSize ?? pageState.gridSize,
|
|
|
+ jumpOver: graphInfo.jumpover ?? pageState.jumpOver,
|
|
|
+ printLine: graphInfo.printLine ?? pageState.printLine,
|
|
|
+ showWatermark: graphInfo.showWatermark ?? pageState.showWatermark,
|
|
|
+ watermarkText: graphInfo.watermarkText ?? pageState.watermarkText,
|
|
|
};
|
|
|
setPageState(pageSetting);
|
|
|
setProjectInfo(data?.result || {});
|