summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSunil Shetye2025-06-04 12:03:47 +0530
committerSunil Shetye2025-06-04 12:03:47 +0530
commit5ea32eec15286c341bf1cb7f872b44d7d7bbc0fe (patch)
treeb1909b596bc997afab268bf552d68bcc8121370d
parent1c8e493de8c3c4517ebf968df1b79216910090f7 (diff)
downloadCommon-Interface-Project-5ea32eec15286c341bf1cb7f872b44d7d7bbc0fe.tar.gz
Common-Interface-Project-5ea32eec15286c341bf1cb7f872b44d7d7bbc0fe.tar.bz2
Common-Interface-Project-5ea32eec15286c341bf1cb7f872b44d7d7bbc0fe.zip
fix quotes
-rw-r--r--blocks/eda-frontend/src/components/Dashboard/SchematicsList.js2
-rw-r--r--blocks/eda-frontend/src/components/SchematicEditor/SchematicToolbar.js10
-rw-r--r--blocks/eda-frontend/src/components/Shared/Navbar.js2
-rw-r--r--blocks/eda-frontend/src/utils/Sigbuilder-graph.js94
-rw-r--r--blocks/eda-frontend/src/utils/dependencies.js24
5 files changed, 66 insertions, 66 deletions
diff --git a/blocks/eda-frontend/src/components/Dashboard/SchematicsList.js b/blocks/eda-frontend/src/components/Dashboard/SchematicsList.js
index f68b8c4c..9f488502 100644
--- a/blocks/eda-frontend/src/components/Dashboard/SchematicsList.js
+++ b/blocks/eda-frontend/src/components/Dashboard/SchematicsList.js
@@ -65,7 +65,7 @@ export default function SchematicsList () {
dispatch(fetchSchematics())
}, [])
- const typography1 = "You don't have any saved " + process.env.REACT_APP_SMALL_DIAGRAMS_NAME + '...'
+ const typography1 = 'You don\'t have any saved ' + process.env.REACT_APP_SMALL_DIAGRAMS_NAME + '...'
return (
<>
<Grid
diff --git a/blocks/eda-frontend/src/components/SchematicEditor/SchematicToolbar.js b/blocks/eda-frontend/src/components/SchematicEditor/SchematicToolbar.js
index b4e7db1e..6b739d1c 100644
--- a/blocks/eda-frontend/src/components/SchematicEditor/SchematicToolbar.js
+++ b/blocks/eda-frontend/src/components/SchematicEditor/SchematicToolbar.js
@@ -500,7 +500,7 @@ export default function SchematicToolbar ({ mobileClose, gridRef }) {
item === 'pipe'
? (
<span key={index} style={{ margin: '0 8px', fontWeight: 'bold', opacity: 0.7, fontSize: '18px' }}>|</span>
- )
+ )
: (
<Tooltip key={index} title={item.label}>
{item.link
@@ -508,14 +508,14 @@ export default function SchematicToolbar ({ mobileClose, gridRef }) {
<IconButton color='inherit' className={classes.tools} size='small' component={RouterLink} to={item.link}>
{item.icon}
</IconButton>
- )
+ )
: (
<IconButton color='inherit' className={classes.tools} size='small' onClick={item.action}>
{item.icon}
</IconButton>
- )}
+ )}
</Tooltip>
- )
+ )
)}
{/* ✅ Mobile: Show only hamburger menu */}
@@ -548,7 +548,7 @@ export default function SchematicToolbar ({ mobileClose, gridRef }) {
<ListItemIcon>{item.icon}</ListItemIcon>
<ListItemText primary={item.label} />
</ListItem>
- )
+ )
)}
<Divider />
<ListItem button onClick={toggleDrawer(false)}>
diff --git a/blocks/eda-frontend/src/components/Shared/Navbar.js b/blocks/eda-frontend/src/components/Shared/Navbar.js
index 3b75f5cf..faf0fd23 100644
--- a/blocks/eda-frontend/src/components/Shared/Navbar.js
+++ b/blocks/eda-frontend/src/components/Shared/Navbar.js
@@ -142,7 +142,7 @@ export function Header () {
Gallery
</Link>
</>
- )
+ )
)
}
</nav>
diff --git a/blocks/eda-frontend/src/utils/Sigbuilder-graph.js b/blocks/eda-frontend/src/utils/Sigbuilder-graph.js
index 91c2e2e6..8f3c81dd 100644
--- a/blocks/eda-frontend/src/utils/Sigbuilder-graph.js
+++ b/blocks/eda-frontend/src/utils/Sigbuilder-graph.js
@@ -6,10 +6,10 @@ const {
mxEvent
} = new mxGraphFactory()
-export const graphSigbuilder = ""
-export let sigbuilderGraph = ""
+export const graphSigbuilder = ''
+export let sigbuilderGraph = ''
-let wind = ""
+let wind = ''
// Function to create a chart with responsive points for Sigbuilder
function createDraggablePointsChartSigbuilder (graphParameters, pointsHistory, xmin, xmax, ymin, ymax, chartType, points, method, xmaxtitle, step, stepname) {
@@ -33,7 +33,7 @@ function createDraggablePointsChartSigbuilder (graphParameters, pointsHistory, x
enabled: false
},
title: {
- text: ""
+ text: ''
},
subtitle: {
text: subtitle
@@ -116,11 +116,11 @@ function createDraggablePointsChartSigbuilder (graphParameters, pointsHistory, x
}
export function updateSubtitleForSigbuilderGraph (points, method, xmaxtitle, periodicFlag) {
- let subTitle = ""
- if (periodicFlag === "y") {
- subTitle = "<b>" + points + " points, Method: " + getmethod(method) + ", periodic, T = " + xmaxtitle + "</b>"
+ let subTitle = ''
+ if (periodicFlag === 'y') {
+ subTitle = '<b>' + points + ' points, Method: ' + getmethod(method) + ', periodic, T = ' + xmaxtitle + '</b>'
} else {
- subTitle = "<b>" + points + " points, Method: " + getmethod(method) + ", aperiodic</b>"
+ subTitle = '<b>' + points + ' points, Method: ' + getmethod(method) + ', aperiodic</b>'
}
return subTitle
}
@@ -145,22 +145,22 @@ function autoscaleFunctionalityForGraph (graphParameters, pointsHistory) {
}
export function editPointsValue (graphObject, graphParameters, pointsHistory) {
- document.getElementById("messageLabel").innerHTML = ""
+ document.getElementById('messageLabel').innerHTML = ''
// Making graph window inaccessible
- const graphWind = document.getElementById("graphcontentwind")
- graphWind.style.pointerEvents = "none"
+ const graphWind = document.getElementById('graphcontentwind')
+ graphWind.style.pointerEvents = 'none'
// Create basic structure for the form
const content = document.createElement('div')
- content.setAttribute("id", "editCoordinates")
+ content.setAttribute('id', 'editCoordinates')
// Add Form
- const myform = document.createElement("form")
- myform.method = "post"
- myform.id = "formEditCoordinate"
- myform.style.padding = "10px"
+ const myform = document.createElement('form')
+ myform.method = 'post'
+ myform.id = 'formEditCoordinate'
+ myform.style.padding = '10px'
const titlelabel = document.createElement('span')
- titlelabel.innerHTML = "Enter new x and y"
+ titlelabel.innerHTML = 'Enter new x and y'
myform.appendChild(titlelabel)
// Line break
const linebreak = document.createElement('br')
@@ -173,21 +173,21 @@ export function editPointsValue (graphObject, graphParameters, pointsHistory) {
// Input Title
const namelabel = document.createElement('label')
namelabel.innerHTML = keys[i].toString()
- namelabel.style.marginLeft = "30px"
+ namelabel.style.marginLeft = '30px'
myform.appendChild(namelabel)
let value = 0
- if (((graphObject.point.options[keys[i]]).toString()).includes(".")) {
+ if (((graphObject.point.options[keys[i]]).toString()).includes('.')) {
value = (graphObject.point.options[keys[i]]).toFixed(6)
} else {
value = (graphObject.point.options[keys[i]])
}
// Input
- const input = document.createElement("input")
- input.name = "edit_" + keys[i]
+ const input = document.createElement('input')
+ input.name = 'edit_' + keys[i]
input.value = value
- input.setAttribute("id", "edit_" + keys[i])
- input.setAttribute("class", "fieldInput")
+ input.setAttribute('id', 'edit_' + keys[i])
+ input.setAttribute('class', 'fieldInput')
myform.appendChild(input)
myform.appendChild(linebreak)
@@ -197,41 +197,41 @@ export function editPointsValue (graphObject, graphParameters, pointsHistory) {
myform.appendChild(linebreak)
// Button - Cancel
- const cancelBtn = document.createElement("button")
- cancelBtn.style.cssFloat = "right"
+ const cancelBtn = document.createElement('button')
+ cancelBtn.style.cssFloat = 'right'
cancelBtn.innerHTML = 'Cancel'
- cancelBtn.type = "button"
- cancelBtn.name = "Cancel"
+ cancelBtn.type = 'button'
+ cancelBtn.name = 'Cancel'
myform.appendChild(cancelBtn)
// Button - OK
- const okBtn = document.createElement("button")
- okBtn.style.cssFloat = "right"
- okBtn.style.marginRight = "20px"
+ const okBtn = document.createElement('button')
+ okBtn.style.cssFloat = 'right'
+ okBtn.style.marginRight = '20px'
okBtn.innerHTML = 'OK'
- okBtn.type = "button"
- okBtn.name = "OK"
+ okBtn.type = 'button'
+ okBtn.name = 'OK'
myform.appendChild(okBtn)
content.appendChild(myform)
const height = 150
wind = showModalWindow(graphSigbuilder, 'Scilab Multiple Values Request', content, 200, height)
wind.addListener(mxEvent.DESTROY, function () {
- graphWind.style.pointerEvents = "auto"
+ graphWind.style.pointerEvents = 'auto'
})
// Executes when button 'cancelBtn' is clicked
cancelBtn.onclick = function () {
- document.getElementById("messageLabel").innerHTML = ""
- graphWind.style.pointerEvents = "auto"
+ document.getElementById('messageLabel').innerHTML = ''
+ graphWind.style.pointerEvents = 'auto'
wind.destroy()
}
// Executes when button 'okBtn' is clicked
okBtn.onclick = function () {
- let xValue = parseFloat(document.getElementById("edit_x").value)
+ let xValue = parseFloat(document.getElementById('edit_x').value)
if (xValue < 0) {
xValue = 0
}
- const yValue = parseFloat(document.getElementById("edit_y").value)
+ const yValue = parseFloat(document.getElementById('edit_y').value)
const points = graphParameters.graphPoints
const xArry = []
for (let i = 0; i < points.length; i++) {
@@ -244,22 +244,22 @@ export function editPointsValue (graphObject, graphParameters, pointsHistory) {
removePointsFromChart(graphObject, graphParameters, pointsHistory)
addPointsOnChart(graphParameters, pointsHistory, xValue, yValue)
autoscaleFunctionalityForGraph(graphParameters, pointsHistory)
- document.getElementById("messageLabel").innerHTML = ""
- graphWind.style.pointerEvents = "auto"
+ document.getElementById('messageLabel').innerHTML = ''
+ graphWind.style.pointerEvents = 'auto'
wind.destroy()
} else {
if (mtdCheck) {
removePointsFromChart(graphObject, graphParameters, pointsHistory)
addPointsOnChart(graphParameters, pointsHistory, xValue, yValue)
autoscaleFunctionalityForGraph(graphParameters, pointsHistory)
- document.getElementById("messageLabel").innerHTML = ""
- graphWind.style.pointerEvents = "auto"
+ document.getElementById('messageLabel').innerHTML = ''
+ graphWind.style.pointerEvents = 'auto'
wind.destroy()
} else {
- document.getElementById("messageLabel").innerHTML = "ERROR IN SPLINE : " + getmethod(graphParameters.mtd)
+ document.getElementById('messageLabel').innerHTML = 'ERROR IN SPLINE : ' + getmethod(graphParameters.mtd)
wind.destroy()
- graphWind.style.pointerEvents = "auto"
- throw new Error("incorrect")
+ graphWind.style.pointerEvents = 'auto'
+ throw new Error('incorrect')
}
}
}
@@ -275,7 +275,7 @@ export function removePointsFromChart (graphObject, graphParameters, pointsHisto
}
export function addPointsOnChart (graphParameters, pointsHistory, xValue, yValue) {
- document.getElementById("messageLabel").innerHTML = ""
+ document.getElementById('messageLabel').innerHTML = ''
if (xValue === 0 && yValue === 0) {
graphParameters.flag_for_zeros = true
}
@@ -301,8 +301,8 @@ export function addPointsOnChart (graphParameters, pointsHistory, xValue, yValue
graphParameters.xmaxTitle = sigbuilderGraph.xAxis[0].getExtremes().dataMax.toFixed(6)
sigbuilderGraph.setTitle(null, { text: updateSubtitleForSigbuilderGraph(graphParameters.points, graphParameters.mtd, graphParameters.xmaxTitle, graphParameters.PeriodicOption) })
} else {
- document.getElementById("messageLabel").innerHTML = "ERROR IN SPLINE : " + getmethod(graphParameters.mtd)
- throw new Error("incorrect")
+ document.getElementById('messageLabel').innerHTML = 'ERROR IN SPLINE : ' + getmethod(graphParameters.mtd)
+ throw new Error('incorrect')
}
}
}
diff --git a/blocks/eda-frontend/src/utils/dependencies.js b/blocks/eda-frontend/src/utils/dependencies.js
index aae50e6f..cda942c3 100644
--- a/blocks/eda-frontend/src/utils/dependencies.js
+++ b/blocks/eda-frontend/src/utils/dependencies.js
@@ -54,9 +54,9 @@ export function updateDetails (graph, cell, details, detailsInstance, styleName,
const fullStyleName = styleName
if (styleName != null) {
const idx = styleName.indexOf(';')
- if (styleName.startsWith("SELF_SWITCH")) {
+ if (styleName.startsWith('SELF_SWITCH')) {
const stateOpen = detailsInstance.stateOpen
- styleName = stateOpen ? "SELF_SWITCH_OFF" : "SELF_SWITCH_ON"
+ styleName = stateOpen ? 'SELF_SWITCH_OFF' : 'SELF_SWITCH_ON'
} else {
if (idx !== -1) {
styleName = styleName.substring(0, idx)
@@ -137,17 +137,17 @@ export function objToArrayList (graphPoints) {
// For Sigbuilder block
export function getmethod (mtd) {
- let METHOD = ""
+ let METHOD = ''
switch (mtd) {
- case 0: METHOD = "zero order"; break
- case 1: METHOD = "linear"; break
- case 2: METHOD = "order 2"; break
- case 3: METHOD = "not_a_knot"; break
- case 4: METHOD = "periodic"; break
- case 5: METHOD = "monotone"; break
- case 6: METHOD = "fast"; break
- case 7: METHOD = "clamped"; break
- default: METHOD = "zero order"; break
+ case 0: METHOD = 'zero order'; break
+ case 1: METHOD = 'linear'; break
+ case 2: METHOD = 'order 2'; break
+ case 3: METHOD = 'not_a_knot'; break
+ case 4: METHOD = 'periodic'; break
+ case 5: METHOD = 'monotone'; break
+ case 6: METHOD = 'fast'; break
+ case 7: METHOD = 'clamped'; break
+ default: METHOD = 'zero order'; break
}
return METHOD
}