@backstage/ui 0.15.0-next.0 → 0.15.0-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 +37 -0
- package/dist/components/Card/Card.module.css.esm.js +2 -2
- package/dist/components/Checkbox/Checkbox.module.css.esm.js +2 -2
- package/dist/components/Container/Container.module.css.esm.js +2 -2
- package/dist/components/Header/Header.esm.js +187 -28
- package/dist/components/Header/Header.esm.js.map +1 -1
- package/dist/components/Header/Header.module.css.esm.js +2 -2
- package/dist/components/Header/HeaderMetadataStatus.esm.js +32 -0
- package/dist/components/Header/HeaderMetadataStatus.esm.js.map +1 -0
- package/dist/components/Header/HeaderMetadataStatus.module.css.esm.js +8 -0
- package/dist/components/Header/HeaderMetadataStatus.module.css.esm.js.map +1 -0
- package/dist/components/Header/HeaderMetadataUsers.esm.js +92 -0
- package/dist/components/Header/HeaderMetadataUsers.esm.js.map +1 -0
- package/dist/components/Header/HeaderMetadataUsers.module.css.esm.js +8 -0
- package/dist/components/Header/HeaderMetadataUsers.module.css.esm.js.map +1 -0
- package/dist/components/Header/definition.esm.js +22 -3
- package/dist/components/Header/definition.esm.js.map +1 -1
- package/dist/components/Link/Link.esm.js +3 -0
- package/dist/components/Link/Link.esm.js.map +1 -1
- package/dist/components/Select/Select.module.css.esm.js +2 -2
- package/dist/components/Select/SelectContent.esm.js.map +1 -1
- package/dist/components/Select/SelectListBox.esm.js +26 -12
- package/dist/components/Select/SelectListBox.esm.js.map +1 -1
- package/dist/components/Select/definition.esm.js +20 -4
- package/dist/components/Select/definition.esm.js.map +1 -1
- package/dist/hooks/useDefinition/useDefinition.esm.js +8 -6
- package/dist/hooks/useDefinition/useDefinition.esm.js.map +1 -1
- package/dist/hooks/useResolvedHref.esm.js +17 -0
- package/dist/hooks/useResolvedHref.esm.js.map +1 -0
- package/dist/index.d.ts +123 -6
- package/dist/index.esm.js +2 -0
- package/dist/index.esm.js.map +1 -1
- package/dist/provider/BUIProvider.esm.js +3 -2
- package/dist/provider/BUIProvider.esm.js.map +1 -1
- package/package.json +7 -3
package/dist/index.d.ts
CHANGED
|
@@ -1568,6 +1568,44 @@ interface HeaderNavTabGroup {
|
|
|
1568
1568
|
* @public
|
|
1569
1569
|
*/
|
|
1570
1570
|
type HeaderNavTabItem = HeaderNavTab | HeaderNavTabGroup;
|
|
1571
|
+
/**
|
|
1572
|
+
* Represents a tag item in the header.
|
|
1573
|
+
*
|
|
1574
|
+
* @public
|
|
1575
|
+
*/
|
|
1576
|
+
interface HeaderTag {
|
|
1577
|
+
label: string;
|
|
1578
|
+
href?: string;
|
|
1579
|
+
}
|
|
1580
|
+
/**
|
|
1581
|
+
* Represents a metadata key-value pair in the header.
|
|
1582
|
+
*
|
|
1583
|
+
* @public
|
|
1584
|
+
*/
|
|
1585
|
+
interface HeaderMetadataItem {
|
|
1586
|
+
label: string;
|
|
1587
|
+
value: React.ReactNode;
|
|
1588
|
+
}
|
|
1589
|
+
/**
|
|
1590
|
+
* Represents a user in the HeaderMetadataUsers component.
|
|
1591
|
+
*
|
|
1592
|
+
* @public
|
|
1593
|
+
*/
|
|
1594
|
+
interface HeaderMetadataUser {
|
|
1595
|
+
name: string;
|
|
1596
|
+
src?: string;
|
|
1597
|
+
href?: string;
|
|
1598
|
+
}
|
|
1599
|
+
/**
|
|
1600
|
+
* Represents a status item in the HeaderMetadataStatus component.
|
|
1601
|
+
*
|
|
1602
|
+
* @public
|
|
1603
|
+
*/
|
|
1604
|
+
interface HeaderMetadataStatusProps {
|
|
1605
|
+
label: string;
|
|
1606
|
+
color: 'danger' | 'warning' | 'success' | 'info';
|
|
1607
|
+
href?: string;
|
|
1608
|
+
}
|
|
1571
1609
|
/**
|
|
1572
1610
|
* Own props for the Header component.
|
|
1573
1611
|
*
|
|
@@ -1578,8 +1616,23 @@ interface HeaderOwnProps {
|
|
|
1578
1616
|
customActions?: React.ReactNode;
|
|
1579
1617
|
tabs?: HeaderNavTabItem[];
|
|
1580
1618
|
activeTabId?: string | null;
|
|
1619
|
+
/**
|
|
1620
|
+
* @deprecated The breadcrumbs prop will be removed in a future release.
|
|
1621
|
+
*/
|
|
1581
1622
|
breadcrumbs?: HeaderBreadcrumb[];
|
|
1623
|
+
/**
|
|
1624
|
+
* Markdown string rendered below the title. Only inline links are supported.
|
|
1625
|
+
* Bold, italic, and block-level markdown are not rendered.
|
|
1626
|
+
*/
|
|
1627
|
+
description?: string;
|
|
1628
|
+
tags?: HeaderTag[];
|
|
1629
|
+
metadata?: HeaderMetadataItem[];
|
|
1582
1630
|
className?: string;
|
|
1631
|
+
/**
|
|
1632
|
+
* Makes the title-and-actions row stick to the top of its nearest scroll
|
|
1633
|
+
* container while the rest of the header content scrolls away.
|
|
1634
|
+
*/
|
|
1635
|
+
sticky?: boolean;
|
|
1583
1636
|
}
|
|
1584
1637
|
/**
|
|
1585
1638
|
* Props for the Header component.
|
|
@@ -1633,12 +1686,27 @@ declare const HeaderDefinition: {
|
|
|
1633
1686
|
readonly styles: {
|
|
1634
1687
|
readonly [key: string]: string;
|
|
1635
1688
|
};
|
|
1689
|
+
readonly bg: "consumer";
|
|
1636
1690
|
readonly classNames: {
|
|
1637
|
-
readonly
|
|
1691
|
+
readonly headerTop: "bui-HeaderTop";
|
|
1692
|
+
readonly stickySentinel: "bui-HeaderStickySentinel";
|
|
1638
1693
|
readonly content: "bui-HeaderContent";
|
|
1694
|
+
readonly headerBottom: "bui-HeaderBottom";
|
|
1639
1695
|
readonly breadcrumbs: "bui-HeaderBreadcrumbs";
|
|
1696
|
+
readonly breadcrumbsSmall: "bui-HeaderBreadcrumbsSmall";
|
|
1697
|
+
readonly breadcrumbLink: "bui-HeaderBreadcrumbLink";
|
|
1698
|
+
readonly breadcrumbLinkSmall: "bui-HeaderBreadcrumbLinkSmall";
|
|
1699
|
+
readonly breadcrumbSeparator: "bui-HeaderBreadcrumbSeparator";
|
|
1700
|
+
readonly titleStack: "bui-HeaderTitleStack";
|
|
1701
|
+
readonly title: "bui-HeaderTitle";
|
|
1702
|
+
readonly titleSmall: "bui-HeaderTitleSmall";
|
|
1640
1703
|
readonly tabsWrapper: "bui-HeaderTabsWrapper";
|
|
1641
1704
|
readonly controls: "bui-HeaderControls";
|
|
1705
|
+
readonly tags: "bui-HeaderTags";
|
|
1706
|
+
readonly tag: "bui-HeaderTag";
|
|
1707
|
+
readonly description: "bui-HeaderDescription";
|
|
1708
|
+
readonly metaRow: "bui-HeaderMetaRow";
|
|
1709
|
+
readonly metaItem: "bui-HeaderMetaItem";
|
|
1642
1710
|
};
|
|
1643
1711
|
readonly propDefs: {
|
|
1644
1712
|
readonly title: {};
|
|
@@ -1646,7 +1714,11 @@ declare const HeaderDefinition: {
|
|
|
1646
1714
|
readonly tabs: {};
|
|
1647
1715
|
readonly activeTabId: {};
|
|
1648
1716
|
readonly breadcrumbs: {};
|
|
1717
|
+
readonly description: {};
|
|
1718
|
+
readonly tags: {};
|
|
1719
|
+
readonly metadata: {};
|
|
1649
1720
|
readonly className: {};
|
|
1721
|
+
readonly sticky: {};
|
|
1650
1722
|
};
|
|
1651
1723
|
};
|
|
1652
1724
|
/**
|
|
@@ -1657,12 +1729,27 @@ declare const HeaderPageDefinition: {
|
|
|
1657
1729
|
readonly styles: {
|
|
1658
1730
|
readonly [key: string]: string;
|
|
1659
1731
|
};
|
|
1732
|
+
readonly bg: "consumer";
|
|
1660
1733
|
readonly classNames: {
|
|
1661
|
-
readonly
|
|
1734
|
+
readonly headerTop: "bui-HeaderTop";
|
|
1735
|
+
readonly stickySentinel: "bui-HeaderStickySentinel";
|
|
1662
1736
|
readonly content: "bui-HeaderContent";
|
|
1737
|
+
readonly headerBottom: "bui-HeaderBottom";
|
|
1663
1738
|
readonly breadcrumbs: "bui-HeaderBreadcrumbs";
|
|
1739
|
+
readonly breadcrumbsSmall: "bui-HeaderBreadcrumbsSmall";
|
|
1740
|
+
readonly breadcrumbLink: "bui-HeaderBreadcrumbLink";
|
|
1741
|
+
readonly breadcrumbLinkSmall: "bui-HeaderBreadcrumbLinkSmall";
|
|
1742
|
+
readonly breadcrumbSeparator: "bui-HeaderBreadcrumbSeparator";
|
|
1743
|
+
readonly titleStack: "bui-HeaderTitleStack";
|
|
1744
|
+
readonly title: "bui-HeaderTitle";
|
|
1745
|
+
readonly titleSmall: "bui-HeaderTitleSmall";
|
|
1664
1746
|
readonly tabsWrapper: "bui-HeaderTabsWrapper";
|
|
1665
1747
|
readonly controls: "bui-HeaderControls";
|
|
1748
|
+
readonly tags: "bui-HeaderTags";
|
|
1749
|
+
readonly tag: "bui-HeaderTag";
|
|
1750
|
+
readonly description: "bui-HeaderDescription";
|
|
1751
|
+
readonly metaRow: "bui-HeaderMetaRow";
|
|
1752
|
+
readonly metaItem: "bui-HeaderMetaItem";
|
|
1666
1753
|
};
|
|
1667
1754
|
readonly propDefs: {
|
|
1668
1755
|
readonly title: {};
|
|
@@ -1670,7 +1757,11 @@ declare const HeaderPageDefinition: {
|
|
|
1670
1757
|
readonly tabs: {};
|
|
1671
1758
|
readonly activeTabId: {};
|
|
1672
1759
|
readonly breadcrumbs: {};
|
|
1760
|
+
readonly description: {};
|
|
1761
|
+
readonly tags: {};
|
|
1762
|
+
readonly metadata: {};
|
|
1673
1763
|
readonly className: {};
|
|
1764
|
+
readonly sticky: {};
|
|
1674
1765
|
};
|
|
1675
1766
|
};
|
|
1676
1767
|
|
|
@@ -1725,6 +1816,26 @@ declare const HeaderNavGroupDefinition: {
|
|
|
1725
1816
|
};
|
|
1726
1817
|
};
|
|
1727
1818
|
|
|
1819
|
+
/**
|
|
1820
|
+
* Displays a list of users as avatars inside a Header metadata value.
|
|
1821
|
+
* A single user shows the avatar with their name beside it.
|
|
1822
|
+
* Multiple users show avatars in a row with the name revealed on hover via tooltip.
|
|
1823
|
+
* When a user has an `href`, the avatar and name become links.
|
|
1824
|
+
*
|
|
1825
|
+
* @public
|
|
1826
|
+
*/
|
|
1827
|
+
declare const HeaderMetadataUsers: ({ users, }: {
|
|
1828
|
+
users: HeaderMetadataUser[];
|
|
1829
|
+
}) => react_jsx_runtime.JSX.Element | null;
|
|
1830
|
+
|
|
1831
|
+
/**
|
|
1832
|
+
* Displays a single status indicator as a coloured dot with a label inside a
|
|
1833
|
+
* Header metadata value. Optionally renders the label as a link when href is provided.
|
|
1834
|
+
*
|
|
1835
|
+
* @public
|
|
1836
|
+
*/
|
|
1837
|
+
declare const HeaderMetadataStatus: ({ label, color, href, }: HeaderMetadataStatusProps) => react_jsx_runtime.JSX.Element;
|
|
1838
|
+
|
|
1728
1839
|
/** @public */
|
|
1729
1840
|
type ButtonIconOwnProps = {
|
|
1730
1841
|
size?: Responsive<'small' | 'medium'>;
|
|
@@ -3446,6 +3557,11 @@ type Option = {
|
|
|
3446
3557
|
disabled?: boolean;
|
|
3447
3558
|
};
|
|
3448
3559
|
/** @public */
|
|
3560
|
+
type OptionSection = {
|
|
3561
|
+
title: string;
|
|
3562
|
+
options: Option[];
|
|
3563
|
+
};
|
|
3564
|
+
/** @public */
|
|
3449
3565
|
type SelectOwnProps = {
|
|
3450
3566
|
/**
|
|
3451
3567
|
* An icon to render before the input
|
|
@@ -3457,9 +3573,10 @@ type SelectOwnProps = {
|
|
|
3457
3573
|
*/
|
|
3458
3574
|
size?: 'small' | 'medium' | Partial<Record<Breakpoint, 'small' | 'medium'>>;
|
|
3459
3575
|
/**
|
|
3460
|
-
* The options of the select field
|
|
3576
|
+
* The options of the select field. Pass flat options, option sections for
|
|
3577
|
+
* grouped display, or a mix of both in the same array.
|
|
3461
3578
|
*/
|
|
3462
|
-
options?: Array<Option>;
|
|
3579
|
+
options?: Array<Option | OptionSection>;
|
|
3463
3580
|
/**
|
|
3464
3581
|
* Enable search/filter functionality in the dropdown
|
|
3465
3582
|
* @defaultValue false
|
|
@@ -3858,5 +3975,5 @@ declare function useAnalytics(): AnalyticsTracker;
|
|
|
3858
3975
|
*/
|
|
3859
3976
|
declare function getNodeText(node: ReactNode | ((...args: any[]) => ReactNode)): string | undefined;
|
|
3860
3977
|
|
|
3861
|
-
export { Accordion, AccordionDefinition, AccordionGroup, AccordionGroupDefinition, AccordionPanel, AccordionPanelDefinition, AccordionTrigger, AccordionTriggerDefinition, Alert, AlertDefinition, Avatar, AvatarDefinition, BUIProvider, Badge, BadgeDefinition, BgProvider, Box, BoxDefinition, Button, ButtonDefinition, ButtonIcon, ButtonIconDefinition, ButtonLink, ButtonLinkDefinition, Card, CardBody, CardBodyDefinition, CardDefinition, CardFooter, CardFooterDefinition, CardHeader, CardHeaderDefinition, Cell, CellProfile, CellText, Checkbox, CheckboxDefinition, CheckboxGroup, CheckboxGroupDefinition, Column, Container, ContainerDefinition, DateRangePicker, DateRangePickerDefinition, Dialog, DialogBody, DialogBodyDefinition, DialogDefinition, DialogFooter, DialogFooterDefinition, DialogHeader, DialogHeaderDefinition, DialogTrigger, FieldLabel, FieldLabelDefinition, Flex, FlexDefinition, FullPage, FullPageDefinition, Grid, GridDefinition, GridItemDefinition, Header, HeaderDefinition, HeaderNavDefinition, HeaderNavGroupDefinition, HeaderNavItemDefinition, HeaderPage, HeaderPageDefinition, Link, LinkDefinition, List, ListDefinition, ListRow, ListRowDefinition, Menu, MenuAutocomplete, MenuAutocompleteListbox, MenuDefinition, MenuItem, MenuListBox, MenuListBoxItem, MenuSection, MenuSeparator, MenuTrigger, PasswordField, PasswordFieldDefinition, PluginHeader, PluginHeaderDefinition, Popover, PopoverDefinition, Radio, RadioDefinition, RadioGroup, RadioGroupDefinition, Row, SearchAutocomplete, SearchAutocompleteDefinition, SearchAutocompleteItem, SearchField, SearchFieldDefinition, Select, SelectDefinition, Skeleton, SkeletonDefinition, Slider, SliderDefinition, SubmenuTrigger, Switch, SwitchDefinition, Tab, TabList, TabPanel, Table, TableBody, TableBodySkeleton, TableDefinition, TableHeader, TablePagination, TablePaginationDefinition, TableRoot, Tabs, TabsDefinition, Tag, TagGroup, TagGroupDefinition, Text, TextDefinition, TextField, TextFieldDefinition, ToggleButton, ToggleButtonDefinition, ToggleButtonGroup, ToggleButtonGroupDefinition, Tooltip, TooltipDefinition, TooltipTrigger, VisuallyHidden, VisuallyHiddenDefinition, getNodeText, useAnalytics, useBgConsumer, useBgProvider, useBreakpoint, useTable };
|
|
3862
|
-
export type { AccordionGroupOwnProps, AccordionGroupProps, AccordionOwnProps, AccordionPanelOwnProps, AccordionPanelProps, AccordionProps, AccordionTriggerOwnProps, AccordionTriggerProps, AlertOwnProps, AlertProps, AlignItems, AnalyticsEventAttributes, AnalyticsTracker, AvatarOwnProps, AvatarProps, BUIProviderProps, BadgeOwnProps, BadgeProps, BgContextValue, BgProviderProps, Border, BorderRadius, BoxOwnProps, BoxProps, BoxUtilityProps, Breakpoint, ButtonIconOwnProps, ButtonIconProps, ButtonLinkOwnProps, ButtonLinkProps, ButtonOwnProps, ButtonProps, CardBaseProps, CardBodyOwnProps, CardBodyProps, CardButtonVariant, CardFooterOwnProps, CardFooterProps, CardHeaderOwnProps, CardHeaderProps, CardLinkVariant, CardOwnProps, CardProps, CardStaticVariant, CellOwnProps, CellProfileOwnProps, CellProfileProps, CellProps, CellTextOwnProps, CellTextProps, CheckboxGroupOwnProps, CheckboxGroupProps, CheckboxOwnProps, CheckboxProps, ColumnConfig, ColumnOwnProps, ColumnProps, Columns, CompletePaginationOptions, ContainerBg, ContainerOwnProps, ContainerProps, CursorParams, CursorResponse, DateRangePickerOwnProps, DateRangePickerProps, DialogBodyOwnProps, DialogBodyProps, DialogFooterOwnProps, DialogFooterProps, DialogHeaderOwnProps, DialogHeaderProps, DialogOwnProps, DialogProps, DialogTriggerProps, Display, FieldLabelOwnProps, FieldLabelProps, FilterState, FlexDirection, FlexItemProps, FlexOwnProps, FlexProps, FlexWrap, FullPageOwnProps, FullPageProps, GridItemOwnProps, GridItemProps, GridOwnProps, GridProps, HeaderBreadcrumb, HeaderNavTab, HeaderNavTabGroup, HeaderNavTabItem, HeaderOwnProps, HeaderPageBreadcrumb, HeaderPageOwnProps, HeaderPageProps, HeaderProps, HeaderTab, JustifyContent, LinkOwnProps, LinkProps, ListOwnProps, ListProps, ListRowOwnProps, ListRowProps, MarginProps, MenuAutocompleteListBoxOwnProps, MenuAutocompleteListBoxProps, MenuAutocompleteOwnProps, MenuAutocompleteProps, MenuItemOwnProps, MenuItemProps, MenuListBoxItemOwnProps, MenuListBoxItemProps, MenuListBoxOwnProps, MenuListBoxProps, MenuOwnProps, MenuPopoverOwnProps, MenuProps, MenuSectionOwnProps, MenuSectionProps, MenuSeparatorOwnProps, MenuSeparatorProps, MenuTriggerProps, NoPagination, OffsetParams, OffsetResponse, Option, PaddingProps, PagePagination, PageSizeOption, PaginationOptions, PasswordFieldOwnProps, PasswordFieldProps, PluginHeaderOwnProps, PluginHeaderProps, PopoverOwnProps, PopoverProps, ProviderBg, QueryOptions, RadioGroupOwnProps, RadioGroupProps, RadioOwnProps, RadioProps, Responsive, RowConfig, RowOwnProps, RowProps, RowRenderFn, SearchAutocompleteItemOwnProps, SearchAutocompleteItemProps, SearchAutocompleteOwnProps, SearchAutocompleteProps, SearchFieldOwnProps, SearchFieldProps, SearchState, SelectOwnProps, SelectProps, SkeletonOwnProps, SkeletonProps, SliderOwnProps, SliderProps, SortDescriptor, SortState, Space, SpaceProps, SubmenuTriggerProps, SwitchOwnProps, SwitchProps, TabListOwnProps, TabListProps, TabMatchStrategy, TabOwnProps, TabPanelOwnProps, TabPanelProps, TabProps, TableBodyOwnProps, TableBodyProps, TableHeaderOwnProps, TableHeaderProps, TableItem, TablePaginationOwnProps, TablePaginationProps, TablePaginationType, TableProps, TableRootOwnProps, TableRootProps, TableSelection, TabsOwnProps, TabsProps, TagGroupOwnProps, TagGroupProps, TagOwnProps, TagProps, TextColorStatus, TextColors, TextFieldOwnProps, TextFieldProps, TextOwnProps, TextProps, TextVariants, TextWeights, ToggleButtonGroupOwnProps, ToggleButtonGroupProps, ToggleButtonOwnProps, ToggleButtonProps, TooltipOwnProps, TooltipProps, UseAnalyticsFn, UseTableCompleteOptions, UseTableCursorOptions, UseTableOffsetOptions, UseTableOptions, UseTableResult, UtilityProps, VirtualizedProp, VisuallyHiddenOwnProps, VisuallyHiddenProps };
|
|
3978
|
+
export { Accordion, AccordionDefinition, AccordionGroup, AccordionGroupDefinition, AccordionPanel, AccordionPanelDefinition, AccordionTrigger, AccordionTriggerDefinition, Alert, AlertDefinition, Avatar, AvatarDefinition, BUIProvider, Badge, BadgeDefinition, BgProvider, Box, BoxDefinition, Button, ButtonDefinition, ButtonIcon, ButtonIconDefinition, ButtonLink, ButtonLinkDefinition, Card, CardBody, CardBodyDefinition, CardDefinition, CardFooter, CardFooterDefinition, CardHeader, CardHeaderDefinition, Cell, CellProfile, CellText, Checkbox, CheckboxDefinition, CheckboxGroup, CheckboxGroupDefinition, Column, Container, ContainerDefinition, DateRangePicker, DateRangePickerDefinition, Dialog, DialogBody, DialogBodyDefinition, DialogDefinition, DialogFooter, DialogFooterDefinition, DialogHeader, DialogHeaderDefinition, DialogTrigger, FieldLabel, FieldLabelDefinition, Flex, FlexDefinition, FullPage, FullPageDefinition, Grid, GridDefinition, GridItemDefinition, Header, HeaderDefinition, HeaderMetadataStatus, HeaderMetadataUsers, HeaderNavDefinition, HeaderNavGroupDefinition, HeaderNavItemDefinition, HeaderPage, HeaderPageDefinition, Link, LinkDefinition, List, ListDefinition, ListRow, ListRowDefinition, Menu, MenuAutocomplete, MenuAutocompleteListbox, MenuDefinition, MenuItem, MenuListBox, MenuListBoxItem, MenuSection, MenuSeparator, MenuTrigger, PasswordField, PasswordFieldDefinition, PluginHeader, PluginHeaderDefinition, Popover, PopoverDefinition, Radio, RadioDefinition, RadioGroup, RadioGroupDefinition, Row, SearchAutocomplete, SearchAutocompleteDefinition, SearchAutocompleteItem, SearchField, SearchFieldDefinition, Select, SelectDefinition, Skeleton, SkeletonDefinition, Slider, SliderDefinition, SubmenuTrigger, Switch, SwitchDefinition, Tab, TabList, TabPanel, Table, TableBody, TableBodySkeleton, TableDefinition, TableHeader, TablePagination, TablePaginationDefinition, TableRoot, Tabs, TabsDefinition, Tag, TagGroup, TagGroupDefinition, Text, TextDefinition, TextField, TextFieldDefinition, ToggleButton, ToggleButtonDefinition, ToggleButtonGroup, ToggleButtonGroupDefinition, Tooltip, TooltipDefinition, TooltipTrigger, VisuallyHidden, VisuallyHiddenDefinition, getNodeText, useAnalytics, useBgConsumer, useBgProvider, useBreakpoint, useTable };
|
|
3979
|
+
export type { AccordionGroupOwnProps, AccordionGroupProps, AccordionOwnProps, AccordionPanelOwnProps, AccordionPanelProps, AccordionProps, AccordionTriggerOwnProps, AccordionTriggerProps, AlertOwnProps, AlertProps, AlignItems, AnalyticsEventAttributes, AnalyticsTracker, AvatarOwnProps, AvatarProps, BUIProviderProps, BadgeOwnProps, BadgeProps, BgContextValue, BgProviderProps, Border, BorderRadius, BoxOwnProps, BoxProps, BoxUtilityProps, Breakpoint, ButtonIconOwnProps, ButtonIconProps, ButtonLinkOwnProps, ButtonLinkProps, ButtonOwnProps, ButtonProps, CardBaseProps, CardBodyOwnProps, CardBodyProps, CardButtonVariant, CardFooterOwnProps, CardFooterProps, CardHeaderOwnProps, CardHeaderProps, CardLinkVariant, CardOwnProps, CardProps, CardStaticVariant, CellOwnProps, CellProfileOwnProps, CellProfileProps, CellProps, CellTextOwnProps, CellTextProps, CheckboxGroupOwnProps, CheckboxGroupProps, CheckboxOwnProps, CheckboxProps, ColumnConfig, ColumnOwnProps, ColumnProps, Columns, CompletePaginationOptions, ContainerBg, ContainerOwnProps, ContainerProps, CursorParams, CursorResponse, DateRangePickerOwnProps, DateRangePickerProps, DialogBodyOwnProps, DialogBodyProps, DialogFooterOwnProps, DialogFooterProps, DialogHeaderOwnProps, DialogHeaderProps, DialogOwnProps, DialogProps, DialogTriggerProps, Display, FieldLabelOwnProps, FieldLabelProps, FilterState, FlexDirection, FlexItemProps, FlexOwnProps, FlexProps, FlexWrap, FullPageOwnProps, FullPageProps, GridItemOwnProps, GridItemProps, GridOwnProps, GridProps, HeaderBreadcrumb, HeaderMetadataItem, HeaderMetadataStatusProps, HeaderMetadataUser, HeaderNavTab, HeaderNavTabGroup, HeaderNavTabItem, HeaderOwnProps, HeaderPageBreadcrumb, HeaderPageOwnProps, HeaderPageProps, HeaderProps, HeaderTab, HeaderTag, JustifyContent, LinkOwnProps, LinkProps, ListOwnProps, ListProps, ListRowOwnProps, ListRowProps, MarginProps, MenuAutocompleteListBoxOwnProps, MenuAutocompleteListBoxProps, MenuAutocompleteOwnProps, MenuAutocompleteProps, MenuItemOwnProps, MenuItemProps, MenuListBoxItemOwnProps, MenuListBoxItemProps, MenuListBoxOwnProps, MenuListBoxProps, MenuOwnProps, MenuPopoverOwnProps, MenuProps, MenuSectionOwnProps, MenuSectionProps, MenuSeparatorOwnProps, MenuSeparatorProps, MenuTriggerProps, NoPagination, OffsetParams, OffsetResponse, Option, OptionSection, PaddingProps, PagePagination, PageSizeOption, PaginationOptions, PasswordFieldOwnProps, PasswordFieldProps, PluginHeaderOwnProps, PluginHeaderProps, PopoverOwnProps, PopoverProps, ProviderBg, QueryOptions, RadioGroupOwnProps, RadioGroupProps, RadioOwnProps, RadioProps, Responsive, RowConfig, RowOwnProps, RowProps, RowRenderFn, SearchAutocompleteItemOwnProps, SearchAutocompleteItemProps, SearchAutocompleteOwnProps, SearchAutocompleteProps, SearchFieldOwnProps, SearchFieldProps, SearchState, SelectOwnProps, SelectProps, SkeletonOwnProps, SkeletonProps, SliderOwnProps, SliderProps, SortDescriptor, SortState, Space, SpaceProps, SubmenuTriggerProps, SwitchOwnProps, SwitchProps, TabListOwnProps, TabListProps, TabMatchStrategy, TabOwnProps, TabPanelOwnProps, TabPanelProps, TabProps, TableBodyOwnProps, TableBodyProps, TableHeaderOwnProps, TableHeaderProps, TableItem, TablePaginationOwnProps, TablePaginationProps, TablePaginationType, TableProps, TableRootOwnProps, TableRootProps, TableSelection, TabsOwnProps, TabsProps, TagGroupOwnProps, TagGroupProps, TagOwnProps, TagProps, TextColorStatus, TextColors, TextFieldOwnProps, TextFieldProps, TextOwnProps, TextProps, TextVariants, TextWeights, ToggleButtonGroupOwnProps, ToggleButtonGroupProps, ToggleButtonOwnProps, ToggleButtonProps, TooltipOwnProps, TooltipProps, UseAnalyticsFn, UseTableCompleteOptions, UseTableCursorOptions, UseTableOffsetOptions, UseTableOptions, UseTableResult, UtilityProps, VirtualizedProp, VisuallyHiddenOwnProps, VisuallyHiddenProps };
|
package/dist/index.esm.js
CHANGED
|
@@ -31,6 +31,8 @@ export { PluginHeaderDefinition } from './components/PluginHeader/definition.esm
|
|
|
31
31
|
export { Header, HeaderPage } from './components/Header/Header.esm.js';
|
|
32
32
|
export { HeaderDefinition, HeaderPageDefinition } from './components/Header/definition.esm.js';
|
|
33
33
|
export { HeaderNavDefinition, HeaderNavGroupDefinition, HeaderNavItemDefinition } from './components/Header/HeaderNavDefinition.esm.js';
|
|
34
|
+
export { HeaderMetadataUsers } from './components/Header/HeaderMetadataUsers.esm.js';
|
|
35
|
+
export { HeaderMetadataStatus } from './components/Header/HeaderMetadataStatus.esm.js';
|
|
34
36
|
export { ButtonIcon } from './components/ButtonIcon/ButtonIcon.esm.js';
|
|
35
37
|
export { ButtonIconDefinition } from './components/ButtonIcon/definition.esm.js';
|
|
36
38
|
export { ButtonLink } from './components/ButtonLink/ButtonLink.esm.js';
|
package/dist/index.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { useMemo } from 'react';
|
|
3
3
|
import { RouterProvider } from 'react-aria-components';
|
|
4
|
-
import { useInRouterContext, useNavigate
|
|
4
|
+
import { useInRouterContext, useNavigate } from 'react-router-dom';
|
|
5
5
|
import { createVersionedValueMap } from '@backstage/version-bridge';
|
|
6
6
|
import { BUIContext } from '../analytics/useAnalytics.esm.js';
|
|
7
|
+
import { useResolvedHref } from '../hooks/useResolvedHref.esm.js';
|
|
7
8
|
|
|
8
9
|
function BUIProvider(props) {
|
|
9
10
|
const { useAnalytics, children } = props;
|
|
@@ -21,7 +22,7 @@ function BUIProvider(props) {
|
|
|
21
22
|
}
|
|
22
23
|
function RoutedContent({ children }) {
|
|
23
24
|
const navigate = useNavigate();
|
|
24
|
-
return /* @__PURE__ */ jsx(RouterProvider, { navigate, useHref, children });
|
|
25
|
+
return /* @__PURE__ */ jsx(RouterProvider, { navigate, useHref: useResolvedHref, children });
|
|
25
26
|
}
|
|
26
27
|
|
|
27
28
|
export { BUIProvider };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BUIProvider.esm.js","sources":["../../src/provider/BUIProvider.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useMemo, type ReactNode } from 'react';\nimport { RouterProvider } from 'react-aria-components';\nimport { useInRouterContext, useNavigate
|
|
1
|
+
{"version":3,"file":"BUIProvider.esm.js","sources":["../../src/provider/BUIProvider.tsx"],"sourcesContent":["/*\n * Copyright 2026 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useMemo, type ReactNode } from 'react';\nimport { RouterProvider } from 'react-aria-components';\nimport { useInRouterContext, useNavigate } from 'react-router-dom';\nimport { createVersionedValueMap } from '@backstage/version-bridge';\nimport { BUIContext } from '../analytics/useAnalytics';\nimport { useResolvedHref } from '../hooks/useResolvedHref';\nimport type { UseAnalyticsFn } from '../analytics/types';\n\n/** @public */\nexport type BUIProviderProps = {\n useAnalytics?: UseAnalyticsFn;\n children: ReactNode;\n};\n\n/**\n * Provides integration capabilities to all descendant BUI components.\n *\n * @example\n * ```tsx\n * import { BUIProvider } from '@backstage/ui';\n * import { useAnalytics as useBackstageAnalytics } from '@backstage/core-plugin-api';\n *\n * function App() {\n * return (\n * <BUIProvider useAnalytics={useBackstageAnalytics}>\n * <AppContent />\n * </BUIProvider>\n * );\n * }\n * ```\n *\n * @public\n */\nexport function BUIProvider(props: BUIProviderProps) {\n const { useAnalytics, children } = props;\n const value = useMemo(\n () =>\n createVersionedValueMap({\n 1: { useAnalytics },\n }),\n [useAnalytics],\n );\n\n const content = (\n <BUIContext.Provider value={value}>{children}</BUIContext.Provider>\n );\n\n if (useInRouterContext()) {\n return <RoutedContent>{content}</RoutedContent>;\n }\n\n return content;\n}\n\nfunction RoutedContent({ children }: { children: ReactNode }) {\n const navigate = useNavigate();\n return (\n <RouterProvider navigate={navigate} useHref={useResolvedHref}>\n {children}\n </RouterProvider>\n );\n}\n"],"names":[],"mappings":";;;;;;;;AAiDO,SAAS,YAAY,KAAA,EAAyB;AACnD,EAAA,MAAM,EAAE,YAAA,EAAc,QAAA,EAAS,GAAI,KAAA;AACnC,EAAA,MAAM,KAAA,GAAQ,OAAA;AAAA,IACZ,MACE,uBAAA,CAAwB;AAAA,MACtB,CAAA,EAAG,EAAE,YAAA;AAAa,KACnB,CAAA;AAAA,IACH,CAAC,YAAY;AAAA,GACf;AAEA,EAAA,MAAM,0BACJ,GAAA,CAAC,UAAA,CAAW,QAAA,EAAX,EAAoB,OAAe,QAAA,EAAS,CAAA;AAG/C,EAAA,IAAI,oBAAmB,EAAG;AACxB,IAAA,uBAAO,GAAA,CAAC,iBAAe,QAAA,EAAA,OAAA,EAAQ,CAAA;AAAA,EACjC;AAEA,EAAA,OAAO,OAAA;AACT;AAEA,SAAS,aAAA,CAAc,EAAE,QAAA,EAAS,EAA4B;AAC5D,EAAA,MAAM,WAAW,WAAA,EAAY;AAC7B,EAAA,uBACE,GAAA,CAAC,cAAA,EAAA,EAAe,QAAA,EAAoB,OAAA,EAAS,iBAC1C,QAAA,EACH,CAAA;AAEJ;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/ui",
|
|
3
|
-
"version": "0.15.0-next.
|
|
3
|
+
"version": "0.15.0-next.1",
|
|
4
4
|
"backstage": {
|
|
5
5
|
"role": "web-library"
|
|
6
6
|
},
|
|
@@ -51,18 +51,22 @@
|
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
53
|
"@backstage/version-bridge": "1.0.12",
|
|
54
|
+
"@braintree/sanitize-url": "^7.1.2",
|
|
54
55
|
"@internationalized/date": "^3.12.0",
|
|
55
|
-
"@remixicon/react": "
|
|
56
|
+
"@remixicon/react": ">=4.6.0 <4.9.0",
|
|
56
57
|
"@tanstack/react-table": "^8.21.3",
|
|
57
58
|
"clsx": "^2.1.1",
|
|
59
|
+
"marked": "^15.0.12",
|
|
58
60
|
"react-aria": "~3.48.0",
|
|
59
61
|
"react-aria-components": "~1.17.0",
|
|
60
62
|
"react-stately": "~3.46.0",
|
|
61
63
|
"use-sync-external-store": "^1.4.0"
|
|
62
64
|
},
|
|
63
65
|
"devDependencies": {
|
|
64
|
-
"@backstage/cli": "0.36.2-next.
|
|
66
|
+
"@backstage/cli": "0.36.2-next.1",
|
|
65
67
|
"@storybook/react-vite": "^10.3.3",
|
|
68
|
+
"@testing-library/jest-dom": "^6.0.0",
|
|
69
|
+
"@testing-library/react": "^16.0.0",
|
|
66
70
|
"@types/react": "^18.0.0",
|
|
67
71
|
"@types/react-dom": "^18.0.0",
|
|
68
72
|
"@types/use-sync-external-store": "^1.0.0",
|