diff --git a/.eustia.js b/.eustia.js index 8f36103..7505f4f 100644 --- a/.eustia.js +++ b/.eustia.js @@ -1,16 +1,16 @@ -module.exports = { - eruda: { - library: 'https://raw.githubusercontent.com/liriliri/fione/master/', - files: 'src/**/*.js', - ignore: 'src/**/stringify.js', - output: 'src/lib/util.js', - exclude: ['createCfg'], - format: 'es' - }, - test: { - files: ['test/*.js', 'test/*.html'], - exclude: ['js'], - namespace: 'util', - output: 'test/util.js' - } -} +module.exports = { + eruda: { + library: 'https://raw.githubusercontent.com/liriliri/fione/master/', + files: 'src/**/*.js', + ignore: 'src/**/stringify.js', + output: 'src/lib/util.js', + exclude: ['createCfg'], + format: 'es' + }, + test: { + files: ['test/*.js', 'test/*.html'], + exclude: ['js'], + namespace: 'util', + output: 'test/util.js' + } +} diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..94f480d --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* text=auto eol=lf \ No newline at end of file diff --git a/prettier.config.js b/prettier.config.js index c86edf5..cbed5f6 100644 --- a/prettier.config.js +++ b/prettier.config.js @@ -1,5 +1,6 @@ module.exports = { singleQuote: true, tabWidth: 2, - semi: false + semi: false, + endOfLine: 'lf' } diff --git a/src/DevTools/DevTools.js b/src/DevTools/DevTools.js index 48261a8..772f932 100644 --- a/src/DevTools/DevTools.js +++ b/src/DevTools/DevTools.js @@ -280,14 +280,14 @@ export default class DevTools extends Emitter { return 0 } $navBar.on('contextmenu', e => e.preventDefault()) - const $body = $(document.body) + const $root = $(document.documentElement) if (isMobile()) { $navBar.on('touchstart', startListener).on('touchmove', moveListener) - $body.on('touchend', endListener) + $root.on('touchend', endListener) } else { $navBar.on('mousedown', startListener) - $body.on('mousemove', moveListener) - $body.on('mouseup', endListener) + $root.on('mousemove', moveListener) + $root.on('mouseup', endListener) } } }