UNPKG

@aurigma/design-atoms

Version:

Design Atoms is a part of Customer's Canvas SDK which allows for manipulating individual design elements through your code.

40 lines (39 loc) 1.64 kB
import { Violation, IViolationInfo, ViolationState, ITotalViolationInfo } from "./Violation"; import { Item } from "@aurigma/design-atoms-model/Product/Items"; import { ProductHandler } from "../../ProductHandler"; import { IViewerMessagesConfig, IQualityMeterConfig } from "../../../Viewer/Interfaces"; import { EventManager } from "../../EventManager"; export declare class ImageQualityViolation extends Violation { private _productHandler; private _messages; private _renderingDpi; private _eventManager; private _dpiValuePlaceholder; private _qualityLevels; constructor(_productHandler: ProductHandler, config: IQualityMeterConfig, _messages: IViewerMessagesConfig, _renderingDpi: number, _eventManager: EventManager); set renderingDpi(value: number); isAvailableFor(item: Item): boolean; getViolationInfo(item: Item, oldViolationInfo: ITotalViolationInfo): IViolationInfo; private _getQualityInfo; /** * Retrieves the target DPI from the container constraints if specified. * If no constraint is set, it falls back to the default `_renderingDpi`. */ private _getTargetDpi; private _getRenderingToSourceImageDpiRatio; private _getMessage; private _checkDpiChanging; getStatePropertyName(): string; getDataPropertyName(): string; static dataPropertyName: string; static statePropertyName: string; } export interface IDpiChangedEventArgs { oldValue: number; newValue: number; item: Item; state: ViolationState; } export interface IImageQualityViolationData { dpiValue: number; }