primevue-mirror/components/lib/tabpanel/TabPanel.d.ts

142 lines
3.6 KiB
TypeScript
Raw Normal View History

2023-03-01 08:06:07 +00:00
/**
*
* TabPanel is a helper component for TabPanel component.
*
* [Live Demo](https://www.primevue.org/tabview/)
*
* @module tabpanel
*
*/
2022-09-14 11:26:01 +00:00
import { AnchorHTMLAttributes, HTMLAttributes, LiHTMLAttributes, VNode } from 'vue';
import { TabViewPassThroughOptions } from '../tabview';
2022-09-06 12:03:37 +00:00
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
export declare type TabPanelPassThroughOptionType = TabPanelPassThroughAttributes | ((options: TabPanelPassThroughMethodOptions) => TabPanelPassThroughAttributes) | null | undefined;
/**
* Custom passthrough(pt) option method.
*/
export interface TabPanelPassThroughMethodOptions {
props: TabPanelProps;
parent: TabViewPassThroughOptions;
}
/**
* Custom passthrough(pt) options.
* @see {@link TabPanelProps.pt}
*/
export interface TabPanelPassThroughOptions {
/**
* Uses to pass attributes to the root's DOM element.
*/
root?: TabPanelPassThroughOptionType;
/**
* Uses to pass attributes to the header's DOM element.
*/
header?: TabPanelPassThroughOptionType;
/**
* Uses to pass attributes to the header action's DOM element.
*/
headeraction?: TabPanelPassThroughOptionType;
/**
* Uses to pass attributes to the title's DOM element.
*/
headertitle?: TabPanelPassThroughOptionType;
/**
* Uses to pass attributes to the list's DOM element.
*/
content?: TabPanelPassThroughOptionType;
}
export interface TabPanelPassThroughAttributes {
[key: string]: any;
}
2023-03-01 08:06:07 +00:00
/**
* Defines valid properties in TabPanel component.
*/
2022-09-06 12:03:37 +00:00
export interface TabPanelProps {
/**
* Orientation of tab headers.
*/
header?: string | undefined;
2022-09-14 11:26:01 +00:00
/**
* Inline style of the tab header.
*/
headerStyle?: any;
/**
* Style class of the tab header.
*/
headerClass?: any;
/**
* Uses to pass all properties of the HTMLLiElement to the tab header.
* @deprecated since v3.26.0. Use 'pt' property instead.
2022-09-14 11:26:01 +00:00
*/
headerProps?: LiHTMLAttributes | undefined;
/**
* Uses to pass all properties of the HTMLAnchorElement to the focusable anchor element inside the tab header.
* @deprecated since v3.26.0. Use 'pt' property instead.
2022-09-14 11:26:01 +00:00
*/
headerActionProps?: AnchorHTMLAttributes | undefined;
/**
* Inline style of the tab content.
* @deprecated since v3.26.0. Use 'pt' property instead.
2022-09-14 11:26:01 +00:00
*/
contentStyle?: any;
/**
* Style class of the tab content.
*/
contentClass?: any;
/**
* Uses to pass all properties of the HTMLDivElement to the tab content.
*/
contentProps?: HTMLAttributes | undefined;
2022-09-06 12:03:37 +00:00
/**
* Whether the tab is disabled.
2023-03-01 08:06:07 +00:00
* @defaultValue false
2022-09-06 12:03:37 +00:00
*/
disabled?: boolean | undefined;
/**
* Uses to pass attributes to DOM elements inside the component.
* @type {TabPanelPassThroughOptions}
*/
pt?: TabPanelPassThroughOptions;
2022-09-06 12:03:37 +00:00
}
2023-03-01 08:06:07 +00:00
/**
* Defines valid slots in TabPanel slots.
*/
2022-09-06 12:03:37 +00:00
export interface TabPanelSlots {
/**
* Custom content template.
*/
2023-04-12 06:42:12 +00:00
default(): VNode[];
2022-09-06 12:03:37 +00:00
/**
* Custom header template.
*/
2023-04-12 06:42:12 +00:00
header(): VNode[];
2022-09-06 12:03:37 +00:00
}
2023-03-01 08:06:07 +00:00
export interface TabPanelEmits {}
2022-09-06 12:03:37 +00:00
2023-03-01 08:06:07 +00:00
/**
* **PrimeVue - TabPanel**
*
* _TabPanel is a helper component for TabPanel component._
*
* [Live Demo](https://www.primevue.org/tabview/)
* --- ---
2023-03-03 10:55:20 +00:00
* ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
2023-03-01 08:06:07 +00:00
*
* @group Component
*
*/
2023-03-01 12:30:54 +00:00
declare class TabPanel extends ClassComponent<TabPanelProps, TabPanelSlots, TabPanelEmits> {}
2022-09-06 12:03:37 +00:00
declare module '@vue/runtime-core' {
interface GlobalComponents {
2022-09-14 11:26:01 +00:00
TabPanel: GlobalComponentConstructor<TabPanel>;
2022-09-06 12:03:37 +00:00
}
}
export default TabPanel;