/* eslint-disable import/group-exports */ import { SylPlugin, SylUnionPlugin } from '../schema'; // eslint-disable-next-line @typescript-eslint/no-namespace namespace Types { export type noop = () => void; export interface StringMap { [index: string]: T; } export type ValueOf = T extends Array ? T[number] : T[keyof T]; export interface IRangeStatic { index: number; length: number; } export interface BoundingStatic { left: number; top: number; right: number; bottom: number; } export interface Ctor { new (...props: any[]): Instance; } export interface DeepArray extends Array> {} } interface ISylPluginProps { controllerProps?: Types.StringMap; layers?: Types.StringMap; } interface IConfigPluginObj { plugin: ISylPlugin; controllerProps?: Types.StringMap; layers?: Types.StringMap<(props: any) => any>; // custom layers } type ISylPlugin = typeof SylPlugin | typeof SylUnionPlugin | Plugin | SylPlugin | SylUnionPlugin; type ISylPluginConfig = ISylPlugin | IConfigPluginObj; export { IConfigPluginObj, ISylPluginConfig, ISylPluginProps, Types };