fixed superuser OTP id input reactivity, enabled truncate dropdown option for system collections, updated jsvm types

This commit is contained in:
Gani Georgiev
2024-11-23 14:12:12 +02:00
parent b34453afc7
commit 2dd4e38e1d
32 changed files with 3027 additions and 2980 deletions
@@ -138,7 +138,7 @@
otpAuthSubmitting = true;
try {
await ApiClient.collection("_superusers").authWithOTP(otpId, otpPassword, { mfaId });
await ApiClient.collection("_superusers").authWithOTP(otpId || lastOTPId, otpPassword, { mfaId });
removeAllToasts();
setErrors({});
replace("/");
@@ -238,7 +238,18 @@
<form class="block" on:submit|preventDefault={authWithOTP}>
<Field class="form-field required" name="otpId" let:uniqueId>
<label for={uniqueId}>Id</label>
<input type="text" id={uniqueId} bind:value={otpId} required />
<input
type="text"
id={uniqueId}
value={otpId}
placeholder={lastOTPId}
on:change={(e) => {
console.log("change");
otpId = e.target.value || lastOTPId;
e.target.value = otpId;
}}
required
/>
</Field>
<Field class="form-field required" name="password" let:uniqueId>