diff --git a/.changeset/wise-pumas-eat.md b/.changeset/wise-pumas-eat.md index 9e90e329..0febc840 100644 --- a/.changeset/wise-pumas-eat.md +++ b/.changeset/wise-pumas-eat.md @@ -2,4 +2,4 @@ "@hydrofoil/shaperone-wc": minor --- -Default resource node is now a blank node. Also fixes an issue that the form would not render when the node was `<>` (empty string URI) +Fixes an issue that the form would not render when the node was `<>` (empty string URI) diff --git a/demos/storybook/stories/Simple.stories.ts b/demos/storybook/stories/Simple.stories.ts index be9bab85..ea468446 100644 --- a/demos/storybook/stories/Simple.stories.ts +++ b/demos/storybook/stories/Simple.stories.ts @@ -32,7 +32,7 @@ const meta: Meta = { export default meta /** - * Without setting the data graph, the form will be empty and a blank node used for focus node. + * Without setting the data graph, the form will be empty and a `<>` IRI used for focus node. */ export const EmptyDataGraph: Story = { name: 'Empty data graph', diff --git a/packages/wc/ShaperoneForm.ts b/packages/wc/ShaperoneForm.ts index ea805310..792b25c5 100644 --- a/packages/wc/ShaperoneForm.ts +++ b/packages/wc/ShaperoneForm.ts @@ -137,7 +137,7 @@ export class ShaperoneForm extends connect(store(), LitElement) { this[notify] = (detail: any) => { this.dispatchEvent(new CustomEvent('changed', { detail })) } - this.resource = this.env.clownface().blankNode() + this.resource = this.env.clownface().namedNode('') } async connectedCallback() { diff --git a/packages/wc/test/shaperone-form.test.ts b/packages/wc/test/shaperone-form.test.ts index a5d0dc55..380fa5b7 100644 --- a/packages/wc/test/shaperone-form.test.ts +++ b/packages/wc/test/shaperone-form.test.ts @@ -10,7 +10,9 @@ import { id } from '../ShaperoneForm.js' import { configure } from '../configure.js' describe('shaperone-form', () => { - before(configure) + before(async () => { + await configure() + }) beforeEach(() => { setEnv(rdf)