Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions apps/website/scripts/generate-api-docs.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable @typescript-eslint/no-explicit-any -- TypeDoc reflection API is untyped */
import { Application, TSConfigReader, ReflectionKind } from 'typedoc';
import fs from 'fs';
import path from 'path';
Expand Down
2 changes: 1 addition & 1 deletion apps/website/src/app/api/hello/route.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export async function GET(_request: Request) {
export async function GET() {
return new Response('Hello, from API!');
}
11 changes: 6 additions & 5 deletions apps/website/src/components/docs/ArchFlowDiagram.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,18 +43,19 @@ export function ArchFlowDiagram() {
setLogs([]);
setBubbles([]);

SCENARIO.forEach((step, i) => {
SCENARIO.forEach((step) => {
timeouts.push(setTimeout(() => {
setLogs(prev => [...prev, step.log]);
if (step.chatBubble) {
const bubble = step.chatBubble;
setBubbles(prev => {
const existing = prev.findIndex(b => b.role === step.chatBubble!.role && b.role === 'assistant');
if (existing >= 0 && step.chatBubble!.role === 'assistant') {
const existing = prev.findIndex(b => b.role === bubble.role && b.role === 'assistant');
if (existing >= 0 && bubble.role === 'assistant') {
const updated = [...prev];
updated[existing] = step.chatBubble!;
updated[existing] = bubble;
return updated;
}
return [...prev, step.chatBubble!];
return [...prev, bubble];
});
}
if (logRef.current) logRef.current.scrollTop = logRef.current.scrollHeight;
Expand Down
3 changes: 2 additions & 1 deletion apps/website/src/components/docs/MdxRenderer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ export function MdxRenderer({ source, library, section, slug, title }: MdxRender
options={{
mdxOptions: {
remarkPlugins: [remarkGfm],
rehypePlugins: [rehypeSlug, [rehypePrettyCode, rehypeOptions] as any],
// eslint-disable-next-line @typescript-eslint/no-explicit-any
rehypePlugins: [rehypeSlug, [rehypePrettyCode, rehypeOptions] as any],
},
}}
/>
Expand Down
5 changes: 3 additions & 2 deletions apps/website/src/components/landing/ChatFeaturesSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,8 @@ export function ChatFeaturesSection() {
const msgsRef = useRef<HTMLDivElement>(null);

const buildCtx = useCallback((token: number): ScenarioCtx => {
const msgs = msgsRef.current!;
const msgs = msgsRef.current;
if (!msgs) return {} as ScenarioCtx;
const scroll = () => { msgs.scrollTop = msgs.scrollHeight; };

const addUser = (text: string) => {
Expand Down Expand Up @@ -259,7 +260,7 @@ export function ChatFeaturesSection() {
for (const ch of text) {
if (tokenRef.current !== token) return;
const s = document.createElement('span'); s.textContent = ch;
out.parentNode!.insertBefore(s, cur);
out.parentNode?.insertBefore(s, cur);
scroll();
await wait(ms);
}
Expand Down
Loading