From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 9B1ADB39D7 for ; Wed, 29 Nov 2023 13:25:24 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 7815C63E0 for ; Wed, 29 Nov 2023 13:25:24 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS for ; Wed, 29 Nov 2023 13:25:23 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 29CF2408CB for ; Wed, 29 Nov 2023 13:25:23 +0100 (CET) From: Maximiliano Sandoval To: pve-devel@lists.proxmox.com Date: Wed, 29 Nov 2023 13:25:21 +0100 Message-Id: <20231129122521.171375-1-m.sandoval@proxmox.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.002 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record T_SCC_BODY_TEXT_LINE -0.01 - Subject: [pve-devel] [PATCH manager v2] ui: mark strings translatable X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Nov 2023 12:25:24 -0000 The string `proxmox.Utils.defaultText + ' (free)'` was inlined as `Default (Unrestricted)` cutting translatable strings makes them harder or even impossible to translate in certain languages. Additionally the extra context makes the work of translators easier. Signed-off-by: Maximiliano Sandoval --- Differences from v1: - Use Unrestricted instead of Free - Added a few more missing strings www/manager6/dc/UserTagAccessEdit.js | 10 +++++----- www/manager6/form/VMCPUFlagSelector.js | 24 ++++++++++++------------ www/manager6/lxc/CreateWizard.js | 4 ++-- www/manager6/qemu/CreateWizard.js | 4 ++-- www/manager6/qemu/HDEdit.js | 2 +- www/manager6/sdn/controllers/IsisEdit.js | 4 ++-- www/manager6/sdn/zones/EvpnEdit.js | 2 +- www/manager6/sdn/zones/QinQEdit.js | 2 +- www/manager6/window/Settings.js | 12 ++++++------ 9 files changed, 32 insertions(+), 32 deletions(-) diff --git a/www/manager6/dc/UserTagAccessEdit.js b/www/manager6/dc/UserTagAccessEdit.js index 61c38c07..90c79b73 100644 --- a/www/manager6/dc/UserTagAccessEdit.js +++ b/www/manager6/dc/UserTagAccessEdit.js @@ -54,11 +54,11 @@ Ext.define('PVE.dc.UserTagAccessEdit', { deleteEmpty: false, value: '__default__', comboItems: [ - ['__default__', Proxmox.Utils.defaultText + ' (free)'], - ['free', 'free'], - ['existing', 'existing'], - ['list', 'list'], - ['none', 'none'], + ['__default__', gettext('Default (Unrestricted)')], + ['free', gettext('Unrestricted')], + ['existing', gettext('Existing')], + ['list', gettext('List')], + ['none', gettext('None')], ], defaultValue: '__default__', }, diff --git a/www/manager6/form/VMCPUFlagSelector.js b/www/manager6/form/VMCPUFlagSelector.js index ace3c531..2c435586 100644 --- a/www/manager6/form/VMCPUFlagSelector.js +++ b/www/manager6/form/VMCPUFlagSelector.js @@ -21,18 +21,18 @@ Ext.define('PVE.form.VMCPUFlagSelector', { fields: ['flag', { name: 'state', defaultValue: '=' }, 'desc'], data: [ // FIXME: let qemu-server host this and autogenerate or get from API call?? - { flag: 'md-clear', desc: 'Required to let the guest OS know if MDS is mitigated correctly' }, - { flag: 'pcid', desc: 'Meltdown fix cost reduction on Westmere, Sandy-, and IvyBridge Intel CPUs' }, - { flag: 'spec-ctrl', desc: 'Allows improved Spectre mitigation with Intel CPUs' }, - { flag: 'ssbd', desc: 'Protection for "Speculative Store Bypass" for Intel models' }, - { flag: 'ibpb', desc: 'Allows improved Spectre mitigation with AMD CPUs' }, - { flag: 'virt-ssbd', desc: 'Basis for "Speculative Store Bypass" protection for AMD models' }, - { flag: 'amd-ssbd', desc: 'Improves Spectre mitigation performance with AMD CPUs, best used with "virt-ssbd"' }, - { flag: 'amd-no-ssb', desc: 'Notifies guest OS that host is not vulnerable for Spectre on AMD CPUs' }, - { flag: 'pdpe1gb', desc: 'Allow guest OS to use 1GB size pages, if host HW supports it' }, - { flag: 'hv-tlbflush', desc: 'Improve performance in overcommitted Windows guests. May lead to guest bluescreens on old CPUs.' }, - { flag: 'hv-evmcs', desc: 'Improve performance for nested virtualization. Only supported on Intel CPUs.' }, - { flag: 'aes', desc: 'Activate AES instruction set for HW acceleration.' }, + { flag: 'md-clear', desc: gettext('Required to let the guest OS know if MDS is mitigated correctly') }, + { flag: 'pcid', desc: gettext('Meltdown fix cost reduction on Westmere, Sandy-, and IvyBridge Intel CPUs') }, + { flag: 'spec-ctrl', desc: gettext('Allows improved Spectre mitigation with Intel CPUs') }, + { flag: 'ssbd', desc: gettext('Protection for "Speculative Store Bypass" for Intel models') }, + { flag: 'ibpb', desc: gettext('Allows improved Spectre mitigation with AMD CPUs') }, + { flag: 'virt-ssbd', desc: gettext('Basis for "Speculative Store Bypass" protection for AMD models') }, + { flag: 'amd-ssbd', desc: gettext('Improves Spectre mitigation performance with AMD CPUs, best used with "virt-ssbd"') }, + { flag: 'amd-no-ssb', desc: gettext('Notifies guest OS that host is not vulnerable for Spectre on AMD CPUs') }, + { flag: 'pdpe1gb', desc: gettext('Allow guest OS to use 1GB size pages, if host HW supports it') }, + { flag: 'hv-tlbflush', desc: gettext('Improve performance in overcommitted Windows guests. May lead to guest bluescreens on old CPUs.') }, + { flag: 'hv-evmcs', desc: gettext('Improve performance for nested virtualization. Only supported on Intel CPUs.') }, + { flag: 'aes', desc: gettext('Activate AES instruction set for HW acceleration.') }, ], listeners: { update: function() { diff --git a/www/manager6/lxc/CreateWizard.js b/www/manager6/lxc/CreateWizard.js index b57b3050..149acd07 100644 --- a/www/manager6/lxc/CreateWizard.js +++ b/www/manager6/lxc/CreateWizard.js @@ -262,8 +262,8 @@ Ext.define('PVE.lxc.CreateWizard', { }], }, columns: [ - { header: 'Key', width: 150, dataIndex: 'key' }, - { header: 'Value', flex: 1, dataIndex: 'value' }, + { header: gettext('Key'), width: 150, dataIndex: 'key' }, + { header: gettext('Value'), flex: 1, dataIndex: 'value' }, ], }, ], diff --git a/www/manager6/qemu/CreateWizard.js b/www/manager6/qemu/CreateWizard.js index 375f0c66..adf14098 100644 --- a/www/manager6/qemu/CreateWizard.js +++ b/www/manager6/qemu/CreateWizard.js @@ -247,8 +247,8 @@ Ext.define('PVE.qemu.CreateWizard', { }], }, columns: [ - { header: 'Key', width: 150, dataIndex: 'key' }, - { header: 'Value', flex: 1, dataIndex: 'value' }, + { header: gettext('Key'), width: 150, dataIndex: 'key' }, + { header: gettext('Value'), flex: 1, dataIndex: 'value' }, ], }, ], diff --git a/www/manager6/qemu/HDEdit.js b/www/manager6/qemu/HDEdit.js index b78647ec..a179e92f 100644 --- a/www/manager6/qemu/HDEdit.js +++ b/www/manager6/qemu/HDEdit.js @@ -253,7 +253,7 @@ Ext.define('PVE.qemu.HDInputPanel', { { xtype: 'proxmoxcheckbox', name: 'iothread', - fieldLabel: 'IO thread', + fieldLabel: gettext('IO thread'), clearOnDisable: true, bind: me.insideWizard || me.isCreate ? { disabled: '{!isVirtIO && !isSCSI}', diff --git a/www/manager6/sdn/controllers/IsisEdit.js b/www/manager6/sdn/controllers/IsisEdit.js index 2e333fa5..47c3f996 100644 --- a/www/manager6/sdn/controllers/IsisEdit.js +++ b/www/manager6/sdn/controllers/IsisEdit.js @@ -31,13 +31,13 @@ Ext.define('PVE.sdn.controllers.IsisInputPanel', { { xtype: 'textfield', name: 'isis-domain', - fieldLabel: 'Domain', + fieldLabel: gettext('Domain'), allowBlank: false, }, { xtype: 'textfield', name: 'isis-net', - fieldLabel: 'Network entity title', + fieldLabel: gettext('Network entity title'), allowBlank: false, }, { diff --git a/www/manager6/sdn/zones/EvpnEdit.js b/www/manager6/sdn/zones/EvpnEdit.js index a08faef2..6f807238 100644 --- a/www/manager6/sdn/zones/EvpnEdit.js +++ b/www/manager6/sdn/zones/EvpnEdit.js @@ -29,7 +29,7 @@ Ext.define('PVE.sdn.zones.EvpnInputPanel', { name: 'vrf-vxlan', minValue: 1, maxValue: 16000000, - fieldLabel: 'VRF-VXLAN Tag', + fieldLabel: gettext('VRF-VXLAN Tag'), allowBlank: false, }, { diff --git a/www/manager6/sdn/zones/QinQEdit.js b/www/manager6/sdn/zones/QinQEdit.js index 795ff9df..ef319062 100644 --- a/www/manager6/sdn/zones/QinQEdit.js +++ b/www/manager6/sdn/zones/QinQEdit.js @@ -22,7 +22,7 @@ Ext.define('PVE.sdn.zones.QinQInputPanel', { { xtype: 'textfield', name: 'bridge', - fieldLabel: 'Bridge', + fieldLabel: gettext('Bridge'), allowBlank: false, }, { diff --git a/www/manager6/window/Settings.js b/www/manager6/window/Settings.js index 5cf7a70f..dbe86b71 100644 --- a/www/manager6/window/Settings.js +++ b/www/manager6/window/Settings.js @@ -267,9 +267,9 @@ Ext.define('PVE.window.Settings', { stateId: 'guest-notes-collapse', reference: 'guestNotesCollapse', comboItems: [ - ['never', 'Show by default'], - ['always', 'Collapse by default'], - ['auto', 'auto (Collapse if empty)'], + ['never', gettext('Show by default')], + ['always', gettext('Collapse by default')], + ['auto', gettext('auto (Collapse if empty)')], ], }, ], @@ -376,19 +376,19 @@ Ext.define('PVE.window.Settings', { xtype: 'radiofield', name: 'noVNCScalingField', inputValue: 'auto', - boxLabel: 'Auto', + boxLabel: gettext('Auto'), }, { xtype: 'radiofield', name: 'noVNCScalingField', inputValue: 'scale', - boxLabel: 'Local Scaling', + boxLabel: gettext('Local Scaling'), margin: '0 0 0 10', }, { xtype: 'radiofield', name: 'noVNCScalingField', inputValue: 'off', - boxLabel: 'Off', + boxLabel: gettext('Off'), margin: '0 0 0 10', }, ], -- 2.39.2