aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--biome.json36
-rwxr-xr-xesbuild.mjs10
-rw-r--r--package.json7
-rw-r--r--pnpm-lock.yaml71
-rw-r--r--src/components/auth/SetupAssistant.tsx7
-rw-r--r--src/components/auth/Welcome.tsx2
-rw-r--r--src/components/layout/Sidebar.tsx1
-rw-r--r--src/components/services/tabs/TabItem.tsx2
-rw-r--r--src/components/settings/services/ServiceItem.tsx30
-rw-r--r--src/components/ui/Link.tsx1
-rw-r--r--src/components/ui/Radio.tsx1
-rw-r--r--src/components/ui/button/index.tsx1
-rw-r--r--src/components/ui/input/index.tsx1
-rw-r--r--src/components/ui/select/index.tsx1
-rw-r--r--src/components/ui/textarea/index.tsx2
-rw-r--r--src/components/ui/toggle/index.tsx1
-rw-r--r--src/features/workspaces/components/WorkspaceDrawerItem.tsx3
-rw-r--r--src/internal-server/app/Controllers/Http/RecipeController.js8
-rw-r--r--src/internal-server/app/Controllers/Http/ServiceController.js7
-rw-r--r--src/internal-server/start/migrate.js3
20 files changed, 145 insertions, 50 deletions
diff --git a/biome.json b/biome.json
new file mode 100644
index 000000000..0e7563225
--- /dev/null
+++ b/biome.json
@@ -0,0 +1,36 @@
1{
2 "$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
3 "formatter": {
4 "enabled": false
5 },
6 "organizeImports": {
7 "enabled": false
8 },
9 "linter": {
10 "ignore": ["build", "coverage", "node_modules", "recipes", "*.json"],
11 "rules": {
12 "style": {
13 "noNonNullAssertion": "off",
14 "noInferrableTypes": "off",
15 "noParameterAssign": "off"
16 },
17 "complexity": {
18 "useLiteralKeys": "off",
19 "noUselessConstructor": "off",
20 "noForEach": "off",
21 "noBannedTypes": "off"
22 },
23 "suspicious": {
24 "noEmptyInterface": "off",
25 "noExplicitAny": "off",
26 "noArrayIndexKey": "off"
27 },
28 "performance": {
29 "noDelete": "off"
30 },
31 "a11y": {
32 "useKeyWithClickEvents": "off"
33 }
34 }
35 }
36}
diff --git a/esbuild.mjs b/esbuild.mjs
index ae940b586..b29f15621 100755
--- a/esbuild.mjs
+++ b/esbuild.mjs
@@ -4,11 +4,11 @@ import { sassPlugin } from 'esbuild-sass-plugin';
4import { copy } from 'esbuild-plugin-copy'; 4import { copy } from 'esbuild-plugin-copy';
5import glob from 'tiny-glob'; 5import glob from 'tiny-glob';
6import livereload from 'gulp-livereload'; 6import livereload from 'gulp-livereload';
7import * as fs from 'fs'; 7import * as fs from 'node:fs';
8import * as buildInfo from 'preval-build-info'; 8import * as buildInfo from 'preval-build-info';
9import fsPkg from 'fs-extra'; 9import fsPkg from 'fs-extra';
10import chalk from 'chalk'; 10import chalk from 'chalk';
11import { performance } from 'perf_hooks'; 11import { performance } from 'node:perf_hooks';
12import moment from 'moment'; 12import moment from 'moment';
13 13
14const { log } = console; 14const { log } = console;
@@ -80,11 +80,11 @@ const runEsbuild = async () => {
80 80
81 const myArgs = process.argv.slice(2); 81 const myArgs = process.argv.slice(2);
82 const isDev = myArgs.includes('--watch'); 82 const isDev = myArgs.includes('--watch');
83 log(chalk.blue(`Starting with args`), myArgs); 83 log(chalk.blue('Starting with args'), myArgs);
84 84
85 if (fs.existsSync(outDir)) { 85 if (fs.existsSync(outDir)) {
86 fs.rmSync(outDir, { force: true, recursive: true }); 86 fs.rmSync(outDir, { force: true, recursive: true });
87 log(chalk.blue(`Cleaning`), outDir); 87 log(chalk.blue('Cleaning'), outDir);
88 } 88 }
89 copyManualAssets(); 89 copyManualAssets();
90 90
@@ -112,7 +112,7 @@ const runEsbuild = async () => {
112 if (error) { 112 if (error) {
113 log(chalk.red(`watch build failed: ${error}`)); 113 log(chalk.red(`watch build failed: ${error}`));
114 } else { 114 } else {
115 log(chalk.blue(`watch build success:`), result); 115 log(chalk.blue('watch build success:'), result);
116 livereload.reload(); 116 livereload.reload();
117 } 117 }
118 }, 118 },
diff --git a/package.json b/package.json
index f52cd8163..f2bcd7f18 100644
--- a/package.json
+++ b/package.json
@@ -34,13 +34,15 @@
34 "typecheck": "tsc --noEmit", 34 "typecheck": "tsc --noEmit",
35 "lint": "eslint \"{src,test,scripts}/**/*.{js,jsx,mjs,ts,tsx}\" --quiet", 35 "lint": "eslint \"{src,test,scripts}/**/*.{js,jsx,mjs,ts,tsx}\" --quiet",
36 "lint:fix": "pnpm lint --cache --fix", 36 "lint:fix": "pnpm lint --cache --fix",
37 "biome:check": "pnpm biome check .",
38 "biome:check:fix": "pnpm biome:check --apply-unsafe",
37 "extract": "formatjs extract \"src/**/*.{js,jsx,mjs,ts,tsx}\" --ignore=\"**/*.d.ts\" --out-file temp.json --flatten --id-interpolation-pattern '[sha512:contenthash:base64:6]' --preserve-whitespace", 39 "extract": "formatjs extract \"src/**/*.{js,jsx,mjs,ts,tsx}\" --ignore=\"**/*.d.ts\" --out-file temp.json --flatten --id-interpolation-pattern '[sha512:contenthash:base64:6]' --preserve-whitespace",
38 "compile": "formatjs compile \"temp.json\" --out-file src/i18n/locales/en-US.json", 40 "compile": "formatjs compile \"temp.json\" --out-file src/i18n/locales/en-US.json",
39 "manage-translations": "pnpm extract && pnpm compile && rimraf temp.json", 41 "manage-translations": "pnpm extract && pnpm compile && rimraf temp.json",
40 "build": "preval-build-info-cli && node esbuild.mjs && electron-builder", 42 "build": "preval-build-info-cli && node esbuild.mjs && electron-builder",
41 "contributors": "all-contributors", 43 "contributors": "all-contributors",
42 "reformat-files": "prettier --ignore-path .eslintignore --write --cache \"**/*.{js,jsx,mjs,ts,tsx,scss}\"", 44 "reformat-files": "prettier --ignore-path .eslintignore --write --cache \"**/*.{js,jsx,mjs,ts,tsx,scss}\"",
43 "prepare-code": "pnpm typecheck && pnpm lint:fix && pnpm reformat-files && pnpm manage-translations", 45 "prepare-code": "pnpm typecheck && pnpm lint:fix && pnpm biome:check:fix && pnpm reformat-files && pnpm manage-translations",
44 "link-readme": "ts-node scripts/link-readme.ts", 46 "link-readme": "ts-node scripts/link-readme.ts",
45 "minify-images": "./scripts/minify-images.sh", 47 "minify-images": "./scripts/minify-images.sh",
46 "start:server": "ts-node src/internal-server/test.ts", 48 "start:server": "ts-node src/internal-server/test.ts",
@@ -134,6 +136,7 @@
134 "ws": "8.14.2" 136 "ws": "8.14.2"
135 }, 137 },
136 "devDependencies": { 138 "devDependencies": {
139 "@biomejs/biome": "1.4.1",
137 "@commitlint/cli": "17.7.1", 140 "@commitlint/cli": "17.7.1",
138 "@commitlint/config-conventional": "17.7.0", 141 "@commitlint/config-conventional": "17.7.0",
139 "@electron/notarize": "1.2.3", 142 "@electron/notarize": "1.2.3",
@@ -216,7 +219,7 @@
216 "har-validator": "5.1.5", 219 "har-validator": "5.1.5",
217 "uuid": "3.4.0", 220 "uuid": "3.4.0",
218 "@sinonjs/fake-timers": "10.2.0", 221 "@sinonjs/fake-timers": "10.2.0",
219 "@npmcli/move-file": "1.1.2", 222 "@npmcli/move-file": "1.1.2 || 2.0.1",
220 "source-map-resolve": "0.5.3", 223 "source-map-resolve": "0.5.3",
221 "source-map-url": "0.4.1", 224 "source-map-url": "0.4.1",
222 "resolve-url": "0.2.1", 225 "resolve-url": "0.2.1",
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index aa412d57d..c29b28eb0 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -267,6 +267,9 @@ optionalDependencies:
267 version: 2.3.0 267 version: 2.3.0
268 268
269devDependencies: 269devDependencies:
270 '@biomejs/biome':
271 specifier: 1.4.1
272 version: 1.4.1
270 '@commitlint/cli': 273 '@commitlint/cli':
271 specifier: 17.7.1 274 specifier: 17.7.1
272 version: 17.7.1 275 version: 17.7.1
@@ -995,6 +998,74 @@ packages:
995 resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} 998 resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==}
996 dev: true 999 dev: true
997 1000
1001 /@biomejs/biome@1.4.1:
1002 resolution: {integrity: sha512-JccVAwPbhi37pdxbAGmaOBjUTKEwEjWAhl7rKkVVuXHo4MLASXJ5HR8BTgrImi4/7rTBsGz1tgVD1Kwv1CHGRg==}
1003 engines: {node: '>=14.*'}
1004 hasBin: true
1005 requiresBuild: true
1006 optionalDependencies:
1007 '@biomejs/cli-darwin-arm64': 1.4.1
1008 '@biomejs/cli-darwin-x64': 1.4.1
1009 '@biomejs/cli-linux-arm64': 1.4.1
1010 '@biomejs/cli-linux-x64': 1.4.1
1011 '@biomejs/cli-win32-arm64': 1.4.1
1012 '@biomejs/cli-win32-x64': 1.4.1
1013 dev: true
1014
1015 /@biomejs/cli-darwin-arm64@1.4.1:
1016 resolution: {integrity: sha512-PZWy2Idndqux38p6AXSDQM2ldRAWi32bvb7bMbTN0ALzpWYMYnxd71ornatumSSJYoNhKmxzDLq+jct7nZJ79w==}
1017 engines: {node: '>=14.*'}
1018 cpu: [arm64]
1019 os: [darwin]
1020 requiresBuild: true
1021 dev: true
1022 optional: true
1023
1024 /@biomejs/cli-darwin-x64@1.4.1:
1025 resolution: {integrity: sha512-soj3BWhnsM1M2JlzR09cibUzG1owJqetwj/Oo7yg0foijo9lNH9XWXZfJBYDKgW/6Fomn+CC2EcUS+hisQzt9g==}
1026 engines: {node: '>=14.*'}
1027 cpu: [x64]
1028 os: [darwin]
1029 requiresBuild: true
1030 dev: true
1031 optional: true
1032
1033 /@biomejs/cli-linux-arm64@1.4.1:
1034 resolution: {integrity: sha512-YIZqfJUg4F+fPsBTXxgD7EU2E5OAYbmYSl/snf4PevwfQCWE/omOFZv+NnIQmjYj9I7ParDgcJvanoA3/kO0JQ==}
1035 engines: {node: '>=14.*'}
1036 cpu: [arm64]
1037 os: [linux]
1038 requiresBuild: true
1039 dev: true
1040 optional: true
1041
1042 /@biomejs/cli-linux-x64@1.4.1:
1043 resolution: {integrity: sha512-9YOZw3qBd/KUj63A6Hn2zZgzGb2nbESM0qNmeMXgmqinVKM//uc4OgY5TuKITuGjMSvcVxxd4dX1IzYjV9qvNQ==}
1044 engines: {node: '>=14.*'}
1045 cpu: [x64]
1046 os: [linux]
1047 requiresBuild: true
1048 dev: true
1049 optional: true
1050
1051 /@biomejs/cli-win32-arm64@1.4.1:
1052 resolution: {integrity: sha512-nWQbvkNKxYn/kCQ0yVF8kCaS3VzaGvtFSmItXiMknU4521LDjJ7tNWH12Gol+pIslrCbd4E1LhJa0a3ThRsBVg==}
1053 engines: {node: '>=14.*'}
1054 cpu: [arm64]
1055 os: [win32]
1056 requiresBuild: true
1057 dev: true
1058 optional: true
1059
1060 /@biomejs/cli-win32-x64@1.4.1:
1061 resolution: {integrity: sha512-88fR2CQxQ4YLs2BUDuywWYQpUKgU3A3sTezANFc/4LGKQFFLV2yX+F7QAdZVkMHfA+RD9Xg178HomM/6mnTNPA==}
1062 engines: {node: '>=14.*'}
1063 cpu: [x64]
1064 os: [win32]
1065 requiresBuild: true
1066 dev: true
1067 optional: true
1068
998 /@colors/colors@1.5.0: 1069 /@colors/colors@1.5.0:
999 resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==} 1070 resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==}
1000 engines: {node: '>=0.1.90'} 1071 engines: {node: '>=0.1.90'}
diff --git a/src/components/auth/SetupAssistant.tsx b/src/components/auth/SetupAssistant.tsx
index fdcbba45e..c25495471 100644
--- a/src/components/auth/SetupAssistant.tsx
+++ b/src/components/auth/SetupAssistant.tsx
@@ -39,10 +39,9 @@ const messages = defineMessages({
39 }, 39 },
40}); 40});
41 41
42const transition = 42const transition = window?.matchMedia('(prefers-reduced-motion: no-preference)')
43 window && window.matchMedia('(prefers-reduced-motion: no-preference)') 43 ? 'all 0.25s'
44 ? 'all 0.25s' 44 : 'none';
45 : 'none';
46 45
47const styles = theme => ({ 46const styles = theme => ({
48 root: { 47 root: {
diff --git a/src/components/auth/Welcome.tsx b/src/components/auth/Welcome.tsx
index 259e3c335..c1a2db386 100644
--- a/src/components/auth/Welcome.tsx
+++ b/src/components/auth/Welcome.tsx
@@ -91,8 +91,8 @@ class Welcome extends Component<IProps> {
91 className="settings__hr-sections" 91 className="settings__hr-sections"
92 style={{ marginTop: 24, marginBottom: 24, borderStyle: 'solid' }} 92 style={{ marginTop: 24, marginBottom: 24, borderStyle: 'solid' }}
93 /> 93 />
94 {/* eslint-disable-next-line react/button-has-type */}
95 <button 94 <button
95 type="button"
96 className="button" 96 className="button"
97 onClick={this.useLocalServer.bind(this)} 97 onClick={this.useLocalServer.bind(this)}
98 onKeyDown={noop} 98 onKeyDown={noop}
diff --git a/src/components/layout/Sidebar.tsx b/src/components/layout/Sidebar.tsx
index 7904d7653..e423e408b 100644
--- a/src/components/layout/Sidebar.tsx
+++ b/src/components/layout/Sidebar.tsx
@@ -352,6 +352,7 @@ class Sidebar extends Component<IProps, IState> {
352 type="button" 352 type="button"
353 onClick={() => openDownloads({ path: '/downloadmanager' })} 353 onClick={() => openDownloads({ path: '/downloadmanager' })}
354 className={ 354 className={
355 // biome-ignore lint/style/useTemplate: <explanation>
355 'sidebar__button' + 356 'sidebar__button' +
356 `${isDownloading ? ' sidebar__button--downloading' : ''}` + 357 `${isDownloading ? ' sidebar__button--downloading' : ''}` +
357 `${justFinishedDownloading ? ' sidebar__button--done' : ''}` 358 `${justFinishedDownloading ? ' sidebar__button--done' : ''}`
diff --git a/src/components/services/tabs/TabItem.tsx b/src/components/services/tabs/TabItem.tsx
index 287dedfcb..804efe8a5 100644
--- a/src/components/services/tabs/TabItem.tsx
+++ b/src/components/services/tabs/TabItem.tsx
@@ -80,7 +80,7 @@ let pollIndicatorTransition = 'none';
80let polledTransition = 'none'; 80let polledTransition = 'none';
81let pollAnsweredTransition = 'none'; 81let pollAnsweredTransition = 'none';
82 82
83if (window && window.matchMedia('(prefers-reduced-motion: no-preference)')) { 83if (window?.matchMedia('(prefers-reduced-motion: no-preference)')) {
84 pollIndicatorTransition = 'background 0.5s'; 84 pollIndicatorTransition = 'background 0.5s';
85 polledTransition = 'background 0.1s'; 85 polledTransition = 'background 0.1s';
86 pollAnsweredTransition = 'background 0.1s'; 86 pollAnsweredTransition = 'background 0.1s';
diff --git a/src/components/settings/services/ServiceItem.tsx b/src/components/settings/services/ServiceItem.tsx
index babe06b5a..35b63b160 100644
--- a/src/components/settings/services/ServiceItem.tsx
+++ b/src/components/settings/services/ServiceItem.tsx
@@ -44,11 +44,7 @@ class ServiceItem extends Component<IProps> {
44 'service-table__row--disabled': !service.isEnabled, 44 'service-table__row--disabled': !service.isEnabled,
45 })} 45 })}
46 > 46 >
47 <td 47 <td className="service-table__column-icon" onClick={goToServiceForm}>
48 className="service-table__column-icon"
49 onClick={goToServiceForm}
50 role="gridcell"
51 >
52 <img 48 <img
53 src={service.icon} 49 src={service.icon}
54 className={classnames({ 50 className={classnames({
@@ -58,18 +54,10 @@ class ServiceItem extends Component<IProps> {
58 alt="" 54 alt=""
59 /> 55 />
60 </td> 56 </td>
61 <td 57 <td className="service-table__column-name" onClick={goToServiceForm}>
62 className="service-table__column-name"
63 onClick={goToServiceForm}
64 role="gridcell"
65 >
66 {service.name === '' ? service.recipe.name : service.name} 58 {service.name === '' ? service.recipe.name : service.name}
67 </td> 59 </td>
68 <td 60 <td className="service-table__column-info" onClick={goToServiceForm}>
69 className="service-table__column-info"
70 onClick={goToServiceForm}
71 role="gridcell"
72 >
73 {service.isMuted && ( 61 {service.isMuted && (
74 <Icon 62 <Icon
75 icon={mdiBellOff} 63 icon={mdiBellOff}
@@ -78,11 +66,7 @@ class ServiceItem extends Component<IProps> {
78 /> 66 />
79 )} 67 )}
80 </td> 68 </td>
81 <td 69 <td className="service-table__column-info" onClick={goToServiceForm}>
82 className="service-table__column-info"
83 onClick={goToServiceForm}
84 role="gridcell"
85 >
86 {!service.isEnabled && ( 70 {!service.isEnabled && (
87 <Icon 71 <Icon
88 icon={mdiPower} 72 icon={mdiPower}
@@ -93,11 +77,7 @@ class ServiceItem extends Component<IProps> {
93 /> 77 />
94 )} 78 )}
95 </td> 79 </td>
96 <td 80 <td className="service-table__column-info" onClick={goToServiceForm}>
97 className="service-table__column-info"
98 onClick={goToServiceForm}
99 role="gridcell"
100 >
101 {!service.isNotificationEnabled && ( 81 {!service.isNotificationEnabled && (
102 <Icon 82 <Icon
103 icon={mdiMessageBulletedOff} 83 icon={mdiMessageBulletedOff}
diff --git a/src/components/ui/Link.tsx b/src/components/ui/Link.tsx
index a9a429d3a..f9fdd57f9 100644
--- a/src/components/ui/Link.tsx
+++ b/src/components/ui/Link.tsx
@@ -54,6 +54,7 @@ class Link extends Component<IProps> {
54 }); 54 });
55 55
56 return ( 56 return (
57 // biome-ignore lint/a11y/useValidAnchor: <explanation>
57 <a 58 <a
58 href={router.history.createHref(to)} 59 href={router.history.createHref(to)}
59 className={linkClasses} 60 className={linkClasses}
diff --git a/src/components/ui/Radio.tsx b/src/components/ui/Radio.tsx
index 1f41deedc..901958c78 100644
--- a/src/components/ui/Radio.tsx
+++ b/src/components/ui/Radio.tsx
@@ -2,6 +2,7 @@ import { Component } from 'react';
2import { observer } from 'mobx-react'; 2import { observer } from 'mobx-react';
3import classnames from 'classnames'; 3import classnames from 'classnames';
4import FieldInterface from 'mobx-react-form/lib/models/FieldInterface'; 4import FieldInterface from 'mobx-react-form/lib/models/FieldInterface';
5// biome-ignore lint/suspicious/noShadowRestrictedNames: <explanation>
5import Error from './error'; 6import Error from './error';
6 7
7type Props = { 8type Props = {
diff --git a/src/components/ui/button/index.tsx b/src/components/ui/button/index.tsx
index f8bcf76b2..a2194e34d 100644
--- a/src/components/ui/button/index.tsx
+++ b/src/components/ui/button/index.tsx
@@ -205,6 +205,7 @@ class ButtonComponent extends Component<IProps, IState> {
205 ); 205 );
206 206
207 const wrapperComponent = href ? ( 207 const wrapperComponent = href ? (
208 // biome-ignore lint/a11y/useValidAnchor: <explanation>
208 <a 209 <a
209 href={href} 210 href={href}
210 target={target} 211 target={target}
diff --git a/src/components/ui/input/index.tsx b/src/components/ui/input/index.tsx
index 064c1807f..68cc9ee22 100644
--- a/src/components/ui/input/index.tsx
+++ b/src/components/ui/input/index.tsx
@@ -14,6 +14,7 @@ import { observer } from 'mobx-react';
14import { defineMessages, injectIntl, WrappedComponentProps } from 'react-intl'; 14import { defineMessages, injectIntl, WrappedComponentProps } from 'react-intl';
15import Icon from '../icon'; 15import Icon from '../icon';
16import { IFormField } from '../typings/generic'; 16import { IFormField } from '../typings/generic';
17// biome-ignore lint/suspicious/noShadowRestrictedNames: <explanation>
17import Error from '../error'; 18import Error from '../error';
18import Label from '../label'; 19import Label from '../label';
19import Wrapper from '../wrapper'; 20import Wrapper from '../wrapper';
diff --git a/src/components/ui/select/index.tsx b/src/components/ui/select/index.tsx
index 650600fb3..c06ac59b0 100644
--- a/src/components/ui/select/index.tsx
+++ b/src/components/ui/select/index.tsx
@@ -10,6 +10,7 @@ import withStyles, { WithStylesProps } from 'react-jss';
10import { noop } from 'lodash'; 10import { noop } from 'lodash';
11import { Theme } from '../../../themes'; 11import { Theme } from '../../../themes';
12import { IFormField } from '../typings/generic'; 12import { IFormField } from '../typings/generic';
13// biome-ignore lint/suspicious/noShadowRestrictedNames: <explanation>
13import Error from '../error'; 14import Error from '../error';
14import Label from '../label'; 15import Label from '../label';
15import Wrapper from '../wrapper'; 16import Wrapper from '../wrapper';
diff --git a/src/components/ui/textarea/index.tsx b/src/components/ui/textarea/index.tsx
index fbdef7fc6..0967c4c25 100644
--- a/src/components/ui/textarea/index.tsx
+++ b/src/components/ui/textarea/index.tsx
@@ -5,6 +5,7 @@ import injectSheet, { WithStylesProps } from 'react-jss';
5import { noop } from 'lodash'; 5import { noop } from 'lodash';
6import { IFormField } from '../typings/generic'; 6import { IFormField } from '../typings/generic';
7 7
8// biome-ignore lint/suspicious/noShadowRestrictedNames: <explanation>
8import Error from '../error'; 9import Error from '../error';
9import Label from '../label'; 10import Label from '../label';
10import Wrapper from '../wrapper'; 11import Wrapper from '../wrapper';
@@ -40,6 +41,7 @@ class TextareaComponent extends Component<IProps> {
40 41
41 if (this.textareaRef?.current && data) { 42 if (this.textareaRef?.current && data) {
42 Object.keys(data).map( 43 Object.keys(data).map(
44 // biome-ignore lint/suspicious/noAssignInExpressions: <explanation>
43 key => (this.textareaRef.current!.dataset[key] = data[key]), 45 key => (this.textareaRef.current!.dataset[key] = data[key]),
44 ); 46 );
45 } 47 }
diff --git a/src/components/ui/toggle/index.tsx b/src/components/ui/toggle/index.tsx
index 275d28bf6..878ffecdc 100644
--- a/src/components/ui/toggle/index.tsx
+++ b/src/components/ui/toggle/index.tsx
@@ -4,6 +4,7 @@ import { noop } from 'lodash';
4import { Component, InputHTMLAttributes, ReactElement } from 'react'; 4import { Component, InputHTMLAttributes, ReactElement } from 'react';
5import withStyles, { WithStylesProps } from 'react-jss'; 5import withStyles, { WithStylesProps } from 'react-jss';
6import { Theme } from '../../../themes'; 6import { Theme } from '../../../themes';
7// biome-ignore lint/suspicious/noShadowRestrictedNames: <explanation>
7import Error from '../error'; 8import Error from '../error';
8import Label from '../label'; 9import Label from '../label';
9import { IFormField } from '../typings/generic'; 10import { IFormField } from '../typings/generic';
diff --git a/src/features/workspaces/components/WorkspaceDrawerItem.tsx b/src/features/workspaces/components/WorkspaceDrawerItem.tsx
index 4fd7662f5..85ed4c38c 100644
--- a/src/features/workspaces/components/WorkspaceDrawerItem.tsx
+++ b/src/features/workspaces/components/WorkspaceDrawerItem.tsx
@@ -72,8 +72,7 @@ interface IProps extends WithStylesProps<typeof styles>, WrappedComponentProps {
72 name: string; 72 name: string;
73 onClick: MouseEventHandler<HTMLInputElement>; 73 onClick: MouseEventHandler<HTMLInputElement>;
74 services: string[]; 74 services: string[];
75 // eslint-disable-next-line @typescript-eslint/no-invalid-void-type 75 onContextMenuEditClick?: (() => void) | null;
76 onContextMenuEditClick?: () => void | null;
77 shortcutIndex: number; 76 shortcutIndex: number;
78} 77}
79 78
diff --git a/src/internal-server/app/Controllers/Http/RecipeController.js b/src/internal-server/app/Controllers/Http/RecipeController.js
index 3e54ab65b..48d3ce7e5 100644
--- a/src/internal-server/app/Controllers/Http/RecipeController.js
+++ b/src/internal-server/app/Controllers/Http/RecipeController.js
@@ -59,8 +59,8 @@ class RecipeController {
59 })); 59 }));
60 } else { 60 } else {
61 let remoteResults = []; 61 let remoteResults = [];
62 // eslint-disable-next-line eqeqeq 62
63 if (Env.get('CONNECT_WITH_FRANZ') == 'true') { 63 if (Env.get('CONNECT_WITH_FRANZ') === 'true') {
64 const recipesUrlFetch = await fetch( 64 const recipesUrlFetch = await fetch(
65 `${RECIPES_URL}/search?needle=${encodeURIComponent(needle)}`, 65 `${RECIPES_URL}/search?needle=${encodeURIComponent(needle)}`,
66 ); 66 );
@@ -123,8 +123,8 @@ class RecipeController {
123 if (await Drive.exists(`${service}.tar.gz`)) { 123 if (await Drive.exists(`${service}.tar.gz`)) {
124 return response.send(await Drive.get(`${service}.tar.gz`)); 124 return response.send(await Drive.get(`${service}.tar.gz`));
125 } 125 }
126 // eslint-disable-next-line eqeqeq 126
127 if (Env.get('CONNECT_WITH_FRANZ') == 'true') { 127 if (Env.get('CONNECT_WITH_FRANZ') === 'true') {
128 return response.redirect(`${RECIPES_URL}/download/${service}`); 128 return response.redirect(`${RECIPES_URL}/download/${service}`);
129 } 129 }
130 return response.status(400).send({ 130 return response.status(400).send({
diff --git a/src/internal-server/app/Controllers/Http/ServiceController.js b/src/internal-server/app/Controllers/Http/ServiceController.js
index 940cac065..8e8aa97a8 100644
--- a/src/internal-server/app/Controllers/Http/ServiceController.js
+++ b/src/internal-server/app/Controllers/Http/ServiceController.js
@@ -126,10 +126,9 @@ class ServiceController {
126 const newSettings = { 126 const newSettings = {
127 ...settings, 127 ...settings,
128 iconId, 128 iconId,
129 customIconVersion: 129 customIconVersion: settings?.customIconVersion
130 settings && settings.customIconVersion 130 ? settings.customIconVersion + 1
131 ? settings.customIconVersion + 1 131 : 1,
132 : 1,
133 }; 132 };
134 133
135 // Update data in database 134 // Update data in database
diff --git a/src/internal-server/start/migrate.js b/src/internal-server/start/migrate.js
index 4cd502c3f..67533ed9e 100644
--- a/src/internal-server/start/migrate.js
+++ b/src/internal-server/start/migrate.js
@@ -35,8 +35,7 @@ module.exports = async () => {
35 !settings.db_version || 35 !settings.db_version ||
36 settings.db_version !== ferdiumVersion 36 settings.db_version !== ferdiumVersion
37 ) { 37 ) {
38 const srcVersion = 38 const srcVersion = settings?.db_version || '5.4.0-beta.2';
39 settings && settings.db_version ? settings.db_version : '5.4.0-beta.2';
40 migrateLog(`🔮 Migrating table from ${srcVersion} to ${ferdiumVersion}`); 39 migrateLog(`🔮 Migrating table from ${srcVersion} to ${ferdiumVersion}`);
41 40
42 // Migrate database to current Ferdium version 41 // Migrate database to current Ferdium version