@@ -12,8 +12,6 @@ import { ExternalRouteRef } from '@backstage/core-plugin-api';
|
||||
import { RouteRef } from '@backstage/core-plugin-api';
|
||||
import { TabProps } from '@material-ui/core';
|
||||
|
||||
// Warning: (ae-missing-release-tag) "catalogEntityRouteRef" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public @deprecated (undocumented)
|
||||
export const catalogEntityRouteRef: ExternalRouteRef<
|
||||
{
|
||||
@@ -24,34 +22,30 @@ export const catalogEntityRouteRef: ExternalRouteRef<
|
||||
true
|
||||
>;
|
||||
|
||||
// Warning: (ae-forgotten-export) The symbol "DomainCardProps" needs to be exported by the entry point index.d.ts
|
||||
// Warning: (ae-missing-release-tag) "DomainCard" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const DomainCard: ({ entity }: DomainCardProps) => JSX.Element;
|
||||
export const DomainCard: (props: { entity: DomainEntity }) => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "DomainExplorerContent" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const DomainExplorerContent: (props: {
|
||||
title?: string | undefined;
|
||||
}) => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "ExploreLayout" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public
|
||||
export const ExploreLayout: {
|
||||
({ title, subtitle, children }: ExploreLayoutProps): JSX.Element;
|
||||
(props: ExploreLayoutProps): JSX.Element;
|
||||
Route: (props: SubRoute) => null;
|
||||
};
|
||||
|
||||
// Warning: (ae-missing-release-tag) "ExplorePage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export type ExploreLayoutProps = {
|
||||
title?: string;
|
||||
subtitle?: string;
|
||||
children?: default_2.ReactNode;
|
||||
};
|
||||
|
||||
// @public (undocumented)
|
||||
export const ExplorePage: () => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "explorePlugin" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
const explorePlugin: BackstagePlugin<
|
||||
{
|
||||
@@ -72,27 +66,29 @@ const explorePlugin: BackstagePlugin<
|
||||
export { explorePlugin };
|
||||
export { explorePlugin as plugin };
|
||||
|
||||
// Warning: (ae-missing-release-tag) "exploreRouteRef" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const exploreRouteRef: RouteRef<undefined>;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "GroupsExplorerContent" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const GroupsExplorerContent: (props: {
|
||||
title?: string | undefined;
|
||||
}) => JSX.Element;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "ToolExplorerContent" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export type SubRoute = {
|
||||
path: string;
|
||||
title: string;
|
||||
children: JSX.Element;
|
||||
tabProps?: TabProps<
|
||||
default_2.ElementType,
|
||||
{
|
||||
component?: default_2.ElementType;
|
||||
}
|
||||
>;
|
||||
};
|
||||
|
||||
// @public (undocumented)
|
||||
export const ToolExplorerContent: (props: {
|
||||
title?: string | undefined;
|
||||
}) => JSX.Element;
|
||||
|
||||
// Warnings were encountered during analysis:
|
||||
//
|
||||
// src/components/ExploreLayout/ExploreLayout.d.ts:29:5 - (ae-forgotten-export) The symbol "ExploreLayoutProps" needs to be exported by the entry point index.d.ts
|
||||
// src/components/ExploreLayout/ExploreLayout.d.ts:30:5 - (ae-forgotten-export) The symbol "SubRoute" needs to be exported by the entry point index.d.ts
|
||||
```
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { DomainEntity, RELATION_OWNED_BY } from '@backstage/catalog-model';
|
||||
import {
|
||||
EntityRefLinks,
|
||||
@@ -33,13 +34,11 @@ import React from 'react';
|
||||
import { Button, ItemCardHeader } from '@backstage/core-components';
|
||||
import { useRouteRef } from '@backstage/core-plugin-api';
|
||||
|
||||
type DomainCardProps = {
|
||||
entity: DomainEntity;
|
||||
};
|
||||
/** @public */
|
||||
export const DomainCard = (props: { entity: DomainEntity }) => {
|
||||
const { entity } = props;
|
||||
|
||||
export const DomainCard = ({ entity }: DomainCardProps) => {
|
||||
const catalogEntityRoute = useRouteRef(entityRouteRef);
|
||||
|
||||
const ownedByRelations = getEntityRelations(entity, RELATION_OWNED_BY);
|
||||
const url = catalogEntityRoute(entityRouteParams(entity));
|
||||
|
||||
|
||||
@@ -13,4 +13,5 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export { DomainCard } from './DomainCard';
|
||||
|
||||
@@ -24,8 +24,8 @@ import { default as React } from 'react';
|
||||
|
||||
// TODO: This layout could be a shared based component if it was possible to create custom TabbedLayouts
|
||||
// A generalized version of createSubRoutesFromChildren, etc. would be required
|
||||
|
||||
type SubRoute = {
|
||||
/** @public */
|
||||
export type SubRoute = {
|
||||
path: string;
|
||||
title: string;
|
||||
children: JSX.Element;
|
||||
@@ -40,7 +40,8 @@ attachComponentData(Route, dataKey, true);
|
||||
// This causes all mount points that are discovered within this route to use the path of the route itself
|
||||
attachComponentData(Route, 'core.gatherMountPoints', true);
|
||||
|
||||
type ExploreLayoutProps = {
|
||||
/** @public */
|
||||
export type ExploreLayoutProps = {
|
||||
title?: string;
|
||||
subtitle?: string;
|
||||
children?: React.ReactNode;
|
||||
@@ -57,12 +58,12 @@ type ExploreLayoutProps = {
|
||||
* </ExploreLayout.Route>
|
||||
* </ExploreLayout>
|
||||
* ```
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export const ExploreLayout = ({
|
||||
title,
|
||||
subtitle,
|
||||
children,
|
||||
}: ExploreLayoutProps) => {
|
||||
export const ExploreLayout = (props: ExploreLayoutProps) => {
|
||||
const { title, subtitle, children } = props;
|
||||
|
||||
const routes = useElementFilter(children, elements =>
|
||||
elements
|
||||
.selectByComponentData({
|
||||
|
||||
@@ -14,4 +14,5 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export type { ExploreLayoutProps, SubRoute } from './ExploreLayout';
|
||||
export { ExploreLayout } from './ExploreLayout';
|
||||
|
||||
@@ -14,5 +14,5 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export { DomainCard } from './DomainCard';
|
||||
export { ExploreLayout } from './ExploreLayout';
|
||||
export * from './DomainCard';
|
||||
export * from './ExploreLayout';
|
||||
|
||||
@@ -21,6 +21,7 @@ import {
|
||||
createRoutableExtension,
|
||||
} from '@backstage/core-plugin-api';
|
||||
|
||||
/** @public */
|
||||
export const ExplorePage = explorePlugin.provide(
|
||||
createRoutableExtension({
|
||||
name: 'ExplorePage',
|
||||
@@ -30,6 +31,7 @@ export const ExplorePage = explorePlugin.provide(
|
||||
}),
|
||||
);
|
||||
|
||||
/** @public */
|
||||
export const DomainExplorerContent = explorePlugin.provide(
|
||||
createComponentExtension({
|
||||
name: 'DomainExplorerContent',
|
||||
@@ -42,6 +44,7 @@ export const DomainExplorerContent = explorePlugin.provide(
|
||||
}),
|
||||
);
|
||||
|
||||
/** @public */
|
||||
export const GroupsExplorerContent = explorePlugin.provide(
|
||||
createComponentExtension({
|
||||
name: 'GroupsExplorerContent',
|
||||
@@ -54,6 +57,7 @@ export const GroupsExplorerContent = explorePlugin.provide(
|
||||
}),
|
||||
);
|
||||
|
||||
/** @public */
|
||||
export const ToolExplorerContent = explorePlugin.provide(
|
||||
createComponentExtension({
|
||||
name: 'ToolExplorerContent',
|
||||
|
||||
@@ -19,6 +19,7 @@ import { catalogEntityRouteRef, exploreRouteRef } from './routes';
|
||||
import { exampleTools } from './util/examples';
|
||||
import { createApiFactory, createPlugin } from '@backstage/core-plugin-api';
|
||||
|
||||
/** @public */
|
||||
export const explorePlugin = createPlugin({
|
||||
id: 'explore',
|
||||
apis: [
|
||||
|
||||
@@ -19,12 +19,14 @@ import {
|
||||
createRouteRef,
|
||||
} from '@backstage/core-plugin-api';
|
||||
|
||||
/** @public */
|
||||
export const exploreRouteRef = createRouteRef({
|
||||
id: 'explore',
|
||||
});
|
||||
|
||||
/**
|
||||
* @deprecated This route is no longer used and can be removed
|
||||
* @public
|
||||
*/
|
||||
export const catalogEntityRouteRef = createExternalRouteRef({
|
||||
id: 'catalog-entity',
|
||||
|
||||
@@ -210,7 +210,6 @@ const ALLOW_WARNINGS = [
|
||||
'plugins/circleci',
|
||||
'plugins/cost-insights',
|
||||
'plugins/dynatrace',
|
||||
'plugins/explore',
|
||||
'plugins/explore-react',
|
||||
'plugins/git-release-manager',
|
||||
'plugins/github-actions',
|
||||
|
||||
Reference in New Issue
Block a user