mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-15 04:44:36 +02:00
Added german translations for label plugin
This commit is contained in:
parent
eba89cee62
commit
5918c55855
3 changed files with 101 additions and 105 deletions
|
@ -1,6 +1,6 @@
|
|||
import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
|
||||
|
||||
require('./lang/en.js');
|
||||
require('./lang/de.js');
|
||||
|
||||
import { addListToDropdown, createDropdown } from '@ckeditor/ckeditor5-ui/src/dropdown/utils';
|
||||
|
||||
|
@ -23,7 +23,7 @@ export default class PartDBLabelUI extends Plugin {
|
|||
dropdownView.buttonView.set( {
|
||||
// The t() function helps localize the editor. All strings enclosed in t() can be
|
||||
// translated and change when the language of the editor changes.
|
||||
label: t( 'part_db.label' ),
|
||||
label: t( 'Label Placeholder' ),
|
||||
tooltip: true,
|
||||
withText: true
|
||||
} );
|
||||
|
@ -45,64 +45,64 @@ export default class PartDBLabelUI extends Plugin {
|
|||
|
||||
const PLACEHOLDERS = [
|
||||
{
|
||||
label: 'section.part',
|
||||
label: 'Part',
|
||||
entries: [
|
||||
['[[ID]]', 'part.id'],
|
||||
['[[NAME]]', 'part.name'],
|
||||
['[[CATEGORY]]', 'part.category'],
|
||||
['[[CATEGORY_FULL]]', 'part.category_full'],
|
||||
['[[MANUFACTURER]]', 'part.manufacturer'],
|
||||
['[[MANUFACTURER_FULL]]', 'part.manufacturer_full'],
|
||||
['[[FOOTPRINT]]', 'part.footprint'],
|
||||
['[[FOOTPRINT_FULL]]', 'part.footprint'],
|
||||
['[[MASS]]', 'part.mass'],
|
||||
['[[MPN]]', 'part.mpn'],
|
||||
['[[TAGS]]', 'part.tags'],
|
||||
['[[M_STATUS]]', 'part.status'],
|
||||
['[[DESCRIPTION]]', 'part.description'],
|
||||
['[[DESCRIPTION_T]]', 'part.description_t'],
|
||||
['[[COMMENT]]', 'part.comment'],
|
||||
['[[COMMENT_T]]', 'part.comment_t'],
|
||||
['[[LAST_MODIFIED]]', 'part.last_modified'],
|
||||
['[[CREATION_DATE]]', 'part.creation_date'],
|
||||
['[[ID]]', 'Database ID'],
|
||||
['[[NAME]]', 'Part name'],
|
||||
['[[CATEGORY]]', 'Category'],
|
||||
['[[CATEGORY_FULL]]', 'Category (Full path)'],
|
||||
['[[MANUFACTURER]]', 'Manufacturer'],
|
||||
['[[MANUFACTURER_FULL]]', 'Manufacturer (Full path)'],
|
||||
['[[FOOTPRINT]]', 'Footprint'],
|
||||
['[[FOOTPRINT_FULL]]', 'Footprint (Full path)'],
|
||||
['[[MASS]]', 'Mass'],
|
||||
['[[MPN]]', 'Manufacturer Product Number (MPN)'],
|
||||
['[[TAGS]]', 'Tags'],
|
||||
['[[M_STATUS]]', 'Manufacturing status'],
|
||||
['[[DESCRIPTION]]', 'Description'],
|
||||
['[[DESCRIPTION_T]]', 'Description (plain text)'],
|
||||
['[[COMMENT]]', 'Comment'],
|
||||
['[[COMMENT_T]]', 'Comment (plain text)'],
|
||||
['[[LAST_MODIFIED]]', 'Last modified datetime'],
|
||||
['[[CREATION_DATE]]', 'Creation datetime'],
|
||||
]
|
||||
},
|
||||
{
|
||||
label: 'section.part_lot',
|
||||
label: 'Part lot',
|
||||
entries: [
|
||||
['[[LOT_ID]]', 'lot.id'],
|
||||
['[[LOT_NAME]]', 'lot.name'],
|
||||
['[[LOT_COMMENT]]', 'lot.comment'],
|
||||
['[[EXPIRATION_DATE]]', 'lot.expiration_date'],
|
||||
['[[AMOUNT]]', 'lot.amount'],
|
||||
['[[LOCATION]]', 'lot.location'],
|
||||
['[[LOCATION_FULL]]', 'lot.location_full'],
|
||||
['[[LOT_ID]]', 'Lot ID'],
|
||||
['[[LOT_NAME]]', 'Lot name'],
|
||||
['[[LOT_COMMENT]]', 'Lot comment'],
|
||||
['[[EXPIRATION_DATE]]', 'Lot expiration date'],
|
||||
['[[AMOUNT]]', 'Lot amount'],
|
||||
['[[LOCATION]]', 'Storage location'],
|
||||
['[[LOCATION_FULL]]', 'Storage location (Full path)'],
|
||||
]
|
||||
},
|
||||
{
|
||||
label: 'section.storelocation',
|
||||
label: 'Storage location',
|
||||
entries: [
|
||||
['[[ID]]', 'storelocation.id'],
|
||||
['[[NAME]]', 'storelocation.name'],
|
||||
['[[FULL_PATH]]', 'storelocation.full_path'],
|
||||
['[[PARENT]]', 'storelocation.parent_name'],
|
||||
['[[PARENT_FULL_PATH]]', 'storelocation.parent_full_path'],
|
||||
['[[COMMENT]]', 'storelocation.comment'],
|
||||
['[[COMMENT_T]]', 'storelocation.comment_t'],
|
||||
['[[LAST_MODIFIED]]', 'storelocation.last_modified'],
|
||||
['[[CREATION_DATE]]', 'storelocation.creation_date'],
|
||||
['[[ID]]', 'Location ID'],
|
||||
['[[NAME]]', 'Name'],
|
||||
['[[FULL_PATH]]', 'Full path'],
|
||||
['[[PARENT]]', 'Parent name'],
|
||||
['[[PARENT_FULL_PATH]]', 'Parent full path'],
|
||||
['[[COMMENT]]', 'Comment'],
|
||||
['[[COMMENT_T]]', 'Comment (plain text)'],
|
||||
['[[LAST_MODIFIED]]', 'Last modified datetime'],
|
||||
['[[CREATION_DATE]]', 'Creation datetime'],
|
||||
]
|
||||
},
|
||||
{
|
||||
label: 'section.global',
|
||||
label: 'Globals',
|
||||
entries: [
|
||||
['[[USERNAME]]', 'global.username'],
|
||||
['[[USERNAME_FULL]]', 'global.username_full'],
|
||||
['[[DATETIME]]', 'global.datetime'],
|
||||
['[[DATE]]', 'global.date'],
|
||||
['[[TIME]]', 'global.time'],
|
||||
['[[INSTALL_NAME]]', 'global.install_name'],
|
||||
['[[TYPE]]', 'global.type']
|
||||
['[[USERNAME]]', 'Username'],
|
||||
['[[USERNAME_FULL]]', 'Username (including name)'],
|
||||
['[[DATETIME]]', 'Current datetime'],
|
||||
['[[DATE]]', 'Current date'],
|
||||
['[[TIME]]', 'Current time'],
|
||||
['[[INSTALL_NAME]]', 'Instance name'],
|
||||
['[[TYPE]]', 'Target type']
|
||||
],
|
||||
},
|
||||
];
|
||||
|
|
54
assets/ckeditor/plugins/PartDBLabel/lang/de.js
Normal file
54
assets/ckeditor/plugins/PartDBLabel/lang/de.js
Normal file
|
@ -0,0 +1,54 @@
|
|||
// Make sure that the global object is defined. If not, define it.
|
||||
window.CKEDITOR_TRANSLATIONS = window.CKEDITOR_TRANSLATIONS || {};
|
||||
|
||||
// Make sure that the dictionary for Polish translations exist.
|
||||
window.CKEDITOR_TRANSLATIONS[ 'de' ] = window.CKEDITOR_TRANSLATIONS[ 'de' ] || {};
|
||||
window.CKEDITOR_TRANSLATIONS[ 'de' ].dictionary = window.CKEDITOR_TRANSLATIONS[ 'de' ].dictionary || {};
|
||||
|
||||
// Extend the dictionary for Polish translations with your translations:
|
||||
Object.assign( window.CKEDITOR_TRANSLATIONS[ 'de' ].dictionary, {
|
||||
'Label Placeholder': 'Label Platzhalter',
|
||||
'Part': 'Bauteil',
|
||||
|
||||
'Database ID': 'Datenbank ID',
|
||||
'Part name': 'Bauteilname',
|
||||
'Category': 'Kategorie',
|
||||
'Category (Full path)': 'Kategorie (Vollständiger Pfad)',
|
||||
'Manufacturer': 'Hersteller',
|
||||
'Manufacturer (Full path)': 'Hersteller (Vollständiger Pfad)',
|
||||
'Footprint': 'Footprint',
|
||||
'Footprint (Full path)': 'Footprint (Vollständiger Pfad)',
|
||||
'Mass': 'Gewicht',
|
||||
'Manufacturer Product Number (MPN)': 'Hersteller Produktnummer (MPN)',
|
||||
'Tags': 'Tags',
|
||||
'Manufacturing status': 'Herstellungsstatus',
|
||||
'Description': 'Beschreibung',
|
||||
'Description (plain text)': 'Beschreibung (Nur-Text)',
|
||||
'Comment': 'Kommentar',
|
||||
'Comment (plain text)': 'Kommentar (Nur-Text)',
|
||||
'Last modified datetime': 'Zuletzt geändert',
|
||||
'Creation datetime': 'Erstellt',
|
||||
|
||||
'Lot ID': 'Lot ID',
|
||||
'Lot name': 'Lot Name',
|
||||
'Lot comment': 'Lot Kommentar',
|
||||
'Lot expiration date': 'Lot Ablaufdatum',
|
||||
'Lot amount': 'Lot Menge',
|
||||
'Storage location': 'Lagerort',
|
||||
'Storage location (Full path)': 'Lagerort (Vollständiger Pfad)',
|
||||
|
||||
'Location ID': 'Lagerort ID',
|
||||
'Name': 'Name',
|
||||
'Full path': 'Vollständiger Pfad',
|
||||
'Parent name': 'Name des Übergeordneten Elements',
|
||||
'Parent full path': 'Ganzer Pfad des Übergeordneten Elements',
|
||||
|
||||
'Username': 'Benutzername',
|
||||
'Username (including name)': 'Benutzername (inklusive Name)',
|
||||
'Current datetime': 'Aktuelle Datum/Zeit',
|
||||
'Current date': 'Aktuelles Datum',
|
||||
'Current time': 'Aktuelle Zeit',
|
||||
'Instance name': 'Instanzname',
|
||||
'Target type': 'Zieltyp',
|
||||
|
||||
} );
|
|
@ -1,58 +0,0 @@
|
|||
// Make sure that the global object is defined. If not, define it.
|
||||
window.CKEDITOR_TRANSLATIONS = window.CKEDITOR_TRANSLATIONS || {};
|
||||
|
||||
// Make sure that the dictionary for Polish translations exist.
|
||||
window.CKEDITOR_TRANSLATIONS[ 'en' ] = window.CKEDITOR_TRANSLATIONS[ 'en' ] || {};
|
||||
window.CKEDITOR_TRANSLATIONS[ 'en' ].dictionary = window.CKEDITOR_TRANSLATIONS[ 'en' ].dictionary || {};
|
||||
|
||||
// Extend the dictionary for Polish translations with your translations:
|
||||
Object.assign( window.CKEDITOR_TRANSLATIONS[ 'en' ].dictionary, {
|
||||
'part_db.title': 'Insert Placeholders',
|
||||
'part_db.label': 'Placeholders',
|
||||
'section.global': 'Globals',
|
||||
'section.part': 'Part',
|
||||
'section.part_lot': 'Part lot',
|
||||
'section.storelocation': 'Storage location',
|
||||
'part.id': 'Database ID',
|
||||
'part.name': 'Part name',
|
||||
'part.category': 'Category',
|
||||
'part.category_full': 'Category (Full path)',
|
||||
'part.manufacturer': 'Manufacturer',
|
||||
'part.manufacturer_full': 'Manufacturer (Full path)',
|
||||
'part.footprint': 'Footprint',
|
||||
'part.footprint_full': 'Footprint (Full path)',
|
||||
'part.mass': 'Mass',
|
||||
'part.tags': 'Tags',
|
||||
'part.mpn': 'Manufacturer Product Number (MPN)',
|
||||
'part.status': 'Manufacturing status',
|
||||
'part.description': 'Description',
|
||||
'part.description_t': 'Description (Text)',
|
||||
'part.comment': 'Comment',
|
||||
'part.comment_t': 'Comment (Text)',
|
||||
'part.last_modified': 'Last modified datetime',
|
||||
'part.creation_date': 'Creation datetime',
|
||||
'global.username': 'Username',
|
||||
'global.username_full': 'Username (including name)',
|
||||
'global.datetime': 'Current datetime',
|
||||
'global.date': 'Current date',
|
||||
'global.time': 'Current time',
|
||||
'global.install_name': 'Instance name',
|
||||
'global.type': 'Target type',
|
||||
'lot.id': 'Lot ID',
|
||||
'lot.name': 'Lot name',
|
||||
'lot.comment': 'Lot comment',
|
||||
'lot.expiration_date': 'Expiration date',
|
||||
'lot.amount': 'Lot amount',
|
||||
'lot.location': 'Storage location',
|
||||
'lot.location_full': 'Storage location (Full path)',
|
||||
|
||||
'storelocation.id': 'Location ID',
|
||||
'storelocation.name': 'Name',
|
||||
'storelocation.full_path': 'Full path',
|
||||
'storelocation.parent_name': 'Parent name',
|
||||
'storelocation.parent_full_path': 'Parent full path',
|
||||
'storelocation.comment': 'Comment',
|
||||
'storelocation.comment_t': 'Comment (Text)',
|
||||
'storelocation.last_modified': 'Last modified datetime',
|
||||
'storelocation.creation_date': 'Createion datetime',
|
||||
} );
|
Loading…
Add table
Add a link
Reference in a new issue