Fixed #1836 - For Breadcrumb
parent
c3dca4fde8
commit
7ef0fee49d
|
@ -1,18 +1,58 @@
|
||||||
interface BreadcrumbProps {
|
import { VNode } from 'vue';
|
||||||
home?: any;
|
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
||||||
model?: any[];
|
import { MenuItem } from '../menuitem';
|
||||||
|
|
||||||
|
export interface BreadcrumbProps {
|
||||||
|
/**
|
||||||
|
* An array of menuitems.
|
||||||
|
*/
|
||||||
|
model?: MenuItem[];
|
||||||
|
/**
|
||||||
|
* Configuration for the home icon.
|
||||||
|
*/
|
||||||
|
home?: MenuItem;
|
||||||
|
/**
|
||||||
|
* Whether to apply 'router-link-active-exact' class if route exactly matches the item path.
|
||||||
|
* Default value is true.
|
||||||
|
*/
|
||||||
exact?: boolean;
|
exact?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface BreadcrumbItemSlotInterface {
|
export interface BreadcrumbSlots {
|
||||||
item: any;
|
/**
|
||||||
|
* Custom item template.
|
||||||
|
* @param {Object} scope - item slot's params.
|
||||||
|
*/
|
||||||
|
item: (scope: {
|
||||||
|
/**
|
||||||
|
* Menuitem instance
|
||||||
|
*/
|
||||||
|
item: MenuItem;
|
||||||
|
}) => VNode[];
|
||||||
}
|
}
|
||||||
|
|
||||||
declare class Breadcrumb {
|
export declare type BreadcrumbEmits = {
|
||||||
$props: BreadcrumbProps;
|
}
|
||||||
$slots: {
|
|
||||||
item: BreadcrumbItemSlotInterface
|
declare class Breadcrumb extends ClassComponent<BreadcrumbProps, BreadcrumbSlots, BreadcrumbEmits> { }
|
||||||
|
|
||||||
|
declare module '@vue/runtime-core' {
|
||||||
|
interface GlobalComponents {
|
||||||
|
Breadcrumb: GlobalComponentConstructor<Breadcrumb>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Breadcrumb provides contextual information about page hierarchy.
|
||||||
|
*
|
||||||
|
* Helper API:
|
||||||
|
*
|
||||||
|
* - [MenuItem](https://www.primefaces.org/primevue/showcase/#/menumodel)
|
||||||
|
*
|
||||||
|
* Demos:
|
||||||
|
*
|
||||||
|
* - [Breadcrumb](https://www.primefaces.org/primevue/showcase/#/breadcrumb)
|
||||||
|
*
|
||||||
|
*/
|
||||||
export default Breadcrumb;
|
export default Breadcrumb;
|
||||||
|
|
Loading…
Reference in New Issue