Breadcrumb
Breadcrumbs should be used as a navigational aid in your app or site. They indicate the current page’s location within a hierarchy and help the user understand where they are in relation to the rest of that hierarchy. They also afford one-click access to higher levels of that hierarchy.
Notes
The BitBreadcrumb is a Multi-API component which can accept the list of Items in 3 different ways: BitBreadcrumbItem class, a custom Generic class, and BitBreadcrumbOption component.Usage
Basic
MaxDisplayedItems & OverflowIndex
You can specify how many items are displayed among the items you have and the rest of the items are displayed as overflow.
You can also choose which index the overflow icon should be placed in.
Icons
Templates
Events
By clicking on the items, the selected item will change and match the SelectedItemStyle.
Customizations
Explore advanced customization of BitBreadcrumb by adding or removing items dynamically and adjusting display settings.
Class & Style
RTL
Use BitBreadcrumb in right-to-left (RTL).
- پوشه اول
- پوشه دوم
- پوشه ششم
- پوشه سوم
- پوشه چهارم
- پوشه پنجم
API
BitBreadcrumb parameters
Name |
Type |
Default value |
Description |
---|---|---|---|
ChildContent | RenderFragment? | null | The content of the BitBreadcrumb, that are BitBreadOption components. |
Classes | BitBreadcrumbClassStyles? | null | Custom CSS classes for different parts of the breadcrumb. |
DividerIconName | string? | null | The divider icon name. |
DividerIconTemplate | RenderFragment? | null | The custom template content to render divider icon. |
Items | IList<TItem> | [] | Collection of BreadLists to render. |
ItemTemplate | RenderFragment<TItem>? | null | The custom template content to render each item. |
MaxDisplayedItems | uint | 0 | The maximum number of breadcrumbs to display before coalescing. If not specified, all breadcrumbs will be rendered. |
NameSelectors | BitBreadcrumbNameSelectors<TItem>? | null | Names and selectors of the custom input type properties. |
OnItemClick | EventCallback<TItem> | Callback for when the breadcrumb item clicked. | |
Options | RenderFragment? | null | Alias of the ChildContent. |
OverflowAriaLabel | string? | null | Aria label for the overflow button. |
OverflowIndex | uint | 0 | Optional index where overflow items will be collapsed. |
OverflowIconName | string | More | The overflow icon name. |
OverflowIconTemplate | RenderFragment? | null | The custom template content to render each overflow icon. |
OverflowTemplate | RenderFragment<TItem>? | null | The custom template content to render each item in overflow list. |
ReversedIcon | bool | false | Reverses the positions of the icon and the item text of the item content. |
Styles | BitBreadcrumbClassStyles? | null | Custom CSS styles for different parts of the breadcrumb. |
BitComponentBase parameters
Name |
Type |
Default value |
Description |
---|---|---|---|
AriaLabel | string? | null | The aria-label of the control for the benefit of screen readers. |
Class | string? | null | Custom CSS class for the root element of the component. |
Dir | BitDir? | null | Determines the component direction. |
HtmlAttributes | Dictionary<string, object> | new Dictionary<string, object>() | Capture and render additional attributes in addition to the component's parameters. |
Id | string? | null | Custom id attribute for the root element. if null the UniqueId will be used instead. |
IsEnabled | bool | true | Whether or not the component is enabled. |
Style | string? | null | Custom CSS style for the root element of the component. |
Visibility | BitVisibility | BitVisibility.Visible | Whether the component is visible, hidden or collapsed. |
BitComponentBase public members
Name |
Type |
Default value |
Description |
---|---|---|---|
UniqueId | Guid | Guid.NewGuid() | The readonly unique id of the root element. it will be assigned to a new Guid at component instance construction. |
RootElement | ElementReference | The ElementReference of the root element. |
BitBreadcrumbClassStyles properties
Name |
Type |
Default value |
Description |
---|---|---|---|
Root | string? | null | Custom CSS classes/styles for the root element of the BitBreadcrumb. |
Overlay | string? | null | Custom CSS classes/styles for the overlay of the BitBreadcrumb. |
ItemContainer | string? | null | Custom CSS classes/styles for the item container of the BitBreadcrumb. |
OverflowButton | string? | null | Custom CSS classes/styles for the overflow button of the BitBreadcrumb. |
OverflowButtonIcon | string? | null | Custom CSS classes/styles for the overflow button icon of the BitBreadcrumb. |
ItemWrapper | string? | null | Custom CSS classes/styles for the item wrapper of the BitBreadcrumb. |
Item | string? | null | Custom CSS classes/styles for each item of the BitBreadcrumb. |
ItemIcon | string? | null | Custom CSS classes/styles for each item icon of the BitBreadcrumb. |
ItemText | string? | null | Custom CSS classes/styles for each item text of the BitBreadcrumb. |
SelectedItem | string? | null | Custom CSS classes/styles for the selected item of the BitBreadcrumb. |
Divider | string? | null | Custom CSS classes/styles for the divider of the BitBreadcrumb. |
DividerIcon | string? | null | Custom CSS classes/styles for the divider icon of the BitBreadcrumb. |
Callout | string? | null | Custom CSS classes/styles for the callout element of the BitBreadcrumb. |
CalloutContainer | string? | null | Custom CSS classes/styles for the callout container of the BitBreadcrumb. |
OverflowItemWrapper | string? | null | Custom CSS classes/styles for the overflow item wrapper of the BitBreadcrumb. |
OverflowItem | string? | null | Custom CSS classes/styles for each overflow item of the BitBreadcrumb. |
OverflowItemIcon | string? | null | Custom CSS classes/styles for each overflow item icon of the BitBreadcrumb. |
OverflowItemText | string? | null | Custom CSS classes/styles for each overflow item text of the BitBreadcrumb. |
OverflowSelectedItem | string? | null | Custom CSS classes/styles for the overflow selected item of the BitBreadcrumb. |
BitBreadcrumbNameSelectors<TItem> properties
Name |
Type |
Default value |
Description |
---|---|---|---|
Key | BitNameSelectorPair<TItem, string?> | new(nameof(BitBreadcrumbItem.Key)) | The Id field name and selector of the custom input class. |
Text | BitNameSelectorPair<TItem, string?> | new(nameof(BitBreadcrumbItem.Text)) | The Text field name and selector of the custom input class. |
Href | BitNameSelectorPair<TItem, string?> | new(nameof(BitBreadcrumbItem.Href)) | The Href field name and selector of the custom input class. |
Class | BitNameSelectorPair<TItem, string?> | new(nameof(BitBreadcrumbItem.Class)) | The CSS Class field name and selector of the custom input class. |
Style | BitNameSelectorPair<TItem, string?> | new(nameof(BitBreadcrumbItem.Style)) | The CSS Style field name and selector of the custom input class. |
IconName | BitNameSelectorPair<TItem, string?> | new(nameof(BitBreadcrumbItem.IconName)) | The IconName field name and selector of the custom input class. |
ReversedIcon | BitNameSelectorPair<TItem, bool?> | new(nameof(BitBreadcrumbItem.ReversedIcon)) | The ReversedIcon field name and selector of the custom input class. |
IsSelected | BitNameSelectorPair<TItem, bool> | new(nameof(BitBreadcrumbItem.IsSelected)) | The IsSelected field name and selector of the custom input class. |
IsEnabled | BitNameSelectorPair<TItem, bool> | new(nameof(BitBreadcrumbItem.IsEnabled)) | The IsEnabled field name and selector of the custom input class. |
OnClick | Action<TItem>? | Click event handler of the item. | |
OverflowTemplate | BitNameSelectorPair<TItem, RenderFragment<TItem>?> | new(nameof(BitBreadcrumbItem.OverflowTemplate)) | The OverflowTemplate field name and selector of the custom input class. |
Template | BitNameSelectorPair<TItem, RenderFragment<TItem>?> | new(nameof(BitBreadcrumbItem.Template)) | The Template field name and selector of the custom input class. |
BitNameSelectorPair<TItem, TProp> properties
Name |
Type |
Default value |
Description |
---|---|---|---|
Name | string | Custom class property name. | |
Selector | Func<TItem, TProp?>? | Custom class property selector. |
BitVisibility enum
Name |
Value |
Description |
---|---|---|
Visible | 0 | The content of the component is visible. |
Hidden | 1 | The content of the component is hidden, but the space it takes on the page remains (visibility:hidden). |
Collapsed | 2 | The component is hidden (display:none). |
BitDir enum
Name |
Value |
Description |
---|---|---|
Ltr | 0 | Ltr (left to right) is to be used for languages that are written from the left to the right (like English). |
Rtl | 1 | Rtl (right to left) is to be used for languages that are written from the right to the left (like Arabic). |
Auto | 2 | Auto lets the user agent decide. It uses a basic algorithm as it parses the characters inside the element until it finds a character with a strong directionality, then applies that directionality to the whole element. |
- On this page