all lists on lists.proxmox.com
 help / color / mirror / Atom feed
From: Timothy Nicholson <t.nicholson@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH manager v2] fix #5847: ui: gettextize several strings in ui
Date: Tue, 12 Nov 2024 10:38:40 +0100	[thread overview]
Message-ID: <20241112093840.74600-1-t.nicholson@proxmox.com> (raw)

Signed-off-by: Timothy Nicholson <t.nicholson@proxmox.com>
---

I missed one occurence of the String 'TFA' not using gettext, so
here is the updated patch.

 www/manager6/Workspace.js              |  2 +-
 www/manager6/ceph/OSD.js               |  6 +++---
 www/manager6/ceph/OSDDetails.js        |  2 +-
 www/manager6/dc/UserView.js            |  2 +-
 www/manager6/form/VMCPUFlagSelector.js | 24 ++++++++++++------------
 www/manager6/qemu/ProcessorEdit.js     |  2 +-
 www/manager6/window/Settings.js        |  6 +++---
 7 files changed, 22 insertions(+), 22 deletions(-)

diff --git a/www/manager6/Workspace.js b/www/manager6/Workspace.js
index 52c66108..56dde151 100644
--- a/www/manager6/Workspace.js
+++ b/www/manager6/Workspace.js
@@ -388,7 +388,7 @@ Ext.define('PVE.StdWorkspace', {
 				    },
 				},
 				{
-				    text: 'TFA',
+				    text: gettext('TFA'),
 				    itemId: 'tfaitem',
 				    iconCls: 'fa fa-fw fa-lock',
 				    handler: function(btn, event, rec) {
diff --git a/www/manager6/ceph/OSD.js b/www/manager6/ceph/OSD.js
index d2caafa4..5a32769c 100644
--- a/www/manager6/ceph/OSD.js
+++ b/www/manager6/ceph/OSD.js
@@ -268,11 +268,11 @@ Ext.define('PVE.CephSetFlags', {
 			    dataIndex: 'value',
 			},
 			{
-			    text: 'Name',
+			    text: gettext('Name'),
 			    dataIndex: 'name',
 			},
 			{
-			    text: 'Description',
+			    text: gettext('Description'),
 			    flex: 1,
 			    dataIndex: 'description',
 			},
@@ -716,7 +716,7 @@ Ext.define('PVE.node.CephOsdTree', {
     columns: [
 	{
 	    xtype: 'treecolumn',
-	    text: 'Name',
+	    text: gettext('Name'),
 	    dataIndex: 'name',
 	    width: 150,
 	},
diff --git a/www/manager6/ceph/OSDDetails.js b/www/manager6/ceph/OSDDetails.js
index 3b1c1d9c..5c14aa05 100644
--- a/www/manager6/ceph/OSDDetails.js
+++ b/www/manager6/ceph/OSDDetails.js
@@ -220,7 +220,7 @@ Ext.define('PVE.CephOsdDetails', {
 						renderer: Proxmox.Utils.render_size,
 					    },
 					    {
-						text: 'Discard',
+						text: gettext('Discard'),
 						dataIndex: 'support_discard',
 						hidden: true,
 					    },
diff --git a/www/manager6/dc/UserView.js b/www/manager6/dc/UserView.js
index 12c3e854..d3b88701 100644
--- a/www/manager6/dc/UserView.js
+++ b/www/manager6/dc/UserView.js
@@ -189,7 +189,7 @@ Ext.define('PVE.dc.UserView', {
 		    dataIndex: 'firstname',
 		},
 		{
-		    header: 'TFA',
+		    header: gettext('TFA'),
 		    width: 120,
 		    sortable: true,
 		    renderer: function(v, metaData, record) {
diff --git a/www/manager6/form/VMCPUFlagSelector.js b/www/manager6/form/VMCPUFlagSelector.js
index ace3c531..48589d3f 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/qemu/ProcessorEdit.js b/www/manager6/qemu/ProcessorEdit.js
index 7aa98eb6..c6498fbe 100644
--- a/www/manager6/qemu/ProcessorEdit.js
+++ b/www/manager6/qemu/ProcessorEdit.js
@@ -234,7 +234,7 @@ Ext.define('PVE.qemu.ProcessorInputPanel', {
     advancedColumnB: [
 	{
 	    xtype: 'label',
-	    text: 'Extra CPU Flags:',
+	    text: gettext('Extra CPU Flags:'),
 	},
 	{
 	    xtype: 'vmcpuflagselector',
diff --git a/www/manager6/window/Settings.js b/www/manager6/window/Settings.js
index 9af11850..9fae305a 100644
--- a/www/manager6/window/Settings.js
+++ b/www/manager6/window/Settings.js
@@ -271,9 +271,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)')],
 		],
 	    },
 	    {
-- 
2.39.5


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


             reply	other threads:[~2024-11-12  9:39 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-12  9:38 Timothy Nicholson [this message]
2024-11-12 11:49 ` Thomas Lamprecht
2024-11-12 11:55   ` Thomas Lamprecht

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241112093840.74600-1-t.nicholson@proxmox.com \
    --to=t.nicholson@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal