mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-14 18:01:06 +00:00
feat(typescript)!: support svelte 4 (#1773)
Closes #1753 The minimum Svelte version required for TypeScript users is now 3.55.
This commit is contained in:
parent
778b2c357f
commit
2f026f792a
192 changed files with 941 additions and 712 deletions
7
types/ContextMenu/ContextMenu.svelte.d.ts
vendored
7
types/ContextMenu/ContextMenu.svelte.d.ts
vendored
|
@ -1,8 +1,9 @@
|
|||
/// <reference types="svelte" />
|
||||
import type { SvelteComponentTyped } from "svelte";
|
||||
import type { SvelteHTMLElements } from "svelte/elements";
|
||||
|
||||
export interface ContextMenuProps
|
||||
extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]> {
|
||||
type RestProps = SvelteHTMLElements["ul"];
|
||||
|
||||
export interface ContextMenuProps extends RestProps {
|
||||
/**
|
||||
* Specify an element or list of elements to trigger the context menu.
|
||||
* If no element is specified, the context menu applies to the entire window
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
/// <reference types="svelte" />
|
||||
import type { SvelteComponentTyped } from "svelte";
|
||||
|
||||
export interface ContextMenuDividerProps {}
|
||||
|
||||
export default class ContextMenuDivider extends SvelteComponentTyped<
|
||||
ContextMenuDividerProps,
|
||||
{},
|
||||
Record<string, any>,
|
||||
{}
|
||||
> {}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="svelte" />
|
||||
import type { SvelteComponentTyped } from "svelte";
|
||||
|
||||
export interface ContextMenuGroupProps {
|
||||
|
@ -16,6 +15,6 @@ export interface ContextMenuGroupProps {
|
|||
|
||||
export default class ContextMenuGroup extends SvelteComponentTyped<
|
||||
ContextMenuGroupProps,
|
||||
{},
|
||||
Record<string, any>,
|
||||
{ default: {} }
|
||||
> {}
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
/// <reference types="svelte" />
|
||||
import type { SvelteComponentTyped } from "svelte";
|
||||
import type { SvelteHTMLElements } from "svelte/elements";
|
||||
|
||||
export interface ContextMenuOptionProps
|
||||
extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["li"]> {
|
||||
type RestProps = SvelteHTMLElements["li"];
|
||||
|
||||
export interface ContextMenuOptionProps extends RestProps {
|
||||
/**
|
||||
* Specify the kind of option
|
||||
* @default "default"
|
||||
|
@ -26,7 +27,7 @@ export interface ContextMenuOptionProps
|
|||
* Icon is rendered to the left of the label text
|
||||
* @default undefined
|
||||
*/
|
||||
icon?: typeof import("svelte").SvelteComponent;
|
||||
icon?: typeof import("svelte").SvelteComponent<any>;
|
||||
|
||||
/**
|
||||
* Specify the label text
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
/// <reference types="svelte" />
|
||||
import type { SvelteComponentTyped } from "svelte";
|
||||
|
||||
export interface ContextMenuRadioGroupProps {
|
||||
|
@ -17,6 +16,6 @@ export interface ContextMenuRadioGroupProps {
|
|||
|
||||
export default class ContextMenuRadioGroup extends SvelteComponentTyped<
|
||||
ContextMenuRadioGroupProps,
|
||||
{},
|
||||
Record<string, any>,
|
||||
{ default: {} }
|
||||
> {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue