@backstage/core-components 0.9.6-next.0 → 0.9.6-next.1
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 +10 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.esm.js +17 -4
- package/dist/index.esm.js.map +1 -1
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# @backstage/core-components
|
|
2
2
|
|
|
3
|
+
## 0.9.6-next.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 3c440ea77e: Change BackstageIconLinkVertical style to use pallette instead of explicit color
|
|
8
|
+
- 7e115d42f9: Support displaying subtitle text in `SidebarSubmenuItem`
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
- @backstage/errors@1.1.0-next.0
|
|
11
|
+
- @backstage/theme@0.2.16-next.0
|
|
12
|
+
|
|
3
13
|
## 0.9.6-next.0
|
|
4
14
|
|
|
5
15
|
### Patch Changes
|
package/dist/index.d.ts
CHANGED
|
@@ -1504,6 +1504,7 @@ declare type SidebarSubmenuItemDropdownItem = {
|
|
|
1504
1504
|
* Holds submenu item content.
|
|
1505
1505
|
*
|
|
1506
1506
|
* title: Text content of submenu item
|
|
1507
|
+
* subtitle: A subtitle displayed under the main title
|
|
1507
1508
|
* to: Path to navigate to when item is clicked
|
|
1508
1509
|
* icon: Icon displayed on the left of text content
|
|
1509
1510
|
* dropdownItems: Optional array of dropdown items displayed when submenu item is clicked.
|
|
@@ -1512,6 +1513,7 @@ declare type SidebarSubmenuItemDropdownItem = {
|
|
|
1512
1513
|
*/
|
|
1513
1514
|
declare type SidebarSubmenuItemProps = {
|
|
1514
1515
|
title: string;
|
|
1516
|
+
subtitle?: string;
|
|
1515
1517
|
to?: string;
|
|
1516
1518
|
icon?: IconComponent;
|
|
1517
1519
|
dropdownItems?: SidebarSubmenuItemDropdownItem[];
|
package/dist/index.esm.js
CHANGED
|
@@ -1384,7 +1384,7 @@ const useIconStyles = makeStyles((theme) => ({
|
|
|
1384
1384
|
textAlign: "center"
|
|
1385
1385
|
},
|
|
1386
1386
|
disabled: {
|
|
1387
|
-
color:
|
|
1387
|
+
color: theme.palette.text.secondary,
|
|
1388
1388
|
cursor: "default"
|
|
1389
1389
|
},
|
|
1390
1390
|
primary: {
|
|
@@ -3545,6 +3545,13 @@ const useStyles$j = makeStyles((theme) => ({
|
|
|
3545
3545
|
fontSize: 14,
|
|
3546
3546
|
whiteSpace: "nowrap",
|
|
3547
3547
|
overflow: "hidden",
|
|
3548
|
+
"text-overflow": "ellipsis",
|
|
3549
|
+
lineHeight: 1
|
|
3550
|
+
},
|
|
3551
|
+
subtitle: {
|
|
3552
|
+
fontSize: 10,
|
|
3553
|
+
whiteSpace: "nowrap",
|
|
3554
|
+
overflow: "hidden",
|
|
3548
3555
|
"text-overflow": "ellipsis"
|
|
3549
3556
|
},
|
|
3550
3557
|
dropdownArrow: {
|
|
@@ -3575,7 +3582,7 @@ const useStyles$j = makeStyles((theme) => ({
|
|
|
3575
3582
|
}
|
|
3576
3583
|
}), { name: "BackstageSidebarSubmenuItem" });
|
|
3577
3584
|
const SidebarSubmenuItem = (props) => {
|
|
3578
|
-
const { title, to, icon: Icon, dropdownItems } = props;
|
|
3585
|
+
const { title, subtitle, to, icon: Icon, dropdownItems } = props;
|
|
3579
3586
|
const classes = useStyles$j();
|
|
3580
3587
|
const { setIsHoveredOn } = useContext(SidebarItemWithSubmenuContext);
|
|
3581
3588
|
const closeSubmenu = () => {
|
|
@@ -3609,7 +3616,10 @@ const SidebarSubmenuItem = (props) => {
|
|
|
3609
3616
|
}), /* @__PURE__ */ React.createElement(Typography, {
|
|
3610
3617
|
variant: "subtitle1",
|
|
3611
3618
|
className: classes.label
|
|
3612
|
-
}, title),
|
|
3619
|
+
}, title, /* @__PURE__ */ React.createElement("br", null), subtitle && /* @__PURE__ */ React.createElement(Typography, {
|
|
3620
|
+
variant: "caption",
|
|
3621
|
+
className: classes.subtitle
|
|
3622
|
+
}, subtitle)), showDropDown ? /* @__PURE__ */ React.createElement(ArrowDropUpIcon, {
|
|
3613
3623
|
className: classes.dropdownArrow
|
|
3614
3624
|
}) : /* @__PURE__ */ React.createElement(ArrowDropDownIcon, {
|
|
3615
3625
|
className: classes.dropdownArrow
|
|
@@ -3647,7 +3657,10 @@ const SidebarSubmenuItem = (props) => {
|
|
|
3647
3657
|
}), /* @__PURE__ */ React.createElement(Typography, {
|
|
3648
3658
|
variant: "subtitle1",
|
|
3649
3659
|
className: classes.label
|
|
3650
|
-
}, title)
|
|
3660
|
+
}, title, /* @__PURE__ */ React.createElement("br", null), subtitle && /* @__PURE__ */ React.createElement(Typography, {
|
|
3661
|
+
variant: "caption",
|
|
3662
|
+
className: classes.subtitle
|
|
3663
|
+
}, subtitle)))));
|
|
3651
3664
|
};
|
|
3652
3665
|
|
|
3653
3666
|
const useStyles$i = makeStyles((theme) => ({
|