From: Maximiliano Sandoval <m.sandoval@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH proxmox-datacenter-manager 1/1] use ngettext for the number of CPUs
Date: Wed, 28 Jan 2026 09:56:12 +0100 [thread overview]
Message-ID: <20260128085614.91769-2-m.sandoval@proxmox.com> (raw)
In-Reply-To: <20260128085614.91769-1-m.sandoval@proxmox.com>
This is following changes in proxmox-widget-toolkit.
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
ui/src/pve/lxc/overview.rs | 4 ++--
ui/src/pve/qemu/overview.rs | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/ui/src/pve/lxc/overview.rs b/ui/src/pve/lxc/overview.rs
index 8c0196b3..2764ffa2 100644
--- a/ui/src/pve/lxc/overview.rs
+++ b/ui/src/pve/lxc/overview.rs
@@ -292,10 +292,10 @@ impl yew::Component for LxcanelComp {
status_row(
tr!("CPU usage"),
"fa-cpu",
+ // TRANSLATORS: For example "5% of 24 CPUs"
tr!(
- "{0}% of {1} CPU(s)",
+ "{0}% of {n} CPU" | "{0}% of {n} CPUs" % status.cpus.unwrap_or_default(),
format!("{:.2}", cpu * 100.0),
- status.cpus.unwrap_or_default()
),
)
.value(cpu as f32),
diff --git a/ui/src/pve/qemu/overview.rs b/ui/src/pve/qemu/overview.rs
index 6e601d00..7766580a 100644
--- a/ui/src/pve/qemu/overview.rs
+++ b/ui/src/pve/qemu/overview.rs
@@ -301,10 +301,10 @@ impl yew::Component for QemuOverviewPanelComp {
status_row(
tr!("CPU usage"),
"fa-cpu",
+ // TRANSLATORS: For example "5% of 24 CPUs"
tr!(
- "{0}% of {1} CPU(s)",
+ "{0}% of {n} CPU" | "{0}% of {n} CPUs" % status.cpus.unwrap_or_default(),
format!("{:.2}", cpu * 100.0),
- status.cpus.unwrap_or_default()
),
)
.value(cpu as f32),
--
2.47.3
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
next prev parent reply other threads:[~2026-01-28 8:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-28 8:56 [pve-devel] [PATCH widget-toolkit 1/1] utils: use ngettext for " Maximiliano Sandoval
2026-01-28 8:56 ` Maximiliano Sandoval [this message]
2026-01-28 9:29 ` Maximiliano Sandoval
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=20260128085614.91769-2-m.sandoval@proxmox.com \
--to=m.sandoval@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox