Add production deployment

This commit is contained in:
2025-08-23 17:17:03 +03:00
Unverified
parent 5b7ba90628
commit 320c6bbe95
11 changed files with 214 additions and 3 deletions
+1 -1
View File
@@ -17,7 +17,7 @@ export const API_BASE_URL: string = '/api';
* @type {string}
* @constant
*/
export const API_FULL_BASE_URL: string = `${location.hostname}:8301/api`;
export const API_FULL_BASE_URL: string = `${location.host}/api`;
/**
* Application name displayed in UI and document title
-1
View File
@@ -27,7 +27,6 @@ body {
}
mdui-dialog {
> *:first-child {
margin-block-start: 0;
}
+6 -1
View File
@@ -17,7 +17,12 @@ import { delay } from "./utils/utils";
* @private
*/
function create(): WebSocket {
return new WebSocket(`ws://${API_FULL_BASE_URL}/chat/ws`);
let prefix = "ws://";
if (location.protocol.includes("https")) {
prefix = "wss://";
}
return new WebSocket(`${prefix}${API_FULL_BASE_URL}/chat/ws`);
}
/**