feat: allow custom base url

This commit is contained in:
hh
2026-05-21 23:27:57 +02:00
parent e8a4e3aa82
commit 64ad92b4c1
8 changed files with 86 additions and 34 deletions
@@ -118,6 +118,7 @@
<script>
(() => {
const CSRF = {{ csrf | tojson }};
const URL_PREFIX = {{ p | tojson }};
const agentSelect = document.getElementById("agent-select");
const messagesEl = document.getElementById("messages");
const form = document.getElementById("chat-form");
@@ -291,7 +292,7 @@
let resp;
try {
resp = await fetch("/chat/send", {
resp = await fetch(URL_PREFIX + "/chat/send", {
method: "POST",
headers: {
"Content-Type": "application/json",