From e8c00a7d6769e9e9210d878e14301232da3e4898 Mon Sep 17 00:00:00 2001 From: nathan Date: Mon, 21 Oct 2024 10:10:07 -0600 Subject: [PATCH] Api: Fix some input widgets (eg: Et2LinkEntry) did not display validation error --- api/js/etemplate/Et2InputWidget/Et2InputWidget.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/js/etemplate/Et2InputWidget/Et2InputWidget.ts b/api/js/etemplate/Et2InputWidget/Et2InputWidget.ts index ba8428432c..335ddbe824 100644 --- a/api/js/etemplate/Et2InputWidget/Et2InputWidget.ts +++ b/api/js/etemplate/Et2InputWidget/Et2InputWidget.ts @@ -698,7 +698,7 @@ const Et2InputWidgetMixin = >(superclass : T) */ async validate(skipManual = false) { - return validate(this,skipManual) + return validate(this, skipManual).then(() => this.requestUpdate()); } set_validation_error(err : string | false) @@ -799,7 +799,7 @@ const Et2InputWidgetMixin = >(superclass : T) protected _helpTextTemplate() : TemplateResult | typeof nothing { const hasHelpTextSlot = this.hasSlotController?.test('help-text'); - const hasHelpText = this.helpText ? true : !!hasHelpTextSlot; + const hasHelpText = this.helpText ? true : !!hasHelpTextSlot || this.hasFeedbackFor.length > 0; return hasHelpText ? html`