Refactor and IE compatibility
Browse files- .eslintrc.json +1 -0
- package.json +1 -1
- server.js +1 -1
- src/core/element.js +3 -3
- src/index.js +4 -4
- webpack.config.dev.js → webpack.config.demo.js +0 -0
.eslintrc.json
CHANGED
@@ -9,6 +9,7 @@
|
|
9 |
"no-plusplus": "off",
|
10 |
"no-cond-assign": "off",
|
11 |
"func-names": "off",
|
|
|
12 |
"no-bitwise": "off",
|
13 |
"class-methods-use-this": "off",
|
14 |
"prefer-destructuring": "off",
|
|
|
9 |
"no-plusplus": "off",
|
10 |
"no-cond-assign": "off",
|
11 |
"func-names": "off",
|
12 |
+
"no-continue": "off",
|
13 |
"no-bitwise": "off",
|
14 |
"class-methods-use-this": "off",
|
15 |
"prefer-destructuring": "off",
|
package.json
CHANGED
@@ -6,7 +6,7 @@
|
|
6 |
"types": "types/index.d.ts",
|
7 |
"scripts": {
|
8 |
"start": "node server.js",
|
9 |
-
"build-demo": "NODE_ENV=production webpack --config webpack.config.
|
10 |
"build": "webpack --config webpack.config.prod.js"
|
11 |
},
|
12 |
"bugs": {
|
|
|
6 |
"types": "types/index.d.ts",
|
7 |
"scripts": {
|
8 |
"start": "node server.js",
|
9 |
+
"build-demo": "NODE_ENV=production webpack --config webpack.config.demo.js",
|
10 |
"build": "webpack --config webpack.config.prod.js"
|
11 |
},
|
12 |
"bugs": {
|
server.js
CHANGED
@@ -2,7 +2,7 @@ const webpack = require('webpack');
|
|
2 |
const WebpackDevServer = require('webpack-dev-server');
|
3 |
const opn = require('opn');
|
4 |
|
5 |
-
const config = require('./webpack.config.
|
6 |
|
7 |
const PORT = 3000;
|
8 |
const HOST = 'localhost';
|
|
|
2 |
const WebpackDevServer = require('webpack-dev-server');
|
3 |
const opn = require('opn');
|
4 |
|
5 |
+
const config = require('./webpack.config.demo');
|
6 |
|
7 |
const PORT = 3000;
|
8 |
const HOST = 'localhost';
|
src/core/element.js
CHANGED
@@ -219,9 +219,9 @@ export default class Element {
|
|
219 |
this.node.classList.remove(CLASS_POSITION_RELATIVE);
|
220 |
|
221 |
const stackFixes = this.document.querySelectorAll(`.${CLASS_FIX_STACKING_CONTEXT}`);
|
222 |
-
stackFixes.
|
223 |
-
|
224 |
-
}
|
225 |
}
|
226 |
|
227 |
/**
|
|
|
219 |
this.node.classList.remove(CLASS_POSITION_RELATIVE);
|
220 |
|
221 |
const stackFixes = this.document.querySelectorAll(`.${CLASS_FIX_STACKING_CONTEXT}`);
|
222 |
+
for (let counter = 0; counter < stackFixes.length; counter++) {
|
223 |
+
stackFixes[counter].classList.remove(CLASS_FIX_STACKING_CONTEXT);
|
224 |
+
}
|
225 |
}
|
226 |
|
227 |
/**
|
src/index.js
CHANGED
@@ -248,14 +248,14 @@ export default class Driver {
|
|
248 |
defineSteps(steps) {
|
249 |
this.steps = [];
|
250 |
|
251 |
-
steps.
|
252 |
-
const element = this.prepareElementFromStep(
|
253 |
if (!element) {
|
254 |
-
|
255 |
}
|
256 |
|
257 |
this.steps.push(element);
|
258 |
-
}
|
259 |
}
|
260 |
|
261 |
/**
|
|
|
248 |
defineSteps(steps) {
|
249 |
this.steps = [];
|
250 |
|
251 |
+
for (let counter = 0; counter < steps.length; counter++) {
|
252 |
+
const element = this.prepareElementFromStep(steps[counter], steps, counter);
|
253 |
if (!element) {
|
254 |
+
continue;
|
255 |
}
|
256 |
|
257 |
this.steps.push(element);
|
258 |
+
}
|
259 |
}
|
260 |
|
261 |
/**
|
webpack.config.dev.js → webpack.config.demo.js
RENAMED
File without changes
|