View as Markdown

API reference: @salmonui/navigation/breadcrumbs

BreadcrumbItemPropsinterface

import type { BreadcrumbItemProps } from '@salmonui/navigation/breadcrumbs';
interface BreadcrumbItemProps {
    readonly children?: ReactNode;
    readonly href?: string | undefined;
    readonly target?: string | undefined;
    readonly rel?: string | undefined;
    readonly icon?: ReactNode;
    readonly disabled?: boolean | undefined;
    readonly current?: boolean | undefined;
    readonly render?: ((props: BreadcrumbItemRenderProps) => ReactElement) | undefined;
    readonly onClick?: ((event: MouseEvent<HTMLElement>) => void) | undefined;
    readonly className?: string | undefined;
    readonly style?: CSSProperties | undefined;
    readonly id?: string | undefined;
    readonly title?: string | undefined;
}
BreadcrumbItemProps members (13)
NameSignatureDescription
childrenoptionalreadonly children?: ReactNode;

The item's label.

hrefoptionalreadonly href?: string | undefined;

Link target. Without href the item renders as text.

targetoptionalreadonly target?: string | undefined;
reloptionalreadonly rel?: string | undefined;
iconoptionalreadonly icon?: ReactNode;

Decorative icon before the label (aria-hidden).

disabledoptionalreadonly disabled?: boolean | undefined;

Not interactive: text with aria-disabled="true".

currentoptionalreadonly current?: boolean | undefined;

The current page (aria-current="page"). Default: the last item.

renderoptionalreadonly render?: ((props: BreadcrumbItemRenderProps) => ReactElement) | undefined;

Renders another element for the link (a router link): render={(props) => <Link {...props} to="/x" />}.

onClickoptionalreadonly onClick?: ((event: MouseEvent<HTMLElement>) => void) | undefined;
classNameoptionalreadonly className?: string | undefined;

On the <li>.

styleoptionalreadonly style?: CSSProperties | undefined;

On the <li>.

idoptionalreadonly id?: string | undefined;

On the <li>.

titleoptionalreadonly title?: string | undefined;