mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-18 11:36:36 +00:00
refactor(types): use typed SvelteComponent interface for typing components
This commit is contained in:
parent
4226535338
commit
dab82d3479
156 changed files with 1379 additions and 1667 deletions
15
types/DatePicker/DatePickerInput.d.ts
vendored
15
types/DatePicker/DatePickerInput.d.ts
vendored
|
@ -1,4 +1,5 @@
|
|||
/// <reference types="svelte" />
|
||||
import { SvelteComponent } from "svelte";
|
||||
|
||||
export interface DatePickerInputProps extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["div"]> {
|
||||
/**
|
||||
|
@ -78,12 +79,8 @@ export interface DatePickerInputProps extends svelte.JSX.HTMLAttributes<HTMLElem
|
|||
ref?: null | HTMLInputElement;
|
||||
}
|
||||
|
||||
export default class DatePickerInput {
|
||||
$$prop_def: DatePickerInputProps;
|
||||
$$slot_def: {};
|
||||
|
||||
$on(eventname: "input", cb: (event: WindowEventMap["input"]) => void): () => void;
|
||||
$on(eventname: "keydown", cb: (event: WindowEventMap["keydown"]) => void): () => void;
|
||||
$on(eventname: "blur", cb: (event: WindowEventMap["blur"]) => void): () => void;
|
||||
$on(eventname: string, cb: (event: Event) => void): () => void;
|
||||
}
|
||||
export default class DatePickerInput extends SvelteComponent<
|
||||
DatePickerInputProps,
|
||||
{ input: WindowEventMap["input"]; keydown: WindowEventMap["keydown"]; blur: WindowEventMap["blur"] },
|
||||
{}
|
||||
> {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue