Another eslint rule
This commit is contained in:
@@ -23,8 +23,8 @@ const OrbitControls = function (object, domElement) {
|
||||
const scope = this;
|
||||
|
||||
const changeEvent = { type: "change" };
|
||||
const startEvent = { type: "start" };
|
||||
const endEvent = { type: "end" };
|
||||
const startEvent = { type: "start" };
|
||||
const endEvent = { type: "end" };
|
||||
|
||||
const STATE = {
|
||||
NONE: -1, ROTATE: 0, DOLLY: 1, PAN: 2, TOUCH_ROTATE: 3, TOUCH_DOLLY_PAN: 4
|
||||
@@ -68,13 +68,13 @@ const OrbitControls = function (object, domElement) {
|
||||
|
||||
// How far you can orbit vertically, upper and lower limits.
|
||||
// Range is 0 to Math.PI radians.
|
||||
this.minPolarAngle = 0; // radians
|
||||
this.minPolarAngle = 0; // radians
|
||||
this.maxPolarAngle = Math.PI; // radians
|
||||
|
||||
// How far you can orbit horizontally, upper and lower limits.
|
||||
// If set, must be a sub-interval of the interval [- Math.PI, Math.PI].
|
||||
this.minAzimuthAngle = -Infinity; // radians
|
||||
this.maxAzimuthAngle = Infinity; // radians
|
||||
this.maxAzimuthAngle = Infinity; // radians
|
||||
|
||||
// Set to true to enable damping (inertia)
|
||||
// If damping is enabled, call controls.update() in your animation loop
|
||||
|
||||
@@ -464,10 +464,10 @@ module.exports = {
|
||||
geometry.translate(0, -length - radius, 0);
|
||||
group.add(new THREE.Mesh(geometry, material));
|
||||
|
||||
if (axis == 0) {
|
||||
if (axis == 0) {
|
||||
group.rotateZ((up ? 0.5 : 1.5) * Math.PI);
|
||||
} else if (axis == 1) {
|
||||
group.rotateX((up ? 0 : 1 ) * Math.PI);
|
||||
group.rotateX((up ? 0 : 1 ) * Math.PI);
|
||||
} else if (axis == 2) {
|
||||
group.rotateX((up ? 1.5 : 0.5) * Math.PI);
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ export const numberWithUnit = {
|
||||
regex: /^\s*(?:(\d+)\s*\/\s*(\d+)|(\d*\.\d+)|(\d+(?:\.\d+)?))\s*("|in|inch|inches|mm|millimeters)\s*$/,
|
||||
parse: function (str: string) {
|
||||
// eslint-disable-next-line prefer-const
|
||||
let [, numerator, denominator, decimal1, decimal2, unit]: any = str?.match(numberWithUnit.regex) ?? [];
|
||||
let [ , numerator, denominator, decimal1, decimal2, unit ]: any = str?.match(numberWithUnit.regex) ?? [];
|
||||
|
||||
numerator = Number.parseFloat(numerator);
|
||||
denominator = Number.parseFloat(denominator);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import sveltePreprocess from 'svelte-preprocess'
|
||||
import sveltePreprocess from "svelte-preprocess";
|
||||
|
||||
export default {
|
||||
// Consult https://github.com/sveltejs/svelte-preprocess
|
||||
// for more information about preprocessors
|
||||
preprocess: sveltePreprocess()
|
||||
}
|
||||
// Consult https://github.com/sveltejs/svelte-preprocess
|
||||
// for more information about preprocessors
|
||||
preprocess: sveltePreprocess()
|
||||
};
|
||||
|
||||
@@ -1,26 +1,26 @@
|
||||
import { defineConfig } from 'vite'
|
||||
import { svelte } from '@sveltejs/vite-plugin-svelte'
|
||||
import { resolve } from 'path';
|
||||
import { defineConfig } from "vite";
|
||||
import { svelte } from "@sveltejs/vite-plugin-svelte";
|
||||
import { resolve } from "path";
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
export default defineConfig({
|
||||
plugins: [
|
||||
svelte()
|
||||
],
|
||||
resolve: {
|
||||
alias: {
|
||||
$lib: resolve('./src/lib'),
|
||||
$dialogs: resolve('./src/dialogs'),
|
||||
$components: resolve('./src/components')
|
||||
plugins: [
|
||||
svelte()
|
||||
],
|
||||
resolve: {
|
||||
alias: {
|
||||
$lib: resolve("./src/lib"),
|
||||
$dialogs: resolve("./src/dialogs"),
|
||||
$components: resolve("./src/components")
|
||||
}
|
||||
},
|
||||
build: {
|
||||
target: "chrome60",
|
||||
lib: {
|
||||
entry: resolve(__dirname, "src/main.ts"),
|
||||
name: "SvelteComponents",
|
||||
formats: [ "iife" ],
|
||||
fileName: () => "index.js"
|
||||
}
|
||||
}
|
||||
},
|
||||
build: {
|
||||
target: "chrome60",
|
||||
lib: {
|
||||
entry: resolve(__dirname, 'src/main.ts'),
|
||||
name: 'SvelteComponents',
|
||||
formats: ['iife'],
|
||||
fileName: () => "index.js"
|
||||
}
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user