Project NOMAD is an offline-first knowledge and education server. Wikipedia, thousands of books, courses, maps, and optional local AI, all running on hardware you own with no internet required.
TypeScript
fix(supply-depot): show clean port + lock on card pill for https:port ui_location
Chris Sherwoodb8674193daae
diff --git a/admin/inertia/pages/supply-depot.tsx b/admin/inertia/pages/supply-depot.tsxindex 4acfd08e..efdec52f 100644--- a/admin/inertia/pages/supply-depot.tsx+++ b/admin/inertia/pages/supply-depot.tsx@@ -621,6 +621,11 @@ function AppCard({const isStopped = service.installed && !isRunningconst catColor = service.category ? CATEGORY_COLORS[service.category] ?? CATEGORY_COLORS.custom : CATEGORY_COLORS.customconst isDropdownOpen = openDropdown === service.service_name+ // Port pill: an ui_location may carry an explicit scheme ("https:8480") — show just the port,+ // with a lock when it's served over HTTPS, rather than the raw "https:8480" string.+ const uiIsPath = !!service.ui_location && service.ui_location.startsWith('/')+ const uiIsHttps = /^https:/.test(service.ui_location || '')+ const uiPort = service.ui_location && !uiIsPath ? service.ui_location.replace(/^https?:/, '') : nullfunction toggleDropdown(e: React.MouseEvent) {e.stopPropagation()@@ -709,9 +714,9 @@ function AppCard({modified</span>) : null}- {service.ui_location && !service.ui_location.startsWith('/') && (+ {uiPort && (<span className="text-xs px-2 py-0.5 rounded-full bg-surface-secondary text-text-muted font-mono">- :{service.ui_location}+ {uiIsHttps ? '🔒 ' : ''}:{uiPort}</span>)}</div>