@rxap/window-system
Version:
A module for creating and managing windows within an Angular application. It provides components for window containers, toolbars, resizers, action bars, and task bars, along with services for managing window instances and configurations. This library allo
36 lines (35 loc) • 1.17 kB
TypeScript
import { ComponentType } from '@angular/cdk/portal';
import { ComponentFactoryResolver, Injector, TemplateRef, ViewContainerRef } from '@angular/core';
import { ButtonDefinition } from '@rxap/rxjs';
import { IconConfig } from '@rxap/utilities';
export interface WindowActions<A> {
position?: 'start' | 'end';
definitions: ButtonDefinition<[A]>[];
}
export interface WindowSettings<D = any> {
id?: string;
title?: string;
icon?: IconConfig;
width?: string;
height?: string;
minWidth?: string;
minHeight?: string;
maxWidth?: string;
maxHeight?: string;
resizeable?: boolean;
minimizable?: boolean;
draggable?: boolean;
panelClass?: string;
data?: D;
actions?: WindowActions<D>;
}
export interface WindowConfig<D = any, T = any> extends WindowSettings<D> {
windowComponent?: ComponentType<T>;
component?: ComponentType<T>;
template?: TemplateRef<T>;
injector?: Injector | null;
injectorName?: string;
componentFactoryResolver?: ComponentFactoryResolver | null;
viewContainerRef?: ViewContainerRef | null;
}
export declare const DEFAULT_WINDOW_CONFIG: WindowConfig<any, any>;