diff --git a/packages/primevue/src/tab/BaseTab.vue b/packages/primevue/src/tab/BaseTab.vue index 15050b3fb..2a801d123 100644 --- a/packages/primevue/src/tab/BaseTab.vue +++ b/packages/primevue/src/tab/BaseTab.vue @@ -15,7 +15,7 @@ export default { default: false }, as: { - type: String, + type: [String, Object], default: 'BUTTON' }, asChild: { diff --git a/packages/primevue/src/tab/Tab.d.ts b/packages/primevue/src/tab/Tab.d.ts index f90c8f9c3..9a422978f 100755 --- a/packages/primevue/src/tab/Tab.d.ts +++ b/packages/primevue/src/tab/Tab.d.ts @@ -10,7 +10,7 @@ import type { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '@primevue/core'; import type { ComponentHooks } from '@primevue/core/basecomponent'; import type { PassThroughOptions } from 'primevue/passthrough'; -import { VNode } from 'vue'; +import type { Component, VNode } from 'vue'; export declare type TabPassThroughOptionType = TabPassThroughAttributes | ((options: TabPassThroughMethodOptions) => TabPassThroughAttributes | string) | string | null | undefined; @@ -81,7 +81,7 @@ export interface TabProps { * Use to change the HTML tag of root element. * @defaultValue BUTTON */ - as?: string | undefined; + as?: string | Component | undefined; /** * When enabled, it changes the default rendered element for the one passed as a child element. * @defaultValue false diff --git a/packages/primevue/src/tabpanel/BaseTabPanel.vue b/packages/primevue/src/tabpanel/BaseTabPanel.vue index 084dcec14..eba74e8c3 100644 --- a/packages/primevue/src/tabpanel/BaseTabPanel.vue +++ b/packages/primevue/src/tabpanel/BaseTabPanel.vue @@ -12,7 +12,7 @@ export default { default: undefined }, as: { - type: String, + type: [String, Object], default: 'DIV' }, asChild: { diff --git a/packages/primevue/src/tabpanel/TabPanel.d.ts b/packages/primevue/src/tabpanel/TabPanel.d.ts index 0f47c26ed..307da7fa6 100755 --- a/packages/primevue/src/tabpanel/TabPanel.d.ts +++ b/packages/primevue/src/tabpanel/TabPanel.d.ts @@ -10,7 +10,7 @@ import type { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '@primevue/core'; import type { ComponentHooks } from '@primevue/core/basecomponent'; import type { PassThroughOptions } from 'primevue/passthrough'; -import { AnchorHTMLAttributes, HTMLAttributes, LiHTMLAttributes, VNode } from 'vue'; +import type { AnchorHTMLAttributes, Component, HTMLAttributes, LiHTMLAttributes, VNode } from 'vue'; export declare type TabPanelPassThroughOptionType = TabPanelPassThroughAttributes | ((options: TabPanelPassThroughMethodOptions) => TabPanelPassThroughAttributes | string) | string | null | undefined; @@ -96,7 +96,7 @@ export interface TabPanelProps { * Use to change the HTML tag of root element. * @defaultValue DIV */ - as?: string | undefined; + as?: string | Component | undefined; /** * When enabled, it changes the default rendered element for the one passed as a child element. * @defaultValue false