* [PATCH manager 1/2] ui: guest identity: hide copy-to-clipboard button when there is no uid
2026-11-23 16:36 [PATCH-SERIES manager 0/2] ui: guest identity: small improvements Fiona Ebner
@ 2026-11-23 16:36 ` Fiona Ebner
2026-11-23 16:36 ` [PATCH manager 2/2] ui: guest identity: use displayfield for uid Fiona Ebner
2026-11-23 17:44 ` applied: [PATCH-SERIES manager 0/2] ui: guest identity: small improvements Thomas Lamprecht
2 siblings, 0 replies; 4+ messages in thread
From: Fiona Ebner @ 2026-11-23 16:36 UTC (permalink / raw)
To: pve-devel
The button cannot be used for a window instance without a uid, so hide
it completely.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
www/manager6/panel/GuestIdentity.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/www/manager6/panel/GuestIdentity.js b/www/manager6/panel/GuestIdentity.js
index 62c54d0f..dbba0062 100644
--- a/www/manager6/panel/GuestIdentity.js
+++ b/www/manager6/panel/GuestIdentity.js
@@ -44,6 +44,7 @@ Ext.define('PVE.window.GuestIdentity', {
tooltip: gettext('Copy to Clipboard'),
ariaLabel: gettext('Copy to Clipboard'),
disabled: !meta.uid,
+ hidden: !meta.uid,
margin: '0 0 0 5',
handler: () => PVE.Utils.copyToClipboard(meta.uid),
},
--
2.47.3
^ permalink raw reply related [flat|nested] 4+ messages in thread* [PATCH manager 2/2] ui: guest identity: use displayfield for uid
2026-11-23 16:36 [PATCH-SERIES manager 0/2] ui: guest identity: small improvements Fiona Ebner
2026-11-23 16:36 ` [PATCH manager 1/2] ui: guest identity: hide copy-to-clipboard button when there is no uid Fiona Ebner
@ 2026-11-23 16:36 ` Fiona Ebner
2026-11-23 17:44 ` applied: [PATCH-SERIES manager 0/2] ui: guest identity: small improvements Thomas Lamprecht
2 siblings, 0 replies; 4+ messages in thread
From: Fiona Ebner @ 2026-11-23 16:36 UTC (permalink / raw)
To: pve-devel
Textfields are usually editable and the uid cannot ever be edited. Use
a displayfield instead to avoid producing this wrong association. For
the default text, grey out the value by using a new user class with
opacity: 0.50 to immediately make it clear that it's not an actual
configuration value.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
www/css/ext6-pve.css | 4 ++++
www/manager6/panel/GuestIdentity.js | 7 +++----
2 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/www/css/ext6-pve.css b/www/css/ext6-pve.css
index 2416bc05..91415c46 100644
--- a/www/css/ext6-pve.css
+++ b/www/css/ext6-pve.css
@@ -701,6 +701,10 @@ table.osds td:first-of-type {
color: #3892d4;
}
+.pmx-opacity-50 {
+ opacity: 0.50;
+}
+
.pmx-opacity-75 {
opacity: 0.75;
}
diff --git a/www/manager6/panel/GuestIdentity.js b/www/manager6/panel/GuestIdentity.js
index dbba0062..bb388c85 100644
--- a/www/manager6/panel/GuestIdentity.js
+++ b/www/manager6/panel/GuestIdentity.js
@@ -31,11 +31,10 @@ Ext.define('PVE.window.GuestIdentity', {
layout: 'hbox',
items: [
{
- xtype: 'textfield',
+ xtype: 'displayfield',
itemId: 'uid',
- value: meta.uid ?? '',
- emptyText: gettext('Assigned with the next configuration change'),
- editable: false,
+ value: meta.uid ?? gettext('Assigned with the next configuration change'),
+ userCls: meta.uid ? '' : 'pmx-opacity-50',
flex: 1,
},
{
--
2.47.3
^ permalink raw reply related [flat|nested] 4+ messages in thread