Merge remote-tracking branch 'origin/main' into arrow-heads-fallback-color
This commit is contained in:
@@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
'@xyflow/react': patch
|
||||||
|
'@xyflow/system': patch
|
||||||
|
---
|
||||||
|
|
||||||
|
Allow strings and enums for existing marker types
|
||||||
@@ -28,7 +28,7 @@ export const MarkerSymbols = {
|
|||||||
[MarkerType.ArrowClosed]: ArrowClosedSymbol,
|
[MarkerType.ArrowClosed]: ArrowClosedSymbol,
|
||||||
};
|
};
|
||||||
|
|
||||||
export function useMarkerSymbol(type: MarkerType) {
|
export function useMarkerSymbol(type: MarkerType | `${MarkerType}`) {
|
||||||
const store = useStoreApi();
|
const store = useStoreApi();
|
||||||
|
|
||||||
const symbol = useMemo(() => {
|
const symbol = useMemo(() => {
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ export enum ConnectionLineType {
|
|||||||
* @public
|
* @public
|
||||||
*/
|
*/
|
||||||
export type EdgeMarker = {
|
export type EdgeMarker = {
|
||||||
type: MarkerType;
|
type: MarkerType | `${MarkerType}`;
|
||||||
color?: string;
|
color?: string;
|
||||||
width?: number;
|
width?: number;
|
||||||
height?: number;
|
height?: number;
|
||||||
|
|||||||
Reference in New Issue
Block a user