diff options
| author | historia <[not public]> | 2026-06-30 19:27:37 -0400 |
|---|---|---|
| committer | historia <[not public]> | 2026-06-30 19:27:37 -0400 |
| commit | fee376102192dc6f24297a7b11324636ace3a07d (patch) | |
| tree | 6c777cc71208b429eebdbdc5864b353d4af34a09 /internal/admin/templates | |
| parent | 98bdef072c843fdd8ccdf85a9b54ab9d32d34187 (diff) | |
| download | thehouseoficarus-fee376102192dc6f24297a7b11324636ace3a07d.tar.gz | |
feat: admin gui object CRUD is much nicer
Diffstat (limited to 'internal/admin/templates')
| -rw-r--r-- | internal/admin/templates/login.html | 9 | ||||
| -rw-r--r-- | internal/admin/templates/map.html | 4 | ||||
| -rw-r--r-- | internal/admin/templates/objects.html | 17 |
3 files changed, 15 insertions, 15 deletions
diff --git a/internal/admin/templates/login.html b/internal/admin/templates/login.html index ffc59c6..52d1f13 100644 --- a/internal/admin/templates/login.html +++ b/internal/admin/templates/login.html @@ -8,7 +8,8 @@ </head> <body> <div class="login"> - <h1>THOI Admin Portal</h1> + <h1 style="margin-bottom:4px">The House of Icarus</h1> + <p style="text-align:center;font-size:13px;color:#aaa;margin-bottom:20px">Admin Portal</p> {{if .Error}}<p style="color:var(--danger);text-align:center;margin-bottom:12px;font-size:13px">{{.Error}}</p>{{end}} <form method="post" action="/login"> <div class="form-group"> @@ -23,6 +24,12 @@ <button type="submit" class="btn btn-primary" style="width:100%">Login</button> </div> </form> + <p style="font-size:11px;color:#888;margin-top:16px;line-height:1.5;text-align:center"> + Use the same credentials you use in-game. To enable admin access, set + <code style="background:var(--input-bg);padding:1px 4px;border-radius:2px">admin: true</code> + in your account YAML at + <code style="background:var(--input-bg);padding:1px 4px;border-radius:2px">data/players/accounts/<account>.yaml</code>. + </p> </div> </body> </html> diff --git a/internal/admin/templates/map.html b/internal/admin/templates/map.html index 6fd6261..3bcbb30 100644 --- a/internal/admin/templates/map.html +++ b/internal/admin/templates/map.html @@ -17,6 +17,10 @@ <span style="font-size:11px;color:#aaa;margin-left:8px">Zoom:</span> <button onclick="zoomIn()" title="Zoom in" style="width:auto;font-size:14px;padding:0 6px;min-width:32px">➕</button> <button onclick="zoomOut()" title="Zoom out" style="width:auto;font-size:14px;padding:0 6px;min-width:32px">➖</button> + <label style="font-size:11px;color:#ccc;cursor:pointer;display:flex;align-items:center;gap:4px;margin-left:8px" title="When unchecked, skips the confirm dialog when deleting rooms"> + <input type="checkbox" id="confirmDelete" style="cursor:pointer"> + Confirm before delete + </label> </div> <svg id="mapSvg" style="width:100%;height:100%"></svg> <div class="room-tooltip" id="tooltip" style="display:none"></div> diff --git a/internal/admin/templates/objects.html b/internal/admin/templates/objects.html index 91aca09..ac9b6be 100644 --- a/internal/admin/templates/objects.html +++ b/internal/admin/templates/objects.html @@ -10,20 +10,9 @@ </div> </div> <script src="/static/editor.js"></script> +<script src="/static/talktree.js"></script> +<script src="/static/objecteditor.js"></script> <script> -initEditor('objects', [ - {key:'name',label:'Name',type:'text'}, - {key:'color',label:'Color',type:'color'}, - {key:'aliases',label:'Aliases (comma sep)',type:'text'}, - {key:'hidden',label:'Hidden',type:'checkbox'}, - {key:'inroom_description',label:'In-Room Description',type:'text'}, - {key:'description',label:'Description',type:'textarea'}, - {key:'removal_item',label:'Removal Item ID',type:'text'}, - {key:'steal_table',label:'Steal Table ID',type:'text'}, - {key:'steal_level',label:'Steal Level',type:'number'}, - {key:'steal_xp',label:'Steal XP',type:'number'}, - {key:'steal_speed',label:'Steal Speed',type:'number'}, - {key:'guard_mob',label:'Guard Mob ID',type:'text'} -]); +initObjectEditor(); </script> {{end}} |
