add more visibility for invite JWT plus a check for JWT, bump version to 0.3.42

This commit is contained in:
2024-12-27 09:06:25 -07:00
parent 4641c46ab2
commit 8cadfb15dd
5 changed files with 46 additions and 8 deletions

View File

@@ -7,12 +7,18 @@
Go back to your invite message and copy the entire text, then paste it
here.
</p>
<input
<p class="mt-2">
If the link looks correct, try Chrome. (For example, iOS Safari does not
work well with the invite link.)
</p>
<textarea
v-model="inputJwt"
type="text"
placeholder="Paste invitation..."
class="mt-4 border-2 border-gray-300 p-2 rounded"
cols="40"
@input="() => checkInvite(inputJwt)"
/>
<br />
<button
@click="() => processInvite(inputJwt, true)"
class="ml-2 p-2 bg-blue-500 text-white rounded"
@@ -134,5 +140,23 @@ export default class InviteOneAcceptView extends Vue {
}
this.checkingInvite = false;
}
// check the invite JWT
async checkInvite(jwtInput: string) {
if (
jwtInput.endsWith("invite-one-accept") ||
jwtInput.endsWith("invite-one-accept/")
) {
this.$notify(
{
group: "alert",
type: "danger",
title: "Error",
text: "That is only part of the invite link; it's missing data at the end. Try another way to get the full link.",
},
5000,
);
}
}
}
</script>