plugin-catalog-import: move NFS page export to alpha entry point
Move NfsDefaultImportPage out of the public API and export it as DefaultImportPage from the alpha entry point instead. Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com> Made-with: Cursor
This commit is contained in:
@@ -11,7 +11,8 @@ import { ExtensionBlueprintParams } from '@backstage/frontend-plugin-api';
|
||||
import { ExtensionDataRef } from '@backstage/frontend-plugin-api';
|
||||
import { ExtensionInput } from '@backstage/frontend-plugin-api';
|
||||
import { IconElement } from '@backstage/frontend-plugin-api';
|
||||
import { JSX as JSX_2 } from 'react';
|
||||
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
||||
import { JSX as JSX_3 } from 'react';
|
||||
import { OverridableExtensionDefinition } from '@backstage/frontend-plugin-api';
|
||||
import { OverridableFrontendPlugin } from '@backstage/frontend-plugin-api';
|
||||
import { RouteRef } from '@backstage/core-plugin-api';
|
||||
@@ -133,7 +134,7 @@ const _default: OverridableFrontendPlugin<
|
||||
optional: true;
|
||||
}
|
||||
>
|
||||
| ExtensionDataRef<JSX_2.Element, 'core.reactElement', {}>
|
||||
| ExtensionDataRef<JSX_3.Element, 'core.reactElement', {}>
|
||||
| ExtensionDataRef<
|
||||
string,
|
||||
'core.title',
|
||||
@@ -150,7 +151,7 @@ const _default: OverridableFrontendPlugin<
|
||||
>;
|
||||
inputs: {
|
||||
pages: ExtensionInput<
|
||||
| ConfigurableExtensionDataRef<JSX_2.Element, 'core.reactElement', {}>
|
||||
| ConfigurableExtensionDataRef<JSX_3.Element, 'core.reactElement', {}>
|
||||
| ConfigurableExtensionDataRef<string, 'core.routing.path', {}>
|
||||
| ConfigurableExtensionDataRef<
|
||||
RouteRef_2<AnyRouteRefParams>,
|
||||
@@ -184,7 +185,7 @@ const _default: OverridableFrontendPlugin<
|
||||
path: string;
|
||||
title?: string;
|
||||
icon?: IconElement;
|
||||
loader?: () => Promise<JSX_2.Element>;
|
||||
loader?: () => Promise<JSX_3.Element>;
|
||||
routeRef?: RouteRef_2;
|
||||
noHeader?: boolean;
|
||||
};
|
||||
@@ -193,5 +194,8 @@ const _default: OverridableFrontendPlugin<
|
||||
>;
|
||||
export default _default;
|
||||
|
||||
// @alpha (undocumented)
|
||||
export const DefaultImportPage: () => JSX_2.Element;
|
||||
|
||||
// (No @packageDocumentation comment for this package)
|
||||
```
|
||||
|
||||
@@ -298,9 +298,6 @@ export interface ImportStepperProps {
|
||||
variant?: InfoCardVariants;
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export const NfsDefaultImportPage: () => JSX_2.Element;
|
||||
|
||||
// @public
|
||||
export const PreparePullRequestForm: <TFieldValues extends Record<string, any>>(
|
||||
props: PreparePullRequestFormProps<TFieldValues>,
|
||||
|
||||
@@ -44,6 +44,8 @@ import { catalogImportTranslationRef as _catalogImportTranslationRef } from './t
|
||||
*/
|
||||
export const catalogImportTranslationRef = _catalogImportTranslationRef;
|
||||
|
||||
export { NfsDefaultImportPage as DefaultImportPage } from './components/DefaultImportPage/DefaultImportPage';
|
||||
|
||||
// TODO: It's currently possible to override the import page with a custom one. We need to decide
|
||||
// whether this type of override is typically done with an input or by overriding the entire extension.
|
||||
const catalogImportPage = PageBlueprint.make({
|
||||
@@ -51,7 +53,7 @@ const catalogImportPage = PageBlueprint.make({
|
||||
path: '/catalog-import',
|
||||
routeRef: rootRouteRef,
|
||||
loader: () =>
|
||||
import('./components/DefaultImportPage').then(m => (
|
||||
import('./components/DefaultImportPage/DefaultImportPage').then(m => (
|
||||
<RequirePermission permission={catalogEntityCreatePermission}>
|
||||
<m.NfsDefaultImportPage />
|
||||
</RequirePermission>
|
||||
|
||||
@@ -82,7 +82,7 @@ export const DefaultImportPage = () => {
|
||||
};
|
||||
|
||||
/**
|
||||
* @public
|
||||
* @alpha
|
||||
*/
|
||||
export const NfsDefaultImportPage = () => {
|
||||
const { t } = useTranslationRef(catalogImportTranslationRef);
|
||||
|
||||
@@ -14,4 +14,4 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export { DefaultImportPage, NfsDefaultImportPage } from './DefaultImportPage';
|
||||
export { DefaultImportPage } from './DefaultImportPage';
|
||||
|
||||
Reference in New Issue
Block a user