Removed inline styling from breadcrumbs
Signed-off-by: Harrison Hogg <hhogg@spotify.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/core-components': patch
|
||||
---
|
||||
|
||||
Removed inline styling in breadcrumbs and replaced with a theme targetable class of BreadcrumbsCurrentPage
|
||||
@@ -136,6 +136,9 @@ export function Breadcrumbs(props: Props_18): React_2.JSX.Element;
|
||||
// @public (undocumented)
|
||||
export type BreadcrumbsClickableTextClassKey = 'root';
|
||||
|
||||
// @public (undocumented)
|
||||
export type BreadcrumbsCurrentPageClassKey = 'root';
|
||||
|
||||
// @public (undocumented)
|
||||
export type BreadcrumbsStyledBoxClassKey = 'root';
|
||||
|
||||
|
||||
@@ -51,6 +51,18 @@ const StyledBox = withStyles(
|
||||
{ name: 'BackstageBreadcrumbsStyledBox' },
|
||||
)(Box);
|
||||
|
||||
/** @public */
|
||||
export type BreadcrumbsCurrentPageClassKey = 'root';
|
||||
|
||||
const BreadcrumbsCurrentPage = withStyles(
|
||||
{
|
||||
root: {
|
||||
fontStyle: 'italic',
|
||||
},
|
||||
},
|
||||
{ name: 'BreadcrumbsCurrentPage' },
|
||||
)(Box);
|
||||
|
||||
/**
|
||||
* Breadcrumbs component to show navigation hierarchical structure
|
||||
*
|
||||
@@ -88,7 +100,7 @@ export function Breadcrumbs(props: Props) {
|
||||
{hasHiddenBreadcrumbs && (
|
||||
<ClickableText onClick={handleClick}>...</ClickableText>
|
||||
)}
|
||||
<Box style={{ fontStyle: 'italic' }}>{currentPage}</Box>
|
||||
<BreadcrumbsCurrentPage>{currentPage}</BreadcrumbsCurrentPage>
|
||||
</MaterialBreadcrumbs>
|
||||
<Popover
|
||||
open={open}
|
||||
|
||||
@@ -18,4 +18,5 @@ export { Breadcrumbs } from './Breadcrumbs';
|
||||
export type {
|
||||
BreadcrumbsClickableTextClassKey,
|
||||
BreadcrumbsStyledBoxClassKey,
|
||||
BreadcrumbsCurrentPageClassKey,
|
||||
} from './Breadcrumbs';
|
||||
|
||||
Reference in New Issue
Block a user