Skip to content

Commit

Permalink
fix separator
Browse files Browse the repository at this point in the history
  • Loading branch information
heorhi-deriv committed Oct 3, 2024
1 parent 1b6334b commit 95e05cc
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 14 deletions.
18 changes: 11 additions & 7 deletions src/components/Breadcrumbs/Breadcrumbs.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@
&__item {
float: left;
list-style-type: none;

&:not(:last-child) {
cursor: pointer;

.deriv-breadcrumbs__text:hover {
color: var(--du-text-general, #333333);
}
}
}

&__text {
Expand All @@ -13,14 +21,10 @@
&--active {
color: var(--du-text-prominent, #333333);
}
}

&:not(:last-child) {
cursor: pointer;

&:hover {
color: var(--du-text-general, #333333);
}
}
&__separator-container {
cursor: default;
}

&__chevron-icon {
Expand Down
17 changes: 10 additions & 7 deletions src/components/Breadcrumbs/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,16 @@ export const Breadcrumbs = ({
>
{item.text}
</Text>
{!isLastItem &&
(separator ?? (
<LegacyChevronRight1pxIcon
className="deriv-breadcrumbs__chevron-icon"
iconSize="xs"
/>
))}
{!isLastItem && (
<span className="deriv-breadcrumbs__separator-container">
{separator || (
<LegacyChevronRight1pxIcon
className="deriv-breadcrumbs__chevron-icon"
iconSize="xs"
/>
)}
</span>
)}
</li>
);
})}
Expand Down

0 comments on commit 95e05cc

Please sign in to comment.