# HG changeset patch # User drewp@bigasterisk.com # Date 2023-05-30 08:00:32 # Node ID 4031e511bca94407b96f44b84ea86ffd7d312162 # Parent c070f46c07614a2e76b299108e21b645756f9d1f resource-display uri can no longer be a string diff --git a/light9/web/EditChoice.ts b/light9/web/EditChoice.ts --- a/light9/web/EditChoice.ts +++ b/light9/web/EditChoice.ts @@ -61,7 +61,7 @@ function setupDrop( // an or tag) @customElement("edit-choice") export class EditChoice extends LitElement { - @property() uri: NamedNode | null = null; + @property() uri?: NamedNode static styles = [ css` :host { @@ -102,12 +102,12 @@ export class EditChoice extends LitEleme // } // } - _setUri(u: any) { + _setUri(u?: NamedNode) { this.uri = u; this.dispatchEvent(new CustomEvent("edited", {detail: {newValue: u}})); } unlink() { - return this._setUri(null); + return this._setUri(undefined); } } diff --git a/light9/web/ResourceDisplay.ts b/light9/web/ResourceDisplay.ts --- a/light9/web/ResourceDisplay.ts +++ b/light9/web/ResourceDisplay.ts @@ -72,8 +72,7 @@ export class ResourceDisplay extends Lit // // `; } - // callers might set this as string or pass a NamedNode. - @property() uri?: NamedNode | string; + @property() uri?: NamedNode; @state() label: string = "";