committed by
Eric Peterson
parent
a7a0e2520a
commit
b3d64b448e
@@ -48,7 +48,7 @@ export const HighlightedSearchResultText: ({
|
||||
postTag,
|
||||
}: HighlightedSearchResultTextProps) => JSX.Element;
|
||||
|
||||
// @public (undocumented)
|
||||
// @public
|
||||
export type HighlightedSearchResultTextProps = {
|
||||
text: string;
|
||||
preTag: string;
|
||||
|
||||
+2
@@ -25,6 +25,8 @@ const useStyles = makeStyles(
|
||||
);
|
||||
|
||||
/**
|
||||
* Props for {@link HighlightedSearchResultText}.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export type HighlightedSearchResultTextProps = {
|
||||
|
||||
@@ -16,16 +16,17 @@ import { SearchAutocompleteFilterProps as SearchAutocompleteFilterProps_2 } from
|
||||
import { SearchFilterComponentProps as SearchFilterComponentProps_2 } from '@backstage/plugin-search-react';
|
||||
import { SearchResultProps } from '@backstage/plugin-search-react';
|
||||
|
||||
// Warning: (ae-missing-release-tag) "DefaultResultListItem" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public @deprecated (undocumented)
|
||||
export const DefaultResultListItem: (
|
||||
props: DefaultResultListItemProps,
|
||||
) => JSX.Element;
|
||||
|
||||
// Warning: (ae-forgotten-export) The symbol "FiltersProps" needs to be exported by the entry point index.d.ts
|
||||
// Warning: (ae-missing-release-tag) "Filters" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export type FilterOptions = {
|
||||
kind: Array<string>;
|
||||
lifecycle: Array<string>;
|
||||
};
|
||||
|
||||
// @public (undocumented)
|
||||
export const Filters: ({
|
||||
filters,
|
||||
@@ -35,25 +36,33 @@ export const Filters: ({
|
||||
updateChecked,
|
||||
}: FiltersProps) => JSX.Element;
|
||||
|
||||
// Warning: (ae-forgotten-export) The symbol "FiltersButtonProps" needs to be exported by the entry point index.d.ts
|
||||
// Warning: (ae-missing-release-tag) "FiltersButton" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const FiltersButton: ({
|
||||
numberOfSelectedFilters,
|
||||
handleToggleFilters,
|
||||
}: FiltersButtonProps) => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "FiltersState" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public
|
||||
export type FiltersButtonProps = {
|
||||
numberOfSelectedFilters: number;
|
||||
handleToggleFilters: () => void;
|
||||
};
|
||||
|
||||
// @public
|
||||
export type FiltersProps = {
|
||||
filters: FiltersState;
|
||||
filterOptions: FilterOptions;
|
||||
resetFilters: () => void;
|
||||
updateSelected: (filter: string) => void;
|
||||
updateChecked: (filter: string) => void;
|
||||
};
|
||||
|
||||
// @public (undocumented)
|
||||
export type FiltersState = {
|
||||
selected: string;
|
||||
checked: Array<string>;
|
||||
};
|
||||
|
||||
// Warning: (ae-missing-release-tag) "HomePageSearchBar" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const HomePageSearchBar: ({
|
||||
...props
|
||||
@@ -64,8 +73,6 @@ export type HomePageSearchBarProps = Partial<
|
||||
Omit<SearchBarBaseProps, 'onChange' | 'onSubmit'>
|
||||
>;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchPage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const Router: () => JSX.Element;
|
||||
|
||||
@@ -76,10 +83,10 @@ export type SearchAutocompleteFilterProps = SearchFilterComponentProps_2 & {
|
||||
multiple?: boolean;
|
||||
};
|
||||
|
||||
// @public @deprecated (undocumented)
|
||||
// @public @deprecated
|
||||
export const SearchBar: ({ onChange, ...props }: SearchBarProps) => JSX.Element;
|
||||
|
||||
// @public @deprecated (undocumented)
|
||||
// @public @deprecated
|
||||
export const SearchBarBase: ({
|
||||
onChange,
|
||||
onKeyDown,
|
||||
@@ -93,7 +100,7 @@ export const SearchBarBase: ({
|
||||
...props
|
||||
}: SearchBarBaseProps) => JSX.Element;
|
||||
|
||||
// @public @deprecated (undocumented)
|
||||
// @public @deprecated
|
||||
export type SearchBarBaseProps = Omit<InputBaseProps, 'onChange'> & {
|
||||
debounceTime?: number;
|
||||
clearButton?: boolean;
|
||||
@@ -102,11 +109,9 @@ export type SearchBarBaseProps = Omit<InputBaseProps, 'onChange'> & {
|
||||
onChange: (value: string) => void;
|
||||
};
|
||||
|
||||
// @public @deprecated (undocumented)
|
||||
// @public @deprecated
|
||||
export type SearchBarProps = Partial<SearchBarBaseProps>;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchFilter" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public @deprecated (undocumented)
|
||||
export const SearchFilter: {
|
||||
({ component: Element, ...props }: SearchFilterWrapperProps): JSX.Element;
|
||||
@@ -137,8 +142,6 @@ export type SearchFilterWrapperProps = SearchFilterComponentProps & {
|
||||
debug?: boolean;
|
||||
};
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchModal" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const SearchModal: ({
|
||||
open,
|
||||
@@ -152,8 +155,6 @@ export interface SearchModalChildrenProps {
|
||||
toggleModal: () => void;
|
||||
}
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchModalProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export interface SearchModalProps {
|
||||
children?: (props: SearchModalChildrenProps) => JSX.Element;
|
||||
@@ -184,13 +185,9 @@ export type SearchModalValue = {
|
||||
setOpen: (open: boolean) => void;
|
||||
};
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchPage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const SearchPage: () => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "searchPlugin" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
const searchPlugin: BackstagePlugin<
|
||||
{
|
||||
@@ -201,18 +198,12 @@ const searchPlugin: BackstagePlugin<
|
||||
export { searchPlugin as plugin };
|
||||
export { searchPlugin };
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchResult" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public @deprecated (undocumented)
|
||||
export const SearchResult: (props: SearchResultProps) => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchResultPager" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public @deprecated (undocumented)
|
||||
export const SearchResultPager: () => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SearchType" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const SearchType: {
|
||||
(props: SearchTypeProps): JSX.Element;
|
||||
@@ -231,7 +222,7 @@ export type SearchTypeAccordionProps = {
|
||||
defaultValue?: string;
|
||||
};
|
||||
|
||||
// @public (undocumented)
|
||||
// @public
|
||||
export type SearchTypeProps = {
|
||||
className?: string;
|
||||
name: string;
|
||||
@@ -248,29 +239,21 @@ export type SearchTypeTabsProps = {
|
||||
defaultValue?: string;
|
||||
};
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SidebarSearch" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const SidebarSearch: (props: SidebarSearchProps) => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SidebarSearchModal" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const SidebarSearchModal: (
|
||||
props: SidebarSearchModalProps,
|
||||
) => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SidebarSearchModalProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
// @public
|
||||
export type SidebarSearchModalProps = {
|
||||
icon?: IconComponent;
|
||||
children?: (props: SearchModalChildrenProps) => JSX.Element;
|
||||
};
|
||||
|
||||
// Warning: (ae-missing-release-tag) "SidebarSearchProps" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
// @public
|
||||
export type SidebarSearchProps = {
|
||||
icon?: IconComponent;
|
||||
};
|
||||
|
||||
@@ -44,17 +44,28 @@ const useStyles = makeStyles(theme => ({
|
||||
},
|
||||
}));
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type FiltersState = {
|
||||
selected: string;
|
||||
checked: Array<string>;
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export type FilterOptions = {
|
||||
kind: Array<string>;
|
||||
lifecycle: Array<string>;
|
||||
};
|
||||
|
||||
type FiltersProps = {
|
||||
/**
|
||||
* Props for {@link Filters}.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export type FiltersProps = {
|
||||
filters: FiltersState;
|
||||
filterOptions: FilterOptions;
|
||||
resetFilters: () => void;
|
||||
@@ -62,6 +73,9 @@ type FiltersProps = {
|
||||
updateChecked: (filter: string) => void;
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const Filters = ({
|
||||
filters,
|
||||
filterOptions,
|
||||
|
||||
@@ -28,11 +28,19 @@ const useStyles = makeStyles(theme => ({
|
||||
},
|
||||
}));
|
||||
|
||||
type FiltersButtonProps = {
|
||||
/**
|
||||
* Props for {@link FiltersButton}.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export type FiltersButtonProps = {
|
||||
numberOfSelectedFilters: number;
|
||||
handleToggleFilters: () => void;
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const FiltersButton = ({
|
||||
numberOfSelectedFilters,
|
||||
handleToggleFilters,
|
||||
|
||||
@@ -15,5 +15,6 @@
|
||||
*/
|
||||
|
||||
export { FiltersButton } from './FiltersButton';
|
||||
export type { FiltersButtonProps } from './FiltersButton';
|
||||
export { Filters } from './Filters';
|
||||
export type { FiltersState } from './Filters';
|
||||
export type { FilterOptions, FiltersProps, FiltersState } from './Filters';
|
||||
|
||||
@@ -37,9 +37,7 @@ export type HomePageSearchBarProps = Partial<
|
||||
>;
|
||||
|
||||
/**
|
||||
* The search bar created specifically for the composable home page
|
||||
*
|
||||
* @public
|
||||
* The search bar created specifically for the composable home page.
|
||||
*/
|
||||
export const HomePageSearchBar = ({ ...props }: HomePageSearchBarProps) => {
|
||||
const classes = useStyles(props);
|
||||
|
||||
@@ -40,11 +40,10 @@ import {
|
||||
} from '@backstage/plugin-search-react';
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* Props for {@link SearchBarBase}.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export type SearchBarBaseProps = Omit<InputBaseProps, 'onChange'> & {
|
||||
debounceTime?: number;
|
||||
@@ -55,13 +54,12 @@ export type SearchBarBaseProps = Omit<InputBaseProps, 'onChange'> & {
|
||||
};
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* All search boxes exported by the search plugin are based on the <SearchBarBase />,
|
||||
* and this one is based on the <InputBase /> component from Material UI.
|
||||
* Recommended if you don't use Search Provider or Search Context.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export const SearchBarBase = ({
|
||||
onChange,
|
||||
@@ -153,20 +151,18 @@ export const SearchBarBase = ({
|
||||
};
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* Props for {@link SearchBar}.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export type SearchBarProps = Partial<SearchBarBaseProps>;
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* Recommended search bar when you use the Search Provider or Search Context.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export const SearchBar = ({ onChange, ...props }: SearchBarProps) => {
|
||||
const { term, setTerm } = useSearch();
|
||||
|
||||
@@ -29,9 +29,8 @@ import {
|
||||
} from '@backstage/plugin-search-react';
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export type SearchAutocompleteFilterProps = SearchFilterComponentProps & {
|
||||
filterSelectedOptions?: boolean;
|
||||
@@ -41,7 +40,6 @@ export type SearchAutocompleteFilterProps = SearchFilterComponentProps & {
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
*/
|
||||
export const AutocompleteFilter = (props: SearchAutocompleteFilterProps) => {
|
||||
const {
|
||||
|
||||
@@ -24,9 +24,8 @@ import {
|
||||
} from '@backstage/plugin-search-react';
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export type SearchFilterComponentProps = {
|
||||
className?: string;
|
||||
@@ -48,9 +47,8 @@ export type SearchFilterComponentProps = {
|
||||
};
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export type SearchFilterWrapperProps = SearchFilterComponentProps & {
|
||||
component: (props: SearchFilterComponentProps) => ReactElement;
|
||||
@@ -58,6 +56,7 @@ export type SearchFilterWrapperProps = SearchFilterComponentProps & {
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
const SearchFilter = ({
|
||||
@@ -82,12 +81,12 @@ SearchFilter.Select = (
|
||||
) => <SearchFilter {...props} component={SelectFilter} />;
|
||||
|
||||
/**
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*
|
||||
* A control surface for a given filter field name, rendered as an autocomplete
|
||||
* textfield. A hard-coded list of values may be provided, or an async function
|
||||
* which returns values may be provided instead.
|
||||
*
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
SearchFilter.Autocomplete = (props: SearchAutocompleteFilterProps) => (
|
||||
<SearchFilter {...props} component={AutocompleteFilter} />
|
||||
|
||||
@@ -50,6 +50,9 @@ export interface SearchModalChildrenProps {
|
||||
toggleModal: () => void;
|
||||
}
|
||||
|
||||
/**
|
||||
* @public
|
||||
**/
|
||||
export interface SearchModalProps {
|
||||
/**
|
||||
* If true, it renders the modal.
|
||||
@@ -167,6 +170,9 @@ export const Modal = ({ toggleModal }: SearchModalProps) => {
|
||||
);
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const SearchModal = ({
|
||||
open = true,
|
||||
hidden,
|
||||
|
||||
@@ -87,6 +87,9 @@ export const UrlUpdater = () => {
|
||||
return null;
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const SearchPage = () => {
|
||||
const outlet = useOutlet();
|
||||
|
||||
|
||||
@@ -30,6 +30,7 @@ const useStyles = makeStyles(theme => ({
|
||||
}));
|
||||
|
||||
/**
|
||||
* @public
|
||||
* @deprecated Moved to `@backstage/plugin-search-react`.
|
||||
*/
|
||||
export const SearchResultPager = () => {
|
||||
|
||||
@@ -47,6 +47,8 @@ const useStyles = makeStyles(theme => ({
|
||||
}));
|
||||
|
||||
/**
|
||||
* Props for {@link SearchType}.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export type SearchTypeProps = {
|
||||
@@ -56,6 +58,9 @@ export type SearchTypeProps = {
|
||||
defaultValue?: string[] | string | null;
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
const SearchType = (props: SearchTypeProps) => {
|
||||
const { className, defaultValue, name, values = [] } = props;
|
||||
const classes = useStyles();
|
||||
|
||||
@@ -21,10 +21,18 @@ import { rootRouteRef } from '../../plugin';
|
||||
import { useRouteRef, IconComponent } from '@backstage/core-plugin-api';
|
||||
import { SidebarSearchField, useContent } from '@backstage/core-components';
|
||||
|
||||
/**
|
||||
* Props for {@link SidebarSearch}.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export type SidebarSearchProps = {
|
||||
icon?: IconComponent;
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const SidebarSearch = (props: SidebarSearchProps) => {
|
||||
const searchRoute = useRouteRef(rootRouteRef);
|
||||
const { focusContent } = useContent();
|
||||
|
||||
@@ -24,6 +24,11 @@ import {
|
||||
useSearchModal,
|
||||
} from '../SearchModal';
|
||||
|
||||
/**
|
||||
* Props for {@link SidebarSearchModal}.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export type SidebarSearchModalProps = {
|
||||
icon?: IconComponent;
|
||||
children?: (props: SearchModalChildrenProps) => JSX.Element;
|
||||
|
||||
@@ -21,7 +21,12 @@
|
||||
*/
|
||||
|
||||
export { Filters, FiltersButton } from './components/Filters';
|
||||
export type { FiltersState } from './components/Filters';
|
||||
export type {
|
||||
FilterOptions,
|
||||
FiltersState,
|
||||
FiltersProps,
|
||||
FiltersButtonProps,
|
||||
} from './components/Filters';
|
||||
export type { HomePageSearchBarProps } from './components/HomePageComponent';
|
||||
export { SearchBar, SearchBarBase } from './components/SearchBar';
|
||||
export type {
|
||||
|
||||
@@ -34,6 +34,9 @@ export const rootRouteRef = createRouteRef({
|
||||
id: 'search',
|
||||
});
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const searchPlugin = createPlugin({
|
||||
id: 'search',
|
||||
apis: [
|
||||
@@ -50,6 +53,9 @@ export const searchPlugin = createPlugin({
|
||||
},
|
||||
});
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const SearchPage = searchPlugin.provide(
|
||||
createRoutableExtension({
|
||||
name: 'SearchPage',
|
||||
@@ -59,10 +65,14 @@ export const SearchPage = searchPlugin.provide(
|
||||
);
|
||||
|
||||
/**
|
||||
* @public
|
||||
* @deprecated Import from `@backstage/plugin-search-react` instead.
|
||||
*/
|
||||
export const SearchResult = RealSearchResult;
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const SidebarSearchModal = searchPlugin.provide(
|
||||
createComponentExtension({
|
||||
name: 'SidebarSearchModal',
|
||||
@@ -76,10 +86,14 @@ export const SidebarSearchModal = searchPlugin.provide(
|
||||
);
|
||||
|
||||
/**
|
||||
* @public
|
||||
* @deprecated Import from `@backstage/plugin-search-react` instead.
|
||||
*/
|
||||
export const DefaultResultListItem = RealDefaultResultListItem;
|
||||
|
||||
/**
|
||||
* @public
|
||||
*/
|
||||
export const HomePageSearchBar = searchPlugin.provide(
|
||||
createComponentExtension({
|
||||
name: 'HomePageSearchBar',
|
||||
|
||||
Reference in New Issue
Block a user