@aurigma/design-atoms
Version: 
Design Atoms is a part of Customer's Canvas SDK which allows for manipulating individual design elements through your code.
33 lines (32 loc) • 1.44 kB
TypeScript
import { BaseTextItem, ShapeItem, LineItem, DashedLineItem, PlaceholderItem, ImageItem, BarcodeItem, ClipartItem } from "@aurigma/design-atoms-model/Product/Items";
import { ItemData } from "@aurigma/design-atoms-model/Product/ItemsData";
import { IColorParser } from "./Serialization/Color";
import { IColorPreviewService } from "./Services/IColorPreviewService";
export declare class ItemDataHandler {
    private _itemData;
    private _colorPreviewServce;
    private _colorParser;
    constructor(_itemData: ItemData, _colorPreviewServce: IColorPreviewService, _colorParser: IColorParser);
    applyImage(image: ImageItem): boolean;
    applyLine(line: LineItem): boolean;
    applyDashedLine(dashedLine: DashedLineItem): boolean;
    applyBaseText(text: BaseTextItem): Promise<boolean>;
    applyShape(shape: ShapeItem): boolean;
    applyClipart(clipart: ClipartItem): boolean;
    applyBarcode(barcode: BarcodeItem): boolean;
    applyPlaceholder(placeholder: PlaceholderItem): boolean;
    private _applyFillColor;
    private _applyClipartColors;
    private _applyTextFillColor;
    private _applyFont;
    private _applyTextProperty;
    private _applyShadow;
    private _applyStroke;
    private _applyOpacity;
    private _applyVisibility;
    private _applyBorderColor;
    private _applyBorderWidth;
    private _applyColor;
    private _tryApplyColor;
    private _applyBarcodeColor;
}