From 7e4b4b6553317aff9f2e45929cd9c2bc5ab4747d Mon Sep 17 00:00:00 2001 From: Pulse Monitor Date: Tue, 2 Sep 2025 07:33:29 +0000 Subject: [PATCH] improve: enhance mobile responsiveness for Settings and Guest URLs pages - Fix button overflow on Settings page by making layouts responsive - Add responsive text sizing and button compacting for mobile - Make Guest URLs input fields wider (300px min) with horizontal scroll - Improve tab navigation scrolling on mobile devices - Better utilize screen space on small devices --- .../src/components/Settings/GuestURLs.tsx | 15 ++-- .../src/components/Settings/Settings.tsx | 84 ++++++++++--------- 2 files changed, 52 insertions(+), 47 deletions(-) diff --git a/frontend-modern/src/components/Settings/GuestURLs.tsx b/frontend-modern/src/components/Settings/GuestURLs.tsx index e21c1be24..910b66dfc 100644 --- a/frontend-modern/src/components/Settings/GuestURLs.tsx +++ b/frontend-modern/src/components/Settings/GuestURLs.tsx @@ -177,22 +177,22 @@ export function GuestURLs(props: GuestURLsProps) { - +
- - - - - @@ -240,9 +240,10 @@ export function GuestURLs(props: GuestURLsProps) { placeholder="https://192.168.1.100:8006" value={meta?.customUrl || ''} onInput={(e) => updateGuestURL(guestId, e.currentTarget.value)} - class="w-full px-2 py-0.5 text-sm border border-gray-300 dark:border-gray-600 rounded + class="w-full min-w-[300px] px-2 py-1 text-sm border border-gray-300 dark:border-gray-600 rounded bg-white dark:bg-gray-700 text-gray-900 dark:text-gray-100 focus:ring-2 focus:ring-blue-500 focus:border-transparent" + style="min-width: 300px;" />
+ Name + Type + VMID + Custom URL + Actions
diff --git a/frontend-modern/src/components/Settings/Settings.tsx b/frontend-modern/src/components/Settings/Settings.tsx index 18d48d231..996b27afe 100644 --- a/frontend-modern/src/components/Settings/Settings.tsx +++ b/frontend-modern/src/components/Settings/Settings.tsx @@ -762,11 +762,11 @@ const Settings: Component = () => { {/* Tab Navigation - modern style */}
-
+
{(tab) => (
-
-

Proxmox VE Nodes

-
+
+

Proxmox VE Nodes

+
{/* Discovery toggle */} -
@@ -876,10 +877,11 @@ const Settings: Component = () => { n.type === 'pve')}> {(node) => (
-
-
-
-
+
+
+
+
{ // Find the corresponding node in the WebSocket state const stateNode = state.nodes.find(n => n.instance === node.name); @@ -894,12 +896,12 @@ const Settings: Component = () => { // Default to red if no state data (node is offline/unreachable) return 'bg-red-500'; })() - }`}>
-
-
-

{node.name}

-

{node.host}

-
+ }`}>
+
+
+

{node.name}

+

{node.host}

+
{node.user ? `User: ${node.user}` : `Token: ${node.tokenName}`} @@ -944,9 +946,10 @@ const Settings: Component = () => {

+
-
+
@@ -1130,13 +1133,14 @@ const Settings: Component = () => { setModalResetKey(prev => prev + 1); setShowNodeModal(true); }} - class="px-4 py-2 text-sm bg-blue-600 text-white rounded-lg hover:bg-blue-700 transition-colors flex items-center gap-2" + class="px-2 sm:px-4 py-1.5 sm:py-2 text-xs sm:text-sm bg-blue-600 text-white rounded-lg hover:bg-blue-700 transition-colors flex items-center gap-1" > - Add PBS Node + Add +
@@ -1145,8 +1149,8 @@ const Settings: Component = () => { n.type === 'pbs')}> {(node) => (
-
-
+
+
{ // Find the corresponding PBS instance in the WebSocket state @@ -1164,9 +1168,9 @@ const Settings: Component = () => { })() }`}>
-

{node.name}

-

{node.host}

-
+

{node.name}

+

{node.host}

+
{node.user ? `User: ${node.user}` : `Token: ${node.tokenName}`} @@ -1177,7 +1181,7 @@ const Settings: Component = () => {
-
+