just some more api report cleanup

Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
Fredrik Adelöw
2022-04-01 14:59:50 +02:00
parent 947ce9d60d
commit 99063c39ae
40 changed files with 187 additions and 287 deletions
+1 -23
View File
@@ -12,9 +12,7 @@ import { IconComponent } from '@backstage/core-plugin-api';
import { OAuthApi } from '@backstage/core-plugin-api';
import { RouteRef } from '@backstage/core-plugin-api';
// Warning: (ae-missing-release-tag) "EndpointConfig" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
// @public
export type EndpointConfig = {
id: string;
title: string;
@@ -25,8 +23,6 @@ export type EndpointConfig = {
};
};
// Warning: (ae-missing-release-tag) "GithubEndpointConfig" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export type GithubEndpointConfig = {
id: string;
@@ -36,42 +32,28 @@ export type GithubEndpointConfig = {
githubAuthApi: OAuthApi;
};
// Warning: (ae-missing-release-tag) "GraphiQLIcon" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export const GraphiQLIcon: IconComponent;
// Warning: (ae-missing-release-tag) "GraphiQLPage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export const GraphiQLPage: () => JSX.Element;
// Warning: (ae-missing-release-tag) "graphiqlPlugin" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
const graphiqlPlugin: BackstagePlugin<{}, {}>;
export { graphiqlPlugin };
export { graphiqlPlugin as plugin };
// Warning: (ae-missing-release-tag) "graphiQLRouteRef" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export const graphiQLRouteRef: RouteRef<undefined>;
// Warning: (ae-missing-release-tag) "GraphQLBrowseApi" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export type GraphQLBrowseApi = {
getEndpoints(): Promise<GraphQLEndpoint[]>;
};
// Warning: (ae-missing-release-tag) "graphQlBrowseApiRef" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export const graphQlBrowseApiRef: ApiRef<GraphQLBrowseApi>;
// Warning: (ae-missing-release-tag) "GraphQLEndpoint" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export type GraphQLEndpoint = {
id: string;
@@ -79,8 +61,6 @@ export type GraphQLEndpoint = {
fetcher: (body: any) => Promise<any>;
};
// Warning: (ae-missing-release-tag) "GraphQLEndpoints" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export class GraphQLEndpoints implements GraphQLBrowseApi {
// (undocumented)
@@ -92,8 +72,6 @@ export class GraphQLEndpoints implements GraphQLBrowseApi {
static github(config: GithubEndpointConfig): GraphQLEndpoint;
}
// Warning: (ae-missing-release-tag) "GraphiQLPage" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
//
// @public (undocumented)
export const Router: () => JSX.Element;
@@ -47,7 +47,9 @@ type GraphiQLBrowserProps = {
endpoints: GraphQLEndpoint[];
};
export const GraphiQLBrowser = ({ endpoints }: GraphiQLBrowserProps) => {
export const GraphiQLBrowser = (props: GraphiQLBrowserProps) => {
const { endpoints } = props;
const classes = useStyles();
const [tabIndex, setTabIndex] = useState(0);
@@ -28,6 +28,7 @@ import {
Progress,
} from '@backstage/core-components';
/** @public */
export const GraphiQLPage = () => {
const graphQlBrowseApi = useApi(graphQlBrowseApiRef);
const endpoints = useAsync(() => graphQlBrowseApi.getEndpoints());
+2
View File
@@ -31,5 +31,7 @@ export {
export { GraphiQLPage as Router } from './components';
export * from './lib/api';
export * from './route-refs';
/** @public */
export const GraphiQLIcon: IconComponent =
GraphiQLIconComponent as IconComponent;
@@ -17,7 +17,11 @@
import { GraphQLBrowseApi, GraphQLEndpoint } from './types';
import { ErrorApi, OAuthApi } from '@backstage/core-plugin-api';
// Helper for generic http endpoints
/**
* Helper for generic http endpoints
*
* @public
*/
export type EndpointConfig = {
id: string;
title: string;
@@ -29,6 +33,7 @@ export type EndpointConfig = {
headers?: { [name in string]: string };
};
/** @public */
export type GithubEndpointConfig = {
id: string;
title: string;
@@ -46,6 +51,7 @@ export type GithubEndpointConfig = {
githubAuthApi: OAuthApi;
};
/** @public */
export class GraphQLEndpoints implements GraphQLBrowseApi {
// Create a support
static create(config: EndpointConfig): GraphQLEndpoint {
+3
View File
@@ -16,6 +16,7 @@
import { createApiRef } from '@backstage/core-plugin-api';
/** @public */
export type GraphQLEndpoint = {
// Will be used as unique key for storing history and query data
id: string;
@@ -29,10 +30,12 @@ export type GraphQLEndpoint = {
fetcher: (body: any) => Promise<any>;
};
/** @public */
export type GraphQLBrowseApi = {
getEndpoints(): Promise<GraphQLEndpoint[]>;
};
/** @public */
export const graphQlBrowseApiRef = createApiRef<GraphQLBrowseApi>({
id: 'plugin.graphiql.browse',
});
+2
View File
@@ -22,6 +22,7 @@ import {
import { graphQlBrowseApiRef, GraphQLEndpoints } from './lib/api';
import { graphiQLRouteRef } from './route-refs';
/** @public */
export const graphiqlPlugin = createPlugin({
id: 'graphiql',
apis: [
@@ -40,6 +41,7 @@ export const graphiqlPlugin = createPlugin({
],
});
/** @public */
export const GraphiQLPage = graphiqlPlugin.provide(
createRoutableExtension({
name: 'GraphiQLPage',
+1
View File
@@ -16,6 +16,7 @@
import { createRouteRef } from '@backstage/core-plugin-api';
/** @public */
export const graphiQLRouteRef = createRouteRef({
id: 'graphiql-root',
});