Translate new tiles in profile page

This commit is contained in:
Florian Dupret 2021-05-07 09:05:44 +02:00
commit a0170d1e8e
3 changed files with 37 additions and 22 deletions

View file

@ -9,6 +9,7 @@
"api-port": "API Port",
"application-mode": "Application Mode",
"database-type": "Database Type",
"database-url": "Database URL",
"default-group": "Default Group",
"demo": "Demo",
"demo-status": "Demo Status",
@ -17,18 +18,17 @@
"download-recipe-json": "Last Scraped JSON",
"not-demo": "Not Demo",
"production": "Production",
"database-url": "Database URL",
"version": "Version"
},
"category": {
"category": "Category",
"category-created": "Category created",
"category-creation-failed": "Category creation failed",
"category-deleted": "Category Deleted",
"category-deletion-failed": "Category deletion failed",
"category-filter": "Category Filter",
"category-update-failed": "Category update failed",
"category-updated": "Category updated",
"category": "Category"
"category-updated": "Category updated"
},
"general": {
"apply": "Apply",
@ -61,11 +61,12 @@
"link": "Link",
"monday": "Monday",
"name": "Name",
"new": "New",
"no": "No",
"ok": "OK",
"options": "Options:",
"rating": "Rating",
"random": "Random",
"rating": "Rating",
"recent": "Recent",
"recipes": "Recipes",
"rename-object": "Rename {0}",
@ -73,13 +74,13 @@
"saturday": "Saturday",
"save": "Save",
"settings": "Settings",
"shuffle": "Shuffle",
"sort": "Sort",
"sort-alphabetically": "Alphabetical",
"status": "Status",
"submit": "Submit",
"success-count": "Success: {count}",
"sunday": "Sunday",
"shuffle": "Shuffle",
"templates": "Templates:",
"themes": "Themes",
"thursday": "Thursday",
@ -116,15 +117,18 @@
"create-a-new-meal-plan": "Create a New Meal Plan",
"dinner-this-week": "Dinner This Week",
"dinner-today": "Dinner Today",
"dinner-tonight": "DINNER TONIGHT",
"edit-meal-plan": "Edit Meal Plan",
"end-date": "End Date",
"group": "Group (Beta)",
"meal-planner": "Meal Planner",
"meal-plans": "Meal Plans",
"mealplan-categories": "MEALPLAN CATEGORIES",
"mealplan-created": "Mealplan created",
"mealplan-creation-failed": "Mealplan creation failed",
"mealplan-deleted": "Mealplan Deleted",
"mealplan-deletion-failed": "Mealplan deletion failed",
"mealplan-settings": "Mealplan Settings",
"mealplan-update-failed": "Mealplan update failed",
"mealplan-updated": "Mealplan Updated",
"no-meal-plan-defined-yet": "No meal plan defined yet",
@ -305,6 +309,14 @@
"theme-updated": "Theme updated",
"warning": "Warning"
},
"token": {
"active-tokens": "ACTIVE TOKENS",
"api-token": "API Token",
"api-tokens": "API Tokens",
"copy-this-token-for-use-with-an-external-application-this-token-will-not-be-viewable-again": "Copy this token for use with an external application. This token will not be viewable again.",
"create-an-api-token": "Create an API Token",
"token-name": "Token Name"
},
"toolbox": {
"assign-all": "Assign All",
"bulk-assign": "Bulk Assign",
@ -319,7 +331,8 @@
"meal-planner-webhooks": "Meal Planner Webhooks",
"test-webhooks": "Test Webhooks",
"the-urls-listed-below-will-recieve-webhooks-containing-the-recipe-data-for-the-meal-plan-on-its-scheduled-day-currently-webhooks-will-execute-at": "The URLs listed below will receive webhooks containing the recipe data for the meal plan on it's scheduled day. Currently Webhooks will execute at",
"webhook-url": "Webhook URL"
"webhook-url": "Webhook URL",
"webhooks-caps": "WEBHOOKS"
}
},
"signup": {
@ -377,6 +390,7 @@
"total-users": "Total Users",
"upload-photo": "Upload Photo",
"use-8-characters-or-more-for-your-password": "Use 8 characters or more for your password",
"user": "User",
"user-created": "User created",
"user-creation-failed": "User creation failed",
"user-deleted": "User deleted",
@ -390,7 +404,6 @@
"webhook-time": "Webhook Time",
"webhooks-enabled": "Webhooks Enabled",
"you-are-not-allowed-to-create-a-user": "You are not allowed to create a user",
"you-are-not-allowed-to-delete-this-user": "You are not allowed to delete this user",
"user": "User"
"you-are-not-allowed-to-delete-this-user": "You are not allowed to delete this user"
}
}
}

