diff --git a/public/css/dk.css b/public/css/dk.css index b9a434c..3d101fb 100644 --- a/public/css/dk.css +++ b/public/css/dk.css @@ -40,7 +40,7 @@ main { } main > section { - padding: 4px; + padding: 0.75rem; } main > section > section { @@ -49,6 +49,7 @@ main > section > section { main section#left { width: 180px; + flex-shrink: 0; border-right: solid 2px black; } @@ -58,6 +59,7 @@ main section#middle { main section#right { width: 180px; + flex-shrink: 0; border-left: solid 2px black; } @@ -82,20 +84,6 @@ td { vertical-align: top; } -td.top { - border-bottom: solid 2px black; -} - -td.left { - width: 180px; - border-right: solid 2px black; -} - -td.right { - width: 180px; - border-left: solid 2px black; -} - a { color: #663300; text-decoration: none; @@ -126,6 +114,7 @@ a:hover { padding: 5px; font-size: 1.2rem; font-family: serif; + margin-bottom: 0.5rem; } .copyright { diff --git a/public/index.php b/public/index.php index 6fe5905..03fae53 100644 --- a/public/index.php +++ b/public/index.php @@ -15,15 +15,13 @@ $r = new Router; $r->get('/', function() { if (user()->currentaction === "In Town") { $page = Towns\town(); - $title = "In Town"; } elseif (user()->currentaction === "Exploring") { - $page = doexplore(); - $title = "Exploring"; + $page = explore(); } elseif (user()->currentaction === "Fighting") { redirect('/fight'); } - return is_htmx() ? $page : display($page, $title); + return is_htmx() ? $page : display($page, ''); }); $r->get('/ninja', function() { @@ -52,7 +50,8 @@ $l = $r->lookup($_SERVER['REQUEST_METHOD'], $_SERVER['REQUEST_URI']); if (is_int($l)) exit("Error: $l"); $content = $l['handler'](...$l['params'] ?? []); -if (is_htmx() && $uri[0] !== 'babblebox') { +if (is_htmx()) { + $content .= '
You are exploring the map, and nothing has happened. Continue exploring using the direction buttons or the Travel To menus.
diff --git a/src/actions/towns.php b/src/actions/towns.php
index 39e79a4..4b1f6b8 100644
--- a/src/actions/towns.php
+++ b/src/actions/towns.php
@@ -73,7 +73,7 @@ function town()
HTML;
}
- if (is_htmx()) htmx_update_page_title($townrow['name']);
+ page_title($townrow['name']);
return render('towns', ['town' => $townrow]);
}
@@ -86,7 +86,7 @@ function inn()
if ($town === false) { exit('Cheat attempt detected.