@descope/web-components-ui 1.0.377 → 1.0.378
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.cjs.js +3 -5
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/index.esm.js +3 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/umd/DescopeDev.js +1 -1
- package/dist/umd/descope-enriched-text-index-js.js +1 -1
- package/package.json +1 -1
- package/src/components/descope-enriched-text/EnrichedTextClass.js +3 -5
package/dist/cjs/index.cjs.js
CHANGED
@@ -5624,14 +5624,12 @@ class EnrichedText extends createBaseClass({ componentName: componentName$F, bas
|
|
5624
5624
|
|
5625
5625
|
let html = decodeHTML(this.innerHTML);
|
5626
5626
|
|
5627
|
-
if (!html) {
|
5627
|
+
if (!html?.trim() && this.isConnected) {
|
5628
5628
|
this.setAttribute('empty', 'true');
|
5629
|
-
|
5630
|
-
|
5629
|
+
} else {
|
5630
|
+
this.removeAttribute('empty');
|
5631
5631
|
}
|
5632
5632
|
|
5633
|
-
this.removeAttribute('empty');
|
5634
|
-
|
5635
5633
|
try {
|
5636
5634
|
const tokens = this.processor.parse(html, { references: undefined });
|
5637
5635
|
html = this.processor.renderer.render(tokens, { html: true, breaks: true });
|