mirror of
				https://github.com/SillyTavern/SillyTavern.git
				synced 2025-06-05 21:59:27 +02:00 
			
		
		
		
	Fix unfixable lints
This commit is contained in:
		| @@ -3,6 +3,9 @@ module.exports = { | |||||||
|     extends: [ |     extends: [ | ||||||
|         'eslint:recommended', |         'eslint:recommended', | ||||||
|     ], |     ], | ||||||
|  |     plugins: [ | ||||||
|  |         'jsdoc', | ||||||
|  |     ], | ||||||
|     env: { |     env: { | ||||||
|         es6: true, |         es6: true, | ||||||
|     }, |     }, | ||||||
| @@ -78,6 +81,7 @@ module.exports = { | |||||||
|         'public/scripts/extensions/tts/lib/**', |         'public/scripts/extensions/tts/lib/**', | ||||||
|     ], |     ], | ||||||
|     rules: { |     rules: { | ||||||
|  |         'jsdoc/no-undefined-types': ['warn', { disableReporting: true, markVariablesAsUsed: true }], | ||||||
|         'no-unused-vars': ['error', { args: 'none' }], |         'no-unused-vars': ['error', { args: 'none' }], | ||||||
|         'no-control-regex': 'off', |         'no-control-regex': 'off', | ||||||
|         'no-constant-condition': ['error', { checkLoops: false }], |         'no-constant-condition': ['error', { checkLoops: false }], | ||||||
|   | |||||||
							
								
								
									
										238
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										238
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							| @@ -110,7 +110,8 @@ | |||||||
|                 "@types/write-file-atomic": "^4.0.3", |                 "@types/write-file-atomic": "^4.0.3", | ||||||
|                 "@types/yargs": "^17.0.33", |                 "@types/yargs": "^17.0.33", | ||||||
|                 "@types/yauzl": "^2.10.3", |                 "@types/yauzl": "^2.10.3", | ||||||
|                 "eslint": "^8.57.1" |                 "eslint": "^8.57.1", | ||||||
|  |                 "eslint-plugin-jsdoc": "^50.6.8" | ||||||
|             }, |             }, | ||||||
|             "engines": { |             "engines": { | ||||||
|                 "node": ">= 18" |                 "node": ">= 18" | ||||||
| @@ -147,6 +148,21 @@ | |||||||
|             "integrity": "sha512-KlmTftToTtmb6aLVdne4NluS+POWputPF5J8v25UN/EQS+K9vahWEIe1NPRSFqBQclObkqHaj7JOnFrmnSm5MA==", |             "integrity": "sha512-KlmTftToTtmb6aLVdne4NluS+POWputPF5J8v25UN/EQS+K9vahWEIe1NPRSFqBQclObkqHaj7JOnFrmnSm5MA==", | ||||||
|             "license": "Apache-2.0" |             "license": "Apache-2.0" | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/@es-joy/jsdoccomment": { | ||||||
|  |             "version": "0.49.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/@es-joy/jsdoccomment/-/jsdoccomment-0.49.0.tgz", | ||||||
|  |             "integrity": "sha512-xjZTSFgECpb9Ohuk5yMX5RhUEbfeQcuOp8IF60e+wyzWEF0M5xeSgqsfLtvPEX8BIyOX9saZqzuGPmZ8oWc+5Q==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "dependencies": { | ||||||
|  |                 "comment-parser": "1.4.1", | ||||||
|  |                 "esquery": "^1.6.0", | ||||||
|  |                 "jsdoc-type-pratt-parser": "~4.1.0" | ||||||
|  |             }, | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">=16" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/@eslint-community/eslint-utils": { |         "node_modules/@eslint-community/eslint-utils": { | ||||||
|             "version": "4.4.0", |             "version": "4.4.0", | ||||||
|             "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", |             "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", | ||||||
| @@ -970,6 +986,19 @@ | |||||||
|                 "node": ">=14" |                 "node": ">=14" | ||||||
|             } |             } | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/@pkgr/core": { | ||||||
|  |             "version": "0.1.1", | ||||||
|  |             "resolved": "https://registry.npmjs.org/@pkgr/core/-/core-0.1.1.tgz", | ||||||
|  |             "integrity": "sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "engines": { | ||||||
|  |                 "node": "^12.20.0 || ^14.18.0 || >=16.0.0" | ||||||
|  |             }, | ||||||
|  |             "funding": { | ||||||
|  |                 "url": "https://opencollective.com/unts" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/@popperjs/core": { |         "node_modules/@popperjs/core": { | ||||||
|             "version": "2.11.8", |             "version": "2.11.8", | ||||||
|             "resolved": "https://registry.npmjs.org/@popperjs/core/-/core-2.11.8.tgz", |             "resolved": "https://registry.npmjs.org/@popperjs/core/-/core-2.11.8.tgz", | ||||||
| @@ -2099,6 +2128,16 @@ | |||||||
|                 "safe-buffer": "~5.2.0" |                 "safe-buffer": "~5.2.0" | ||||||
|             } |             } | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/are-docs-informative": { | ||||||
|  |             "version": "0.0.2", | ||||||
|  |             "resolved": "https://registry.npmjs.org/are-docs-informative/-/are-docs-informative-0.0.2.tgz", | ||||||
|  |             "integrity": "sha512-ixiS0nLNNG5jNQzgZJNoUpBKdo9yTYZMGJ+QgT2jmjR7G7+QHRCc4v6LQ3NgE7EBJq+o0ams3waJwkrlBom8Ig==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">=14" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/argparse": { |         "node_modules/argparse": { | ||||||
|             "version": "2.0.1", |             "version": "2.0.1", | ||||||
|             "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", |             "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", | ||||||
| @@ -2614,6 +2653,16 @@ | |||||||
|             "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", |             "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", | ||||||
|             "license": "MIT" |             "license": "MIT" | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/comment-parser": { | ||||||
|  |             "version": "1.4.1", | ||||||
|  |             "resolved": "https://registry.npmjs.org/comment-parser/-/comment-parser-1.4.1.tgz", | ||||||
|  |             "integrity": "sha512-buhp5kePrmda3vhc5B9t7pUQXAb2Tnd0qgpkIhPhkHXxJpiPJ11H0ZEU0oBpJ2QztSbzG/ZxMj/CHsYJqRHmyg==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">= 12.0.0" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/compress-commons": { |         "node_modules/compress-commons": { | ||||||
|             "version": "6.0.2", |             "version": "6.0.2", | ||||||
|             "resolved": "https://registry.npmjs.org/compress-commons/-/compress-commons-6.0.2.tgz", |             "resolved": "https://registry.npmjs.org/compress-commons/-/compress-commons-6.0.2.tgz", | ||||||
| @@ -3560,6 +3609,101 @@ | |||||||
|                 "url": "https://opencollective.com/eslint" |                 "url": "https://opencollective.com/eslint" | ||||||
|             } |             } | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/eslint-plugin-jsdoc": { | ||||||
|  |             "version": "50.6.8", | ||||||
|  |             "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-50.6.8.tgz", | ||||||
|  |             "integrity": "sha512-PPZVqhoXaalMQwDGzcQrJtPSPIPOYsSMtvkjYAdsIazOW20yhYtVX4+jLL+XznD4zYTXyZbPWPRKkNev4D4lyw==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "BSD-3-Clause", | ||||||
|  |             "dependencies": { | ||||||
|  |                 "@es-joy/jsdoccomment": "~0.49.0", | ||||||
|  |                 "are-docs-informative": "^0.0.2", | ||||||
|  |                 "comment-parser": "1.4.1", | ||||||
|  |                 "debug": "^4.3.6", | ||||||
|  |                 "escape-string-regexp": "^4.0.0", | ||||||
|  |                 "espree": "^10.1.0", | ||||||
|  |                 "esquery": "^1.6.0", | ||||||
|  |                 "parse-imports": "^2.1.1", | ||||||
|  |                 "semver": "^7.6.3", | ||||||
|  |                 "spdx-expression-parse": "^4.0.0", | ||||||
|  |                 "synckit": "^0.9.1" | ||||||
|  |             }, | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">=18" | ||||||
|  |             }, | ||||||
|  |             "peerDependencies": { | ||||||
|  |                 "eslint": "^7.0.0 || ^8.0.0 || ^9.0.0" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|  |         "node_modules/eslint-plugin-jsdoc/node_modules/debug": { | ||||||
|  |             "version": "4.4.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.0.tgz", | ||||||
|  |             "integrity": "sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "dependencies": { | ||||||
|  |                 "ms": "^2.1.3" | ||||||
|  |             }, | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">=6.0" | ||||||
|  |             }, | ||||||
|  |             "peerDependenciesMeta": { | ||||||
|  |                 "supports-color": { | ||||||
|  |                     "optional": true | ||||||
|  |                 } | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|  |         "node_modules/eslint-plugin-jsdoc/node_modules/escape-string-regexp": { | ||||||
|  |             "version": "4.0.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", | ||||||
|  |             "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">=10" | ||||||
|  |             }, | ||||||
|  |             "funding": { | ||||||
|  |                 "url": "https://github.com/sponsors/sindresorhus" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|  |         "node_modules/eslint-plugin-jsdoc/node_modules/eslint-visitor-keys": { | ||||||
|  |             "version": "4.2.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", | ||||||
|  |             "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "Apache-2.0", | ||||||
|  |             "engines": { | ||||||
|  |                 "node": "^18.18.0 || ^20.9.0 || >=21.1.0" | ||||||
|  |             }, | ||||||
|  |             "funding": { | ||||||
|  |                 "url": "https://opencollective.com/eslint" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|  |         "node_modules/eslint-plugin-jsdoc/node_modules/espree": { | ||||||
|  |             "version": "10.3.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/espree/-/espree-10.3.0.tgz", | ||||||
|  |             "integrity": "sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "BSD-2-Clause", | ||||||
|  |             "dependencies": { | ||||||
|  |                 "acorn": "^8.14.0", | ||||||
|  |                 "acorn-jsx": "^5.3.2", | ||||||
|  |                 "eslint-visitor-keys": "^4.2.0" | ||||||
|  |             }, | ||||||
|  |             "engines": { | ||||||
|  |                 "node": "^18.18.0 || ^20.9.0 || >=21.1.0" | ||||||
|  |             }, | ||||||
|  |             "funding": { | ||||||
|  |                 "url": "https://opencollective.com/eslint" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|  |         "node_modules/eslint-plugin-jsdoc/node_modules/ms": { | ||||||
|  |             "version": "2.1.3", | ||||||
|  |             "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", | ||||||
|  |             "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT" | ||||||
|  |         }, | ||||||
|         "node_modules/eslint-scope": { |         "node_modules/eslint-scope": { | ||||||
|             "version": "7.2.2", |             "version": "7.2.2", | ||||||
|             "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", |             "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", | ||||||
| @@ -3690,9 +3834,9 @@ | |||||||
|             } |             } | ||||||
|         }, |         }, | ||||||
|         "node_modules/esquery": { |         "node_modules/esquery": { | ||||||
|             "version": "1.5.0", |             "version": "1.6.0", | ||||||
|             "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz", |             "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.6.0.tgz", | ||||||
|             "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==", |             "integrity": "sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==", | ||||||
|             "dev": true, |             "dev": true, | ||||||
|             "license": "BSD-3-Clause", |             "license": "BSD-3-Clause", | ||||||
|             "dependencies": { |             "dependencies": { | ||||||
| @@ -5015,6 +5159,16 @@ | |||||||
|             "integrity": "sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A==", |             "integrity": "sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A==", | ||||||
|             "license": "MIT" |             "license": "MIT" | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/jsdoc-type-pratt-parser": { | ||||||
|  |             "version": "4.1.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/jsdoc-type-pratt-parser/-/jsdoc-type-pratt-parser-4.1.0.tgz", | ||||||
|  |             "integrity": "sha512-Hicd6JK5Njt2QB6XYFS7ok9e37O8AYk3jTcppG4YVQnYjOemymvTcmc7OWsmq/Qqj5TdRFO5/x/tIPmBeRtGHg==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">=12.0.0" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/json-buffer": { |         "node_modules/json-buffer": { | ||||||
|             "version": "3.0.1", |             "version": "3.0.1", | ||||||
|             "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", |             "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", | ||||||
| @@ -5891,6 +6045,20 @@ | |||||||
|             "integrity": "sha512-ft3iAoLOB/MlwbNXgzy43SWGP6sQki2jQvAyBg/zDFAgr9bfNWZIUj42Kw2eJIl8kEi4PbgE6U1Zau/HwI75HA==", |             "integrity": "sha512-ft3iAoLOB/MlwbNXgzy43SWGP6sQki2jQvAyBg/zDFAgr9bfNWZIUj42Kw2eJIl8kEi4PbgE6U1Zau/HwI75HA==", | ||||||
|             "license": "MIT" |             "license": "MIT" | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/parse-imports": { | ||||||
|  |             "version": "2.2.1", | ||||||
|  |             "resolved": "https://registry.npmjs.org/parse-imports/-/parse-imports-2.2.1.tgz", | ||||||
|  |             "integrity": "sha512-OL/zLggRp8mFhKL0rNORUTR4yBYujK/uU+xZL+/0Rgm2QE4nLO9v8PzEweSJEbMGKmDRjJE4R3IMJlL2di4JeQ==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "Apache-2.0 AND MIT", | ||||||
|  |             "dependencies": { | ||||||
|  |                 "es-module-lexer": "^1.5.3", | ||||||
|  |                 "slashes": "^3.0.12" | ||||||
|  |             }, | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">= 18" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/parse5": { |         "node_modules/parse5": { | ||||||
|             "version": "7.1.2", |             "version": "7.1.2", | ||||||
|             "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.1.2.tgz", |             "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.1.2.tgz", | ||||||
| @@ -6600,6 +6768,19 @@ | |||||||
|             "integrity": "sha512-8OwmbklUNzwezjGInmZ+2clQmExQPvomqjL7LFqOYqtmuxRgQYqOD3mHaU+MvZn5FLUeVxVfQjwLZW/n/JFuqg==", |             "integrity": "sha512-8OwmbklUNzwezjGInmZ+2clQmExQPvomqjL7LFqOYqtmuxRgQYqOD3mHaU+MvZn5FLUeVxVfQjwLZW/n/JFuqg==", | ||||||
|             "license": "MIT" |             "license": "MIT" | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/semver": { | ||||||
|  |             "version": "7.7.1", | ||||||
|  |             "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.1.tgz", | ||||||
|  |             "integrity": "sha512-hlq8tAfn0m/61p4BVRcPzIGr6LKiMwo4VM6dGi6pt4qcRkmNzTcWq6eCEjEh+qXjkMDvPlOFFSGwQjoEa6gyMA==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "ISC", | ||||||
|  |             "bin": { | ||||||
|  |                 "semver": "bin/semver.js" | ||||||
|  |             }, | ||||||
|  |             "engines": { | ||||||
|  |                 "node": ">=10" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/send": { |         "node_modules/send": { | ||||||
|             "version": "0.19.0", |             "version": "0.19.0", | ||||||
|             "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", |             "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", | ||||||
| @@ -6811,6 +6992,13 @@ | |||||||
|             "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", |             "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", | ||||||
|             "license": "MIT" |             "license": "MIT" | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/slashes": { | ||||||
|  |             "version": "3.0.12", | ||||||
|  |             "resolved": "https://registry.npmjs.org/slashes/-/slashes-3.0.12.tgz", | ||||||
|  |             "integrity": "sha512-Q9VME8WyGkc7pJf6QEkj3wE+2CnvZMI+XJhwdTPR8Z/kWQRXi7boAWLDibRPyHRTUTPx5FaU7MsyrjI3yLB4HA==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "ISC" | ||||||
|  |         }, | ||||||
|         "node_modules/sliced": { |         "node_modules/sliced": { | ||||||
|             "version": "1.0.1", |             "version": "1.0.1", | ||||||
|             "resolved": "https://registry.npmjs.org/sliced/-/sliced-1.0.1.tgz", |             "resolved": "https://registry.npmjs.org/sliced/-/sliced-1.0.1.tgz", | ||||||
| @@ -6903,6 +7091,31 @@ | |||||||
|                 "source-map": "^0.6.0" |                 "source-map": "^0.6.0" | ||||||
|             } |             } | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/spdx-exceptions": { | ||||||
|  |             "version": "2.5.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.5.0.tgz", | ||||||
|  |             "integrity": "sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "CC-BY-3.0" | ||||||
|  |         }, | ||||||
|  |         "node_modules/spdx-expression-parse": { | ||||||
|  |             "version": "4.0.0", | ||||||
|  |             "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-4.0.0.tgz", | ||||||
|  |             "integrity": "sha512-Clya5JIij/7C6bRR22+tnGXbc4VKlibKSVj2iHvVeX5iMW7s1SIQlqu699JkODJJIhh/pUu8L0/VLh8xflD+LQ==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "dependencies": { | ||||||
|  |                 "spdx-exceptions": "^2.1.0", | ||||||
|  |                 "spdx-license-ids": "^3.0.0" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|  |         "node_modules/spdx-license-ids": { | ||||||
|  |             "version": "3.0.21", | ||||||
|  |             "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.21.tgz", | ||||||
|  |             "integrity": "sha512-Bvg/8F5XephndSK3JffaRqdT+gyhfqIPwDHpX80tJrF8QQRYMo8sNMeaZ2Dp5+jhwKnUmIOyFFQfHRkjJm5nXg==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "CC0-1.0" | ||||||
|  |         }, | ||||||
|         "node_modules/sprintf-js": { |         "node_modules/sprintf-js": { | ||||||
|             "version": "1.1.3", |             "version": "1.1.3", | ||||||
|             "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.1.3.tgz", |             "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.1.3.tgz", | ||||||
| @@ -7042,6 +7255,23 @@ | |||||||
|                 "node": ">=8" |                 "node": ">=8" | ||||||
|             } |             } | ||||||
|         }, |         }, | ||||||
|  |         "node_modules/synckit": { | ||||||
|  |             "version": "0.9.2", | ||||||
|  |             "resolved": "https://registry.npmjs.org/synckit/-/synckit-0.9.2.tgz", | ||||||
|  |             "integrity": "sha512-vrozgXDQwYO72vHjUb/HnFbQx1exDjoKzqx23aXEg2a9VIg2TSFZ8FmeZpTjUCFMYw7mpX4BE2SFu8wI7asYsw==", | ||||||
|  |             "dev": true, | ||||||
|  |             "license": "MIT", | ||||||
|  |             "dependencies": { | ||||||
|  |                 "@pkgr/core": "^0.1.0", | ||||||
|  |                 "tslib": "^2.6.2" | ||||||
|  |             }, | ||||||
|  |             "engines": { | ||||||
|  |                 "node": "^14.18.0 || >=16.0.0" | ||||||
|  |             }, | ||||||
|  |             "funding": { | ||||||
|  |                 "url": "https://opencollective.com/unts" | ||||||
|  |             } | ||||||
|  |         }, | ||||||
|         "node_modules/tapable": { |         "node_modules/tapable": { | ||||||
|             "version": "2.2.1", |             "version": "2.2.1", | ||||||
|             "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.2.1.tgz", |             "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.2.1.tgz", | ||||||
|   | |||||||
| @@ -140,6 +140,7 @@ | |||||||
|         "@types/write-file-atomic": "^4.0.3", |         "@types/write-file-atomic": "^4.0.3", | ||||||
|         "@types/yargs": "^17.0.33", |         "@types/yargs": "^17.0.33", | ||||||
|         "@types/yauzl": "^2.10.3", |         "@types/yauzl": "^2.10.3", | ||||||
|         "eslint": "^8.57.1" |         "eslint": "^8.57.1", | ||||||
|  |         "eslint-plugin-jsdoc": "^50.6.8" | ||||||
|     } |     } | ||||||
| } | } | ||||||
|   | |||||||
| @@ -3,10 +3,8 @@ import { debounce, escapeRegex } from '../utils.js'; | |||||||
| import { AutoCompleteOption } from './AutoCompleteOption.js'; | import { AutoCompleteOption } from './AutoCompleteOption.js'; | ||||||
| import { AutoCompleteFuzzyScore } from './AutoCompleteFuzzyScore.js'; | import { AutoCompleteFuzzyScore } from './AutoCompleteFuzzyScore.js'; | ||||||
| import { BlankAutoCompleteOption } from './BlankAutoCompleteOption.js'; | import { BlankAutoCompleteOption } from './BlankAutoCompleteOption.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { AutoCompleteNameResult } from './AutoCompleteNameResult.js'; | import { AutoCompleteNameResult } from './AutoCompleteNameResult.js'; | ||||||
| import { AutoCompleteSecondaryNameResult } from './AutoCompleteSecondaryNameResult.js'; | import { AutoCompleteSecondaryNameResult } from './AutoCompleteSecondaryNameResult.js'; | ||||||
| import { Popup, getTopmostModalLayer } from '../popup.js'; |  | ||||||
|  |  | ||||||
| /**@readonly*/ | /**@readonly*/ | ||||||
| /**@enum {Number}*/ | /**@enum {Number}*/ | ||||||
|   | |||||||
| @@ -1,4 +1,3 @@ | |||||||
| import { SlashCommandNamedArgumentAutoCompleteOption } from '../slash-commands/SlashCommandNamedArgumentAutoCompleteOption.js'; |  | ||||||
| import { AutoCompleteOption } from './AutoCompleteOption.js'; | import { AutoCompleteOption } from './AutoCompleteOption.js'; | ||||||
|  |  | ||||||
|  |  | ||||||
|   | |||||||
| @@ -1,4 +1,3 @@ | |||||||
| import { SlashCommand } from '../slash-commands/SlashCommand.js'; |  | ||||||
| import { AutoCompleteFuzzyScore } from './AutoCompleteFuzzyScore.js'; | import { AutoCompleteFuzzyScore } from './AutoCompleteFuzzyScore.js'; | ||||||
|  |  | ||||||
|  |  | ||||||
|   | |||||||
| @@ -1,10 +1,7 @@ | |||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReply } from '../src/QuickReply.js'; | import { QuickReply } from '../src/QuickReply.js'; | ||||||
| import { QuickReplyContextLink } from '../src/QuickReplyContextLink.js'; | import { QuickReplyContextLink } from '../src/QuickReplyContextLink.js'; | ||||||
| import { QuickReplySet } from '../src/QuickReplySet.js'; | import { QuickReplySet } from '../src/QuickReplySet.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReplySettings } from '../src/QuickReplySettings.js'; | import { QuickReplySettings } from '../src/QuickReplySettings.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { SettingsUi } from '../src/ui/SettingsUi.js'; | import { SettingsUi } from '../src/ui/SettingsUi.js'; | ||||||
| import { onlyUnique } from '../../../utils.js'; | import { onlyUnique } from '../../../utils.js'; | ||||||
|  |  | ||||||
|   | |||||||
| @@ -1,7 +1,5 @@ | |||||||
| import { warn } from '../index.js'; | import { warn } from '../index.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReply } from './QuickReply.js'; | import { QuickReply } from './QuickReply.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReplySettings } from './QuickReplySettings.js'; | import { QuickReplySettings } from './QuickReplySettings.js'; | ||||||
|  |  | ||||||
| export class AutoExecuteHandler { | export class AutoExecuteHandler { | ||||||
|   | |||||||
| @@ -635,7 +635,6 @@ export class QuickReply { | |||||||
|             }, { passive:true }); |             }, { passive:true }); | ||||||
|             const getLineStart = ()=>{ |             const getLineStart = ()=>{ | ||||||
|                 const start = message.selectionStart; |                 const start = message.selectionStart; | ||||||
|                 const end = message.selectionEnd; |  | ||||||
|                 let lineStart; |                 let lineStart; | ||||||
|                 if (start == 0 || message.value[start - 1] == '\n') { |                 if (start == 0 || message.value[start - 1] == '\n') { | ||||||
|                     // cursor is already at beginning of line |                     // cursor is already at beginning of line | ||||||
| @@ -701,7 +700,6 @@ export class QuickReply { | |||||||
|                 } else if (evt.key == 'Enter' && !evt.ctrlKey && !evt.shiftKey && !evt.altKey && !(ac.isReplaceable && ac.isActive)) { |                 } else if (evt.key == 'Enter' && !evt.ctrlKey && !evt.shiftKey && !evt.altKey && !(ac.isReplaceable && ac.isActive)) { | ||||||
|                     // new line, keep indent |                     // new line, keep indent | ||||||
|                     const start = message.selectionStart; |                     const start = message.selectionStart; | ||||||
|                     const end = message.selectionEnd; |  | ||||||
|                     let lineStart = getLineStart(); |                     let lineStart = getLineStart(); | ||||||
|                     const indent = /^([^\S\n]*)/.exec(message.value.slice(lineStart))[1] ?? ''; |                     const indent = /^([^\S\n]*)/.exec(message.value.slice(lineStart))[1] ?? ''; | ||||||
|                     if (indent.length) { |                     if (indent.length) { | ||||||
|   | |||||||
| @@ -8,7 +8,6 @@ import { SlashCommandEnumValue, enumTypes } from '../../../slash-commands/SlashC | |||||||
| import { SlashCommandParser } from '../../../slash-commands/SlashCommandParser.js'; | import { SlashCommandParser } from '../../../slash-commands/SlashCommandParser.js'; | ||||||
| import { SlashCommandScope } from '../../../slash-commands/SlashCommandScope.js'; | import { SlashCommandScope } from '../../../slash-commands/SlashCommandScope.js'; | ||||||
| import { isTrueBoolean } from '../../../utils.js'; | import { isTrueBoolean } from '../../../utils.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReplyApi } from '../api/QuickReplyApi.js'; | import { QuickReplyApi } from '../api/QuickReplyApi.js'; | ||||||
| import { QuickReply } from './QuickReply.js'; | import { QuickReply } from './QuickReply.js'; | ||||||
| import { QuickReplySet } from './QuickReplySet.js'; | import { QuickReplySet } from './QuickReplySet.js'; | ||||||
|   | |||||||
| @@ -1,7 +1,6 @@ | |||||||
| import { animation_duration } from '../../../../../script.js'; | import { animation_duration } from '../../../../../script.js'; | ||||||
| import { dragElement } from '../../../../RossAscends-mods.js'; | import { dragElement } from '../../../../RossAscends-mods.js'; | ||||||
| import { loadMovingUIState } from '../../../../power-user.js'; | import { loadMovingUIState } from '../../../../power-user.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReplySettings } from '../QuickReplySettings.js'; | import { QuickReplySettings } from '../QuickReplySettings.js'; | ||||||
|  |  | ||||||
| export class ButtonUi { | export class ButtonUi { | ||||||
|   | |||||||
| @@ -3,7 +3,6 @@ import { getSortableDelay } from '../../../../utils.js'; | |||||||
| import { log, warn } from '../../index.js'; | import { log, warn } from '../../index.js'; | ||||||
| import { QuickReply } from '../QuickReply.js'; | import { QuickReply } from '../QuickReply.js'; | ||||||
| import { QuickReplySet } from '../QuickReplySet.js'; | import { QuickReplySet } from '../QuickReplySet.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReplySettings } from '../QuickReplySettings.js'; | import { QuickReplySettings } from '../QuickReplySettings.js'; | ||||||
|  |  | ||||||
| export class SettingsUi { | export class SettingsUi { | ||||||
|   | |||||||
| @@ -1,5 +1,4 @@ | |||||||
| import { QuickReply } from '../../QuickReply.js'; | import { QuickReply } from '../../QuickReply.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { QuickReplySet } from '../../QuickReplySet.js'; | import { QuickReplySet } from '../../QuickReplySet.js'; | ||||||
| import { MenuHeader } from './MenuHeader.js'; | import { MenuHeader } from './MenuHeader.js'; | ||||||
| import { MenuItem } from './MenuItem.js'; | import { MenuItem } from './MenuItem.js'; | ||||||
|   | |||||||
| @@ -183,8 +183,6 @@ class GptSovitsV2Provider { | |||||||
|  |  | ||||||
|         let prompt_text = replaceSpeaker(voiceId); |         let prompt_text = replaceSpeaker(voiceId); | ||||||
|  |  | ||||||
|         const streaming = this.settings.streaming; |  | ||||||
|  |  | ||||||
|         const params = { |         const params = { | ||||||
|             text: inputText, |             text: inputText, | ||||||
|             prompt_text: prompt_text, |             prompt_text: prompt_text, | ||||||
|   | |||||||
| @@ -795,6 +795,7 @@ export function parseNovelAILogprobs(data) { | |||||||
|  |  | ||||||
|     // Add the chosen token to `merged` if it's not already there. This can |     // Add the chosen token to `merged` if it's not already there. This can | ||||||
|     // happen if the chosen token was not among the top 10 most likely ones. |     // happen if the chosen token was not among the top 10 most likely ones. | ||||||
|  |     // eslint-disable-next-line no-unused-vars | ||||||
|     const [[chosenId], [_, chosenAfter]] = data.chosen[0]; |     const [[chosenId], [_, chosenAfter]] = data.chosen[0]; | ||||||
|     if (!merged.some(([id]) => id === chosenId)) { |     if (!merged.some(([id]) => id === chosenId)) { | ||||||
|         merged.push([chosenId, chosenAfter]); |         merged.push([chosenId, chosenAfter]); | ||||||
|   | |||||||
| @@ -3,16 +3,16 @@ import { SlashCommandAbortController } from './SlashCommandAbortController.js'; | |||||||
| import { SlashCommandArgument, SlashCommandNamedArgument } from './SlashCommandArgument.js'; | import { SlashCommandArgument, SlashCommandNamedArgument } from './SlashCommandArgument.js'; | ||||||
| import { SlashCommandClosure } from './SlashCommandClosure.js'; | import { SlashCommandClosure } from './SlashCommandClosure.js'; | ||||||
| import { SlashCommandDebugController } from './SlashCommandDebugController.js'; | import { SlashCommandDebugController } from './SlashCommandDebugController.js'; | ||||||
| import { PARSER_FLAG } from './SlashCommandParser.js'; |  | ||||||
| import { SlashCommandScope } from './SlashCommandScope.js'; | import { SlashCommandScope } from './SlashCommandScope.js'; | ||||||
|  |  | ||||||
|  | /** | ||||||
|  |  * @typedef {import('./SlashCommandParser.js').ParserFlags} ParserFlags | ||||||
|  |  */ | ||||||
|  |  | ||||||
| /** | /** | ||||||
|  * @typedef {{ |  * @typedef {{ | ||||||
|  * _scope:SlashCommandScope, |  * _scope:SlashCommandScope, | ||||||
|  * _parserFlags:{[id:PARSER_FLAG]:boolean}, |  * _parserFlags:{ParserFlags}, | ||||||
|  * _abortController:SlashCommandAbortController, |  * _abortController:SlashCommandAbortController, | ||||||
|  * _debugController:SlashCommandDebugController, |  * _debugController:SlashCommandDebugController, | ||||||
|  * _hasUnnamedArgument:boolean, |  * _hasUnnamedArgument:boolean, | ||||||
|   | |||||||
| @@ -1,9 +1,6 @@ | |||||||
| import { AutoCompleteNameResult } from '../autocomplete/AutoCompleteNameResult.js'; | import { AutoCompleteNameResult } from '../autocomplete/AutoCompleteNameResult.js'; | ||||||
| import { AutoCompleteOption } from '../autocomplete/AutoCompleteOption.js'; |  | ||||||
| import { AutoCompleteSecondaryNameResult } from '../autocomplete/AutoCompleteSecondaryNameResult.js'; | import { AutoCompleteSecondaryNameResult } from '../autocomplete/AutoCompleteSecondaryNameResult.js'; | ||||||
| import { SlashCommand } from './SlashCommand.js'; | import { SlashCommand } from './SlashCommand.js'; | ||||||
| import { SlashCommandNamedArgument } from './SlashCommandArgument.js'; |  | ||||||
| import { SlashCommandClosure } from './SlashCommandClosure.js'; |  | ||||||
| import { SlashCommandCommandAutoCompleteOption } from './SlashCommandCommandAutoCompleteOption.js'; | import { SlashCommandCommandAutoCompleteOption } from './SlashCommandCommandAutoCompleteOption.js'; | ||||||
| import { SlashCommandEnumAutoCompleteOption } from './SlashCommandEnumAutoCompleteOption.js'; | import { SlashCommandEnumAutoCompleteOption } from './SlashCommandEnumAutoCompleteOption.js'; | ||||||
| import { SlashCommandExecutor } from './SlashCommandExecutor.js'; | import { SlashCommandExecutor } from './SlashCommandExecutor.js'; | ||||||
|   | |||||||
| @@ -2,7 +2,6 @@ import { substituteParams } from '../../script.js'; | |||||||
| import { delay, escapeRegex, uuidv4 } from '../utils.js'; | import { delay, escapeRegex, uuidv4 } from '../utils.js'; | ||||||
| import { SlashCommand } from './SlashCommand.js'; | import { SlashCommand } from './SlashCommand.js'; | ||||||
| import { SlashCommandAbortController } from './SlashCommandAbortController.js'; | import { SlashCommandAbortController } from './SlashCommandAbortController.js'; | ||||||
| import { SlashCommandNamedArgument } from './SlashCommandArgument.js'; |  | ||||||
| import { SlashCommandBreak } from './SlashCommandBreak.js'; | import { SlashCommandBreak } from './SlashCommandBreak.js'; | ||||||
| import { SlashCommandBreakController } from './SlashCommandBreakController.js'; | import { SlashCommandBreakController } from './SlashCommandBreakController.js'; | ||||||
| import { SlashCommandBreakPoint } from './SlashCommandBreakPoint.js'; | import { SlashCommandBreakPoint } from './SlashCommandBreakPoint.js'; | ||||||
| @@ -16,9 +15,7 @@ import { SlashCommandScope } from './SlashCommandScope.js'; | |||||||
| export class SlashCommandClosure { | export class SlashCommandClosure { | ||||||
|     /** @type {SlashCommandScope} */ scope; |     /** @type {SlashCommandScope} */ scope; | ||||||
|     /** @type {boolean} */ executeNow = false; |     /** @type {boolean} */ executeNow = false; | ||||||
|     // @ts-ignore |  | ||||||
|     /** @type {SlashCommandNamedArgumentAssignment[]} */ argumentList = []; |     /** @type {SlashCommandNamedArgumentAssignment[]} */ argumentList = []; | ||||||
|     // @ts-ignore |  | ||||||
|     /** @type {SlashCommandNamedArgumentAssignment[]} */ providedArgumentList = []; |     /** @type {SlashCommandNamedArgumentAssignment[]} */ providedArgumentList = []; | ||||||
|     /** @type {SlashCommandExecutor[]} */ executorList = []; |     /** @type {SlashCommandExecutor[]} */ executorList = []; | ||||||
|     /** @type {SlashCommandAbortController} */ abortController; |     /** @type {SlashCommandAbortController} */ abortController; | ||||||
|   | |||||||
| @@ -1,7 +1,3 @@ | |||||||
| import { SlashCommandExecutor } from './SlashCommandExecutor.js'; |  | ||||||
| import { SlashCommandScope } from './SlashCommandScope.js'; |  | ||||||
|  |  | ||||||
|  |  | ||||||
| /** | /** | ||||||
|  * @typedef {'enum' | 'command' | 'namedArgument' | 'variable' | 'qr' | 'macro' | 'number' | 'name'} EnumType |  * @typedef {'enum' | 'command' | 'namedArgument' | 'variable' | 'qr' | 'macro' | 'number' | 'name'} EnumType | ||||||
|  */ |  */ | ||||||
|   | |||||||
| @@ -1,11 +1,7 @@ | |||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { uuidv4 } from '../utils.js'; | import { uuidv4 } from '../utils.js'; | ||||||
| import { SlashCommand } from './SlashCommand.js'; | import { SlashCommand } from './SlashCommand.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { SlashCommandClosure } from './SlashCommandClosure.js'; | import { SlashCommandClosure } from './SlashCommandClosure.js'; | ||||||
| import { SlashCommandNamedArgumentAssignment } from './SlashCommandNamedArgumentAssignment.js'; | import { SlashCommandNamedArgumentAssignment } from './SlashCommandNamedArgumentAssignment.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { PARSER_FLAG } from './SlashCommandParser.js'; |  | ||||||
| import { SlashCommandUnnamedArgumentAssignment } from './SlashCommandUnnamedArgumentAssignment.js'; | import { SlashCommandUnnamedArgumentAssignment } from './SlashCommandUnnamedArgumentAssignment.js'; | ||||||
|  |  | ||||||
| export class SlashCommandExecutor { | export class SlashCommandExecutor { | ||||||
| @@ -29,10 +25,9 @@ export class SlashCommandExecutor { | |||||||
|         } |         } | ||||||
|     } |     } | ||||||
|     /** @type {SlashCommand} */ command; |     /** @type {SlashCommand} */ command; | ||||||
|     // @ts-ignore |  | ||||||
|     /** @type {SlashCommandNamedArgumentAssignment[]} */ namedArgumentList = []; |     /** @type {SlashCommandNamedArgumentAssignment[]} */ namedArgumentList = []; | ||||||
|     /** @type {SlashCommandUnnamedArgumentAssignment[]} */ unnamedArgumentList = []; |     /** @type {SlashCommandUnnamedArgumentAssignment[]} */ unnamedArgumentList = []; | ||||||
|     /**@type {{[id:PARSER_FLAG]:boolean}} */ parserFlags; |     /** @type {import('./SlashCommandParser.js').ParserFlags} */ parserFlags; | ||||||
|  |  | ||||||
|     get commandCount() { |     get commandCount() { | ||||||
|         return 1 |         return 1 | ||||||
|   | |||||||
| @@ -1,7 +1,6 @@ | |||||||
| import { AutoCompleteOption } from '../autocomplete/AutoCompleteOption.js'; | import { AutoCompleteOption } from '../autocomplete/AutoCompleteOption.js'; | ||||||
| import { SlashCommand } from './SlashCommand.js'; | import { SlashCommand } from './SlashCommand.js'; | ||||||
| import { SlashCommandNamedArgument } from './SlashCommandArgument.js'; | import { SlashCommandNamedArgument } from './SlashCommandArgument.js'; | ||||||
| import { SlashCommandNamedArgumentAssignment } from './SlashCommandNamedArgumentAssignment.js'; |  | ||||||
|  |  | ||||||
| export class SlashCommandNamedArgumentAutoCompleteOption extends AutoCompleteOption { | export class SlashCommandNamedArgumentAutoCompleteOption extends AutoCompleteOption { | ||||||
|     /** @type {SlashCommandNamedArgument} */ arg; |     /** @type {SlashCommandNamedArgument} */ arg; | ||||||
|   | |||||||
| @@ -8,11 +8,9 @@ import { SlashCommandExecutor } from './SlashCommandExecutor.js'; | |||||||
| import { SlashCommandParserError } from './SlashCommandParserError.js'; | import { SlashCommandParserError } from './SlashCommandParserError.js'; | ||||||
| import { AutoCompleteNameResult } from '../autocomplete/AutoCompleteNameResult.js'; | import { AutoCompleteNameResult } from '../autocomplete/AutoCompleteNameResult.js'; | ||||||
| import { SlashCommandQuickReplyAutoCompleteOption } from './SlashCommandQuickReplyAutoCompleteOption.js'; | import { SlashCommandQuickReplyAutoCompleteOption } from './SlashCommandQuickReplyAutoCompleteOption.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { SlashCommandScope } from './SlashCommandScope.js'; | import { SlashCommandScope } from './SlashCommandScope.js'; | ||||||
| import { SlashCommandVariableAutoCompleteOption } from './SlashCommandVariableAutoCompleteOption.js'; | import { SlashCommandVariableAutoCompleteOption } from './SlashCommandVariableAutoCompleteOption.js'; | ||||||
| import { SlashCommandNamedArgumentAssignment } from './SlashCommandNamedArgumentAssignment.js'; | import { SlashCommandNamedArgumentAssignment } from './SlashCommandNamedArgumentAssignment.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { SlashCommandAbortController } from './SlashCommandAbortController.js'; | import { SlashCommandAbortController } from './SlashCommandAbortController.js'; | ||||||
| import { SlashCommandAutoCompleteNameResult } from './SlashCommandAutoCompleteNameResult.js'; | import { SlashCommandAutoCompleteNameResult } from './SlashCommandAutoCompleteNameResult.js'; | ||||||
| import { SlashCommandUnnamedArgumentAssignment } from './SlashCommandUnnamedArgumentAssignment.js'; | import { SlashCommandUnnamedArgumentAssignment } from './SlashCommandUnnamedArgumentAssignment.js'; | ||||||
| @@ -28,15 +26,17 @@ import { t } from '../i18n.js'; | |||||||
| /** @typedef {import('./SlashCommand.js').NamedArgumentsCapture} NamedArgumentsCapture */ | /** @typedef {import('./SlashCommand.js').NamedArgumentsCapture} NamedArgumentsCapture */ | ||||||
| /** @typedef {import('./SlashCommand.js').NamedArguments} NamedArguments */ | /** @typedef {import('./SlashCommand.js').NamedArguments} NamedArguments */ | ||||||
|  |  | ||||||
| /**@readonly*/ | /** | ||||||
| /**@enum {Number}*/ |  * @enum {Number} | ||||||
|  |  * @readonly | ||||||
|  |  * @typedef {{[id:PARSER_FLAG]:boolean}} ParserFlags | ||||||
|  |  */ | ||||||
| export const PARSER_FLAG = { | export const PARSER_FLAG = { | ||||||
|     'STRICT_ESCAPING': 1, |     'STRICT_ESCAPING': 1, | ||||||
|     'REPLACE_GETVAR': 2, |     'REPLACE_GETVAR': 2, | ||||||
| }; | }; | ||||||
|  |  | ||||||
| export class SlashCommandParser { | export class SlashCommandParser { | ||||||
|     // @ts-ignore |  | ||||||
|     /** @type {Object.<string, SlashCommand>} */ static commands = {}; |     /** @type {Object.<string, SlashCommand>} */ static commands = {}; | ||||||
|  |  | ||||||
|     /** |     /** | ||||||
| @@ -101,7 +101,6 @@ export class SlashCommandParser { | |||||||
|     get commands() { |     get commands() { | ||||||
|         return SlashCommandParser.commands; |         return SlashCommandParser.commands; | ||||||
|     } |     } | ||||||
|     // @ts-ignore |  | ||||||
|     /** @type {Object.<string, string>} */ helpStrings = {}; |     /** @type {Object.<string, string>} */ helpStrings = {}; | ||||||
|     /** @type {boolean} */ verifyCommandNames = true; |     /** @type {boolean} */ verifyCommandNames = true; | ||||||
|     /** @type {string} */ text; |     /** @type {string} */ text; | ||||||
|   | |||||||
| @@ -13,7 +13,6 @@ import { | |||||||
|     DEFAULT_PRINT_TIMEOUT, |     DEFAULT_PRINT_TIMEOUT, | ||||||
|     printCharacters, |     printCharacters, | ||||||
| } from '../script.js'; | } from '../script.js'; | ||||||
| // eslint-disable-next-line no-unused-vars |  | ||||||
| import { FILTER_TYPES, FILTER_STATES, DEFAULT_FILTER_STATE, isFilterState, FilterHelper } from './filters.js'; | import { FILTER_TYPES, FILTER_STATES, DEFAULT_FILTER_STATE, isFilterState, FilterHelper } from './filters.js'; | ||||||
|  |  | ||||||
| import { groupCandidatesFilter, groups, selected_group } from './group-chats.js'; | import { groupCandidatesFilter, groups, selected_group } from './group-chats.js'; | ||||||
|   | |||||||
| @@ -9,7 +9,7 @@ import { SlashCommandClosure } from './slash-commands/SlashCommandClosure.js'; | |||||||
| import { SlashCommandClosureResult } from './slash-commands/SlashCommandClosureResult.js'; | import { SlashCommandClosureResult } from './slash-commands/SlashCommandClosureResult.js'; | ||||||
| import { commonEnumProviders, enumIcons } from './slash-commands/SlashCommandCommonEnumsProvider.js'; | import { commonEnumProviders, enumIcons } from './slash-commands/SlashCommandCommonEnumsProvider.js'; | ||||||
| import { SlashCommandEnumValue, enumTypes } from './slash-commands/SlashCommandEnumValue.js'; | import { SlashCommandEnumValue, enumTypes } from './slash-commands/SlashCommandEnumValue.js'; | ||||||
| import { PARSER_FLAG, SlashCommandParser } from './slash-commands/SlashCommandParser.js'; | import { SlashCommandParser } from './slash-commands/SlashCommandParser.js'; | ||||||
| import { slashCommandReturnHelper } from './slash-commands/SlashCommandReturnHelper.js'; | import { slashCommandReturnHelper } from './slash-commands/SlashCommandReturnHelper.js'; | ||||||
| import { SlashCommandScope } from './slash-commands/SlashCommandScope.js'; | import { SlashCommandScope } from './slash-commands/SlashCommandScope.js'; | ||||||
| import { isFalseBoolean, convertValueType, isTrueBoolean } from './utils.js'; | import { isFalseBoolean, convertValueType, isTrueBoolean } from './utils.js'; | ||||||
| @@ -583,7 +583,7 @@ export function evalBoolean(rule, a, b) { | |||||||
|  * Executes a slash command from a string (may be enclosed in quotes) and returns the result. |  * Executes a slash command from a string (may be enclosed in quotes) and returns the result. | ||||||
|  * @param {string} command Command to execute. May contain escaped macro and batch separators. |  * @param {string} command Command to execute. May contain escaped macro and batch separators. | ||||||
|  * @param {SlashCommandScope} [scope] The scope to use. |  * @param {SlashCommandScope} [scope] The scope to use. | ||||||
|  * @param {{[id:PARSER_FLAG]:boolean}} [parserFlags] The parser flags to use. |  * @param {import('./slash-commands/SlashCommandParser.js').ParserFlags} [parserFlags] The parser flags to use. | ||||||
|  * @param {SlashCommandAbortController} [abortController] The abort controller to use. |  * @param {SlashCommandAbortController} [abortController] The abort controller to use. | ||||||
|  * @returns {Promise<SlashCommandClosureResult>} Closure execution result |  * @returns {Promise<SlashCommandClosureResult>} Closure execution result | ||||||
|  */ |  */ | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user