Files
openswarm/frontend/src/shared/dashboardClipboard.ts
T
2026-03-30 05:39:24 -07:00

28 lines
561 B
TypeScript

import type { CardType } from '@/app/pages/Dashboard/useDashboardSelection';
export interface ClipboardCard {
type: CardType;
id: string;
name: string;
meta: Record<string, any>;
x: number;
y: number;
width: number;
height: number;
expanded?: boolean;
}
let clipboardCards: ClipboardCard[] = [];
export function setClipboardCards(cards: ClipboardCard[]): void {
clipboardCards = cards;
}
export function getClipboardCards(): ClipboardCard[] {
return clipboardCards;
}
export function clearClipboard(): void {
clipboardCards = [];
}