fix: code review cleanup - schema sync, type safety, null handling
- Sync KnowledgeLink schema with migration (add displayText, positionStart, positionEnd, resolved) - Make targetId optional to support unresolved links - Fix null handling in graph.service.ts (skip unresolved links) - Add explicit types to frontend components (remove implicit any) - Remove unused WikiLink import - Add null-safe statusInfo check in EntryCard
This commit is contained in:
@@ -40,7 +40,7 @@ export default function KnowledgePage() {
|
||||
// Filter by tag
|
||||
if (selectedTag !== "all") {
|
||||
filtered = filtered.filter((entry) =>
|
||||
entry.tags.some((tag) => tag.slug === selectedTag)
|
||||
entry.tags.some((tag: { slug: string }) => tag.slug === selectedTag)
|
||||
);
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ export default function KnowledgePage() {
|
||||
(entry) =>
|
||||
entry.title.toLowerCase().includes(query) ||
|
||||
entry.summary?.toLowerCase().includes(query) ||
|
||||
entry.tags.some((tag) => tag.name.toLowerCase().includes(query))
|
||||
entry.tags.some((tag: { name: string }) => tag.name.toLowerCase().includes(query))
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user