From 5f37dc9b6f6b79da04da70ae0c33ec8d02998587 Mon Sep 17 00:00:00 2001 From: historia <[not public]> Date: Wed, 1 Jul 2026 02:21:42 -0400 Subject: feat: qol improvements to items crud in admin gui --- internal/admin/static/map.js | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'internal/admin/static/map.js') diff --git a/internal/admin/static/map.js b/internal/admin/static/map.js index 5bff9d7..e5d9a19 100644 --- a/internal/admin/static/map.js +++ b/internal/admin/static/map.js @@ -595,8 +595,10 @@ function renderItemsTab(spawns) { h += '
'; h += '
'; h += '' + esc(spawn.id || '') + ''; - h += ''; - h += ''; + h += '
'; + h += '
'; + h += '
'; + h += '
'; h += '
'; h += ''; h += ''; @@ -666,7 +668,7 @@ function editExitCondition(dir) { overlay.className = 'cm-overlay exit-overlay'; var menu = document.createElement('div'); menu.className = 'cm-menu exit-modal'; - menu.style.cssText = 'position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);min-width:420px;max-width:90vw;max-height:85vh;overflow-y:auto;overflow-x:hidden;padding:14px;z-index:201'; + menu.style.cssText = 'position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);min-width:520px;max-width:90vw;max-height:85vh;overflow-y:auto;overflow-x:hidden;padding:14px;z-index:201'; var h = '

Exit: ' + esc(dir) + ' → #' + exit.room + '

'; h += '
'; @@ -742,7 +744,7 @@ function renderConditionClauses(menu) { } else { h += ''; } - h += ''; + h += ''; h += ''; h += '
'; }); @@ -833,7 +835,8 @@ function saveExitCondition() { } function buildSingleCondition(clause) { - var obj = {not: !!clause.not}; + var obj = {}; + if (clause.not) obj.not = true; if (clause.type === 'value') { var parts = (clause.value || '').split('=', 2); obj.value = {key: (parts[0] || '').trim(), value: (parts[1] || '').trim()}; -- cgit v1.2.3