/************************************************************************* * Copyright 2022 Adobe * All Rights Reserved. * * NOTICE: Adobe permits you to use, modify, and distribute this file in * accordance with the terms of the Adobe license agreement accompanying * it. If you have received this file from a source other than Adobe, * then your use, modification, or distribution of it requires the prior * written permission of Adobe. **************************************************************************/ export declare enum COMPONENT { ACC_EMAIL_DESIGNER = "creative-designer", EMAIL_DESIGNER = "cjm-email-designer", FIRST_MILE = "ajoFirstmile", MARKETO_TEMPLATE_CONVERTER = "marketoTemplateConverter" } /** * Defines the data argument that is passed to the open function. */ export interface OpenDataParam { componentPath?: string; [key: string]: any; } /** * Defines component APIs available to solutions. */ export interface ComponentApi { /** * Tells the Unified Shell to close the component modal. * * ```typescript * component.close({some: 'data'}); * ``` */ close(data?: any): void; /** * Tells the calling application if it is loaded as a component. * * ```typescript * component.isComponent(); * ``` */ isComponent(): boolean; /** * Tells the Unifed Shell to open the specified component within an iframe in * a modal. Promise is resolved when the component modal is closed. * * ```typescript * component.open(COMPONENT.EMAIL_DESIGNER, {item: 'value'}).then((data: Record) => { * // Handle the data * }); */ open(component: COMPONENT, data?: Record): Promise | undefined>; } declare const component: ComponentApi; export default component;