From 6bca78b9cb927265a7c99032748406079a008fca Mon Sep 17 00:00:00 2001 From: Iryna Lagno Date: Fri, 17 May 2024 15:24:17 -0500 Subject: [PATCH] - remove from the documentation not supported functionality --- .../aem-universal-editor/api/events/index.md | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/pages/services/aem-universal-editor/api/events/index.md b/src/pages/services/aem-universal-editor/api/events/index.md index f44ed5c8..eaa47e42 100644 --- a/src/pages/services/aem-universal-editor/api/events/index.md +++ b/src/pages/services/aem-universal-editor/api/events/index.md @@ -11,15 +11,23 @@ The Universal Editor sends defined events to remote applications. In case the re ### Working with Events -If your business logic requires sending an event to the Universal Editor, you can use the `dispatchEvent` method. -Here's an example of how to dispatch the `aue:ui-select` event: +If your business logic requires sending an event to the Universal Editor, you can use the `triggerEvent` method. +Here's an example of how to dispatch the `aue:ui-viewport-change` event: ```js useEffect(() => { (async () => { const guestConnection = await attach({id: extensionId}); ... - await guestConnection.host.remoteApp.dispatchEvent('aue:ui-select', {data: 'some data'}); + await guestConnection.host.remoteApp.triggerEvent('aue:ui-viewport-change', + 'main', + { + details: { + height: 1024, + width: 768, + } + } + ); ... })(); }, []);