From 98302e417eca5f51bc2657be1587b2def1840e59 Mon Sep 17 00:00:00 2001 From: Mert Sincan Date: Thu, 16 May 2024 11:50:43 +0100 Subject: [PATCH] Fixed #5405 - TypeScript emits are in an incompatible format with defineEmits --- components/lib/accordion/Accordion.d.ts | 10 +++-- .../accordioncontent/AccordionContent.d.ts | 10 +++-- .../lib/accordionheader/AccordionHeader.d.ts | 10 +++-- .../lib/accordionpanel/AccordionPanel.d.ts | 10 +++-- components/lib/accordiontab/AccordionTab.d.ts | 11 +++-- components/lib/autocomplete/AutoComplete.d.ts | 10 +++-- components/lib/avatar/Avatar.d.ts | 11 +++-- components/lib/avatargroup/AvatarGroup.d.ts | 11 +++-- components/lib/badge/Badge.d.ts | 11 +++-- components/lib/blockui/BlockUI.d.ts | 11 +++-- components/lib/breadcrumb/Breadcrumb.d.ts | 10 +++-- components/lib/button/Button.d.ts | 11 +++-- components/lib/buttongroup/ButtonGroup.d.ts | 11 +++-- components/lib/calendar/Calendar.d.ts | 11 +++-- components/lib/card/Card.d.ts | 11 +++-- components/lib/carousel/Carousel.d.ts | 10 +++-- .../lib/cascadeselect/CascadeSelect.d.ts | 11 +++-- components/lib/chart/Chart.d.ts | 36 ++++++++------- components/lib/checkbox/Checkbox.d.ts | 10 +++-- components/lib/chip/Chip.d.ts | 11 +++-- components/lib/chips/Chips.d.ts | 10 +++-- components/lib/colorpicker/ColorPicker.d.ts | 10 +++-- components/lib/column/Column.d.ts | 13 +++--- components/lib/columngroup/ColumnGroup.d.ts | 11 +++-- .../lib/confirmdialog/ConfirmDialog.d.ts | 11 +++-- components/lib/confirmpopup/ConfirmPopup.d.ts | 11 +++-- components/lib/contextmenu/ContextMenu.d.ts | 38 +++++++++------- components/lib/datatable/DataTable.d.ts | 27 ++++++----- components/lib/dataview/DataView.d.ts | 10 +++-- components/lib/datepicker/DatePicker.d.ts | 11 +++-- .../lib/deferredcontent/DeferredContent.d.ts | 11 +++-- components/lib/dialog/Dialog.d.ts | 11 +++-- components/lib/divider/Divider.d.ts | 10 +++-- components/lib/dock/Dock.d.ts | 10 +++-- components/lib/drawer/Drawer.d.ts | 11 +++-- components/lib/dropdown/Dropdown.d.ts | 39 +++++++++------- .../lib/dynamicdialog/DynamicDialog.d.ts | 19 ++++---- components/lib/editor/Editor.d.ts | 10 +++-- components/lib/fieldset/Fieldset.d.ts | 10 +++-- components/lib/fileupload/FileUpload.d.ts | 26 ++++++----- components/lib/floatlabel/FloatLabel.d.ts | 10 +++-- components/lib/galleria/Galleria.d.ts | 10 +++-- components/lib/iconfield/IconField.d.ts | 10 +++-- components/lib/icons/index.d.ts | 8 ++-- components/lib/image/Image.d.ts | 36 ++++++++------- .../lib/inlinemessage/InlineMessage.d.ts | 10 +++-- components/lib/inplace/Inplace.d.ts | 11 +++-- components/lib/inputchips/InputChips.d.ts | 10 +++-- components/lib/inputgroup/InputGroup.d.ts | 11 +++-- .../lib/inputgroupaddon/InputGroupAddon.d.ts | 11 +++-- components/lib/inputicon/InputIcon.d.ts | 11 +++-- components/lib/inputmask/InputMask.d.ts | 10 +++-- components/lib/inputnumber/InputNumber.d.ts | 27 ++++++----- components/lib/inputotp/InputOtp.d.ts | 10 +++-- components/lib/inputswitch/InputSwitch.d.ts | 10 +++-- components/lib/inputtext/InputText.d.ts | 11 +++-- components/lib/knob/Knob.d.ts | 12 +++-- components/lib/listbox/Listbox.d.ts | 10 +++-- components/lib/megamenu/MegaMenu.d.ts | 10 +++-- components/lib/menu/Menu.d.ts | 36 ++++++++------- components/lib/menubar/Menubar.d.ts | 10 +++-- components/lib/message/Message.d.ts | 10 +++-- components/lib/metergroup/MeterGroup.d.ts | 11 +++-- components/lib/multiselect/MultiSelect.d.ts | 36 ++++++++------- components/lib/orderlist/OrderList.d.ts | 11 +++-- .../organizationchart/OrganizationChart.d.ts | 11 +++-- components/lib/overlaypanel/OverlayPanel.d.ts | 39 +++++++++------- components/lib/paginator/Paginator.d.ts | 11 +++-- components/lib/panel/Panel.d.ts | 10 +++-- components/lib/panelmenu/PanelMenu.d.ts | 10 +++-- components/lib/password/Password.d.ts | 11 +++-- components/lib/picklist/PickList.d.ts | 11 +++-- components/lib/popover/Popover.d.ts | 35 ++++++++------- components/lib/portal/Portal.d.ts | 10 +++-- components/lib/progressbar/ProgressBar.d.ts | 11 +++-- .../lib/progressspinner/ProgressSpinner.d.ts | 11 +++-- components/lib/radiobutton/RadioButton.d.ts | 10 +++-- components/lib/rating/Rating.d.ts | 11 +++-- components/lib/row/Row.d.ts | 11 +++-- components/lib/scrollpanel/ScrollPanel.d.ts | 10 +++-- components/lib/scrolltop/ScrollTop.d.ts | 11 +++-- components/lib/select/Select.d.ts | 45 +++++++++++-------- components/lib/selectbutton/SelectButton.d.ts | 11 +++-- components/lib/sidebar/Sidebar.d.ts | 11 +++-- components/lib/skeleton/Skeleton.d.ts | 11 +++-- components/lib/slider/Slider.d.ts | 10 +++-- components/lib/speeddial/SpeedDial.d.ts | 10 +++-- components/lib/splitbutton/SplitButton.d.ts | 10 +++-- components/lib/splitter/Splitter.d.ts | 10 +++-- .../lib/splitterpanel/SplitterPanel.d.ts | 10 +++-- components/lib/stepper/Stepper.d.ts | 10 +++-- components/lib/stepperpanel/StepperPanel.d.ts | 10 +++-- components/lib/steps/Steps.d.ts | 10 +++-- components/lib/tab/Tab.d.ts | 10 +++-- components/lib/tablist/TabList.d.ts | 10 +++-- components/lib/tabmenu/TabMenu.d.ts | 10 +++-- components/lib/tabpanel/TabPanel.d.ts | 10 +++-- components/lib/tabpanels/TabPanels.d.ts | 10 +++-- components/lib/tabs/Tabs.d.ts | 11 ++--- components/lib/tabview/TabView.d.ts | 10 +++-- components/lib/tag/Tag.d.ts | 11 +++-- components/lib/terminal/Terminal.d.ts | 11 +++-- components/lib/textarea/Textarea.d.ts | 10 +++-- components/lib/tieredmenu/TieredMenu.d.ts | 36 ++++++++------- components/lib/timeline/Timeline.d.ts | 11 +++-- components/lib/toast/Toast.d.ts | 10 +++-- components/lib/togglebutton/ToggleButton.d.ts | 10 +++-- components/lib/toggleswitch/ToggleSwitch.d.ts | 10 +++-- components/lib/toolbar/Toolbar.d.ts | 10 +++-- components/lib/tree/Tree.d.ts | 11 +++-- components/lib/treeselect/TreeSelect.d.ts | 35 ++++++++------- components/lib/treetable/TreeTable.d.ts | 11 +++-- components/lib/ts-helpers.d.ts | 24 +++++----- .../lib/virtualscroller/VirtualScroller.d.ts | 35 ++++++++------- 114 files changed, 948 insertions(+), 637 deletions(-) diff --git a/components/lib/accordion/Accordion.d.ts b/components/lib/accordion/Accordion.d.ts index 0191ad9cf..11b93511f 100755 --- a/components/lib/accordion/Accordion.d.ts +++ b/components/lib/accordion/Accordion.d.ts @@ -11,7 +11,7 @@ import { VNode } from 'vue'; import { AccordionTabPassThroughOptionType } from '../accordiontab'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type AccordionPassThroughOptionType = AccordionPassThroughAttributes | ((options: AccordionPassThroughMethodOptions) => AccordionPassThroughAttributes | string) | string | null | undefined; @@ -206,7 +206,7 @@ export interface AccordionSlots { /** * Defines valid emits in Accordion component. */ -export interface AccordionEmits { +interface AccordionEmitsOptions { /** * Emitted when the active panel changes. * @param {string | string[] | null | undefined} value - Value of new active panel. @@ -238,6 +238,8 @@ export interface AccordionEmits { 'tab-click'(event: AccordionClickEvent): void; } +export declare type AccordionEmits = EmitFn; + /** * **PrimeVue - Accordion** * @@ -250,11 +252,11 @@ export interface AccordionEmits { * @group Component * */ -declare class Accordion extends ClassComponent {} +declare const Accordion: DefineComponent; declare module 'vue' { export interface GlobalComponents { - Accordion: GlobalComponentConstructor; + Accordion: GlobalComponentConstructor; } } diff --git a/components/lib/accordioncontent/AccordionContent.d.ts b/components/lib/accordioncontent/AccordionContent.d.ts index b45e7d6b6..0256693b6 100755 --- a/components/lib/accordioncontent/AccordionContent.d.ts +++ b/components/lib/accordioncontent/AccordionContent.d.ts @@ -10,7 +10,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type AccordionContentPassThroughOptionType = AccordionContentPassThroughAttributes | ((options: AccordionContentPassThroughMethodOptions) => AccordionContentPassThroughAttributes | string) | string | null | undefined; @@ -122,7 +122,9 @@ export interface AccordionContentSlots { default(): VNode[]; } -export interface AccordionContentEmits {} +interface AccordionContentEmitsOptions {} + +export declare type AccordionContentEmits = EmitFn; /** * **PrimeVue - AccordionContent** @@ -136,11 +138,11 @@ export interface AccordionContentEmits {} * @group Component * */ -declare class AccordionContent extends ClassComponent {} +declare const AccordionContent: DefineComponent; declare module 'vue' { export interface GlobalComponents { - AccordionContent: GlobalComponentConstructor; + AccordionContent: GlobalComponentConstructor; } } diff --git a/components/lib/accordionheader/AccordionHeader.d.ts b/components/lib/accordionheader/AccordionHeader.d.ts index c8dafd282..fabb01794 100755 --- a/components/lib/accordionheader/AccordionHeader.d.ts +++ b/components/lib/accordionheader/AccordionHeader.d.ts @@ -10,7 +10,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type AccordionHeaderPassThroughOptionType = AccordionHeaderPassThroughAttributes | ((options: AccordionHeaderPassThroughMethodOptions) => AccordionHeaderPassThroughAttributes | string) | string | null | undefined; @@ -122,7 +122,9 @@ export interface AccordionHeaderSlots { toggleicon(): VNode[]; } -export interface AccordionHeaderEmits {} +interface AccordionHeaderEmitsOptions {} + +export declare type AccordionHeaderEmits = EmitFn; /** * **PrimeVue - AccordionHeader** @@ -136,11 +138,11 @@ export interface AccordionHeaderEmits {} * @group Component * */ -declare class AccordionHeader extends ClassComponent {} +declare const AccordionHeader: DefineComponent; declare module 'vue' { export interface GlobalComponents { - AccordionHeader: GlobalComponentConstructor; + AccordionHeader: GlobalComponentConstructor; } } diff --git a/components/lib/accordionpanel/AccordionPanel.d.ts b/components/lib/accordionpanel/AccordionPanel.d.ts index a2b73844e..c74c4e310 100755 --- a/components/lib/accordionpanel/AccordionPanel.d.ts +++ b/components/lib/accordionpanel/AccordionPanel.d.ts @@ -10,7 +10,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type AccordionPanelPassThroughOptionType = AccordionPanelPassThroughAttributes | ((options: AccordionPanelPassThroughMethodOptions) => AccordionPanelPassThroughAttributes | string) | string | null | undefined; @@ -120,7 +120,9 @@ export interface AccordionPanelSlots { default(): VNode[]; } -export interface AccordionPanelEmits {} +interface AccordionPanelEmitsOptions {} + +export declare type AccordionPanelEmits = EmitFn; /** * **PrimeVue - AccordionPanel** @@ -134,11 +136,11 @@ export interface AccordionPanelEmits {} * @group Component * */ -declare class AccordionPanel extends ClassComponent {} +declare const AccordionPanel: DefineComponent; declare module 'vue' { export interface GlobalComponents { - AccordionPanel: GlobalComponentConstructor; + AccordionPanel: GlobalComponentConstructor; } } diff --git a/components/lib/accordiontab/AccordionTab.d.ts b/components/lib/accordiontab/AccordionTab.d.ts index 2099f021e..18a4e1e2c 100755 --- a/components/lib/accordiontab/AccordionTab.d.ts +++ b/components/lib/accordiontab/AccordionTab.d.ts @@ -10,7 +10,7 @@ */ import { AnchorHTMLAttributes, HTMLAttributes, TransitionProps, VNode } from 'vue'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type AccordionTabPassThroughOptionType = AccordionTabPassThroughAttributes | ((options: AccordionTabPassThroughMethodOptions) => AccordionTabPassThroughAttributes | string) | string | null | undefined; @@ -216,7 +216,9 @@ export interface AccordionTabSlots { /** * Defines valid emits in AcordionTab component. */ -export interface AccordionTabEmits {} +interface AccordionTabEmitsOptions {} + +export declare type AccordionTabEmits = EmitFn; /** * @deprecated since v4. Use the new structure of Accordion instead. @@ -230,12 +232,13 @@ export interface AccordionTabEmits {} * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png) * * @group Component + * */ -declare class AccordionTab extends ClassComponent {} +declare const AccordionTab: DefineComponent; declare module 'vue' { export interface GlobalComponents { - AccordionTab: GlobalComponentConstructor; + AccordionTab: GlobalComponentConstructor; } } diff --git a/components/lib/autocomplete/AutoComplete.d.ts b/components/lib/autocomplete/AutoComplete.d.ts index 812dc1def..a0167a5c4 100755 --- a/components/lib/autocomplete/AutoComplete.d.ts +++ b/components/lib/autocomplete/AutoComplete.d.ts @@ -12,7 +12,7 @@ import { ComponentHooks } from '../basecomponent'; import { ChipPassThroughOptions } from '../chip'; import { InputTextPassThroughOptions } from '../inputtext'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, HintedString, Nullable, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, HintedString, Nullable, PassThrough } from '../ts-helpers'; import { VirtualScrollerItemOptions, VirtualScrollerPassThroughOptionType, VirtualScrollerProps } from '../virtualscroller'; export declare type AutoCompletePassThroughOptionType = AutoCompletePassThroughAttributes | ((options: AutoCompletePassThroughMethodOptions) => AutoCompletePassThroughAttributes | string) | string | null | undefined; @@ -778,7 +778,7 @@ export interface AutoCompleteSlots { /** * Defines valid emits in AutoComplete component. */ -export interface AutoCompleteEmits { +interface AutoCompleteEmitsOptions { /** * Emitted when the value changes. * @param {*} value - New value. @@ -853,6 +853,8 @@ export interface AutoCompleteEmits { hide(): void; } +export declare type AutoCompleteEmits = EmitFn; + /** * **PrimeVue - AutoComplete** * @@ -865,11 +867,11 @@ export interface AutoCompleteEmits { * @group Component * */ -declare class AutoComplete extends ClassComponent {} +declare const AutoComplete: DefineComponent; declare module 'vue' { export interface GlobalComponents { - AutoComplete: GlobalComponentConstructor; + AutoComplete: GlobalComponentConstructor; } } diff --git a/components/lib/avatar/Avatar.d.ts b/components/lib/avatar/Avatar.d.ts index a7ed13053..4c190814c 100644 --- a/components/lib/avatar/Avatar.d.ts +++ b/components/lib/avatar/Avatar.d.ts @@ -9,7 +9,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type AvatarPassThroughOptionType = AvatarPassThroughAttributes | ((options: AvatarPassThroughMethodOptions) => AvatarPassThroughAttributes | string) | string | null | undefined; @@ -147,13 +147,15 @@ export interface AvatarSlots { /** * Defines valid emits in Avatar component. */ -export interface AvatarEmits { +interface AvatarEmitsOptions { /** * Triggered when an error occurs while loading an image file. */ error(event: Event): void; } +export declare type AvatarEmits = EmitFn; + /** * **PrimeVue - Avatar** * @@ -164,12 +166,13 @@ export interface AvatarEmits { * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png) * * @group Component + * */ -declare class Avatar extends ClassComponent {} +declare const Avatar: DefineComponent; declare module 'vue' { export interface GlobalComponents { - Avatar: GlobalComponentConstructor; + Avatar: GlobalComponentConstructor; } } diff --git a/components/lib/avatargroup/AvatarGroup.d.ts b/components/lib/avatargroup/AvatarGroup.d.ts index a3a1cec9c..b55a3ae18 100644 --- a/components/lib/avatargroup/AvatarGroup.d.ts +++ b/components/lib/avatargroup/AvatarGroup.d.ts @@ -10,7 +10,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type AvatarGroupPassThroughOptionType = AvatarGroupPassThroughAttributes | ((options: AvatarGroupPassThroughMethodOptions) => AvatarGroupPassThroughAttributes | string) | string | null | undefined; @@ -101,7 +101,9 @@ export interface AvatarGroupSlots { /** * Defines valid emits in AvatarGroup component. */ -export interface AvatarGroupEmits {} +interface AvatarGroupEmitsOptions {} + +export declare type AvatarGroupEmits = EmitFn; /** * **PrimeVue - AvatarGroup** @@ -113,12 +115,13 @@ export interface AvatarGroupEmits {} * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png) * * @group Component + * */ -declare class AvatarGroup extends ClassComponent {} +declare const AvatarGroup: DefineComponent; declare module 'vue' { export interface GlobalComponents { - AvatarGroup: GlobalComponentConstructor; + AvatarGroup: GlobalComponentConstructor; } } diff --git a/components/lib/badge/Badge.d.ts b/components/lib/badge/Badge.d.ts index b6257c714..da36a08fa 100644 --- a/components/lib/badge/Badge.d.ts +++ b/components/lib/badge/Badge.d.ts @@ -10,7 +10,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, HintedString, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, HintedString, PassThrough } from '../ts-helpers'; export declare type BadgePassThroughOptionType = BadgePassThroughAttributes | ((options: BadgePassThroughMethodOptions) => BadgePassThroughAttributes | string) | string | null | undefined; @@ -109,7 +109,9 @@ export interface BadgeSlots { /** * Defines valid emits in Badge component. */ -export interface BadgeEmits {} +interface BadgeEmitsOptions {} + +export declare type BadgeEmits = EmitFn; /** * **PrimeVue - Badge** @@ -121,12 +123,13 @@ export interface BadgeEmits {} * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png) * * @group Component + * */ -declare class Badge extends ClassComponent {} +declare const Badge: DefineComponent; declare module 'vue' { export interface GlobalComponents { - Badge: GlobalComponentConstructor; + Badge: GlobalComponentConstructor; } } diff --git a/components/lib/blockui/BlockUI.d.ts b/components/lib/blockui/BlockUI.d.ts index dd685d651..d2ac111cc 100755 --- a/components/lib/blockui/BlockUI.d.ts +++ b/components/lib/blockui/BlockUI.d.ts @@ -10,7 +10,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type BlockUIPassThroughOptionType = BlockUIPassThroughAttributes | ((options: BlockUIPassThroughMethodOptions) => BlockUIPassThroughAttributes | string) | string | null | undefined; @@ -140,7 +140,7 @@ export interface BlockUISlots { /** * Defines valid emits in BlockUI component */ -export interface BlockUIEmits { +interface BlockUIEmitsOptions { /** * Fired when the element gets blocked. */ @@ -151,6 +151,8 @@ export interface BlockUIEmits { unblock(): void; } +export declare type BlockUIEmits = EmitFn; + /** * **PrimeVue - BlockUI** * @@ -161,12 +163,13 @@ export interface BlockUIEmits { * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png) * * @group Component + * */ -declare class BlockUI extends ClassComponent {} +declare const BlockUI: DefineComponent; declare module 'vue' { export interface GlobalComponents { - BlockUI: GlobalComponentConstructor; + BlockUI: GlobalComponentConstructor; } } diff --git a/components/lib/breadcrumb/Breadcrumb.d.ts b/components/lib/breadcrumb/Breadcrumb.d.ts index 9577a491c..c2e5889de 100755 --- a/components/lib/breadcrumb/Breadcrumb.d.ts +++ b/components/lib/breadcrumb/Breadcrumb.d.ts @@ -11,7 +11,7 @@ import { VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { MenuItem } from '../menuitem'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers'; export declare type BreadcrumbPassThroughOptionType = BreadcrumbPassThroughAttributes | ((options: BreadcrumbPassThroughMethodOptions) => BreadcrumbPassThroughAttributes | string) | string | null | undefined; @@ -220,7 +220,9 @@ export interface BreadcrumbSlots { /** * Defines valid emits in Breadcrumb component. */ -export interface BreadcrumbEmits {} +interface BreadcrumbEmitsOptions {} + +export declare type BreadcrumbEmits = EmitFn; /** * **PrimeVue - Breadcrumb** @@ -234,11 +236,11 @@ export interface BreadcrumbEmits {} * @group Component * */ -declare class Breadcrumb extends ClassComponent {} +declare const Breadcrumb: DefineComponent; declare module 'vue' { export interface GlobalComponents { - Breadcrumb: GlobalComponentConstructor; + Breadcrumb: GlobalComponentConstructor; } } diff --git a/components/lib/button/Button.d.ts b/components/lib/button/Button.d.ts index 437610ead..c14665067 100755 --- a/components/lib/button/Button.d.ts +++ b/components/lib/button/Button.d.ts @@ -10,7 +10,7 @@ import { ButtonHTMLAttributes, VNode } from 'vue'; import { ComponentHooks } from '../basecomponent'; import { PassThroughOptions } from '../passthrough'; -import { ClassComponent, DesignToken, GlobalComponentConstructor, HintedString, PassThrough } from '../ts-helpers'; +import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, HintedString, PassThrough } from '../ts-helpers'; export declare type ButtonPassThroughOptionType = ButtonPassThroughAttributes | ((options: ButtonPassThroughMethodOptions) => ButtonPassThroughAttributes | string) | string | null | undefined; @@ -232,7 +232,9 @@ export interface ButtonSlots { /** * Defines valid emits in Button component. */ -export interface ButtonEmits {} +interface ButtonEmitsOptions {} + +export declare type ButtonEmits = EmitFn; /** * **PrimeVue - Button** @@ -244,12 +246,13 @@ export interface ButtonEmits {} * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png) * * @group Component + * */ -declare class Button extends ClassComponent {} +declare const Button: DefineComponent; declare module 'vue' { export interface GlobalComponents { - Button: GlobalComponentConstructor