Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,47 +1,38 @@
<nav
*ngIf="this.breakpointInputs().crumbs.length > 0"
aria-label="Breadcrumb"
class="tedi__breadcrumbs"
>
<ol class="tedi__breadcrumbs__list">
<ng-container *ngIf="!this.breakpointInputs().shortCrumbs">
<ng-container
*ngFor="let crumb of this.breakpointInputs().crumbs; let last = last"
>
@if (!last) {
<li class="tedi__breadcrumbs__item">
<a tedi-link [routerLink]="crumb.href" [underline]="false">{{
crumb.label
}}</a>
<tedi-icon color="brand" name="chevron_right" />
</li>
} @else {
<li
aria-current="page"
tedi-text
modifiers="inline-block"
color="secondary"
>
{{ crumb.label }}
</li>
@if (breakpointInputs().crumbs.length > 0) {
<nav aria-label="Breadcrumb" class="tedi-breadcrumbs">
<ol class="tedi-breadcrumbs__list">
@if (!breakpointInputs().shortCrumbs) {
@for (crumb of breakpointInputs().crumbs; track crumb.href; let last = $last) {
@if (!last) {
<li class="tedi-breadcrumbs__item">
<a tedi-link [routerLink]="crumb.href" [underline]="false">{{
crumb.label
}}</a>
<tedi-icon color="brand" name="chevron_right" />
</li>
} @else {
<li
aria-current="page"
tedi-text
modifiers="inline-block"
color="secondary"
>
{{ crumb.label }}
</li>
}
}
</ng-container>
</ng-container>
</ol>
<ng-container
*ngIf="
this.breakpointInputs().crumbs.length > 1 &&
this.breakpointInputs().shortCrumbs
"
>
<div class="tedi__breadcrumbs__item">
<tedi-icon color="brand" name="arrow_back" />
<a
tedi-link
[routerLink]="getSecondLastCrumb()?.href"
[underline]="false"
>{{ getSecondLastCrumb()?.label }}</a
>
</div>
</ng-container>
</nav>
}
</ol>
@if (breakpointInputs().crumbs.length > 1 && breakpointInputs().shortCrumbs) {
<div class="tedi-breadcrumbs__item">
<tedi-icon color="brand" name="arrow_back" />
<a
tedi-link
[routerLink]="getSecondLastCrumb()?.href"
[underline]="false"
>{{ getSecondLastCrumb()?.label }}</a
>
</div>
}
</nav>
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
display: block;
}

.tedi__breadcrumbs {
.tedi-breadcrumbs {
&__list {
display: flex;
flex-wrap: wrap;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { Component, computed, inject, input } from "@angular/core";
import { CommonModule } from "@angular/common";
import { RouterLink } from "@angular/router";
import {
IconComponent,
Expand Down Expand Up @@ -45,7 +44,6 @@ export type Breadcrumbs = {
selector: "tedi-breadcrumbs",
standalone: true,
imports: [
CommonModule,
RouterLink,
LinkComponent,
IconComponent,
Expand Down
2 changes: 1 addition & 1 deletion tedi/components/overlay/dropdown/dropdown.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ export const Default: Story = {
props: args,
template: `
<tedi-dropdown [position]="position" [preventOverflow]="preventOverflow" [appendTo]="appendTo">
<button tedi-button tedi-dropdown-trigger [ariaHasPopuo]="ariaHasPopup">
<button tedi-button tedi-dropdown-trigger [ariaHasPopup]="ariaHasPopup">
Trigger
</button>
<tedi-dropdown-content [dropdownRole]="dropdownRole">
Expand Down