Fix register sentense string

See https://framacolibri.org/t/sinscrire-sur-mobilizon-affiche-au-lieu-du-nom-de-linstance/9838

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2020-11-17 10:57:04 +01:00
parent 15fe86b176
commit 5d9a36917d
5 changed files with 26 additions and 7 deletions

View File

@@ -156,7 +156,9 @@ import AuthProviders from "../../components/User/AuthProviders.vue";
metaInfo() {
return {
// if no subcomponents specify a metaInfo.title, this title will be used
title: this.$t("Register an account on Mobilizon!") as string,
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore
title: this.title,
// all titles will be injected into this template
titleTemplate: "%s | Mobilizon",
};
@@ -184,6 +186,15 @@ export default class Register extends Vue {
config!: IConfig;
get title(): string {
if (this.config) {
return this.$t("Register an account on {instanceName}!", {
instanceName: this.config.name,
}) as string;
}
return "";
}
async submit(): Promise<void> {
this.sendingForm = true;
this.credentials.locale = this.$i18n.locale;