RTL support in translation interface (#14665)

* first draft for translations rtl implementation

* make direction field dybamic

* Fixed default direction field

* added directionality to: tags, input-multiline, repeater (list)

* added directionality for wysiwyg, input-autocomplete, groups

* reverted directionality in wysiwyg-editor

* removed hardcoded rtl, ltr buttons from wysiwyg toolbar

* working directionality in wysiwyg editor

* also add v-if to await language for second language (split-view) in translations.vue

* added watcher for changing wysiwyg directionality on language change

Co-authored-by: Rijk van Zanten <rijkvanzanten@me.com>
Co-authored-by: Martijn de Voogd <devoogd@kissthefrog.nl>
Co-authored-by: Martijn <73393707+martijn-dev@users.noreply.github.com>
Co-authored-by: Brainslug <br41nslug@users.noreply.github.com>
This commit is contained in:
Ramon van Bezouw
2022-08-09 15:23:05 +02:00
committed by GitHub
parent 3e4ca34f0e
commit df054f294d
18 changed files with 173 additions and 4 deletions

View File

@@ -19,7 +19,12 @@
<template #item="{ element, index }">
<v-list-item :dense="internalValue.length > 4" block @click="openItem(index)">
<v-icon v-if="!disabled && !sort" name="drag_handle" class="drag-handle" left @click.stop="() => {}" />
<render-template :fields="fields" :item="{ ...defaults, ...element }" :template="templateWithDefaults" />
<render-template
:fields="fields"
:item="{ ...defaults, ...element }"
:direction="direction"
:template="templateWithDefaults"
/>
<div class="spacer" />
<v-icon v-if="!disabled" name="close" @click.stop="removeItem(element)" />
</v-list-item>
@@ -54,6 +59,7 @@
:disabled="disabled"
:fields="fieldsWithNames"
:model-value="activeItem"
:direction="direction"
autofocus
primary-key="+"
@update:model-value="trackEdits($event)"
@@ -130,6 +136,10 @@ export default defineComponent({
type: String,
default: () => i18n.global.t('no_items'),
},
direction: {
type: String,
default: undefined,
},
},
emits: ['input'],
setup(props, { emit }) {