mirror of
https://github.com/HKUDS/DeepTutor.git
synced 2026-12-05 22:49:51 +08:00
feat(knowledge): expose bounded web sources in detail view
This commit is contained in:
@@ -173,7 +173,7 @@ export default function KbWebSourcesSection({
|
||||
type="url"
|
||||
value={urlInput}
|
||||
onChange={(e) => setUrlInput(e.target.value)}
|
||||
placeholder={t("https://example.com/docs/")}
|
||||
placeholder={t("https://docs.deeptutor.info/")}
|
||||
className="w-full rounded-md border border-[var(--border)] bg-[var(--card)] px-2.5 py-1.5 text-[12.5px] text-[var(--foreground)] outline-none focus:border-[var(--primary)]"
|
||||
/>
|
||||
</label>
|
||||
|
||||
@@ -7,6 +7,7 @@ import {
|
||||
Database,
|
||||
FileText,
|
||||
Github,
|
||||
Globe,
|
||||
Layers,
|
||||
Loader2,
|
||||
RefreshCw,
|
||||
@@ -33,6 +34,7 @@ import KbDocumentsSection from "./KbDocumentsSection";
|
||||
import KbIndexVersionsSection from "./KbIndexVersionsSection";
|
||||
import KbSettingsSection from "./KbSettingsSection";
|
||||
import KbGitHubSourcesSection from "./KbGitHubSourcesSection";
|
||||
import KbWebSourcesSection from "./KbWebSourcesSection";
|
||||
import KbMarginNoteDevicesSection from "./KbMarginNoteDevicesSection";
|
||||
|
||||
interface KnowledgeBaseDetailProps {
|
||||
@@ -61,6 +63,7 @@ const SECTION_CHROME: Record<
|
||||
files: { label: "Files", Icon: FileText },
|
||||
add: { label: "Add documents", Icon: Upload },
|
||||
github: { label: "GitHub", Icon: Github },
|
||||
web: { label: "Web", Icon: Globe },
|
||||
versions: { label: "Index versions", Icon: Layers },
|
||||
devices: { label: "Devices", Icon: Smartphone },
|
||||
settings: { label: "Settings", Icon: SettingsIcon },
|
||||
@@ -284,6 +287,9 @@ export default function KnowledgeBaseDetail({
|
||||
{activeSection === "github" && (
|
||||
<KbGitHubSourcesSection kbName={kb.name} />
|
||||
)}
|
||||
{activeSection === "web" && (
|
||||
<KbWebSourcesSection kbName={kb.name} />
|
||||
)}
|
||||
{activeSection === "devices" && (
|
||||
<KbMarginNoteDevicesSection key={kb.name} kb={kb} />
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user