import { Component, ComponentOptions } from 'vue'; import { DeepPartial } from './misc'; import { Field } from './fields'; import { Query } from './query'; export type PanelQuery = { collection: string; query: Query; key?: string }; export interface PanelConfig { id: string; name: string; icon: string; description?: string; query?: (options: Record) => PanelQuery | PanelQuery[] | undefined; variable?: true; // Mark the panel as a global variable component: Component; options: | DeepPartial[] | { standard: DeepPartial[]; advanced: DeepPartial[] } | (( ctx: Partial ) => DeepPartial[] | { standard: DeepPartial[]; advanced: DeepPartial[] }) | ComponentOptions | null; minWidth: number; minHeight: number; skipUndefinedKeys?: string[]; } export type Panel = { id: string; dashboard: string; show_header: boolean; name: string; icon: string; color: string; note: string; type: string; position_x: number; position_y: number; width: number; height: number; options: Record; date_created: string; user_created: string; };