Hello everyone,
I’m currently building an app that uses multiple CUSTOM_MODEL views—one embedded in the deals sidebar, and another that opens as a modal via a button click inside that sidebar.
Using the App Extensions SDK, I open the modal with OPEN_MODEL and pass data into it successfully.
async displayModel(id: string, name: string, modelId: string): Promise<void> {
const sdk = await this.initialize();
await sdk.execute(Command.OPEN_MODAL, {
type: Modal.CUSTOM_MODAL,
action_id: modelId,
data: {
id: id,
name: name,
},
});
}
After the form in the modal is filled and submitted, I close the modal using CLOSE_MODEL. However, I’m unable to pass any context (e.g., customer ID or form data) back to the sidebar CUSTOM_MODEL to update the UI or trigger a snackbar confirmation.
Has anyone implemented a pattern like this? What’s the best way to send data back to the sidebar after closing a modal so I can update the view and show feedback?
Would appreciate any help or ideas—thanks in advance!