ConceptPortal-public/rsconcept/frontend/src/features/oss/models/ossLayout.ts
Ivan 6e8192404f
Some checks are pending
Frontend CI / build (22.x) (push) Waiting to run
R: Refactor type definitions
2025-02-18 19:40:24 +03:00

40 lines
631 B
TypeScript

/**
* Module: OSS representation.
*/
import { Node } from 'reactflow';
import { IOperation } from '../backend/types';
/**
* Represents XY Position.
*/
export interface Position2D {
x: number;
y: number;
}
/**
* Represents graph OSS node data.
*/
export interface OssNode extends Node {
id: string;
data: {
label: string;
operation: IOperation;
};
position: { x: number; y: number };
}
/**
* Represents graph OSS node internal data.
*/
export interface OssNodeInternal {
id: string;
data: {
label: string;
operation: IOperation;
};
dragging: boolean;
xPos: number;
yPos: number;
}