diff --git a/.changeset/pink-worms-suffer.md b/.changeset/pink-worms-suffer.md
new file mode 100644
index 00000000..72832604
--- /dev/null
+++ b/.changeset/pink-worms-suffer.md
@@ -0,0 +1,5 @@
+---
+"@zazuko/trifid-entity-renderer": patch
+---
+
+Fix issue where graph name label was not shown if it is not a known prefix (closes #213)
diff --git a/packages/entity-renderer/renderer/metadata/namedGraphs.js b/packages/entity-renderer/renderer/metadata/namedGraphs.js
index b805c320..3b23a16a 100644
--- a/packages/entity-renderer/renderer/metadata/namedGraphs.js
+++ b/packages/entity-renderer/renderer/metadata/namedGraphs.js
@@ -17,7 +17,7 @@ const getLabel = (term) => {
if (term.constructor.name === 'DefaultGraph') {
return 'Default graph'
}
- return shrink(term.value)
+ return shrink(term.value) || term.value
}
const getNamedGraphsCounts = (dataset) => {
diff --git a/packages/entity-renderer/renderer/web-component/N3Term.js b/packages/entity-renderer/renderer/web-component/N3Term.js
index f9413f28..737ac936 100644
--- a/packages/entity-renderer/renderer/web-component/N3Term.js
+++ b/packages/entity-renderer/renderer/web-component/N3Term.js
@@ -4,7 +4,7 @@ import { shrink } from '@zazuko/prefixes'
function renderTerm (term) {
if (term.termType === 'NamedNode') {
- return html`${shrink(term.value)}`
+ return html`${shrink(term.value) || term.value}`
}
if (term.constructor.name === 'DefaultGraph') {
return html`Default graph`