@adobe/cq-angular-editable-components
Version:
* [API](#api) * [Documentation](#documentation) * [Changelog](#changelog)
35 lines (34 loc) • 1.48 kB
TypeScript
import { ComponentMapping as SPAComponentMapping } from '@adobe/cq-spa-component-mapping';
/**
* The current class extends the @adobe/cq-spa-component-mapping#Mapto library and features with Angular specifics such as
*
* - Storing the editing configurations for each resource type
*/
export declare class ComponentMappingWithConfig {
private spaMapping;
/**
* Store of EditConfig structures
*/
private editConfigMap;
constructor(spaMapping: SPAComponentMapping);
/**
* Stores a component class for the given resource types and also allows to provide an EditConfig object
* @param resourceTypes - List of resource types
* @param clazz - Component class to be stored
* @param [editConfig] - Edit configuration to be stored for the given resource types
*/
map(resourceTypes: any, clazz: any, editConfig?: any): void;
/**
* Returns the component class for the given resourceType
* @param resourceType - Resource type for which the component class has been stored
*/
get(resourceType: any): any;
/**
* Returns the EditConfig structure for the given type
* @param resourceType - Resource type for which the configuration has been stored
*/
getEditConfig(resourceType: any): any;
}
declare let componentMapping: ComponentMappingWithConfig;
declare function MapTo(resourceTypes: any): (clazz: any, editConfig?: any) => void;
export { componentMapping as ComponentMapping, MapTo };