import * as vue28 from "vue"; import { App, DeepReadonly, VNode } from "vue"; //#region src/components/Window.vue.d.ts type __VLS_Props$1 = { window: DeepReadonly; }; declare var __VLS_6: {}; type __VLS_Slots = {} & { default?: (props: typeof __VLS_6) => any; }; declare const __VLS_base: vue28.DefineComponent<__VLS_Props$1, {}, {}, {}, {}, vue28.ComponentOptionsMixin, vue28.ComponentOptionsMixin, {}, string, vue28.PublicProps, Readonly<__VLS_Props$1> & Readonly<{}>, {}, {}, {}, {}, string, vue28.ComponentProvideOptions, false, {}, any>; declare const __VLS_export$1: __VLS_WithSlots; declare const _default$2: typeof __VLS_export$1; type __VLS_WithSlots = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/WindowManager.vue.d.ts type __VLS_Props = { /** * scoop custom class name | 范围自定义类名 * @description if set, will extend default class name | 如果设置了范围自定义类名,会扩展默认类名 */ customClass?: { /** custom class name for manager | 自定义管理器类名 */ manager?: string; /** custom class name for window | 自定义窗口类名 */ window?: string; }; }; declare const __VLS_export: vue28.DefineComponent<__VLS_Props, {}, {}, {}, {}, vue28.ComponentOptionsMixin, vue28.ComponentOptionsMixin, {}, string, vue28.PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, vue28.ComponentProvideOptions, false, {}, any>; declare const _default$1: typeof __VLS_export; //#endregion //#region src/types/window.d.ts /** late window options | late window 窗口选项 */ declare type LateWindowOptions = { /** window icon | 窗口图标 */ icon?: string; /** * window title | 窗口标题 * @default 'Untitled Window' */ title?: string; /** window content | 窗口内容 */ content?: string | VNode; /** window maximized state | 窗口最大化状态 */ isMaximized?: boolean; /** window minimized state | 窗口最小化状态 */ isMinimized?: boolean; /** * window position | 窗口位置 * @default { x: 50 + (state.windows.length * 20), y: 50 + (state.windows.length * 20) } */ position?: { x: number; y: number; }; /** * window size | 窗口大小 * @default { width: 800, height: 600 } */ size?: { /** @default 800 */ width: number | string; /** @default 600 */ height: number | string; }; /** window closeable state | 窗口能否关闭 */ closeable?: boolean; /** window moveable state | 窗口能否移动 */ moveable?: boolean; /** window maximizable state | 窗口能否最大化 */ maximizable?: boolean; /** window minimizable state | 窗口能否最小化 */ minimizable?: boolean; /** custom controls | 自定义窗口控件 */ controls?: VNode[]; }; /** late window state | late window 窗口状态 */ declare type LateWindowState = LateWindowOptions & { /** * window unique id | 窗口唯一标识 * @requires */ id: string; /** window z-index | 窗口 z-index */ zIndex: number; /** window last position | 窗口上次位置 */ lastPosition?: { x: number; y: number; }; /** window last size | 窗口上次大小 */ lastSize?: { width: number | string; height: number | string; }; }; //#endregion //#region src/types/options.d.ts /** late window manager options | late window 窗口管理器选项 */ declare type UserOptions = { /** default console options | 默认控制台选项 */ console?: { /** * enable console log | 启用控制台日志 * @default true */ enabled?: boolean; }; /** default window options | 默认窗口选项 */ window?: LateWindowOptions; /** default window manager options | 默认窗口管理器选项 */ manager?: { /** * initial z-index | 初始 z-index * @default 100 */ initZIndex?: number; /** custom class name | 自定义类名 */ customClass?: { /** * custom class name for window manager | 窗口管理器自定义类名 * @default 'late-window-manager' */ manager?: string; /** * custom class name for window | 窗口自定义类名 * @default 'late-window' */ window?: string; }; /** * globally register components | 全局注册组件 * @default true */ globallyRegisterComponts?: boolean; }; }; //#endregion //#region src/types/index.d.ts declare global { /** late window manager namespace | late window 窗口管理器命名空间 */ namespace LWM { /** late window manager instance | late window 窗口管理器实例 */ interface Instance { /** late window manager actions | late window 窗口管理器操作 */ actions: { /** focus window | 聚焦窗口 */ focusWindow: (id: string) => void; /** close window | 关闭窗口 */ closeWindow: (id: string) => void; /** open new window | 打开新窗口 */ openWindow: (id: string, options?: LateWindowOptions) => void; /** maximize window | 最大化窗口 */ maximizeWindow: (id: string) => void; /** minimize window | 最小化窗口 */ minimizeWindow: (id: string) => void; /** update window position | 更新窗口位置 */ updateWindowPos: (id: string, pos: { x: number; y: number; }) => void; }; /** * late window manager default options | late window 窗口管理器默认选项 * @readonly */ DefaultOptions: DeepReadonly; /** * late window manager state | late window 窗口管理器状态 * @readonly */ State: DeepReadonly<{ /** active window id | 活动窗口 id */ activeWindowId: string | null; /** windows list | 窗口列表 */ windows: LateWindowState[]; }>; } /** late window manager element namespace | late window 窗口管理器元素命名空间 */ namespace Element { /** late window element | late window 窗口元素 */ type LateWindow = typeof _default$2; /** late window manager element | late window 窗口管理器元素 */ type LateWindowManager = typeof _default$1; } } } declare module 'vue' { interface ComponentCustomProperties { /** * late window manager instance | late window 窗口管理器实例 */ $lwm: LWM.Instance; } interface GlobalComponents { /** * late window element | late window 窗口元素 * @alias late-window */ LateWindow: LWM.Element.LateWindow; /** * late window element | late window 窗口元素 * @alias LateWindow */ 'late-window': LWM.Element.LateWindow; /** * late window manager | late window 窗口管理器 * @alias late-window-manager * @alias LWM */ LateWindowManager: LWM.Element.LateWindowManager; /** * late window manager element | late window 窗口管理器元素 * @alias LateWindowManager * @alias LWM */ 'late-window-manager': LWM.Element.LateWindowManager; /** * late window manager element | late window 窗口管理器元素 * @alias LateWindowManager * @alias late-window-manager */ LWM: LWM.Element.LateWindowManager; } } //#endregion //#region package.d.ts declare let version: string; //#endregion //#region src/index.d.ts declare const LateWindow: { new (...args: any[]): vue28.CreateComponentPublicInstanceWithMixins; }> & Readonly<{}>, {}, {}, {}, {}, vue28.ComponentOptionsMixin, vue28.ComponentOptionsMixin, {}, vue28.PublicProps, {}, false, {}, {}, vue28.GlobalComponents, vue28.GlobalDirectives, string, {}, any, vue28.ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly<{ window: vue28.DeepReadonly; }> & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & vue28.ComponentOptionsBase; }> & Readonly<{}>, {}, {}, {}, {}, vue28.ComponentOptionsMixin, vue28.ComponentOptionsMixin, {}, string, {}, {}, string, {}, vue28.GlobalComponents, vue28.GlobalDirectives, string, vue28.ComponentProvideOptions> & vue28.VNodeProps & vue28.AllowedComponentProps & vue28.ComponentCustomProps & (new () => { $slots: { default?: (props: {}) => any; }; }); declare const LateWindowManager: vue28.DefineComponent<{ customClass?: { manager?: string; window?: string; }; }, {}, {}, {}, {}, vue28.ComponentOptionsMixin, vue28.ComponentOptionsMixin, {}, string, vue28.PublicProps, Readonly<{ customClass?: { manager?: string; window?: string; }; }> & Readonly<{}>, {}, {}, {}, {}, string, vue28.ComponentProvideOptions, false, {}, any>; declare const useLateWindowManager: () => LWM.Instance | undefined; declare const _default: { install(app: App, options?: UserOptions): void; }; //#endregion export { LateWindow, LateWindowManager, _default as default, useLateWindowManager as useLWM, useLateWindowManager, version };