From 2f29a6728a0daa782f3f0874179d3f98b0d7cc42 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20Lyngs=C3=B8?= Date: Mon, 27 May 2024 11:13:28 +0200 Subject: [PATCH] correct to Umbraco.TinyMCE for block layout --- .../tiny-mce/property-editor-ui-tiny-mce.element.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/tiny-mce/property-editors/tiny-mce/property-editor-ui-tiny-mce.element.ts b/src/Umbraco.Web.UI.Client/src/packages/tiny-mce/property-editors/tiny-mce/property-editor-ui-tiny-mce.element.ts index 2a18f9014f..1fa9cc13ae 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/tiny-mce/property-editors/tiny-mce/property-editor-ui-tiny-mce.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/tiny-mce/property-editors/tiny-mce/property-editor-ui-tiny-mce.element.ts @@ -19,6 +19,8 @@ export interface UmbRichTextEditorValueType { blocks: UmbBlockValueType; } +const UMB_BLOCK_RTE_BLOCK_LAYOUT_ALIAS = 'Umbraco.TinyMCE'; // Not rich text, cause this has not been migrated [NL] + /** * @element umb-property-editor-ui-tiny-mce */ @@ -47,7 +49,7 @@ export class UmbPropertyEditorUITinyMceElement extends UmbLitElement implements buildUpValue.blocks.settingsData ??= []; this._value = buildUpValue as UmbRichTextEditorValueType; - this.#managerContext.setLayouts(buildUpValue.blocks.layout[UMB_BLOCK_RTE_PROPERTY_EDITOR_SCHEMA_ALIAS] ?? []); + this.#managerContext.setLayouts(buildUpValue.blocks.layout[UMB_BLOCK_RTE_BLOCK_LAYOUT_ALIAS] ?? []); this.#managerContext.setContents(buildUpValue.blocks.contentData); this.#managerContext.setSettings(buildUpValue.blocks.settingsData); } @@ -73,7 +75,7 @@ export class UmbPropertyEditorUITinyMceElement extends UmbLitElement implements this.observe(this.#managerContext.layouts, (layouts) => { this._value = { ...this._value, - blocks: { ...this._value.blocks, layout: { [UMB_BLOCK_RTE_PROPERTY_EDITOR_SCHEMA_ALIAS]: layouts } }, + blocks: { ...this._value.blocks, layout: { [UMB_BLOCK_RTE_BLOCK_LAYOUT_ALIAS]: layouts } }, }; this.#fireChangeEvent(); });