diff --git a/package-lock.json b/package-lock.json index e13bde3b3..a0e551483 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7264,9 +7264,9 @@ } }, "node_modules/electron-to-chromium": { - "version": "1.5.395", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.395.tgz", - "integrity": "sha512-7zt9Aw+SrmxLWLN0zhaTWZQiCdryLVrYTq5R7iZakLvi2UQPYMMsROYV/2qVCzMeCiSXHwKOU+sZ4zOVVlrtKA==", + "version": "1.5.396", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.396.tgz", + "integrity": "sha512-yHiw2Y3C3H9U6TMbOfoWK/BPreiOPXRfTWPBwQBoZG6/8TB6eOPnsy5oaRYuatR7Fw2SJ4kKforgufeo7fq0EQ==", "dev": true, "license": "ISC" }, diff --git a/src/components/rdf-input/RDFInput.ts b/src/components/rdf-input/RDFInput.ts index b8e96f83c..3a551b1c5 100644 --- a/src/components/rdf-input/RDFInput.ts +++ b/src/components/rdf-input/RDFInput.ts @@ -1,4 +1,4 @@ -import { property } from 'lit/decorators.js' +import { property, state } from 'lit/decorators.js' import { html } from 'lit/html.js' import ns from '../../lib/ns' import { customElement, generateId, WebComponent } from '@/lib/components' @@ -32,6 +32,9 @@ export default class RDFInput extends WebComponent { @property({ type: Number }) accessor storeVersion = 0 + @state() + private accessor localInputValue: string | null = null + private _updateInFlight = false private _pendingUpdateValue: string | null = null @@ -59,7 +62,9 @@ export default class RDFInput extends WebComponent { // for populating the HTML input element const selectedTerm = this.getSelectedTerm(this.dataSubject, uiPropertyTerm, this.formSubject, params) const placeholder = readonly ? '' : this.defaultInputValue(params) - const inputValue = this.termToInputValue(selectedTerm) + const inputValue = this._updateInFlight || this._pendingUpdateValue !== null + ? this.localInputValue ?? '' + : this.termToInputValue(selectedTerm) return html`