diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts index d4f7d19981..c2727af359 100644 --- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts +++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts @@ -96,7 +96,7 @@ export class UmbWorkspacePropertyContext { } public resetValue() { - this.setValue(null); + this.setValue(null);// TODO: Consider if this can be configured/provided from Property Editor or DataType Configuration or even locally specified in DocumentType. } // TODO: how can we make sure to call this. diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/clear/property-action-clear.element.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/clear/property-action-clear.element.ts index da748fa52b..bfa19bce97 100644 --- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/clear/property-action-clear.element.ts +++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/clear/property-action-clear.element.ts @@ -37,10 +37,10 @@ export class UmbPropertyActionClearElement extends UmbLitElement implements UmbP private _clearValue() { // TODO: how do we want to update the value? Testing an event based approach. We need to test an api based approach too. - //this.value = ''; + //this.value = '';// This is though bad as it assumes we are dealing with a string. So wouldn't work as a generalized element. //this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true })); // Or you can do this: - this._propertyContext?.resetValue(''); + this._propertyContext?.resetValue();// This resets value to what the property wants. } render() {