<link rel="stylesheet" href="/assets/css/reset.css">
<link rel="stylesheet" href="/assets/css/game.css">
<link rel="stylesheet" href="/assets/css/sky.css">
- <script src="https://code.jquery.com/jquery-3.7.0.min.js" integrity="sha256-2Pmvv0kuTBOenSvLm6bvfBSSHrUJ+3A7x6P5Ebd07/g=" crossorigin="anonymous"></script>
+ <script src="https://unpkg.com/htmx.org@1.9.4" integrity="sha384-zUfuhFKKZCbHTY6aRR46gxiqszMk5tcHjsVFxnUo8VMus4kHGVdIYVbOYYNlKmHV" crossorigin="anonymous"></script>
<script src="/socket.io/socket.io.js"></script>
</head>
<body>
<div class="progress-bar" id="exp-bar"></div>
</div>
<nav>
- <li><a href="#" data-section="inventory" data-container="main-nav">Profile</a></li>
- <li><a href="#" data-section="skills" data-container="main-nav">Skills</a></li>
- <li><a href="#" data-section="explore" data-container="main-nav">Explore</a></li>
+ <li><a href="#" class="active" hx-get="/player" hx-target="#profile">Profile</a></li>
+ <li><a href="#" hx-get="/player/inventory" hx-target="#inventory">Inventory</a></li>
+ <li><a href="#" hx-get="/player/skills" hx-target="#skills">Skills</a></li>
+ <li><a href="#" hx-get="/player/explore" hx-target="#explore">Explore</a></li>
</nav>
</div>
</header>
<div id="announcements" class="hidden"></div>
<div id="alerts"></div>
+ <div id="modal-wrapper"></div>
<div id="main-nav">
+ <section id="profile" class="tab active">PROFILE</section>
<section id="inventory" class="tab">INVENTORY</section>
<section id="skills" class="tab">SKILLS</section>
<section id="explore" class="tab">
</div>
<section id="chat">
- <div id="chat-messages"></div>
- <form id="chat-form">
- <input type="text" id="message" autocomplete="off"><button type="submit">Send</button>
+ <div id="chat-messages" hx-trigger="load delay:1s" hx-get="/chat/history" hx-swap="afterend"></div>
+ <form id="chat-form" hx-post="/chat">
+ <input type="text" id="message" name="message" autocomplete="off"><button type="submit">Send</button>
</form>
</section>
<section id="game-footer">
<div>
<nav>
- <a href="#" data-section="settings" data-container="main-nav">Settings</a>
+ <a href="#" data-section="settings" data-container="main-nav" hx-get="/settings" hx-target="#settings">Settings</a>
</nav>
</div>
- <div id="server-stats">0 Online - Now</div>
+ <div id="server-stats">...Loading</div>
</section>
<footer>Another project by <a href="https://xangelo.ca/gardens/rising-legends/">xangelo.ca</a>. <span id="version"></span></footer>