[pve-devel] [PATCH novnc] backport correct fix for extra keys

Dominik Csapak d.csapak at proxmox.com
Tue Mar 25 08:53:43 CET 2025


Instead of our own fix for the extra keys, backport the proper one from
upstream. As mentioned in the commit message, this also fixes
the clibpoard textarea margin.

We can drop this patch then when we update to a new upstream release
with this included.

Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 ...-Fix-appearance-of-extra-key-buttons.patch | 60 +++++++++++++++++++
 .../patches/0020-fix-broken-extra-keys.patch  | 32 ----------
 debian/patches/series                         |  2 +-
 3 files changed, 61 insertions(+), 33 deletions(-)
 create mode 100644 debian/patches/0020-Fix-appearance-of-extra-key-buttons.patch
 delete mode 100644 debian/patches/0020-fix-broken-extra-keys.patch

diff --git a/debian/patches/0020-Fix-appearance-of-extra-key-buttons.patch b/debian/patches/0020-Fix-appearance-of-extra-key-buttons.patch
new file mode 100644
index 0000000..5363835
--- /dev/null
+++ b/debian/patches/0020-Fix-appearance-of-extra-key-buttons.patch
@@ -0,0 +1,60 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Samuel Mannehed <samuel at cendio.se>
+Date: Mon, 24 Mar 2025 22:14:43 +0100
+Subject: [PATCH] Fix appearance of extra key buttons
+
+Since the extra keys panel is quite narrow in width, a max-width style
+resulted in the buttons almost disappearing. That rule was only intended
+for elements inside the settings panel.
+
+Broken by commit 14f9ea5880f32f2a4867006d46c8e871942c698e.
+
+Another minor error that is also fixed by this commit is that the
+clipboard textarea no longer incorrectly gets a left margin of 6px.
+
+Fixes #1946.
+
+Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
+---
+ app/styles/base.css | 18 +++++++++---------
+ 1 file changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/app/styles/base.css b/app/styles/base.css
+index 6e9b25d..0c7c544 100644
+--- a/app/styles/base.css
++++ b/app/styles/base.css
+@@ -475,15 +475,6 @@ html {
+     margin: 5px;
+ }
+ 
+-.noVNC_panel button,
+-.noVNC_panel select,
+-.noVNC_panel textarea,
+-.noVNC_panel input:not([type=checkbox]):not([type=radio]) {
+-    margin-left: 6px;
+-    /* Prevent inputs in panels from being too wide */
+-    max-width: calc(100% - 6px - var(--input-xpadding) * 2);
+-}
+-
+ .noVNC_panel .noVNC_heading {
+     background-color: var(--novnc-blue);
+     border-radius: 6px;
+@@ -621,6 +612,15 @@ html {
+     list-style: none;
+     padding: 0px;
+ }
++#noVNC_settings button,
++#noVNC_settings select,
++#noVNC_settings textarea,
++#noVNC_settings input:not([type=checkbox]):not([type=radio]) {
++    margin-left: 6px;
++    /* Prevent inputs in panels from being too wide */
++    max-width: calc(100% - 6px - var(--input-xpadding) * 2);
++}
++
+ #noVNC_setting_port {
+     width: 80px;
+ }
+-- 
+2.39.5
+
diff --git a/debian/patches/0020-fix-broken-extra-keys.patch b/debian/patches/0020-fix-broken-extra-keys.patch
deleted file mode 100644
index c072210..0000000
--- a/debian/patches/0020-fix-broken-extra-keys.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Dominik Csapak <d.csapak at proxmox.com>
-Date: Mon, 24 Mar 2025 14:25:39 +0100
-Subject: [PATCH] fix broken extra keys
-
-commit:
-14f9ea5: ("Fix settings panel layout on small screens")
-
-changed the selector for the max-width calculation here to include the
-images type, but this was actually not intended.
-
-Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
----
- app/styles/base.css | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/app/styles/base.css b/app/styles/base.css
-index 6e9b25d..948074c 100644
---- a/app/styles/base.css
-+++ b/app/styles/base.css
-@@ -478,7 +478,7 @@ html {
- .noVNC_panel button,
- .noVNC_panel select,
- .noVNC_panel textarea,
--.noVNC_panel input:not([type=checkbox]):not([type=radio]) {
-+.noVNC_panel input:not([type=checkbox]):not([type=radio]):not([type=image]) {
-     margin-left: 6px;
-     /* Prevent inputs in panels from being too wide */
-     max-width: calc(100% - 6px - var(--input-xpadding) * 2);
--- 
-2.39.5
-
diff --git a/debian/patches/series b/debian/patches/series
index 66ee38e..94bc5c4 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -17,4 +17,4 @@
 0017-make-error-hideable.patch
 0018-show-start-button-on-not-running-vm-ct.patch
 0019-show-clipboard-button.patch
-0020-fix-broken-extra-keys.patch
+0020-Fix-appearance-of-extra-key-buttons.patch
-- 
2.39.5





More information about the pve-devel mailing list