From 602ac44c1562f704f59d0f57228acd9bda53001d Mon Sep 17 00:00:00 2001 From: nathan Date: Tue, 21 Dec 2021 10:50:21 -0700 Subject: [PATCH] Fix readonly webcomponents inside a legacy widget were not loaded as readonly --- api/js/etemplate/et2_core_widget.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/api/js/etemplate/et2_core_widget.ts b/api/js/etemplate/et2_core_widget.ts index 445fc6edca..67538b1cef 100644 --- a/api/js/etemplate/et2_core_widget.ts +++ b/api/js/etemplate/et2_core_widget.ts @@ -803,6 +803,10 @@ export class et2_widget extends ClassWithAttributes } else { + if(readonly === true && typeof window.customElements.get(_nodeName + "_ro") != "undefined") + { + _nodeName += "_ro"; + } widget = loadWebComponent(_nodeName, _node, this); } return widget;