summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheThinker2772022-06-17 12:55:34 +0530
committerTheThinker2772022-06-17 13:58:08 +0530
commit12d5105a5dca731bdc9eac1e9332b6bb8889a390 (patch)
treeb8cb4d33eaa27744195394d1dd0dfe319179d539
parentd90dab3268b8c38359de58f20b78ed720439bb74 (diff)
downloadCommon-Interface-Project-12d5105a5dca731bdc9eac1e9332b6bb8889a390.tar.gz
Common-Interface-Project-12d5105a5dca731bdc9eac1e9332b6bb8889a390.tar.bz2
Common-Interface-Project-12d5105a5dca731bdc9eac1e9332b6bb8889a390.zip
Canvas Display Fix
-rw-r--r--blocks/eda-frontend/src/components/SchematicEditor/Helper/SchematicEditor.css2
-rw-r--r--blocks/eda-frontend/src/components/SchematicEditor/SideComp.js3
-rw-r--r--blocks/eda-frontend/src/components/SchematicEditor/SimulationScreen.js26
3 files changed, 8 insertions, 23 deletions
diff --git a/blocks/eda-frontend/src/components/SchematicEditor/Helper/SchematicEditor.css b/blocks/eda-frontend/src/components/SchematicEditor/Helper/SchematicEditor.css
index fa8e252b..fa54f0f2 100644
--- a/blocks/eda-frontend/src/components/SchematicEditor/Helper/SchematicEditor.css
+++ b/blocks/eda-frontend/src/components/SchematicEditor/Helper/SchematicEditor.css
@@ -19,7 +19,7 @@
.grid-container {
position: relative;
overflow: hidden;
- margin: 100px;
+ margin: 0px;
-webkit-box-shadow: -8px -2px 24px 9px rgba(208, 218, 225, 1);
-moz-box-shadow: -8px -2px 24px 9px rgba(208, 218, 225, 1);
box-shadow: -8px -2px 24px 9px rgba(208, 218, 225, 1);
diff --git a/blocks/eda-frontend/src/components/SchematicEditor/SideComp.js b/blocks/eda-frontend/src/components/SchematicEditor/SideComp.js
index f5ddffb4..4d9677e0 100644
--- a/blocks/eda-frontend/src/components/SchematicEditor/SideComp.js
+++ b/blocks/eda-frontend/src/components/SchematicEditor/SideComp.js
@@ -11,7 +11,8 @@ const useStyles = makeStyles((theme) => ({
margin: theme.spacing(1.5),
padding: theme.spacing(1.5),
border: '1px solid blue',
- borderRadius: '5px'
+ borderRadius: '5px',
+ position: 'absolute'
}
}))
diff --git a/blocks/eda-frontend/src/components/SchematicEditor/SimulationScreen.js b/blocks/eda-frontend/src/components/SchematicEditor/SimulationScreen.js
index 3c4ac261..23132d73 100644
--- a/blocks/eda-frontend/src/components/SchematicEditor/SimulationScreen.js
+++ b/blocks/eda-frontend/src/components/SchematicEditor/SimulationScreen.js
@@ -58,12 +58,11 @@ export default function SimulationScreen ({ open, close }) {
const stitle = useSelector(state => state.netlistReducer.title)
const taskId = useSelector(state => state.simulationReducer.taskId)
const [isResult, setIsResult] = useState(false)
- const [logs, setlog] = useState(false)
const graphsRef = useRef([])
const datapointsRef = useRef([])
const timeoutRef = useRef(null)
const [noOfGraphs, setNoOfGraphs] = useState(0)
- const [error, seterror] = useState(0)
+ const [error, setError] = useState('')
const chartIdCount = useRef(0)
const chartIdList = useRef({})
@@ -85,8 +84,6 @@ export default function SimulationScreen ({ open, close }) {
if (loglines > 0) {
console.log(loglines, 'log lines')
loglines = 0
- } else if (loglines === 0) {
- setlog(true)
}
}
@@ -573,7 +570,7 @@ export default function SimulationScreen ({ open, close }) {
sse.addEventListener('ERROR', e => {
printloglines()
console.log('ERROR', e)
- seterror(1)
+ setError('Error in simulation: ' + e.data)
sse.close()
}, false)
sse.addEventListener('MESSAGE', e => {
@@ -675,8 +672,7 @@ export default function SimulationScreen ({ open, close }) {
}
const typography1 = 'SOMETHING WENT WRONG. Please Check The Simulation Parameters.'
- const typography2 = 'PLease Wait The Graph is Rendering with' + process.env.REACT_APP_DIAGRAM_NAME + '.'
- const typography3 = 'NO LOG LINES FOUND'
+ const typography2 = 'Please Wait. The Graph is Rendering with ' + process.env.REACT_APP_DIAGRAM_NAME + '.'
return (
<div>
<Dialog
@@ -753,23 +749,11 @@ export default function SimulationScreen ({ open, close }) {
}
{/* Diplay of Simulation parameter Not present */}
{
- (error === 1)
+ (error !== '')
? <Grid item xs={12} sm={12}>
<Paper className={classes.paper}>
<Typography variant='h4' align='center' gutterBottom>
- {typography1}
- </Typography>
- </Paper>
- </Grid>
- : <span />
- }
- {/* Diplay of No log lines Present */}
- {
- (logs === true)
- ? <Grid item xs={12} sm={12}>
- <Paper className={classes.paper}>
- <Typography variant='h4' align='center' gutterBottom>
- {typography3}
+ {error}
</Typography>
</Paper>
</Grid>