@conboai/storybook.components 0.3.65 → 0.3.68

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
2
  import { IShapesProps } from './types';
3
3
 
4
- declare const Shapes: ({ children, mode: modeFromProps, onModeChange: _onModeChange, shapes: shapesFromProps, selected, onShapeChange, onShapeSelect, onMouseMove, menu, showNumbers, showId, showOnlyPoints, showPoints, showDirection }: IShapesProps) => React.JSX.Element;
4
+ declare const Shapes: ({ children, mode: modeFromProps, onModeChange: _onModeChange, shapes: shapesFromProps, selected, onShapeChange, onShapeSelect, onMouseMove, menu, showNumbers, showId, showOnlyPoints, showPoints, showDirection, selectedShapeZIndex, styles }: IShapesProps) => React.JSX.Element;
5
5
  export default Shapes;
@@ -45,5 +45,7 @@ export interface IShapesProps {
45
45
  showDirection?: boolean;
46
46
  showNumbers?: boolean;
47
47
  showOnlyPoints?: boolean;
48
+ selectedShapeZIndex?: boolean;
48
49
  showPoints?: boolean;
50
+ styles?: any;
49
51
  }
@@ -1,4 +1,4 @@
1
- import { Point } from './types';
1
+ import { Point, Shape } from './types';
2
2
 
3
3
  export declare const generateRainbowColor: (id: string, total: number) => string;
4
4
  export declare const toNormalizedCoords: (x: number, y: number, rect: DOMRect) => Point;
@@ -8,3 +8,5 @@ export declare const isPointNearFirstPoint: (point: Point, firstPoint: Point, th
8
8
  export declare const calculateDistanceToSegment: (point: Point, segmentStart: Point, segmentEnd: Point) => number;
9
9
  export declare const shapePointsToArray: (shapePoints: Point[]) => Array<[number, number]>;
10
10
  export declare const arrayToShapePoints: (pixelsList?: Array<[number, number]>) => Point[];
11
+ export declare const getAspectRatio: (width?: number, height?: number) => string;
12
+ export declare function sortPolygonsByArea(polygons: Shape[]): Shape[];