Commit e5c812f1 authored by Timothy J. Baek's avatar Timothy J. Baek
Browse files

refac

parent 8461b92f
...@@ -69,7 +69,6 @@ ...@@ -69,7 +69,6 @@
let tags = []; let tags = [];
let title = ''; let title = '';
let pageTitle = WEBUI_NAME;
let prompt = ''; let prompt = '';
let files = []; let files = [];
let messages = []; let messages = [];
...@@ -78,13 +77,6 @@ ...@@ -78,13 +77,6 @@
currentId: null currentId: null
}; };
$: if (title) {
const trimmedTitle = title.length > 30 ? `${title.slice(0, 30)}...` : title;
pageTitle = `${trimmedTitle} | ${$WEBUI_NAME}`;
} else {
pageTitle = $WEBUI_NAME;
}
$: if (history.currentId !== null) { $: if (history.currentId !== null) {
let _messages = []; let _messages = [];
...@@ -819,7 +811,9 @@ ...@@ -819,7 +811,9 @@
<svelte:head> <svelte:head>
<title> <title>
{pageTitle} {title
? `${title.length > 30 ? `${title.slice(0, 30)}...` : title} | ${$WEBUI_NAME}`
: `${$WEBUI_NAME}`}
</title> </title>
</svelte:head> </svelte:head>
......
...@@ -72,7 +72,6 @@ ...@@ -72,7 +72,6 @@
let tags = []; let tags = [];
let title = ''; let title = '';
let pageTitle = WEBUI_NAME;
let prompt = ''; let prompt = '';
let files = []; let files = [];
...@@ -82,13 +81,6 @@ ...@@ -82,13 +81,6 @@
currentId: null currentId: null
}; };
$: if (title) {
const trimmedTitle = title.length > 30 ? `${title.slice(0, 30)}...` : title;
pageTitle = `${trimmedTitle} | ${$WEBUI_NAME}`;
} else {
pageTitle = $WEBUI_NAME;
}
$: if (history.currentId !== null) { $: if (history.currentId !== null) {
let _messages = []; let _messages = [];
...@@ -834,7 +826,11 @@ ...@@ -834,7 +826,11 @@
</script> </script>
<svelte:head> <svelte:head>
<title>{pageTitle}</title> <title>
{title
? `${title.length > 30 ? `${title.slice(0, 30)}...` : title} | ${$WEBUI_NAME}`
: `${$WEBUI_NAME}`}
</title>
</svelte:head> </svelte:head>
{#if loaded} {#if loaded}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment