@backstage/core-components 0.8.6 → 0.8.7-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/index.d.ts +4 -1
- package/dist/index.esm.js +19 -8
- package/dist/index.esm.js.map +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @backstage/core-components
|
|
2
2
|
|
|
3
|
+
## 0.8.7-next.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 4c773ed25c: Change subtitle of Header style to use palette.bursts.fontColor
|
|
8
|
+
- f465b63b7f: Fix an issue where changes related to the `MobileSidebar` prevented scrolling pages. Additionally improve the menu of the `MobileSidebar` to not overlay the `BottomNavigation`.
|
|
9
|
+
- a681cb9c2f: Make linkTarget configurable for MarkdownContent component
|
|
10
|
+
|
|
3
11
|
## 0.8.6
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
package/dist/index.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ import { ButtonProps as ButtonProps$1 } from '@material-ui/core/Button';
|
|
|
5
5
|
import { LinkProps as LinkProps$1 } from '@material-ui/core/Link';
|
|
6
6
|
import { LinkProps as LinkProps$2, NavLinkProps } from 'react-router-dom';
|
|
7
7
|
import CSS from 'csstype';
|
|
8
|
+
import { Options } from 'react-markdown';
|
|
8
9
|
import { TooltipProps } from '@material-ui/core/Tooltip';
|
|
9
10
|
import { TextTruncateProps } from 'react-text-truncate';
|
|
10
11
|
import { LinearProgressProps } from '@material-ui/core/LinearProgress';
|
|
@@ -669,6 +670,7 @@ declare type MarkdownContentClassKey = 'markdown';
|
|
|
669
670
|
declare type Props$b = {
|
|
670
671
|
content: string;
|
|
671
672
|
dialect?: 'gfm' | 'common-mark';
|
|
673
|
+
linkTarget?: Options['linkTarget'];
|
|
672
674
|
};
|
|
673
675
|
/**
|
|
674
676
|
* MarkdownContent
|
|
@@ -1332,8 +1334,9 @@ declare function ItemCardHeader(props: ItemCardHeaderProps): JSX.Element;
|
|
|
1332
1334
|
declare type PageClassKey = 'root';
|
|
1333
1335
|
declare type Props$3 = {
|
|
1334
1336
|
themeId: string;
|
|
1337
|
+
children?: React__default.ReactNode;
|
|
1335
1338
|
};
|
|
1336
|
-
declare function Page(props:
|
|
1339
|
+
declare function Page(props: Props$3): JSX.Element;
|
|
1337
1340
|
|
|
1338
1341
|
declare type PageWithHeaderProps = ComponentProps<typeof Header> & {
|
|
1339
1342
|
themeId: string;
|
package/dist/index.esm.js
CHANGED
|
@@ -1673,13 +1673,14 @@ const components = {
|
|
|
1673
1673
|
}
|
|
1674
1674
|
};
|
|
1675
1675
|
function MarkdownContent(props) {
|
|
1676
|
-
const { content, dialect = "gfm" } = props;
|
|
1676
|
+
const { content, dialect = "gfm", linkTarget } = props;
|
|
1677
1677
|
const classes = useStyles$C();
|
|
1678
1678
|
return /* @__PURE__ */ React.createElement(ReactMarkdown, {
|
|
1679
1679
|
remarkPlugins: dialect === "gfm" ? [gfm] : [],
|
|
1680
1680
|
className: classes.markdown,
|
|
1681
1681
|
children: content,
|
|
1682
|
-
components
|
|
1682
|
+
components,
|
|
1683
|
+
linkTarget
|
|
1683
1684
|
});
|
|
1684
1685
|
}
|
|
1685
1686
|
|
|
@@ -3115,6 +3116,9 @@ const useStyles$m = makeStyles((theme) => ({
|
|
|
3115
3116
|
},
|
|
3116
3117
|
overlayHeaderClose: {
|
|
3117
3118
|
color: theme.palette.bursts.fontColor
|
|
3119
|
+
},
|
|
3120
|
+
marginMobileSidebar: {
|
|
3121
|
+
marginBottom: `${sidebarConfig.mobileSidebarHeight}px`
|
|
3118
3122
|
}
|
|
3119
3123
|
}));
|
|
3120
3124
|
const sortSidebarGroupsForPriority = (children) => orderBy(children, ({ props: { priority } }) => Number.isInteger(priority) ? priority : -1, "desc");
|
|
@@ -3130,7 +3134,13 @@ const OverlayMenu = ({
|
|
|
3130
3134
|
anchor: "bottom",
|
|
3131
3135
|
open,
|
|
3132
3136
|
onClose,
|
|
3133
|
-
|
|
3137
|
+
ModalProps: {
|
|
3138
|
+
BackdropProps: { classes: { root: classes.marginMobileSidebar } }
|
|
3139
|
+
},
|
|
3140
|
+
classes: {
|
|
3141
|
+
root: classes.marginMobileSidebar,
|
|
3142
|
+
paperAnchorBottom: classes.overlay
|
|
3143
|
+
}
|
|
3134
3144
|
}, /* @__PURE__ */ React.createElement(Box, {
|
|
3135
3145
|
className: classes.overlayHeader
|
|
3136
3146
|
}, /* @__PURE__ */ React.createElement(Typography, {
|
|
@@ -5133,7 +5143,7 @@ const useStyles$5 = makeStyles((theme) => ({
|
|
|
5133
5143
|
marginBottom: 0
|
|
5134
5144
|
},
|
|
5135
5145
|
subtitle: {
|
|
5136
|
-
color: theme.palette.
|
|
5146
|
+
color: theme.palette.bursts.fontColor,
|
|
5137
5147
|
opacity: 0.8,
|
|
5138
5148
|
display: "inline-block",
|
|
5139
5149
|
marginTop: theme.spacing(1),
|
|
@@ -5408,18 +5418,19 @@ function ItemCardGrid(props) {
|
|
|
5408
5418
|
}
|
|
5409
5419
|
|
|
5410
5420
|
const useStyles$1 = makeStyles(() => ({
|
|
5411
|
-
root: {
|
|
5421
|
+
root: ({ isMobile }) => ({
|
|
5412
5422
|
display: "grid",
|
|
5413
5423
|
gridTemplateAreas: "'pageHeader pageHeader pageHeader' 'pageSubheader pageSubheader pageSubheader' 'pageNav pageContent pageSidebar'",
|
|
5414
5424
|
gridTemplateRows: "max-content auto 1fr",
|
|
5415
5425
|
gridTemplateColumns: "auto 1fr auto",
|
|
5416
|
-
height: "100%",
|
|
5426
|
+
height: isMobile ? "100%" : "100vh",
|
|
5417
5427
|
overflowY: "auto"
|
|
5418
|
-
}
|
|
5428
|
+
})
|
|
5419
5429
|
}), { name: "BackstagePage" });
|
|
5420
5430
|
function Page(props) {
|
|
5421
5431
|
const { themeId, children } = props;
|
|
5422
|
-
const
|
|
5432
|
+
const { isMobile } = useContext(SidebarPinStateContext);
|
|
5433
|
+
const classes = useStyles$1({ isMobile });
|
|
5423
5434
|
return /* @__PURE__ */ React.createElement(ThemeProvider, {
|
|
5424
5435
|
theme: (baseTheme) => ({
|
|
5425
5436
|
...baseTheme,
|