View file

@ -2,14 +2,16 @@
<StatCard icon="mdi-api" color="accent">
<template v-slot:after-heading>
<div class="ml-auto text-right">
<div class="body-3 grey--text font-weight-light" v-text="'API Tokens'" />
<h2 class="body-3 grey--text font-weight-light">
{{$t('settings.token.api-tokens')}}
</h2>
<h3 class="display-2 font-weight-light text--primary">
<small> {{ user.tokens.length }} </small>
</h3>
</div>
</template>
<template v-slot:bottom>
<v-subheader class="mb-n2">ACTIVE TOKENS</v-subheader>
<v-subheader class="mb-n2">{{$t('settings.token.active-tokens')}}</v-subheader>
<v-virtual-scroll height="210" item-height="70" :items="user.tokens" class="mt-2">
<template v-slot:default="{ item }">
<v-divider></v-divider>
@ -38,7 +40,7 @@
<v-card-actions class="pb-1 pt-3">
<v-spacer></v-spacer>
<BaseDialog
:title="'Create an API Token'"
:title="$t('settings.token.create-an-api-token')"
title-icon="mdi-api"
@submit="createToken"
:submit-text="buttonText"
@ -46,13 +48,13 @@
>
<v-card-text>
<v-form ref="newTokenForm">
<v-text-field v-model="name" label="Token Name" required> </v-text-field>
<v-text-field v-model="name" :label="$t('settings.token.token-name')" required> </v-text-field>
</v-form>
<div v-if="createdToken != ''">
<v-textarea
class="mb-0 pb-0"
label="API Token"
:label="$t('settings.token.api-token')"
readonly
v-model="createdToken"
append-outer-icon="mdi-content-copy"
@ -60,7 +62,7 @@
>
</v-textarea>
<v-subheader class="text-center">
Copy this token for use with an external application. This token will not be viewable again.
{{$t('settings.token.copy-this-token-for-use-with-an-external-application-this-token-will-not-be-viewable-again')}}
</v-subheader>
</div>
</v-card-text>
@ -107,9 +109,9 @@ export default {
},
buttonText() {
if (this.createdToken === "") {
return "Create";
return this.$t('general.create');
} else {
return "Close";
return this.$t('general.close');
}
},
},

View file

@ -11,7 +11,7 @@
</template>
<template v-slot:bottom>
<div v-if="todaysMeal">
<v-subheader>DINNER TONIGHT</v-subheader>
<v-subheader>{{$t('meal-plan.dinner-tonight')}}</v-subheader>
<MobileRecipeCard
:name="todaysMeal.name"
:slug="todaysMeal.slug"
@ -48,12 +48,12 @@
<v-icon x-large>
mdi-food-variant
</v-icon>
<small> Mealplan Settings </small>
<small> {{$t('meal-plan.mealplan-settings')}} </small>
</h3>
</div>
<v-divider></v-divider>
<v-subheader>MEALPLAN CATEGORIES</v-subheader>
<v-subheader>{{$t('meal-plan.mealplan-categories')}}</v-subheader>
<v-card-text class="mt-0 pt-0">
{{ $t("meal-plan.only-recipes-with-these-categories-will-be-used-in-meal-plans") }}
</v-card-text>
@ -66,7 +66,7 @@
/>
<v-divider></v-divider>
<v-subheader>WEBHOOKS</v-subheader>
<v-subheader>{{$t('settings.webhooks.webhooks-caps')}}</v-subheader>
<v-card-text class="mt-0 pt-0">
{{
$t(
@ -93,7 +93,7 @@
<v-spacer></v-spacer>
<v-btn small color="success" @click="addWebhook">
<v-icon left> mdi-webhook </v-icon>
New
{{$t('general.new')}}
</v-btn>
</v-card-actions>
</v-card-text>