@opencloud-eu/design-system
Version:
OpenCloud Design System is used to design OpenCloud UI components
69 lines (68 loc) • 2.38 kB
TypeScript
import { BreadcrumbItem, SizeType } from '../../helpers';
import { RouteLocationPathRaw } from 'vue-router';
export interface Props {
/**
* @docs The items to display in the breadcrumb. Please refer to the component source for the `BreadcrumbItem` type definition.
*/
items: BreadcrumbItem[];
/**
* @docs The padding size of the context menu dropdown.
* @default medium
*/
contextMenuPadding?: SizeType | 'remove';
/**
* @docs The element ID of the breadcrumb.
*/
id?: string;
/**
* @docs The maximum width of the breadcrumb. If the breadcrumb exceeds this width, items will be truncated. Set to `-1` to disable truncation.
* @default -1
*/
maxWidth?: number;
/**
* @docs Determines if the context actions are shown for the last breadcrumb item.
* @default false
*/
showContextActions?: boolean;
/**
* @docs The number of items to show before truncating the breadcrumb.
* @default 2
*/
truncationOffset?: number;
/**
* @docs The variation of the breadcrumb.
* @default default
*/
variation?: 'default' | 'lead';
}
export interface Emits {
/**
* @docs Emitted when an item has been droped onto a breadcrumb element.
*/
(e: 'itemDroppedBreadcrumb', to: RouteLocationPathRaw): void;
}
export interface Slots {
/**
* @docs Context menu for the last breadcrumb item. Needs `showContextActions` to be `true`.
*/
contextMenu?: () => unknown;
}
declare function __VLS_template(): {
attrs: Partial<{}>;
slots: Readonly<Slots> & Slots;
refs: {};
rootEl: any;
};
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
declare const __VLS_component: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
itemDroppedBreadcrumb: (to: RouteLocationPathRaw) => any;
}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
onItemDroppedBreadcrumb?: (to: RouteLocationPathRaw) => any;
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
export default _default;
type __VLS_WithTemplateSlots<T, S> = T & {
new (): {
$slots: S;
};
};