42 lines
1.1 KiB
TypeScript
42 lines
1.1 KiB
TypeScript
/**
|
|
* AI Helper page template
|
|
*/
|
|
|
|
// oxlint-disable-next-line no-unused-vars
|
|
import { Html } from "@elysiajs/html";
|
|
import { page } from "./base";
|
|
import {
|
|
AiHelperHeader,
|
|
ChatPanel,
|
|
CurrentPromptPanel,
|
|
QuickActions,
|
|
QuickGeneratePanel,
|
|
ReferenceSidebar,
|
|
} from "./components/ai-helper/page-sections";
|
|
export { aiHelperChatResponse, aiHelperGenerateResponse } from "./components/ai-helper/responses";
|
|
|
|
const aiHelperScriptTag = <script src="/assets/ai-helper.js"></script>;
|
|
|
|
export function aiHelperPage(guildId?: string, guildName?: string): string {
|
|
return page({
|
|
title: "AI Personality Helper - Joel Bot",
|
|
content: (
|
|
<div class="mx-auto max-w-300 px-5 py-6">
|
|
<AiHelperHeader guildId={guildId} guildName={guildName} />
|
|
<QuickActions />
|
|
|
|
<div class="grid gap-6 lg:grid-cols-[1fr_350px]">
|
|
<div>
|
|
<ChatPanel />
|
|
<CurrentPromptPanel />
|
|
<QuickGeneratePanel />
|
|
</div>
|
|
|
|
<ReferenceSidebar />
|
|
</div>
|
|
</div>
|
|
),
|
|
scripts: aiHelperScriptTag,
|
|
});
|
|
}
|