@backstage/core-components 0.8.1 → 0.8.2
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 +16 -0
- package/dist/index.d.ts +130 -36
- package/dist/index.esm.js +60 -46
- package/dist/index.esm.js.map +1 -1
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @backstage/core-components
|
|
2
2
|
|
|
3
|
+
## 0.8.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 73a91e25f9: Added description to components: BottomLink, Breadcrumbs, BrokenImageIcon, CardTab, Content, ContentHeader, EmptyState, ErrorPage, FeatureCalloutCircular, Gauge, GaugeCard, Header, HeaderIconLinkRow, HeaderLabel, HeaderTabs, HorizontalScrollGrid, InfoCard, IntroCard
|
|
8
|
+
- 27af6d996b: Locking `rc-progress` to the working version of 3.1.4
|
|
9
|
+
- 10e5f9d10c: Do not `setState` when unmounted in `OverflowTooltip`
|
|
10
|
+
- b646a73fe0: In @backstage/plugin-scaffolder - When user will have one option available in hostUrl or owner - autoselect and select component should be readonly.
|
|
11
|
+
|
|
12
|
+
in @backstage/core-components - Select component has extended API with few more props: native : boolean, disabled: boolean. native - if set to true - Select component will use native browser select picker (not rendered by Material UI lib ).
|
|
13
|
+
disabled - if set to true - action on component will not be possible.
|
|
14
|
+
|
|
15
|
+
- 7a4bd2ceac: Prefer using `Link` from `@backstage/core-components` rather than material-UI.
|
|
16
|
+
- Updated dependencies
|
|
17
|
+
- @backstage/core-plugin-api@0.4.0
|
|
18
|
+
|
|
3
19
|
## 0.8.1
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
package/dist/index.d.ts
CHANGED
|
@@ -524,7 +524,12 @@ declare type Props$i = {
|
|
|
524
524
|
missing: 'field' | 'info' | 'content' | 'data';
|
|
525
525
|
action?: JSX.Element;
|
|
526
526
|
};
|
|
527
|
-
/**
|
|
527
|
+
/**
|
|
528
|
+
* Various placeholder views for empty state pages
|
|
529
|
+
*
|
|
530
|
+
* @public
|
|
531
|
+
*
|
|
532
|
+
*/
|
|
528
533
|
declare function EmptyState(props: Props$i): JSX.Element;
|
|
529
534
|
|
|
530
535
|
/** @public */
|
|
@@ -567,7 +572,12 @@ declare type Props$g = {
|
|
|
567
572
|
title: string;
|
|
568
573
|
description: string;
|
|
569
574
|
};
|
|
570
|
-
/**
|
|
575
|
+
/**
|
|
576
|
+
* One-time, round 'telescope' animation showing new feature.
|
|
577
|
+
*
|
|
578
|
+
* @public
|
|
579
|
+
*
|
|
580
|
+
*/
|
|
571
581
|
declare function FeatureCalloutCircular(props: PropsWithChildren<Props$g>): JSX.Element;
|
|
572
582
|
|
|
573
583
|
declare type IconLinkVerticalProps = {
|
|
@@ -587,7 +597,12 @@ declare type HeaderIconLinkRowClassKey = 'links';
|
|
|
587
597
|
declare type Props$f = {
|
|
588
598
|
links: IconLinkVerticalProps[];
|
|
589
599
|
};
|
|
590
|
-
/**
|
|
600
|
+
/**
|
|
601
|
+
* HTML nav tag with links mapped inside
|
|
602
|
+
*
|
|
603
|
+
* @public
|
|
604
|
+
*
|
|
605
|
+
*/
|
|
591
606
|
declare function HeaderIconLinkRow(props: Props$f): JSX.Element;
|
|
592
607
|
|
|
593
608
|
declare type Props$e = {
|
|
@@ -597,7 +612,12 @@ declare type Props$e = {
|
|
|
597
612
|
};
|
|
598
613
|
/** @public */
|
|
599
614
|
declare type HorizontalScrollGridClassKey = 'root' | 'container' | 'fade' | 'fadeLeft' | 'fadeRight' | 'fadeHidden' | 'button' | 'buttonLeft' | 'buttonRight';
|
|
600
|
-
/**
|
|
615
|
+
/**
|
|
616
|
+
* Horizontal scrollable component with arrows to navigate
|
|
617
|
+
*
|
|
618
|
+
* @public
|
|
619
|
+
*
|
|
620
|
+
*/
|
|
601
621
|
declare function HorizontalScrollGrid(props: PropsWithChildren<Props$e>): JSX.Element;
|
|
602
622
|
|
|
603
623
|
declare type Props$d = CSS.Properties & {
|
|
@@ -674,6 +694,22 @@ declare function OverflowTooltip(props: Props$b): JSX.Element;
|
|
|
674
694
|
|
|
675
695
|
declare function Progress(props: PropsWithChildren<LinearProgressProps>): JSX.Element;
|
|
676
696
|
|
|
697
|
+
/** @public */
|
|
698
|
+
declare type BottomLinkClassKey = 'root' | 'boxTitle' | 'arrow';
|
|
699
|
+
/** @public */
|
|
700
|
+
declare type BottomLinkProps = {
|
|
701
|
+
link: string;
|
|
702
|
+
title: string;
|
|
703
|
+
onClick?: (event: React__default.MouseEvent<HTMLAnchorElement>) => void;
|
|
704
|
+
};
|
|
705
|
+
/**
|
|
706
|
+
* Footer with link used in {@link InfoCard } and {@link TabbedCard}
|
|
707
|
+
*
|
|
708
|
+
* @public
|
|
709
|
+
*
|
|
710
|
+
*/
|
|
711
|
+
declare function BottomLink(props: BottomLinkProps): JSX.Element;
|
|
712
|
+
|
|
677
713
|
declare type SlackChannel = {
|
|
678
714
|
name: string;
|
|
679
715
|
href?: string;
|
|
@@ -690,17 +726,6 @@ declare type State = {
|
|
|
690
726
|
/** @public */
|
|
691
727
|
declare const ErrorBoundary: ComponentClass<ErrorBoundaryProps, State>;
|
|
692
728
|
|
|
693
|
-
/** @public */
|
|
694
|
-
declare type BottomLinkClassKey = 'root' | 'boxTitle' | 'arrow';
|
|
695
|
-
/** @public */
|
|
696
|
-
declare type BottomLinkProps = {
|
|
697
|
-
link: string;
|
|
698
|
-
title: string;
|
|
699
|
-
onClick?: (event: React__default.MouseEvent<HTMLAnchorElement>) => void;
|
|
700
|
-
};
|
|
701
|
-
/** @public */
|
|
702
|
-
declare function BottomLink(props: BottomLinkProps): JSX.Element;
|
|
703
|
-
|
|
704
729
|
/** @public */
|
|
705
730
|
declare type InfoCardClassKey = 'noPadding' | 'header' | 'headerTitle' | 'headerSubheader' | 'headerAvatar' | 'headerAction' | 'headerContent';
|
|
706
731
|
/** @public */
|
|
@@ -746,7 +771,12 @@ declare type Props$a = {
|
|
|
746
771
|
noPadding?: boolean;
|
|
747
772
|
titleTypographyProps?: object;
|
|
748
773
|
};
|
|
749
|
-
/**
|
|
774
|
+
/**
|
|
775
|
+
* Material-ui card with header , content and actions footer
|
|
776
|
+
*
|
|
777
|
+
* @public
|
|
778
|
+
*
|
|
779
|
+
*/
|
|
750
780
|
declare function InfoCard(props: Props$a): JSX.Element;
|
|
751
781
|
|
|
752
782
|
/** @public */
|
|
@@ -769,7 +799,12 @@ declare type GaugePropsGetColorOptions = {
|
|
|
769
799
|
};
|
|
770
800
|
/** @public */
|
|
771
801
|
declare type GaugePropsGetColor = (args: GaugePropsGetColorOptions) => string;
|
|
772
|
-
/**
|
|
802
|
+
/**
|
|
803
|
+
* Circular Progress Bar
|
|
804
|
+
*
|
|
805
|
+
* @public
|
|
806
|
+
*
|
|
807
|
+
*/
|
|
773
808
|
declare function Gauge(props: GaugeProps): JSX.Element;
|
|
774
809
|
|
|
775
810
|
declare type Props$9 = {
|
|
@@ -784,7 +819,12 @@ declare type Props$9 = {
|
|
|
784
819
|
};
|
|
785
820
|
/** @public */
|
|
786
821
|
declare type GaugeCardClassKey = 'root';
|
|
787
|
-
/**
|
|
822
|
+
/**
|
|
823
|
+
* {@link Gauge} with header, subheader and footer
|
|
824
|
+
*
|
|
825
|
+
* @public
|
|
826
|
+
*
|
|
827
|
+
*/
|
|
788
828
|
declare function GaugeCard(props: Props$9): JSX.Element;
|
|
789
829
|
|
|
790
830
|
declare type Props$8 = {
|
|
@@ -796,22 +836,29 @@ declare type Props$8 = {
|
|
|
796
836
|
};
|
|
797
837
|
declare function LinearGauge(props: Props$8): JSX.Element | null;
|
|
798
838
|
|
|
839
|
+
/** @public */
|
|
799
840
|
declare type SelectInputBaseClassKey = 'root' | 'input';
|
|
841
|
+
/** @public */
|
|
800
842
|
declare type SelectClassKey = 'formControl' | 'label' | 'chips' | 'chip' | 'checkbox' | 'root';
|
|
801
|
-
|
|
843
|
+
/** @public */
|
|
844
|
+
declare type SelectItem = {
|
|
802
845
|
label: string;
|
|
803
846
|
value: string | number;
|
|
804
847
|
};
|
|
805
|
-
|
|
848
|
+
/** @public */
|
|
849
|
+
declare type SelectedItems = string | string[] | number | number[];
|
|
806
850
|
declare type SelectProps = {
|
|
807
851
|
multiple?: boolean;
|
|
808
|
-
items:
|
|
852
|
+
items: SelectItem[];
|
|
809
853
|
label: string;
|
|
810
854
|
placeholder?: string;
|
|
811
|
-
selected?:
|
|
812
|
-
onChange: (arg:
|
|
855
|
+
selected?: SelectedItems;
|
|
856
|
+
onChange: (arg: SelectedItems) => void;
|
|
813
857
|
triggerReset?: boolean;
|
|
858
|
+
native?: boolean;
|
|
859
|
+
disabled?: boolean;
|
|
814
860
|
};
|
|
861
|
+
/** @public */
|
|
815
862
|
declare function SelectComponent(props: SelectProps): JSX.Element;
|
|
816
863
|
|
|
817
864
|
/** @public */
|
|
@@ -1024,7 +1071,12 @@ declare type SupportConfig = {
|
|
|
1024
1071
|
declare function useSupportConfig(): SupportConfig;
|
|
1025
1072
|
|
|
1026
1073
|
declare type IconComponentProps = ComponentProps<IconComponent>;
|
|
1027
|
-
/**
|
|
1074
|
+
/**
|
|
1075
|
+
* Broken Image Icon
|
|
1076
|
+
*
|
|
1077
|
+
* @public
|
|
1078
|
+
*
|
|
1079
|
+
*/
|
|
1028
1080
|
declare function BrokenImageIcon(props: IconComponentProps): JSX.Element;
|
|
1029
1081
|
/** @public */
|
|
1030
1082
|
declare function CatalogIcon(props: IconComponentProps): JSX.Element;
|
|
@@ -1054,11 +1106,13 @@ declare type Props$6 = {
|
|
|
1054
1106
|
noPadding?: boolean;
|
|
1055
1107
|
className?: string;
|
|
1056
1108
|
};
|
|
1057
|
-
declare function Content(props: PropsWithChildren<Props$6>): JSX.Element;
|
|
1058
|
-
|
|
1059
1109
|
/**
|
|
1060
|
-
*
|
|
1110
|
+
* The main content part inside a {@link Page}.
|
|
1111
|
+
*
|
|
1112
|
+
* @public
|
|
1113
|
+
*
|
|
1061
1114
|
*/
|
|
1115
|
+
declare function Content(props: PropsWithChildren<Props$6>): JSX.Element;
|
|
1062
1116
|
|
|
1063
1117
|
/** @public */
|
|
1064
1118
|
declare type ContentHeaderClassKey = 'container' | 'leftItemsBox' | 'rightItemsBox' | 'description' | 'title';
|
|
@@ -1072,7 +1126,12 @@ declare type ContentHeaderProps = {
|
|
|
1072
1126
|
description?: string;
|
|
1073
1127
|
textAlign?: 'left' | 'right' | 'center';
|
|
1074
1128
|
};
|
|
1075
|
-
/**
|
|
1129
|
+
/**
|
|
1130
|
+
* A header at the top inside a {@link Content}.
|
|
1131
|
+
*
|
|
1132
|
+
* @public
|
|
1133
|
+
*
|
|
1134
|
+
*/
|
|
1076
1135
|
declare function ContentHeader(props: PropsWithChildren<ContentHeaderProps>): JSX.Element;
|
|
1077
1136
|
|
|
1078
1137
|
interface IErrorPageProps {
|
|
@@ -1082,7 +1141,12 @@ interface IErrorPageProps {
|
|
|
1082
1141
|
}
|
|
1083
1142
|
/** @public */
|
|
1084
1143
|
declare type ErrorPageClassKey = 'container' | 'title' | 'subtitle';
|
|
1085
|
-
/**
|
|
1144
|
+
/**
|
|
1145
|
+
* Error page with status and description
|
|
1146
|
+
*
|
|
1147
|
+
* @public
|
|
1148
|
+
*
|
|
1149
|
+
*/
|
|
1086
1150
|
declare function ErrorPage(props: IErrorPageProps): JSX.Element;
|
|
1087
1151
|
|
|
1088
1152
|
declare type MicDropClassKey = 'micDrop';
|
|
@@ -1099,7 +1163,12 @@ declare type Props$5 = {
|
|
|
1099
1163
|
type?: string;
|
|
1100
1164
|
typeLink?: string;
|
|
1101
1165
|
};
|
|
1102
|
-
/**
|
|
1166
|
+
/**
|
|
1167
|
+
* Backstage main header with abstract color background in multiple variants
|
|
1168
|
+
*
|
|
1169
|
+
* @public
|
|
1170
|
+
*
|
|
1171
|
+
*/
|
|
1103
1172
|
declare function Header(props: PropsWithChildren<Props$5>): JSX.Element;
|
|
1104
1173
|
|
|
1105
1174
|
/** @public */
|
|
@@ -1113,7 +1182,12 @@ declare type HeaderLabelProps = {
|
|
|
1113
1182
|
value?: HeaderLabelContentProps['value'];
|
|
1114
1183
|
url?: string;
|
|
1115
1184
|
};
|
|
1116
|
-
/**
|
|
1185
|
+
/**
|
|
1186
|
+
* Additional label to main {@link Header}
|
|
1187
|
+
*
|
|
1188
|
+
* @public
|
|
1189
|
+
*
|
|
1190
|
+
*/
|
|
1117
1191
|
declare function HeaderLabel(props: HeaderLabelProps): JSX.Element;
|
|
1118
1192
|
|
|
1119
1193
|
/** @public */
|
|
@@ -1130,7 +1204,12 @@ declare type HeaderTabsProps = {
|
|
|
1130
1204
|
onChange?: (index: number) => void;
|
|
1131
1205
|
selectedIndex?: number;
|
|
1132
1206
|
};
|
|
1133
|
-
/**
|
|
1207
|
+
/**
|
|
1208
|
+
* Horizontal Tabs component
|
|
1209
|
+
*
|
|
1210
|
+
* @public
|
|
1211
|
+
*
|
|
1212
|
+
*/
|
|
1134
1213
|
declare function HeaderTabs(props: HeaderTabsProps): JSX.Element;
|
|
1135
1214
|
|
|
1136
1215
|
/**
|
|
@@ -1388,7 +1467,12 @@ declare type IntroCardProps = {
|
|
|
1388
1467
|
text: string;
|
|
1389
1468
|
onClose: () => void;
|
|
1390
1469
|
};
|
|
1391
|
-
/**
|
|
1470
|
+
/**
|
|
1471
|
+
* Closable card with information from Navigation Sidebar
|
|
1472
|
+
*
|
|
1473
|
+
* @public
|
|
1474
|
+
*
|
|
1475
|
+
*/
|
|
1392
1476
|
declare function IntroCard(props: IntroCardProps): JSX.Element;
|
|
1393
1477
|
declare function SidebarIntro(_props: {}): JSX.Element | null;
|
|
1394
1478
|
|
|
@@ -1517,7 +1601,12 @@ declare type CardTabClassKey = 'root' | 'selected';
|
|
|
1517
1601
|
declare type CardTabProps = TabProps$1 & {
|
|
1518
1602
|
children: ReactNode;
|
|
1519
1603
|
};
|
|
1520
|
-
/**
|
|
1604
|
+
/**
|
|
1605
|
+
* Card tab component used in {@link TabbedCard}
|
|
1606
|
+
*
|
|
1607
|
+
* @public
|
|
1608
|
+
*
|
|
1609
|
+
*/
|
|
1521
1610
|
declare function CardTab(props: PropsWithChildren<CardTabProps>): JSX.Element;
|
|
1522
1611
|
|
|
1523
1612
|
declare type Props = ComponentProps<typeof MaterialBreadcrumbs>;
|
|
@@ -1525,7 +1614,12 @@ declare type Props = ComponentProps<typeof MaterialBreadcrumbs>;
|
|
|
1525
1614
|
declare type BreadcrumbsClickableTextClassKey = 'root';
|
|
1526
1615
|
/** @public */
|
|
1527
1616
|
declare type BreadcrumbsStyledBoxClassKey = 'root';
|
|
1528
|
-
/**
|
|
1617
|
+
/**
|
|
1618
|
+
* Breadcrumbs component to show navigation hierarchical structure
|
|
1619
|
+
*
|
|
1620
|
+
* @public
|
|
1621
|
+
*
|
|
1622
|
+
*/
|
|
1529
1623
|
declare function Breadcrumbs(props: Props): JSX.Element;
|
|
1530
1624
|
|
|
1531
1625
|
declare type BackstageComponentsNameToClassKey = {
|
|
@@ -1609,4 +1703,4 @@ declare type BackstageOverrides = Overrides & {
|
|
|
1609
1703
|
[Name in keyof BackstageComponentsNameToClassKey]?: Partial<StyleRules<BackstageComponentsNameToClassKey[Name]>>;
|
|
1610
1704
|
};
|
|
1611
1705
|
|
|
1612
|
-
export { AlertDisplay, Avatar, AvatarClassKey, AvatarProps, BackstageContentClassKey, BackstageOverrides, BoldHeaderClassKey, BottomLink, BottomLinkClassKey, BottomLinkProps, Breadcrumbs, BreadcrumbsClickableTextClassKey, BreadcrumbsStyledBoxClassKey, BrokenImageIcon, ActualButton as Button, ButtonProps, CardActionsTopRightClassKey, CardTab, CardTabClassKey, CatalogIcon, ChatIcon, ClosedDropdownClassKey, CodeSnippet, CodeSnippetProps, Content, ContentHeader, ContentHeaderClassKey, CopyTextButton, CopyTextButtonProps, CreateButton, CreateButtonProps, CustomProviderClassKey, DashboardIcon, DependencyGraph, DependencyGraphDefaultLabelClassKey, DependencyGraphDefaultNodeClassKey, DependencyGraphEdgeClassKey, DependencyGraphNodeClassKey, DependencyGraphProps, types_d as DependencyGraphTypes, DismissableBanner, DismissableBannerClassKey, DismissbleBannerClassKey, DocsIcon, EmailIcon, EmptyState, EmptyStateClassKey, EmptyStateImageClassKey, ErrorBoundary, ErrorBoundaryProps, ErrorPage, ErrorPageClassKey, ErrorPanel, ErrorPanelClassKey, ErrorPanelProps, FeatureCalloutCircleClassKey, FeatureCalloutCircular, FiltersContainerClassKey, Gauge, GaugeCard, GaugeCardClassKey, GaugeClassKey, GaugeProps, GaugePropsGetColor, GaugePropsGetColorOptions, GitHubIcon, GroupIcon, Header, HeaderClassKey, HeaderIconLinkRow, HeaderIconLinkRowClassKey, HeaderLabel, HeaderLabelClassKey, HeaderTabs, HeaderTabsClassKey, HelpIcon, HomepageTimer, HorizontalScrollGrid, HorizontalScrollGridClassKey, IconLinkVerticalClassKey, IconLinkVerticalProps, InfoCard, InfoCardClassKey, InfoCardVariants, IntroCard, ItemCard, ItemCardGrid, ItemCardGridClassKey, ItemCardGridProps, ItemCardHeader, ItemCardHeaderClassKey, ItemCardHeaderProps, Lifecycle, LifecycleClassKey, LinearGauge, ActualLink as Link, LinkProps, LogViewer, LogViewerClassKey, LogViewerProps, LoginRequestListItemClassKey, MarkdownContent, MarkdownContentClassKey, MetadataTableCellClassKey, MetadataTableListClassKey, MetadataTableListItemClassKey, MetadataTableTitleCellClassKey, MicDropClassKey, MissingAnnotationEmptyState, MissingAnnotationEmptyStateClassKey, OAuthRequestDialog, OAuthRequestDialogClassKey, OpenedDropdownClassKey, OverflowTooltip, OverflowTooltipClassKey, Page, PageClassKey, PageWithHeader, Progress, ResponseErrorPanel, ResponseErrorPanelClassKey, RoutedTabs, SIDEBAR_INTRO_LOCAL_STORAGE, SelectComponent as Select, SelectClassKey, SelectInputBaseClassKey, Sidebar, SidebarClassKey, SidebarContext, SidebarContextType, SidebarDivider, SidebarDividerClassKey, SidebarExpandButton, SidebarIntro, SidebarIntroClassKey, SidebarItem, SidebarItemClassKey, SidebarPage, SidebarPageClassKey, SidebarPinStateContext, SidebarPinStateContextType, SidebarScrollWrapper, SidebarSearchField, SidebarSpace, SidebarSpaceClassKey, SidebarSpacer, SidebarSpacerClassKey, SidebarSubmenu, SidebarSubmenuItem, SidebarSubmenuItemDropdownItem, SidebarSubmenuItemProps, SidebarSubmenuProps, SignInPage, SignInPageClassKey, SignInProviderConfig, SimpleStepper, SimpleStepperFooterClassKey, SimpleStepperStep, SimpleStepperStepClassKey, StatusAborted, StatusClassKey, StatusError, StatusOK, StatusPending, StatusRunning, StatusWarning, StructuredMetadataTable, StructuredMetadataTableListClassKey, StructuredMetadataTableNestedListClassKey, SubvalueCell, SubvalueCellClassKey, SupportButton, SupportButtonClassKey, SupportConfig, SupportItem, SupportItemLink, Tab, TabBarClassKey, TabIconClassKey, TabbedCard, TabbedCardClassKey, TabbedLayout, Table, TableClassKey, TableColumn, TableFilter, TableFiltersClassKey, TableHeaderClassKey, TableProps, TableState, TableToolbarClassKey, Tabs, TabsClassKey, TrendLine, UserIcon, UserIdentity, WarningIcon, WarningPanel, WarningPanelClassKey, sidebarConfig, useQueryParamState, useSupportConfig };
|
|
1706
|
+
export { AlertDisplay, Avatar, AvatarClassKey, AvatarProps, BackstageContentClassKey, BackstageOverrides, BoldHeaderClassKey, BottomLink, BottomLinkClassKey, BottomLinkProps, Breadcrumbs, BreadcrumbsClickableTextClassKey, BreadcrumbsStyledBoxClassKey, BrokenImageIcon, ActualButton as Button, ButtonProps, CardActionsTopRightClassKey, CardTab, CardTabClassKey, CatalogIcon, ChatIcon, ClosedDropdownClassKey, CodeSnippet, CodeSnippetProps, Content, ContentHeader, ContentHeaderClassKey, CopyTextButton, CopyTextButtonProps, CreateButton, CreateButtonProps, CustomProviderClassKey, DashboardIcon, DependencyGraph, DependencyGraphDefaultLabelClassKey, DependencyGraphDefaultNodeClassKey, DependencyGraphEdgeClassKey, DependencyGraphNodeClassKey, DependencyGraphProps, types_d as DependencyGraphTypes, DismissableBanner, DismissableBannerClassKey, DismissbleBannerClassKey, DocsIcon, EmailIcon, EmptyState, EmptyStateClassKey, EmptyStateImageClassKey, ErrorBoundary, ErrorBoundaryProps, ErrorPage, ErrorPageClassKey, ErrorPanel, ErrorPanelClassKey, ErrorPanelProps, FeatureCalloutCircleClassKey, FeatureCalloutCircular, FiltersContainerClassKey, Gauge, GaugeCard, GaugeCardClassKey, GaugeClassKey, GaugeProps, GaugePropsGetColor, GaugePropsGetColorOptions, GitHubIcon, GroupIcon, Header, HeaderClassKey, HeaderIconLinkRow, HeaderIconLinkRowClassKey, HeaderLabel, HeaderLabelClassKey, HeaderTabs, HeaderTabsClassKey, HelpIcon, HomepageTimer, HorizontalScrollGrid, HorizontalScrollGridClassKey, IconLinkVerticalClassKey, IconLinkVerticalProps, InfoCard, InfoCardClassKey, InfoCardVariants, IntroCard, ItemCard, ItemCardGrid, ItemCardGridClassKey, ItemCardGridProps, ItemCardHeader, ItemCardHeaderClassKey, ItemCardHeaderProps, Lifecycle, LifecycleClassKey, LinearGauge, ActualLink as Link, LinkProps, LogViewer, LogViewerClassKey, LogViewerProps, LoginRequestListItemClassKey, MarkdownContent, MarkdownContentClassKey, MetadataTableCellClassKey, MetadataTableListClassKey, MetadataTableListItemClassKey, MetadataTableTitleCellClassKey, MicDropClassKey, MissingAnnotationEmptyState, MissingAnnotationEmptyStateClassKey, OAuthRequestDialog, OAuthRequestDialogClassKey, OpenedDropdownClassKey, OverflowTooltip, OverflowTooltipClassKey, Page, PageClassKey, PageWithHeader, Progress, ResponseErrorPanel, ResponseErrorPanelClassKey, RoutedTabs, SIDEBAR_INTRO_LOCAL_STORAGE, SelectComponent as Select, SelectClassKey, SelectInputBaseClassKey, SelectItem, SelectedItems, Sidebar, SidebarClassKey, SidebarContext, SidebarContextType, SidebarDivider, SidebarDividerClassKey, SidebarExpandButton, SidebarIntro, SidebarIntroClassKey, SidebarItem, SidebarItemClassKey, SidebarPage, SidebarPageClassKey, SidebarPinStateContext, SidebarPinStateContextType, SidebarScrollWrapper, SidebarSearchField, SidebarSpace, SidebarSpaceClassKey, SidebarSpacer, SidebarSpacerClassKey, SidebarSubmenu, SidebarSubmenuItem, SidebarSubmenuItemDropdownItem, SidebarSubmenuItemProps, SidebarSubmenuProps, SignInPage, SignInPageClassKey, SignInProviderConfig, SimpleStepper, SimpleStepperFooterClassKey, SimpleStepperStep, SimpleStepperStepClassKey, StatusAborted, StatusClassKey, StatusError, StatusOK, StatusPending, StatusRunning, StatusWarning, StructuredMetadataTable, StructuredMetadataTableListClassKey, StructuredMetadataTableNestedListClassKey, SubvalueCell, SubvalueCellClassKey, SupportButton, SupportButtonClassKey, SupportConfig, SupportItem, SupportItemLink, Tab, TabBarClassKey, TabIconClassKey, TabbedCard, TabbedCardClassKey, TabbedLayout, Table, TableClassKey, TableColumn, TableFilter, TableFiltersClassKey, TableHeaderClassKey, TableProps, TableState, TableToolbarClassKey, Tabs, TabsClassKey, TrendLine, UserIcon, UserIdentity, WarningIcon, WarningPanel, WarningPanelClassKey, sidebarConfig, useQueryParamState, useSupportConfig };
|
package/dist/index.esm.js
CHANGED
|
@@ -12,7 +12,7 @@ import Link from '@material-ui/core/Link';
|
|
|
12
12
|
import { Link as Link$1, useSearchParams, useResolvedPath, useLocation, resolvePath, NavLink } from 'react-router-dom';
|
|
13
13
|
import Tooltip from '@material-ui/core/Tooltip';
|
|
14
14
|
import CopyIcon from '@material-ui/icons/FileCopy';
|
|
15
|
-
import { useCopyToClipboard, useObservable, useDebounce, useWindowSize, useLocalStorage, useMount } from 'react-use';
|
|
15
|
+
import { useCopyToClipboard, useObservable, useMountedState, useDebounce, useWindowSize, useLocalStorage, useMount } from 'react-use';
|
|
16
16
|
import { LightAsync } from 'react-syntax-highlighter';
|
|
17
17
|
import dark from 'react-syntax-highlighter/dist/esm/styles/hljs/dark';
|
|
18
18
|
import docco from 'react-syntax-highlighter/dist/esm/styles/hljs/docco';
|
|
@@ -28,8 +28,8 @@ import * as d3Shape from 'd3-shape';
|
|
|
28
28
|
import isFinite from 'lodash/isFinite';
|
|
29
29
|
import classNames from 'classnames';
|
|
30
30
|
import SnackbarContent from '@material-ui/core/SnackbarContent';
|
|
31
|
-
import Typography from '@material-ui/core/Typography';
|
|
32
31
|
import Grid from '@material-ui/core/Grid';
|
|
32
|
+
import Typography from '@material-ui/core/Typography';
|
|
33
33
|
import missingAnnotation from './components/EmptyState/assets/missingAnnotation.svg';
|
|
34
34
|
import noInformation from './components/EmptyState/assets/noInformation.svg';
|
|
35
35
|
import createComponent from './components/EmptyState/assets/createComponent.svg';
|
|
@@ -62,8 +62,8 @@ import Card from '@material-ui/core/Card';
|
|
|
62
62
|
import CardActions from '@material-ui/core/CardActions';
|
|
63
63
|
import CardContent from '@material-ui/core/CardContent';
|
|
64
64
|
import CardHeader from '@material-ui/core/CardHeader';
|
|
65
|
-
import ArrowIcon from '@material-ui/icons/ArrowForward';
|
|
66
65
|
import Box from '@material-ui/core/Box';
|
|
66
|
+
import ArrowIcon from '@material-ui/icons/ArrowForward';
|
|
67
67
|
import { Circle, Line } from 'rc-progress';
|
|
68
68
|
import Checkbox from '@material-ui/core/Checkbox';
|
|
69
69
|
import Chip from '@material-ui/core/Chip';
|
|
@@ -1760,9 +1760,12 @@ const useStyles$y = makeStyles({
|
|
|
1760
1760
|
function OverflowTooltip(props) {
|
|
1761
1761
|
var _a;
|
|
1762
1762
|
const [hover, setHover] = useState(false);
|
|
1763
|
+
const isMounted = useMountedState();
|
|
1763
1764
|
const classes = useStyles$y();
|
|
1764
1765
|
const handleToggled = (truncated) => {
|
|
1765
|
-
|
|
1766
|
+
if (isMounted()) {
|
|
1767
|
+
setHover(truncated);
|
|
1768
|
+
}
|
|
1766
1769
|
};
|
|
1767
1770
|
return /* @__PURE__ */ React.createElement(Tooltip, {
|
|
1768
1771
|
title: (_a = props.title) != null ? _a : props.text || "",
|
|
@@ -1790,6 +1793,39 @@ function Progress(props) {
|
|
|
1790
1793
|
});
|
|
1791
1794
|
}
|
|
1792
1795
|
|
|
1796
|
+
const useStyles$x = makeStyles((theme) => ({
|
|
1797
|
+
root: {
|
|
1798
|
+
maxWidth: "fit-content",
|
|
1799
|
+
padding: theme.spacing(2, 2, 2, 2.5)
|
|
1800
|
+
},
|
|
1801
|
+
boxTitle: {
|
|
1802
|
+
margin: 0,
|
|
1803
|
+
color: theme.palette.textSubtle
|
|
1804
|
+
},
|
|
1805
|
+
arrow: {
|
|
1806
|
+
color: theme.palette.textSubtle
|
|
1807
|
+
}
|
|
1808
|
+
}), { name: "BackstageBottomLink" });
|
|
1809
|
+
function BottomLink(props) {
|
|
1810
|
+
const { link, title, onClick } = props;
|
|
1811
|
+
const classes = useStyles$x();
|
|
1812
|
+
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement(Divider, null), /* @__PURE__ */ React.createElement(ActualLink, {
|
|
1813
|
+
to: link,
|
|
1814
|
+
onClick,
|
|
1815
|
+
underline: "none"
|
|
1816
|
+
}, /* @__PURE__ */ React.createElement(Box, {
|
|
1817
|
+
display: "flex",
|
|
1818
|
+
alignItems: "center",
|
|
1819
|
+
className: classes.root
|
|
1820
|
+
}, /* @__PURE__ */ React.createElement(Box, {
|
|
1821
|
+
className: classes.boxTitle,
|
|
1822
|
+
fontWeight: "fontWeightBold",
|
|
1823
|
+
m: 1
|
|
1824
|
+
}, /* @__PURE__ */ React.createElement(Typography, null, /* @__PURE__ */ React.createElement("strong", null, title))), /* @__PURE__ */ React.createElement(ArrowIcon, {
|
|
1825
|
+
className: classes.arrow
|
|
1826
|
+
}))));
|
|
1827
|
+
}
|
|
1828
|
+
|
|
1793
1829
|
const SlackLink = (props) => {
|
|
1794
1830
|
const { slackChannel } = props;
|
|
1795
1831
|
if (!slackChannel) {
|
|
@@ -1831,39 +1867,6 @@ const ErrorBoundary = class ErrorBoundary2 extends Component$3 {
|
|
|
1831
1867
|
}
|
|
1832
1868
|
};
|
|
1833
1869
|
|
|
1834
|
-
const useStyles$x = makeStyles((theme) => ({
|
|
1835
|
-
root: {
|
|
1836
|
-
maxWidth: "fit-content",
|
|
1837
|
-
padding: theme.spacing(2, 2, 2, 2.5)
|
|
1838
|
-
},
|
|
1839
|
-
boxTitle: {
|
|
1840
|
-
margin: 0,
|
|
1841
|
-
color: theme.palette.textSubtle
|
|
1842
|
-
},
|
|
1843
|
-
arrow: {
|
|
1844
|
-
color: theme.palette.textSubtle
|
|
1845
|
-
}
|
|
1846
|
-
}), { name: "BackstageBottomLink" });
|
|
1847
|
-
function BottomLink(props) {
|
|
1848
|
-
const { link, title, onClick } = props;
|
|
1849
|
-
const classes = useStyles$x();
|
|
1850
|
-
return /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement(Divider, null), /* @__PURE__ */ React.createElement(ActualLink, {
|
|
1851
|
-
to: link,
|
|
1852
|
-
onClick,
|
|
1853
|
-
underline: "none"
|
|
1854
|
-
}, /* @__PURE__ */ React.createElement(Box, {
|
|
1855
|
-
display: "flex",
|
|
1856
|
-
alignItems: "center",
|
|
1857
|
-
className: classes.root
|
|
1858
|
-
}, /* @__PURE__ */ React.createElement(Box, {
|
|
1859
|
-
className: classes.boxTitle,
|
|
1860
|
-
fontWeight: "fontWeightBold",
|
|
1861
|
-
m: 1
|
|
1862
|
-
}, /* @__PURE__ */ React.createElement(Typography, null, /* @__PURE__ */ React.createElement("strong", null, title))), /* @__PURE__ */ React.createElement(ArrowIcon, {
|
|
1863
|
-
className: classes.arrow
|
|
1864
|
-
}))));
|
|
1865
|
-
}
|
|
1866
|
-
|
|
1867
1870
|
const useStyles$w = makeStyles((theme) => ({
|
|
1868
1871
|
noPadding: {
|
|
1869
1872
|
padding: 0,
|
|
@@ -2203,7 +2206,9 @@ function SelectComponent(props) {
|
|
|
2203
2206
|
placeholder,
|
|
2204
2207
|
selected,
|
|
2205
2208
|
onChange,
|
|
2206
|
-
triggerReset
|
|
2209
|
+
triggerReset,
|
|
2210
|
+
native = false,
|
|
2211
|
+
disabled = false
|
|
2207
2212
|
} = props;
|
|
2208
2213
|
const classes = useStyles$r();
|
|
2209
2214
|
const [value, setValue] = useState(selected || (multiple ? [] : ""));
|
|
@@ -2221,6 +2226,10 @@ function SelectComponent(props) {
|
|
|
2221
2226
|
onChange(event.target.value);
|
|
2222
2227
|
};
|
|
2223
2228
|
const handleClick = (event) => {
|
|
2229
|
+
if (disabled) {
|
|
2230
|
+
event.preventDefault();
|
|
2231
|
+
return;
|
|
2232
|
+
}
|
|
2224
2233
|
setOpen((previous) => {
|
|
2225
2234
|
if (multiple && !(event.target instanceof HTMLElement)) {
|
|
2226
2235
|
return true;
|
|
@@ -2246,6 +2255,8 @@ function SelectComponent(props) {
|
|
|
2246
2255
|
className: classes.formControl
|
|
2247
2256
|
}, /* @__PURE__ */ React.createElement(Select, {
|
|
2248
2257
|
value,
|
|
2258
|
+
native,
|
|
2259
|
+
disabled,
|
|
2249
2260
|
"data-testid": "select",
|
|
2250
2261
|
displayEmpty: true,
|
|
2251
2262
|
multiple,
|
|
@@ -2282,7 +2293,10 @@ function SelectComponent(props) {
|
|
|
2282
2293
|
}
|
|
2283
2294
|
}, placeholder && !multiple && /* @__PURE__ */ React.createElement(MenuItem, {
|
|
2284
2295
|
value: []
|
|
2285
|
-
}, placeholder), items && items.map((item) => /* @__PURE__ */ React.createElement(
|
|
2296
|
+
}, placeholder), native ? items && items.map((item) => /* @__PURE__ */ React.createElement("option", {
|
|
2297
|
+
value: item.value,
|
|
2298
|
+
key: item.value
|
|
2299
|
+
}, item.label)) : items && items.map((item) => /* @__PURE__ */ React.createElement(MenuItem, {
|
|
2286
2300
|
key: item.value,
|
|
2287
2301
|
value: item.value
|
|
2288
2302
|
}, multiple && /* @__PURE__ */ React.createElement(Checkbox, {
|
|
@@ -3848,13 +3862,13 @@ function ErrorPage(props) {
|
|
|
3848
3862
|
className: classes.title
|
|
3849
3863
|
}, "Looks like someone dropped the mic!"), /* @__PURE__ */ React.createElement(Typography, {
|
|
3850
3864
|
variant: "h6"
|
|
3851
|
-
}, /* @__PURE__ */ React.createElement(
|
|
3865
|
+
}, /* @__PURE__ */ React.createElement(ActualLink, {
|
|
3866
|
+
to: "#",
|
|
3852
3867
|
"data-testid": "go-back-link",
|
|
3853
3868
|
onClick: () => navigate(-1)
|
|
3854
|
-
}, "Go back"), "... or please
|
|
3855
|
-
|
|
3856
|
-
|
|
3857
|
-
}, "contact support"), " ", "if you think this is a bug.")));
|
|
3869
|
+
}, "Go back"), "... or please ", /* @__PURE__ */ React.createElement(ActualLink, {
|
|
3870
|
+
to: support.url
|
|
3871
|
+
}, "contact support"), " if you think this is a bug.")));
|
|
3858
3872
|
}
|
|
3859
3873
|
|
|
3860
3874
|
const ClickableText = withStyles({
|
|
@@ -4096,8 +4110,8 @@ function HeaderLabel(props) {
|
|
|
4096
4110
|
className: classes.root
|
|
4097
4111
|
}, /* @__PURE__ */ React.createElement(Typography, {
|
|
4098
4112
|
className: classes.label
|
|
4099
|
-
}, label), url ? /* @__PURE__ */ React.createElement(
|
|
4100
|
-
|
|
4113
|
+
}, label), url ? /* @__PURE__ */ React.createElement(ActualLink, {
|
|
4114
|
+
to: url
|
|
4101
4115
|
}, content) : content));
|
|
4102
4116
|
}
|
|
4103
4117
|
|