Enable Typescript noImplicitThis
(#33250)
- Enable https://www.typescriptlang.org/tsconfig/#noImplicitThis - Wrap Vue Template-Syntax SFCs in [`defineComponent`](https://vuejs.org/api/general#definecomponent) which makes type inference and linter work better - Move `createApp` calls outside the SFCs into separate files - Use [`PropType`](https://vuejs.org/api/utility-types#proptype-t) where appropriate - Some top-level component properties changed order as dictated by the linter - Fix all tsc and lint issues that popped up during these refactors
This commit is contained in:
parent
b15d01b0ce
commit
4b21a6c792
29 changed files with 209 additions and 190 deletions
|
@ -27,7 +27,7 @@ function initPreInstall() {
|
|||
const dbName = document.querySelector<HTMLInputElement>('#db_name');
|
||||
|
||||
// Database type change detection.
|
||||
document.querySelector('#db_type').addEventListener('change', function () {
|
||||
document.querySelector<HTMLInputElement>('#db_type').addEventListener('change', function () {
|
||||
const dbType = this.value;
|
||||
hideElem('div[data-db-setting-for]');
|
||||
showElem(`div[data-db-setting-for=${dbType}]`);
|
||||
|
@ -59,26 +59,26 @@ function initPreInstall() {
|
|||
}
|
||||
|
||||
// TODO: better handling of exclusive relations.
|
||||
document.querySelector('#offline-mode input').addEventListener('change', function () {
|
||||
document.querySelector<HTMLInputElement>('#offline-mode input').addEventListener('change', function () {
|
||||
if (this.checked) {
|
||||
document.querySelector<HTMLInputElement>('#disable-gravatar input').checked = true;
|
||||
document.querySelector<HTMLInputElement>('#federated-avatar-lookup input').checked = false;
|
||||
}
|
||||
});
|
||||
document.querySelector('#disable-gravatar input').addEventListener('change', function () {
|
||||
document.querySelector<HTMLInputElement>('#disable-gravatar input').addEventListener('change', function () {
|
||||
if (this.checked) {
|
||||
document.querySelector<HTMLInputElement>('#federated-avatar-lookup input').checked = false;
|
||||
} else {
|
||||
document.querySelector<HTMLInputElement>('#offline-mode input').checked = false;
|
||||
}
|
||||
});
|
||||
document.querySelector('#federated-avatar-lookup input').addEventListener('change', function () {
|
||||
document.querySelector<HTMLInputElement>('#federated-avatar-lookup input').addEventListener('change', function () {
|
||||
if (this.checked) {
|
||||
document.querySelector<HTMLInputElement>('#disable-gravatar input').checked = false;
|
||||
document.querySelector<HTMLInputElement>('#offline-mode input').checked = false;
|
||||
}
|
||||
});
|
||||
document.querySelector('#enable-openid-signin input').addEventListener('change', function () {
|
||||
document.querySelector<HTMLInputElement>('#enable-openid-signin input').addEventListener('change', function () {
|
||||
if (this.checked) {
|
||||
if (!document.querySelector<HTMLInputElement>('#disable-registration input').checked) {
|
||||
document.querySelector<HTMLInputElement>('#enable-openid-signup input').checked = true;
|
||||
|
@ -87,7 +87,7 @@ function initPreInstall() {
|
|||
document.querySelector<HTMLInputElement>('#enable-openid-signup input').checked = false;
|
||||
}
|
||||
});
|
||||
document.querySelector('#disable-registration input').addEventListener('change', function () {
|
||||
document.querySelector<HTMLInputElement>('#disable-registration input').addEventListener('change', function () {
|
||||
if (this.checked) {
|
||||
document.querySelector<HTMLInputElement>('#enable-captcha input').checked = false;
|
||||
document.querySelector<HTMLInputElement>('#enable-openid-signup input').checked = false;
|
||||
|
@ -95,7 +95,7 @@ function initPreInstall() {
|
|||
document.querySelector<HTMLInputElement>('#enable-openid-signup input').checked = true;
|
||||
}
|
||||
});
|
||||
document.querySelector('#enable-captcha input').addEventListener('change', function () {
|
||||
document.querySelector<HTMLInputElement>('#enable-captcha input').addEventListener('change', function () {
|
||||
if (this.checked) {
|
||||
document.querySelector<HTMLInputElement>('#disable-registration input').checked = false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue