diff --git a/settings/languages/en.yaml b/settings/languages/en.yaml index b06f608..7001473 100644 --- a/settings/languages/en.yaml +++ b/settings/languages/en.yaml @@ -1,4 +1,65 @@ # English + +# themes/typemill/typemill.yaml +ACTIVATE_SPECIAL_STARTPAGE_DESIGN: Activate Special Startpage-Design +AUTHOR_INTRO: Author Intro +BOTTOM: Bottom +BY: by +COUNT_CHAPTERS_IN_NAVIGATION?: Count chapters in navigation? +DIFFERENT_DESIGN_FOR_STARTPAGE: Different Design for Startpage +FACEBOOK: Facebook +FORMAT: Format +GITHUB: GitHub +LABEL_FOR_CHAPTER: Label for Chapter +LABEL_FOR_START_BUTTON: Label for Start Button +LAST_MODIFIED_FORMAT: Last Modified Format +LAST_MODIFIED: Last Modified +LAST_MODIFIED_TEXT: Last Modified Text +LINKEDIN: Linkedin +LINK_TO_GIT_REPOSITORY: Link to git repository +MAIL: Mail +POSITION_OF_AUTHOR: Position of Author +POSITION_OF_GIT_EDIT_LINK: Position of Git Edit Link +POSITION_OF_MODIFIED_TEXT: Position of Modified Text +POSITION_OF_SHARE_BUTTONS: Position of Share-Buttons +SELECT_SHARE_BUTTONS: Select Share Buttons +SHARE: Share +SHOW_CHAPTER_NUMBERS: Show Chapter Numbers +TOP: Top +TWITTER: Twitter +TYPEMILL_DESCRIPTION: The standard theme for Typemill. Responsive, minimal and without any dependencies. It uses the system fonts Calibri and Helvetica. No JavaScript is used. +WHATSAPP: WhatsApp +XING: Xing + +# system/author/layouts/layoutBlox.twig +ADD: add +BOLD: bold +BULLET_LIST: Bullet List +CHECK: check +CODE: Code +COG: cog +CROSS: cross +DEFINITION: Definition List +DELETE_CLOSE: delete/close +DELETE: delete +EXTERNAL_LINK: external-link +FOLDER: folder +HEADLINE: Headline +HOME: home +HORIZONTAL_LINE: Horizontal Line +IMAGE: Image +ITALIC: italic +LINK: link +MOVE_VERTICAL: move vertical +NUMBERED_LIST: Numbered List +PARAGRAPH: Paragraph +POWER_OFF: power-off +QUOTES: Quote +TABLE_OF_CONTENTS: Table of Contents +TABLE: Table +TEXT_FILE: text-file +VIDEO: Video + ACCOUNT: Account ACTIVE: Active ACTUAL_PASSWORD: Actual Password diff --git a/settings/languages/it.yaml b/settings/languages/it.yaml index 3d90b2c..9294297 100644 --- a/settings/languages/it.yaml +++ b/settings/languages/it.yaml @@ -1,4 +1,65 @@ # Italiano + +# themes/typemill/typemill.yaml +ACTIVATE_SPECIAL_STARTPAGE_DESIGN: Attiva il disegno speciale della pagina iniziale +AUTHOR_INTRO: Introduzione dell'autore +BOTTOM: Sotto +BY: di +COUNT_CHAPTERS_IN_NAVIGATION?: Contare i capitoli nella navigazione? +DIFFERENT_DESIGN_FOR_STARTPAGE: Disegno diverso per la pagina iniziale +FACEBOOK: Facebook +FORMAT: Format +GITHUB: GitHub +LABEL_FOR_CHAPTER: Etichetta per capitolo +LABEL_FOR_START_BUTTON: Etichetta per il pulsante Comincia +LAST_MODIFIED_FORMAT: Ultimo formato modificato +LAST_MODIFIED_TEXT: Ultimo testo modificato +LAST_MODIFIED: Ultima modifica +LINKEDIN: Linkedin +LINK_TO_GIT_REPOSITORY: Collegamento al deposito git +MAIL: Mail +POSITION_OF_AUTHOR: Posizione dell'autore +POSITION_OF_GIT_EDIT_LINK: Posizione del collegamento modifica Git +POSITION_OF_MODIFIED_TEXT: Posizione del testo modificato +POSITION_OF_SHARE_BUTTONS: Posizione dei pulsanti di condivisione +SELECT_SHARE_BUTTONS: Seleziona i pulsanti pulsanti di condivisione +SHARE: Condividere +SHOW_CHAPTER_NUMBERS: Mostra i numeri dei capitoli +TOP: Sopra +TWITTER: Twitter +TYPEMILL_DESCRIPTION: Il tema standard per Typemill. Reattivo, minimo e senza dipendenze. Utilizza i caratteri di sistema Calibri ed Helvetica. Non viene utilizzato JavaScript. +WHATSAPP: WhatsApp +XING: Xing + +# system/author/layouts/layoutBlox.twig +ADD: aggiungi +BOLD: grassetto +BULLET_LIST: Elenco puntato +CHECK: controllo +CODE: Codice +COG: ingranaggio +CROSS: croce +DEFINITION: Elenco delle definizioni +DELETE_CLOSE: elimina/chiudi +DELETE: elimina +EXTERNAL_LINK: collegamento esterno +FOLDER: cartella +HEADLINE: Titolo +HOME: home +HORIZONTAL_LINE: Linea orizzontale +IMAGE: Immagine +ITALIC: corsivo +LINK: collegamento +MOVE_VERTICAL: spostare in verticale +NUMBERED_LIST: Elenco numerato +PARAGRAPH: Paragrafo +POWER_OFF: spegni +QUOTES: Citazione +TABLE_OF_CONTENTS: Sommario +TABLE: Tabella +TEXT_FILE: file di testo +VIDEO: Video + ACCOUNT: Utenza ACTIVE: Attivo ACTUAL_PASSWORD: Parola d'ordine corrente diff --git a/settings/languages/vuejs-en.yaml b/settings/languages/vuejs-en.yaml new file mode 100644 index 0000000..fd6176b --- /dev/null +++ b/settings/languages/vuejs-en.yaml @@ -0,0 +1,53 @@ +# English +en: + add content-block: add content-block + add definition: add definition + add left column: add left column + add right column: add right column + add row above: add row above + add row below: add row below + Alt-Text: Alt-Text + author: author + Bullet List: Bullet List + cancel: cancel + Caption: Caption + cell: cell + Center: Center + Class: Class + Code: Code + Content: Content + Created at (readonly): Created at (readonly) + Definition List: Definition List + delete column: delete column + delete content-block: delete content-block + delete row: delete row + description: description + drag a picture or click to select: drag a picture or click to select + Head: Head + Headline: Headline + Horizontal Line: Horizontal Line + If not filled, the description is extracted from content.: If not filled, the description is extracted from content. + Image: Image + Last modified live (readonly): Last modified live (readonly) + Left: Left + Link: Link + Link to video: Link to video + Manual date: Manual date + Meta description: Meta description + meta: meta + Meta title: Meta title + Numbered List: Numbered List + Paragraph: Paragraph + Please correct the errors above: Please correct the errors above + Quote: Quote + Right: Right + Saved successfully: Saved successfully + save: save + save: save + table of contents: Table of Contents + Table: Table + Taken from your user account if set.: Taken from your user account if set. + term: term + Title: Title + Used as fallback when no manual date is set.: Used as fallback when no manual date is set. + Video: Video diff --git a/settings/languages/vuejs-it.yaml b/settings/languages/vuejs-it.yaml new file mode 100644 index 0000000..fbdb60b --- /dev/null +++ b/settings/languages/vuejs-it.yaml @@ -0,0 +1,53 @@ +# Italiano +it: + add content-block: aggiungi blocco contenuto + add definition: aggiungi definizione + add left column: aggiungi colonna a sinistra + add right column: aggiungi colonna a destra + add row above: aggiungi la riga sopra + add row below: aggiungi la riga sotto + Alt-Text: Testo alternativo + author: autore + Bullet List: Elenco puntato + cancel: Annulla + Caption: Didascalia + cell: cella + Center: Centro + Class: Classe + Code: Codice + Content: Contenuto + Created at (readonly): Creato il (sola lettura) + Definition List: Elenco delle definizioni + delete column: elimina colonna + delete content-block: elimina blocco contenuto + delete row: elimina riga + description: descrizione + drag a picture or click to select: trascina un'immagine o fai clic per selezionare + Head: Intestazione + Headline: Titolo + Horizontal Line: Linea orizzontale + If not filled, the description is extracted from content.: Se non compilato, la descrizione viene estratta dal contenuto. + Image: Immagine + Last modified live (readonly): Ultima modifica (sola lettura) + Left: Sinistra + Link: Collegamento + Link to video: Collega al video + Manual date: Data manuale + Meta description: Descrizione + meta: Metadati + Meta title: Titolo + Numbered List: Elenco numerato + Paragraph: Paragrafo + Please correct the errors above: Si prega di correggere gli errori sopra + Quote: Citazione + Right: Destra + Saved successfully: Salvato con successo + save: salva + save: Salva + table of contents: Sommario + Table: Tabella + Taken from your user account if set.: Tratto dalla tua utenza, se impostata. + term: termine + Title: Titolo + Used as fallback when no manual date is set.: Utilizzato come ripiego quando non รจ impostata alcuna data manuale. + Video: Video diff --git a/system/Settings.php b/system/Settings.php index 4bb7b0b..a78066a 100644 --- a/system/Settings.php +++ b/system/Settings.php @@ -17,9 +17,10 @@ class Settings } # i18n - # load the strings of the set language - $language = $settings['language']; - $settings['labels'] = self::getLanguageLabels($language); + # load the strings of the set language + $language = $settings['language']; + $settings['labels'] = self::getLanguageLabels($language); + $settings['vuejsLabels'] = self::getVuejsLabels($language); # We know the used theme now so create the theme path $settings['themePath'] = $settings['rootPath'] . $settings['themeFolder'] . DIRECTORY_SEPARATOR . $settings['theme']; @@ -92,6 +93,19 @@ class Settings return $labels; } + public static function getVuejsLabels($language) + { + if( empty($language) ){ + $language = 'en'; + } + + // load the strings of the set language + $yaml = new Models\WriteYaml(); + $labels = $yaml->getYaml('settings/languages', 'vuejs-'.$language.'.yaml'); + + return $labels; + } + public static function getObjectSettings($objectType, $objectName) { @@ -156,4 +170,4 @@ class Settings $yaml->updateYaml('settings', 'settings.yaml', $settings); } } -} \ No newline at end of file +} diff --git a/system/author/js/vue-meta.js b/system/author/js/vue-meta.js index 34cb534..6e573c4 100644 --- a/system/author/js/vue-meta.js +++ b/system/author/js/vue-meta.js @@ -3,7 +3,7 @@ const FormBus = new Vue(); Vue.component('component-text', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -28,7 +28,7 @@ Vue.component('component-text', { Vue.component('component-textarea', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -52,7 +52,7 @@ Vue.component('component-textarea', { Vue.component('component-url', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -77,7 +77,7 @@ Vue.component('component-url', { Vue.component('component-number', { props: ['class', 'id', 'description', 'min', 'max', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -104,7 +104,7 @@ Vue.component('component-number', { Vue.component('component-email', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -129,7 +129,7 @@ Vue.component('component-email', { Vue.component('component-tel', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -154,7 +154,7 @@ Vue.component('component-tel', { Vue.component('component-password', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -179,7 +179,7 @@ Vue.component('component-password', { Vue.component('component-date', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -203,7 +203,7 @@ Vue.component('component-date', { Vue.component('component-color', { props: ['class', 'id', 'description', 'maxlength', 'readonly', 'required', 'disabled', 'placeholder', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -227,7 +227,7 @@ Vue.component('component-color', { Vue.component('component-select', { props: ['class', 'id', 'description', 'readonly', 'required', 'disabled', 'label', 'name', 'type', 'options', 'value', 'errors'], template: '
' + - '' + + '' + '{{option}}' + '' + '{{ errors[name] }}' + - '{{ description }}' + + '{{ $t(description) }}' + '
', methods: { update: function($event, name) @@ -251,7 +251,7 @@ Vue.component('component-select', { Vue.component('component-checkbox', { props: ['class', 'id', 'description', 'readonly', 'required', 'disabled', 'label', 'checkboxlabel', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '
', methods: { @@ -277,7 +277,7 @@ Vue.component('component-checkbox', { Vue.component('component-checkboxlist', { props: ['class', 'description', 'readonly', 'required', 'disabled', 'label', 'checkboxlabel', 'options', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '
', methods: { update: function($event, value, optionvalue, name) @@ -304,7 +304,7 @@ Vue.component('component-checkboxlist', { Vue.component('component-radio', { props: ['class', 'id', 'description', 'readonly', 'required', 'disabled', 'options', 'label', 'name', 'type', 'value', 'errors'], template: '
' + - '' + + '' + '' + '
', methods: { @@ -339,9 +339,9 @@ Vue.component('tab-meta', { 'v-model="formdata[index]"' + 'v-bind="field">' + '' + - '
Saved successfully
' + - '
Please correct the errors above
' + - '
' + + '
{{ $t(\'Saved successfully\') }}
' + + '
{{ $t(\'Please correct the errors above\') }}
' + + '
' + '', methods: { selectComponent: function(field) @@ -356,6 +356,12 @@ Vue.component('tab-meta', { }) let meta = new Vue({ + + i18n: new VueI18n({ + locale: language, + messages: vuejsLabels + }), + delimiters: ['${', '}'], el: '#metanav', data: function () { diff --git a/system/author/layouts/layoutBlox.twig b/system/author/layouts/layoutBlox.twig index c79fcc2..f54144b 100644 --- a/system/author/layouts/layoutBlox.twig +++ b/system/author/layouts/layoutBlox.twig @@ -28,118 +28,118 @@ - external-link + {{ __('EXTERNAL_LINK') }} - text-file + {{ __('TEXT_FILE') }} - cog + {{ __('COG') }} - power-off + {{ __('POWER_OFF') }} - delete + {{ __('DELETE') }} - add + {{ __('ADD') }} - delete/close + {{ __('DELETE_CLOSE') }} - home + {{ __('HOME') }} - move vertical + {{ __('MOVE_VERTICAL') }} - folder + {{ __('FOLDER') }} - image + {{ __('IMAGE') }} - video + {{ __('VIDEO') }} - quotes + {{ __('QUOTES') }} - numbered list + {{ __('NUMBERED_LIST') }} - bullet list + {{ __('BULLET_LIST') }} - link + {{ ('LINK') }} - bold + {{ __('BOLD') }} - italic + {{ __('ITALIC') }} - horizontal line + {{ __('HORIZONTAL_LINE') }} - table + {{ __('TABLE') }} - paragraph + {{ __('PARAGRAPH') }} - code + {{ __('CODE') }} - headline + {{ __('HEADLINE') }} - table of contents + {{ __('TABLE_OF_CONTENTS') }} - definition + {{ __('DEFINITION') }} - check + {{ __('CHECK') }} - cross + {{ __('CROSS') }} @@ -171,6 +171,7 @@ myaxios.defaults.baseURL = "{{ base_url }}"; + @@ -179,6 +180,8 @@ {{ assets.renderEditorJS() }}