Skip to content

Commit 6758f77

Browse files
committed
typos: fixing typos and cases erros
1 parent 61971e5 commit 6758f77

19 files changed

Lines changed: 107 additions & 101 deletions

File tree

assets/blocksConfig/uPlotSection.json

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,29 @@
55
"type": "scatter",
66
"opt": {
77
"pxAlign": false,
8+
"cursor": {
9+
"drag": {
10+
"x":true,
11+
"y":true,
12+
"uni": 50
13+
}
14+
},
815
"scales": {
916
"x": {
1017
"time": false,
11-
"auto": true
18+
"auto": true,
19+
"range": [0,10]
1220
},
1321
"y": {
14-
"auto": true
22+
"auto": true,
23+
"range": [0,10]
1524
}
1625
},
17-
"axes": [{
26+
"axis": [{
1827
"space": 30
1928
},{
2029
"space":30
2130
}],
22-
"cursor": {
23-
"show": true
24-
},
2531
"series": [{}, {}]
2632
}
2733
}

src/components/blockContainer/blockContainer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ module.exports = class BlockContainer {
133133

134134
}
135135

136-
uptadeBlockGeneralConfig(newConfig) {
136+
updateBlockGeneralConfig(newConfig) {
137137

138138
this.eventHandler.dispatchEvent('DashboardNotSaved');
139139

src/components/blocks/Blocks/uPlot/plugins/zoom-wheel.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ module.exports = function wheelZoomPlugin(opts) {
4747

4848
let xUnitsPerPx = u.posToVal(1, 'x') - u.posToVal(0, 'x');
4949

50-
function onmove(e) {
50+
function onMove(e) {
5151
e.preventDefault();
5252

5353
let left1 = e.clientX;
@@ -60,13 +60,13 @@ module.exports = function wheelZoomPlugin(opts) {
6060
});
6161
}
6262

63-
function onup(e) {
64-
document.removeEventListener("mousemove", onmove);
65-
document.removeEventListener("mouseup", onup);
63+
function onUp(e) {
64+
document.removeEventListener("mousemove", onMove);
65+
document.removeEventListener("mouseup", onUp);
6666
}
6767

68-
document.addEventListener("mousemove", onmove);
69-
document.addEventListener("mouseup", onup);
68+
document.addEventListener("mousemove", onMove);
69+
document.addEventListener("mouseup", onUp);
7070
}
7171
});
7272

src/components/blocks/Blocks/uPlot/scatter.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,15 @@ module.exports = class Scatter extends Block {
3030
get formConfig() {
3131

3232
const response = {
33-
axes: {
33+
axis: {
3434
x: {
3535
dir: this.opt.scales.x.dir,
3636
inputName: this.opt.series[0].label,
37-
side: this.opt.axes[0].side,
37+
side: this.opt.axis[0].side,
3838
},
3939
y: {
4040
dir: this.opt.scales.y.dir,
41-
side: this.opt.axes[1].side,
41+
side: this.opt.axis[1].side,
4242
type: this.opt.scales.y.distr
4343
}
4444
}
@@ -99,7 +99,7 @@ module.exports = class Scatter extends Block {
9999
this.opt.series[0].label = newConfig.inputName;
100100

101101
this.opt.scales.x.dir = Number(newConfig.dir);
102-
this.opt.axes[0].side = Number(newConfig.side);
102+
this.opt.axis[0].side = Number(newConfig.side);
103103
this.redraw();
104104
}
105105

@@ -109,7 +109,7 @@ module.exports = class Scatter extends Block {
109109

110110
this.opt.scales.y.dir = newConfig.dir;
111111

112-
this.opt.axes[1].side = Number(newConfig.side);
112+
this.opt.axis[1].side = Number(newConfig.side);
113113

114114
this.redraw();
115115

@@ -138,9 +138,9 @@ module.exports = class Scatter extends Block {
138138
});
139139
}
140140

141-
removeSerie(rmvdSerie) {
141+
removeSerie(removedSerie) {
142142

143-
let currSerie = this.opt.series.find(serie => serie.uuid === rmvdSerie.uuid);
143+
let currSerie = this.opt.series.find(serie => serie.uuid === removedSerie.uuid);
144144
let index = this.opt.series.indexOf(currSerie);
145145

146146
if (index >= 0) {

src/components/components.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@ const fs = require('fs');
22

33
module.exports = class Components {
44

5-
static spliter(id, text, content, startOpen) {
5+
static splitter(id, text, content, startOpen) {
66

77
const card = document.createElement('div');
8-
card.className = 'card menuSpliter';
8+
card.className = 'card menuSplitter';
99

1010
const cardHeader = document.createElement('div');
1111

@@ -27,11 +27,11 @@ module.exports = class Components {
2727
if (startOpen) {
2828

2929
cardBodyCollapse.className = 'collapse show';
30-
cardHeader.className = 'card-header menuSpliter-header';
30+
cardHeader.className = 'card-header menuSplitter-header';
3131

3232
} else {
3333

34-
cardHeader.className = 'card-header menuSpliter-header collapsed';
34+
cardHeader.className = 'card-header menuSplitter-header collapsed';
3535
cardBodyCollapse.className = 'collapse';
3636

3737
}

src/components/formBuilder/Field.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,8 @@ module.exports = class Field {
105105
cont++;
106106

107107
}
108-
const splited = attributesUntilHere.split('.');
109-
const sliced = splited.slice(0, splited.length - cont);
108+
const splitted = attributesUntilHere.split('.');
109+
const sliced = splitted.slice(0, splitted.length - cont);
110110

111111
this.att.split('.').forEach((att) => {
112112

src/components/formBuilder/formBuilder.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,8 @@ class FormPattern {
7373
}
7474
if (attributesUntilHere !== undefined) {
7575

76-
const splited = attributesUntilHere.split('.');
77-
const sliced = splited.slice(0, splited.length - cont);
76+
const splitted = attributesUntilHere.split('.');
77+
const sliced = splitted.slice(0, splitted.length - cont);
7878
sliced.push(this.att);
7979
this.att = sliced.join('.');
8080

@@ -335,14 +335,14 @@ class Container extends FormPattern {
335335
return container;
336336

337337
}
338-
static spliter(config, containerConfig) {
338+
static splitter(config, containerConfig) {
339339

340340
containerConfig = containerConfig || {};
341341
const container = new Container(config, containerConfig);
342342

343343
const card = document.createElement('div');
344344

345-
card.className = 'card menuSpliter';
345+
card.className = 'card menuSplitter';
346346

347347
const cardHeader = document.createElement('div');
348348

@@ -367,11 +367,11 @@ class Container extends FormPattern {
367367
if (containerConfig.startOpen) {
368368

369369
cardBodyCollapse.className = 'collapse show';
370-
cardHeader.className = 'card-header menuSpliter-header';
370+
cardHeader.className = 'card-header menuSplitter-header';
371371

372372
} else {
373373

374-
cardHeader.className = 'card-header menuSpliter-header collapsed';
374+
cardHeader.className = 'card-header menuSplitter-header collapsed';
375375
cardBodyCollapse.className = 'collapse';
376376

377377
}

src/components/sideMenu/menus/EditMenu/EditMenu.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ module.exports = class EditMenu extends Menu {
2424

2525
}
2626

27-
this.generalContainer = Container.spliter({
27+
this.generalContainer = Container.splitter({
2828
title: Field.text({
2929
label: 'Título',
3030
att: 'blockTitle',
@@ -119,7 +119,7 @@ module.exports = class EditMenu extends Menu {
119119
};
120120

121121
this.generalContainer.htmlComponent.oninput = () => {
122-
this.currentBlock.uptadeBlockGeneralConfig(this.form.getData());
122+
this.currentBlock.updateBlockGeneralConfig(this.form.getData());
123123

124124
};
125125

src/components/sideMenu/menus/EditMenu/menus/GPS/GPS.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ module.exports = class MapEditMenu {
99
this.eventHandler = new EventHandler();
1010

1111
this.form = Container.div({
12-
GPSconfig: Container.spliter({
12+
GPSconfig: Container.splitter({
1313
longitude: Field.select({
1414
att: 'longitude',
1515
label: "Longitude",

src/components/sideMenu/menus/EditMenu/menus/uPlot/types/scatter.js

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ module.exports = class uPlotScatter {
1010

1111
this.eventHandler = new EventHandler();
1212

13-
this.seriesSection = Container.spliter({
13+
this.seriesSection = Container.splitter({
1414
newSerie: Container.div({
1515
newSerieSelector: Field.select({
1616
label: 'Nova série',
@@ -32,7 +32,7 @@ module.exports = class uPlotScatter {
3232

3333
this.form = Container.div({
3434
uPlotSeriesStyle: this.seriesSection,
35-
uPlotXAxesStyle: Container.spliter({
35+
uPlotXAxisStyle: Container.splitter({
3636
xAxis: Field.select({
3737
att: 'inputName',
3838
label: "Eixo X",
@@ -45,7 +45,7 @@ module.exports = class uPlotScatter {
4545
],
4646
}),
4747
scaleOpts: Container.formRow({
48-
xAxesDirection: Field.select(
48+
xAxisDirection: Field.select(
4949
{
5050
label: 'Direção',
5151
att: 'dir',
@@ -62,7 +62,7 @@ module.exports = class uPlotScatter {
6262
],
6363
},
6464
),
65-
xAxesPos: Field.select(
65+
xAxisPos: Field.select(
6666
{
6767
label: 'Posição',
6868
att: 'side',
@@ -85,8 +85,8 @@ module.exports = class uPlotScatter {
8585
text: 'Eixo X',
8686
id: 'uPlotXAxeStyle',
8787
}),
88-
uPlotYAxesStyle: Container.spliter({
89-
yAxesScale: Field.select({
88+
uPlotYAxisStyle: Container.splitter({
89+
yAxisScale: Field.select({
9090
label: 'Escala',
9191
att: 'type',
9292
options: [
@@ -95,13 +95,13 @@ module.exports = class uPlotScatter {
9595
value: 1,
9696
},
9797
{
98-
text: 'Logaritimica',
98+
text: 'Logarítmica',
9999
value: 3,
100100
},
101101
],
102102
}),
103103
scaleOpts: Container.formRow({
104-
yAxesDirection: Field.select(
104+
yAxisDirection: Field.select(
105105
{
106106
label: 'Tamanho',
107107
att: 'dir',
@@ -118,7 +118,7 @@ module.exports = class uPlotScatter {
118118
],
119119
},
120120
),
121-
yAxesPos: Field.select(
121+
yAxisPos: Field.select(
122122
{
123123
label: 'Posição',
124124
att: 'side',
@@ -169,7 +169,7 @@ module.exports = class uPlotScatter {
169169

170170
window.CurrentBlock.sendBlockInstruction({
171171
command: 'editXAxis',
172-
data: this.form.formTree.uPlotXAxesStyle.self.getData().blockConfig.uPlot.scatter.axis.x
172+
data: this.form.formTree.uPlotXAxisStyle.self.getData().blockConfig.uPlot.scatter.axis.x
173173
});
174174

175175
}
@@ -178,12 +178,12 @@ module.exports = class uPlotScatter {
178178

179179
window.CurrentBlock.sendBlockInstruction({
180180
command: 'editYAxis',
181-
data: this.form.formTree.uPlotYAxesStyle.self.getData().blockConfig.uPlot.scatter.axis.y
181+
data: this.form.formTree.uPlotYAxisStyle.self.getData().blockConfig.uPlot.scatter.axis.y
182182
});
183183

184184
}
185185

186-
attXandYInputList() {
186+
attXAndYInputList() {
187187

188188
const callBack = (input) => {
189189

@@ -196,7 +196,7 @@ module.exports = class uPlotScatter {
196196
allInputs = allInputs.concat(window.CurrentInputGroup.rawInputs);
197197
allInputs = allInputs.concat(window.CurrentInputGroup.inputs);
198198

199-
this.form.formTree.uPlotXAxesStyle.xAxis.setOptions(allInputs, callBack);
199+
this.form.formTree.uPlotXAxisStyle.xAxis.setOptions(allInputs, callBack);
200200

201201
this.seriesSection.formTree.newSerie.newSerieSelector.setOptions(allInputs, callBack);
202202
}
@@ -314,7 +314,7 @@ module.exports = class uPlotScatter {
314314

315315
this.eventHandler.addEventListener('AttInputList', () => {
316316

317-
this.attXandYInputList();
317+
this.attXAndYInputList();
318318

319319
});
320320

@@ -340,17 +340,17 @@ module.exports = class uPlotScatter {
340340

341341
};
342342

343-
this.form.formTree.uPlotXAxesStyle.self.htmlComponent.addEventListener('input', (evt) => {
343+
this.form.formTree.uPlotXAxisStyle.self.htmlComponent.addEventListener('input', (evt) => {
344344

345345
this.editXAxis();
346346
evt.stopPropagation();
347347

348348
});
349349

350-
this.form.formTree.uPlotYAxesStyle.self.htmlComponent.addEventListener('input', (evt) => {
350+
this.form.formTree.uPlotYAxisStyle.self.htmlComponent.addEventListener('input', (evt) => {
351351

352352
this.editYAxis();
353-
evt.stopPropagation();
353+
//evt.stopPropagation();
354354

355355
});
356356

0 commit comments

Comments
 (0)