From 3e16bad550b55c0f40fbeb6aed2ed3d580a17ed0 Mon Sep 17 00:00:00 2001 From: Tim Martin Date: Sun, 14 Jul 2024 08:59:37 -0500 Subject: [PATCH] Include SVGElement in types --- src/lib/index.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lib/index.ts b/src/lib/index.ts index dcc1f78..271965d 100644 --- a/src/lib/index.ts +++ b/src/lib/index.ts @@ -18,9 +18,9 @@ export type ComputeConfig = Partial & { autoUpdate?: boolean | Partial }; export type UpdatePosition = (contentOptions?: Omit) => void; -export type ReferenceAction = (node: HTMLElement | Writable | VirtualElement) => void; -export type ContentAction = (node: HTMLElement, contentOptions?: ComputeConfig) => void; -export type ArrowOptions = { padding?: Padding, element: Writable }; +export type ReferenceAction = (node: HTMLElement | SVGElement | Writable | VirtualElement) => void; +export type ContentAction = (node: HTMLElement | SVGElement, contentOptions?: ComputeConfig) => void; +export type ArrowOptions = { padding?: Padding, element: Writable }; export function createFloatingActions(initOptions?: ComputeConfig): [ReferenceAction, ContentAction, UpdatePosition] { let referenceElement: ReferenceElement;