Skip to content

Commit

Permalink
update: use set value after backspace - how a human would actually do
Browse files Browse the repository at this point in the history
  • Loading branch information
VsevolodX committed Nov 7, 2023
1 parent 2afd422 commit 8870f5f
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions tests/cucumber/support/widgets/dialogs/surface_dialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@ export class SurfaceDialogWidget extends Widget {
}

generateSurface({ h, k, l, thickness, vacuumRatio, vx, vy }) {
if (h) exabrowser.setValue(this.selectors.h, h);
if (k) exabrowser.setValue(this.selectors.k, k);
if (l) exabrowser.setValue(this.selectors.l, l);
if (thickness) exabrowser.setValue(this.selectors.thickness, thickness);
if (vacuumRatio) exabrowser.setValue(this.selectors.vacuumRatio, vacuumRatio);
if (vx) exabrowser.setValue(this.selectors.vx, vx);
if (vy) exabrowser.setValue(this.selectors.vy, vy);
if (h) exabrowser.setValueWithBackspaceClear(this.selectors.h, h);
if (k) exabrowser.setValueWithBackspaceClear(this.selectors.k, k);
if (l) exabrowser.setValueWithBackspaceClear(this.selectors.l, l);
if (thickness) exabrowser.setValueWithBackspaceClear(this.selectors.thickness, thickness);
if (vacuumRatio)
exabrowser.setValueWithBackspaceClear(this.selectors.vacuumRatio, vacuumRatio);
if (vx) exabrowser.setValueWithBackspaceClear(this.selectors.vx, vx);
if (vy) exabrowser.setValueWithBackspaceClear(this.selectors.vy, vy);
}

submit() {
Expand Down

0 comments on commit 8870f5f

Please sign in to comment.