Files
bot/apps/builder/src/features/graph/constants.ts
2023-03-15 11:52:38 +01:00

29 lines
471 B
TypeScript

import { Coordinates } from './types'
export const stubLength = 20
export const blockWidth = 300
export const blockAnchorsOffset = {
left: {
x: 0,
y: 20,
},
top: {
x: blockWidth / 2,
y: 0,
},
right: {
x: blockWidth,
y: 20,
},
}
export const graphPositionDefaultValue = (
firstGroupCoordinates: Coordinates
) => ({
x: 400 - firstGroupCoordinates.x,
y: 100 - firstGroupCoordinates.y,
scale: 1,
})
export const pathRadius = 20