Skip to content
This repository was archived by the owner on May 16, 2025. It is now read-only.

Commit 1905411

Browse files
committed
Fixes for declarations as narrative elements
1 parent 68b35a3 commit 1905411

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/Clients/LibraryClient/objects/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,9 @@ export type INarrativeElement =
144144
IOpaqueElement |
145145
IDocument |
146146
IDocumentRef |
147-
IModuleRef;
147+
IModuleRef |
148+
IDeclaration |
149+
IDeclarationRef;
148150

149151
// parent of a document
150152
export type IDocumentParentRef = IArchiveRef | IDocumentRef;

src/Routes/Library/Document/Content/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ function NarrativeElementViewItem(props: {element: INarrativeElement}) {
2626
const { element } = props;
2727
if (element.ref && element.kind === "module")
2828
return <Module mod={element} />;
29+
else if (element.kind === "declaration")
30+
return null; // unsupported in this version
2931
else if (element.kind === "opaque")
3032
return <Opaque element={element} />;
3133
else

0 commit comments

Comments
 (0)