diff --git a/surfsense_web/.npmrc b/surfsense_web/.npmrc new file mode 100644 index 000000000..150cdf725 --- /dev/null +++ b/surfsense_web/.npmrc @@ -0,0 +1 @@ +public-hoist-pattern[]=pdfjs-dist diff --git a/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx index b522bc913..6c94134b7 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx @@ -162,6 +162,7 @@ const TOOLS_WITH_UI = new Set([ "web_search", "generate_podcast", "generate_report", + "generate_resume", "generate_video_presentation", "display_image", "generate_image", diff --git a/surfsense_web/atoms/chat/report-panel.atom.ts b/surfsense_web/atoms/chat/report-panel.atom.ts index edae8979d..60de50d67 100644 --- a/surfsense_web/atoms/chat/report-panel.atom.ts +++ b/surfsense_web/atoms/chat/report-panel.atom.ts @@ -8,6 +8,8 @@ interface ReportPanelState { wordCount: number | null; /** When set, uses public endpoints for fetching report data (public shared chat) */ shareToken: string | null; + /** Content type of the report — "markdown" (default) or "typst" (resume) */ + contentType: string; } const initialState: ReportPanelState = { @@ -16,6 +18,7 @@ const initialState: ReportPanelState = { title: null, wordCount: null, shareToken: null, + contentType: "markdown", }; /** Core atom holding the report panel state */ @@ -38,7 +41,8 @@ export const openReportPanelAtom = atom( title, wordCount, shareToken, - }: { reportId: number; title: string; wordCount?: number; shareToken?: string | null } + contentType, + }: { reportId: number; title: string; wordCount?: number; shareToken?: string | null; contentType?: string } ) => { if (!get(reportPanelAtom).isOpen) { set(preReportCollapsedAtom, get(rightPanelCollapsedAtom)); @@ -49,6 +53,7 @@ export const openReportPanelAtom = atom( title, wordCount: wordCount ?? null, shareToken: shareToken ?? null, + contentType: contentType ?? "markdown", }); set(rightPanelTabAtom, "report"); set(rightPanelCollapsedAtom, false);