feat: finish new i18n translation format

This commit is contained in:
liyasthomas
2021-08-19 00:10:57 +05:30
parent ceb8bdf0fd
commit c1ce90dad0
66 changed files with 755 additions and 802 deletions

View File

@@ -18,8 +18,14 @@
</template>
<template #footer>
<span>
<ButtonPrimary :label="$t('save')" @click.native="addNewCollection" />
<ButtonSecondary :label="$t('cancel')" @click.native="hideModal" />
<ButtonPrimary
:label="$t('action.save')"
@click.native="addNewCollection"
/>
<ButtonSecondary
:label="$t('action.cancel')"
@click.native="hideModal"
/>
</span>
</template>
</SmartModal>

View File

@@ -22,8 +22,11 @@
</template>
<template #footer>
<span>
<ButtonPrimary :label="$t('save')" @click.native="addFolder" />
<ButtonSecondary :label="$t('cancel')" @click.native="hideModal" />
<ButtonPrimary :label="$t('action.save')" @click.native="addFolder" />
<ButtonSecondary
:label="$t('action.cancel')"
@click.native="hideModal"
/>
</span>
</template>
</SmartModal>

View File

@@ -54,7 +54,7 @@
<template #trigger>
<ButtonSecondary
v-tippy="{ theme: 'tooltip' }"
:title="$t('more')"
:title="$t('action.more')"
icon="more_vert"
/>
</template>
@@ -70,7 +70,7 @@
/>
<SmartItem
icon="create"
:label="$t('edit')"
:label="$t('action.edit')"
@click.native="
$emit('edit-collection')
$refs.options.tippy().hide()
@@ -219,7 +219,7 @@ export default Vue.extend({
}
removeGraphqlCollection(this.collectionIndex)
this.$toast.error(this.$t("deleted").toString(), {
this.$toast.error(this.$t("state.deleted").toString(), {
icon: "delete",
})
},

View File

@@ -18,8 +18,14 @@
</template>
<template #footer>
<span>
<ButtonPrimary :label="$t('save')" @click.native="saveCollection" />
<ButtonSecondary :label="$t('cancel')" @click.native="hideModal" />
<ButtonPrimary
:label="$t('action.save')"
@click.native="saveCollection"
/>
<ButtonSecondary
:label="$t('action.cancel')"
@click.native="hideModal"
/>
</span>
</template>
</SmartModal>

View File

@@ -22,8 +22,11 @@
</template>
<template #footer>
<span>
<ButtonPrimary :label="$t('save')" @click.native="editFolder" />
<ButtonSecondary :label="$t('cancel')" @click.native="hideModal" />
<ButtonPrimary :label="$t('action.save')" @click.native="editFolder" />
<ButtonSecondary
:label="$t('action.cancel')"
@click.native="hideModal"
/>
</span>
</template>
</SmartModal>

View File

@@ -1,5 +1,5 @@
<template>
<SmartModal v-if="show" :title="$t('edit_request')" @close="hideModal">
<SmartModal v-if="show" :title="$t('modal.edit_request')" @close="hideModal">
<template #body>
<div class="flex flex-col px-2">
<input
@@ -18,8 +18,11 @@
</template>
<template #footer>
<span>
<ButtonPrimary :label="$t('save')" @click.native="saveRequest" />
<ButtonSecondary :label="$t('cancel')" @click.native="hideModal" />
<ButtonPrimary :label="$t('action.save')" @click.native="saveRequest" />
<ButtonSecondary
:label="$t('action.cancel')"
@click.native="hideModal"
/>
</span>
</template>
</SmartModal>

View File

@@ -52,7 +52,7 @@
<template #trigger>
<ButtonSecondary
v-tippy="{ theme: 'tooltip' }"
:title="$t('more')"
:title="$t('action.more')"
icon="more_vert"
/>
</template>
@@ -66,7 +66,7 @@
/>
<SmartItem
icon="edit"
:label="$t('edit')"
:label="$t('action.edit')"
@click.native="
$emit('edit-folder', { folder, folderPath })
$refs.options.tippy().hide()
@@ -217,7 +217,7 @@ export default Vue.extend({
}
removeGraphqlFolder(this.folderPath)
this.$toast.error(this.$t("deleted").toString(), {
this.$toast.error(this.$t("state.deleted").toString(), {
icon: "delete",
})
},

View File

@@ -10,7 +10,7 @@
<template #trigger>
<ButtonSecondary
v-tippy="{ theme: 'tooltip' }"
:title="$t('more')"
:title="$t('action.more')"
class="rounded"
icon="more_vert"
/>
@@ -53,9 +53,9 @@
<div class="flex flex-col space-y-2">
<SmartItem
v-tippy="{ theme: 'tooltip' }"
:title="$t('replace_current')"
:title="$t('action.replace_current')"
icon="folder_special"
:label="$t('replace_json')"
:label="$t('action.replace_json')"
@click.native="openDialogChooseFileToReplaceWith"
/>
<input
@@ -67,7 +67,7 @@
/>
<SmartItem
v-tippy="{ theme: 'tooltip' }"
:title="$t('preserve_current')"
:title="$t('action.preserve_current')"
icon="create_new_folder"
:label="$t('import.json')"
@click.native="openDialogChooseFileToImportFrom"
@@ -81,7 +81,7 @@
/>
<SmartItem
v-tippy="{ theme: 'tooltip' }"
:title="$t('download_file')"
:title="$t('action.download_file')"
icon="drive_file_move"
:label="$t('export.as_json')"
@click.native="exportJSON"
@@ -248,7 +248,7 @@ export default defineComponent({
a.download = `${url.split("/").pop().split("#")[0].split("?")[0]}`
document.body.appendChild(a)
a.click()
this.$toast.success(this.$t("download_started"), {
this.$toast.success(this.$t("state.download_started"), {
icon: "done",
})
setTimeout(() => {
@@ -257,7 +257,7 @@ export default defineComponent({
}, 1000)
},
fileImported() {
this.$toast.info(this.$t("file_imported"), {
this.$toast.info(this.$t("state.file_imported"), {
icon: "folder_shared",
})
},

View File

@@ -43,7 +43,7 @@
v-if="!savingMode"
v-tippy="{ theme: 'tooltip' }"
icon="replay"
:title="$t('restore')"
:title="$t('action.restore')"
class="hidden group-hover:inline-flex"
@click.native="!doc ? selectRequest() : {}"
/>
@@ -58,13 +58,13 @@
<template #trigger>
<ButtonSecondary
v-tippy="{ theme: 'tooltip' }"
:title="$t('more')"
:title="$t('action.more')"
icon="more_vert"
/>
</template>
<SmartItem
icon="edit"
:label="$t('edit')"
:label="$t('action.edit')"
@click.native="
$emit('edit-request', {
request,
@@ -171,7 +171,7 @@ export default Vue.extend({
}
removeGraphqlRequest(this.folderPath, this.requestIndex)
this.$toast.error(this.$t("deleted").toString(), {
this.$toast.error(this.$t("state.deleted").toString(), {
icon: "delete",
})
},

View File

@@ -11,7 +11,7 @@
<input
v-model="filterText"
type="search"
:placeholder="$t('search')"
:placeholder="$t('action.search')"
class="
bg-primaryLight
border-b border-dividerLight
@@ -26,7 +26,7 @@
<div class="border-b border-dividerLight flex flex-1 justify-between">
<ButtonSecondary
icon="add"
:label="$t('new')"
:label="$t('action.new')"
class="rounded-none"
@click.native="displayModalAdd(true)"
/>
@@ -86,7 +86,7 @@
>
<i class="opacity-75 pb-2 material-icons">manage_search</i>
<span class="text-center">
{{ $t("nothing_found") }} "{{ filterText }}"
{{ $t("state.nothing_found") }} "{{ filterText }}"
</span>
</div>
<CollectionsGraphqlAdd