From b747a5b4ac99f1792e347c6a3a97cc8002379e6f Mon Sep 17 00:00:00 2001 From: Nick McCurdy Date: Fri, 20 Nov 2020 17:26:42 -0500 Subject: [PATCH] fix(types): allow all elements --- types/index.d.ts | 14 +++++++------- types/test.ts | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/types/index.d.ts b/types/index.d.ts index f50ac952..f5e7c5db 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -12,13 +12,13 @@ import {queries, EventType, BoundFunctions} from '@testing-library/dom' export * from '@testing-library/dom' export interface RenderResult extends BoundFunctions { - container: HTMLElement - baseElement: HTMLElement + container: Element + baseElement: Element debug: ( baseElement?: - | HTMLElement + | Element | DocumentFragment - | Array, + | Array, maxLength?: number, options?: PrettyFormatOptions, ) => void @@ -36,8 +36,8 @@ export interface RenderOptions props?: object store?: StoreOptions routes?: RouteConfig[] - container?: HTMLElement - baseElement?: HTMLElement + container?: Element + baseElement?: Element } export type ConfigurationCallback = ( @@ -68,7 +68,7 @@ export interface VueFireEventObject extends AsyncFireObject { element: HTMLInputElement | HTMLSelectElement | HTMLTextAreaElement, value: string, ): Promise - update(element: HTMLElement, value?: string): Promise + update(element: Element, value?: string): Promise } export const fireEvent: VueFireEventObject diff --git a/types/test.ts b/types/test.ts index 6663d3c7..18092963 100644 --- a/types/test.ts +++ b/types/test.ts @@ -1,7 +1,7 @@ import Vue from 'vue' import {render, fireEvent, screen, waitFor} from '@testing-library/vue' -declare const elem: HTMLElement +declare const elem: Element const SomeComponent = Vue.extend({ name: 'SomeComponent',