@backstage/plugin-techdocs 1.12.5-next.1 → 1.12.5-next.2

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.
Files changed (68) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/dist/EntityPageDocs.esm.js +11 -8
  3. package/dist/EntityPageDocs.esm.js.map +1 -1
  4. package/dist/Router.esm.js +15 -12
  5. package/dist/Router.esm.js.map +1 -1
  6. package/dist/alpha.d.ts +6 -6
  7. package/dist/alpha.esm.js +14 -10
  8. package/dist/alpha.esm.js.map +1 -1
  9. package/dist/home/components/DefaultTechDocsHome.esm.js +21 -10
  10. package/dist/home/components/DefaultTechDocsHome.esm.js.map +1 -1
  11. package/dist/home/components/Grids/DocsCardGrid.esm.js +26 -22
  12. package/dist/home/components/Grids/DocsCardGrid.esm.js.map +1 -1
  13. package/dist/home/components/Grids/EntityListDocsGrid.esm.js +22 -14
  14. package/dist/home/components/Grids/EntityListDocsGrid.esm.js.map +1 -1
  15. package/dist/home/components/Grids/InfoCardGrid.esm.js +19 -17
  16. package/dist/home/components/Grids/InfoCardGrid.esm.js.map +1 -1
  17. package/dist/home/components/Tables/CursorPaginatedDocsTable.esm.js +2 -2
  18. package/dist/home/components/Tables/CursorPaginatedDocsTable.esm.js.map +1 -1
  19. package/dist/home/components/Tables/DocsTable.esm.js +8 -8
  20. package/dist/home/components/Tables/DocsTable.esm.js.map +1 -1
  21. package/dist/home/components/Tables/EntityListDocsTable.esm.js +8 -8
  22. package/dist/home/components/Tables/EntityListDocsTable.esm.js.map +1 -1
  23. package/dist/home/components/Tables/OffsetPaginatedDocsTable.esm.js +4 -3
  24. package/dist/home/components/Tables/OffsetPaginatedDocsTable.esm.js.map +1 -1
  25. package/dist/home/components/Tables/actions.esm.js +3 -3
  26. package/dist/home/components/Tables/actions.esm.js.map +1 -1
  27. package/dist/home/components/Tables/columns.esm.js +4 -4
  28. package/dist/home/components/Tables/columns.esm.js.map +1 -1
  29. package/dist/home/components/TechDocsCustomHome.esm.js +41 -34
  30. package/dist/home/components/TechDocsCustomHome.esm.js.map +1 -1
  31. package/dist/home/components/TechDocsIndexPage.esm.js +2 -2
  32. package/dist/home/components/TechDocsIndexPage.esm.js.map +1 -1
  33. package/dist/home/components/TechDocsPageWrapper.esm.js +6 -6
  34. package/dist/home/components/TechDocsPageWrapper.esm.js.map +1 -1
  35. package/dist/index.d.ts +39 -38
  36. package/dist/reader/components/TechDocsBuildLogs.esm.js +48 -40
  37. package/dist/reader/components/TechDocsBuildLogs.esm.js.map +1 -1
  38. package/dist/reader/components/TechDocsNotFound.esm.js +3 -2
  39. package/dist/reader/components/TechDocsNotFound.esm.js.map +1 -1
  40. package/dist/reader/components/TechDocsReaderPage/TechDocsReaderPage.esm.js +18 -13
  41. package/dist/reader/components/TechDocsReaderPage/TechDocsReaderPage.esm.js.map +1 -1
  42. package/dist/reader/components/TechDocsReaderPageContent/TechDocsReaderPageContent.esm.js +19 -11
  43. package/dist/reader/components/TechDocsReaderPageContent/TechDocsReaderPageContent.esm.js.map +1 -1
  44. package/dist/reader/components/TechDocsReaderPageContent/TechDocsReaderPageContentAddons.esm.js +6 -2
  45. package/dist/reader/components/TechDocsReaderPageContent/TechDocsReaderPageContentAddons.esm.js.map +1 -1
  46. package/dist/reader/components/TechDocsReaderPageHeader/TechDocsReaderPageHeader.esm.js +55 -44
  47. package/dist/reader/components/TechDocsReaderPageHeader/TechDocsReaderPageHeader.esm.js.map +1 -1
  48. package/dist/reader/components/TechDocsReaderPageSubheader/TechDocsReaderPageSubheader.esm.js +33 -27
  49. package/dist/reader/components/TechDocsReaderPageSubheader/TechDocsReaderPageSubheader.esm.js.map +1 -1
  50. package/dist/reader/components/TechDocsReaderProvider.esm.js +4 -3
  51. package/dist/reader/components/TechDocsReaderProvider.esm.js.map +1 -1
  52. package/dist/reader/components/TechDocsRedirectNotification/TechDocsRedirectNotification.esm.js +7 -6
  53. package/dist/reader/components/TechDocsRedirectNotification/TechDocsRedirectNotification.esm.js.map +1 -1
  54. package/dist/reader/components/TechDocsStateIndicator.esm.js +43 -36
  55. package/dist/reader/components/TechDocsStateIndicator.esm.js.map +1 -1
  56. package/dist/reader/transformers/addGitFeedbackLink.esm.js +2 -2
  57. package/dist/reader/transformers/addGitFeedbackLink.esm.js.map +1 -1
  58. package/dist/reader/transformers/addSidebarToggle.esm.js +2 -2
  59. package/dist/reader/transformers/addSidebarToggle.esm.js.map +1 -1
  60. package/dist/reader/transformers/copyToClipboard.esm.js +16 -15
  61. package/dist/reader/transformers/copyToClipboard.esm.js.map +1 -1
  62. package/dist/reader/transformers/handleMetaRedirects.esm.js +2 -2
  63. package/dist/reader/transformers/handleMetaRedirects.esm.js.map +1 -1
  64. package/dist/search/components/TechDocsSearch.esm.js +5 -4
  65. package/dist/search/components/TechDocsSearch.esm.js.map +1 -1
  66. package/dist/search/components/TechDocsSearchResultListItem.esm.js +28 -20
  67. package/dist/search/components/TechDocsSearchResultListItem.esm.js.map +1 -1
  68. package/package.json +20 -20
@@ -1,10 +1,10 @@
1
- import React from 'react';
1
+ import { jsx } from 'react/jsx-runtime';
2
2
  import { useOutlet } from 'react-router-dom';
3
3
  import { DefaultTechDocsHome } from './DefaultTechDocsHome.esm.js';
4
4
 
5
5
  const TechDocsIndexPage = (props) => {
6
6
  const outlet = useOutlet();
7
- return outlet || /* @__PURE__ */ React.createElement(DefaultTechDocsHome, { ...props });
7
+ return outlet || /* @__PURE__ */ jsx(DefaultTechDocsHome, { ...props });
8
8
  };
9
9
 
10
10
  export { TechDocsIndexPage };
@@ -1 +1 @@
1
- {"version":3,"file":"TechDocsIndexPage.esm.js","sources":["../../../src/home/components/TechDocsIndexPage.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 React from 'react';\nimport { useOutlet } from 'react-router-dom';\nimport {\n TableColumn,\n TableProps,\n TableOptions,\n} from '@backstage/core-components';\nimport {\n EntityListPagination,\n EntityOwnerPickerProps,\n UserListFilterKind,\n} from '@backstage/plugin-catalog-react';\nimport { DefaultTechDocsHome } from './DefaultTechDocsHome';\nimport { DocsTableRow } from './Tables';\n\n/**\n * Props for {@link TechDocsIndexPage}\n *\n * @public\n */\nexport type TechDocsIndexPageProps = {\n initialFilter?: UserListFilterKind;\n columns?: TableColumn<DocsTableRow>[];\n actions?: TableProps<DocsTableRow>['actions'];\n ownerPickerMode?: EntityOwnerPickerProps['mode'];\n pagination?: EntityListPagination;\n options?: TableOptions<DocsTableRow>;\n PageWrapper?: React.FC;\n CustomHeader?: React.FC;\n};\n\nexport const TechDocsIndexPage = (props: TechDocsIndexPageProps) => {\n const outlet = useOutlet();\n\n return outlet || <DefaultTechDocsHome {...props} />;\n};\n"],"names":[],"mappings":";;;;AA+Ca,MAAA,iBAAA,GAAoB,CAAC,KAAkC,KAAA;AAClE,EAAA,MAAM,SAAS,SAAU,EAAA;AAEzB,EAAA,OAAO,MAAU,oBAAA,KAAA,CAAA,aAAA,CAAC,mBAAqB,EAAA,EAAA,GAAG,KAAO,EAAA,CAAA;AACnD;;;;"}
1
+ {"version":3,"file":"TechDocsIndexPage.esm.js","sources":["../../../src/home/components/TechDocsIndexPage.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 { FC } from 'react';\nimport { useOutlet } from 'react-router-dom';\nimport {\n TableColumn,\n TableProps,\n TableOptions,\n} from '@backstage/core-components';\nimport {\n EntityListPagination,\n EntityOwnerPickerProps,\n UserListFilterKind,\n} from '@backstage/plugin-catalog-react';\nimport { DefaultTechDocsHome } from './DefaultTechDocsHome';\nimport { DocsTableRow } from './Tables';\n\n/**\n * Props for {@link TechDocsIndexPage}\n *\n * @public\n */\nexport type TechDocsIndexPageProps = {\n initialFilter?: UserListFilterKind;\n columns?: TableColumn<DocsTableRow>[];\n actions?: TableProps<DocsTableRow>['actions'];\n ownerPickerMode?: EntityOwnerPickerProps['mode'];\n pagination?: EntityListPagination;\n options?: TableOptions<DocsTableRow>;\n PageWrapper?: FC;\n CustomHeader?: FC;\n};\n\nexport const TechDocsIndexPage = (props: TechDocsIndexPageProps) => {\n const outlet = useOutlet();\n\n return outlet || <DefaultTechDocsHome {...props} />;\n};\n"],"names":[],"mappings":";;;;AA+Ca,MAAA,iBAAA,GAAoB,CAAC,KAAkC,KAAA;AAClE,EAAA,MAAM,SAAS,SAAU,EAAA;AAEzB,EAAA,OAAO,MAAU,oBAAA,GAAA,CAAC,mBAAqB,EAAA,EAAA,GAAG,KAAO,EAAA,CAAA;AACnD;;;;"}
@@ -1,4 +1,4 @@
1
- import React from 'react';
1
+ import { jsx, Fragment } from 'react/jsx-runtime';
2
2
  import { PageWithHeader } from '@backstage/core-components';
3
3
  import { useApi, configApiRef } from '@backstage/core-plugin-api';
4
4
 
@@ -6,15 +6,15 @@ const TechDocsPageWrapper = (props) => {
6
6
  const { children, CustomPageWrapper } = props;
7
7
  const configApi = useApi(configApiRef);
8
8
  const generatedSubtitle = `Documentation available in ${configApi.getOptionalString("organization.name") ?? "Backstage"}`;
9
- return /* @__PURE__ */ React.createElement(React.Fragment, null, CustomPageWrapper ? /* @__PURE__ */ React.createElement(CustomPageWrapper, null, children) : /* @__PURE__ */ React.createElement(
9
+ return /* @__PURE__ */ jsx(Fragment, { children: CustomPageWrapper ? /* @__PURE__ */ jsx(CustomPageWrapper, { children }) : /* @__PURE__ */ jsx(
10
10
  PageWithHeader,
11
11
  {
12
12
  title: "Documentation",
13
13
  subtitle: generatedSubtitle,
14
- themeId: "documentation"
15
- },
16
- children
17
- ));
14
+ themeId: "documentation",
15
+ children
16
+ }
17
+ ) });
18
18
  };
19
19
 
20
20
  export { TechDocsPageWrapper };
@@ -1 +1 @@
1
- {"version":3,"file":"TechDocsPageWrapper.esm.js","sources":["../../../src/home/components/TechDocsPageWrapper.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 React from 'react';\n\nimport { PageWithHeader } from '@backstage/core-components';\nimport { useApi, configApiRef } from '@backstage/core-plugin-api';\n\n/**\n * Props for {@link TechDocsPageWrapper}\n *\n * @public\n */\nexport type TechDocsPageWrapperProps = {\n children?: React.ReactNode;\n CustomPageWrapper?: React.FC<{ children?: React.ReactNode }>;\n};\n\n/**\n * Component wrapping a TechDocs page with Page and Header components\n *\n * @public\n */\nexport const TechDocsPageWrapper = (props: TechDocsPageWrapperProps) => {\n const { children, CustomPageWrapper } = props;\n const configApi = useApi(configApiRef);\n const generatedSubtitle = `Documentation available in ${\n configApi.getOptionalString('organization.name') ?? 'Backstage'\n }`;\n\n return (\n <>\n {CustomPageWrapper ? (\n <CustomPageWrapper>{children}</CustomPageWrapper>\n ) : (\n <PageWithHeader\n title=\"Documentation\"\n subtitle={generatedSubtitle}\n themeId=\"documentation\"\n >\n {children}\n </PageWithHeader>\n )}\n </>\n );\n};\n"],"names":[],"mappings":";;;;AAoCa,MAAA,mBAAA,GAAsB,CAAC,KAAoC,KAAA;AACtE,EAAM,MAAA,EAAE,QAAU,EAAA,iBAAA,EAAsB,GAAA,KAAA;AACxC,EAAM,MAAA,SAAA,GAAY,OAAO,YAAY,CAAA;AACrC,EAAA,MAAM,oBAAoB,CACxB,2BAAA,EAAA,SAAA,CAAU,iBAAkB,CAAA,mBAAmB,KAAK,WACtD,CAAA,CAAA;AAEA,EAAA,uBAEK,KAAA,CAAA,aAAA,CAAA,KAAA,CAAA,QAAA,EAAA,IAAA,EAAA,iBAAA,mBACE,KAAA,CAAA,aAAA,CAAA,iBAAA,EAAA,IAAA,EAAmB,QAAS,CAE7B,mBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,cAAA;AAAA,IAAA;AAAA,MACC,KAAM,EAAA,eAAA;AAAA,MACN,QAAU,EAAA,iBAAA;AAAA,MACV,OAAQ,EAAA;AAAA,KAAA;AAAA,IAEP;AAAA,GAGP,CAAA;AAEJ;;;;"}
1
+ {"version":3,"file":"TechDocsPageWrapper.esm.js","sources":["../../../src/home/components/TechDocsPageWrapper.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 { ReactNode, FC } from 'react';\n\nimport { PageWithHeader } from '@backstage/core-components';\nimport { useApi, configApiRef } from '@backstage/core-plugin-api';\n\n/**\n * Props for {@link TechDocsPageWrapper}\n *\n * @public\n */\nexport type TechDocsPageWrapperProps = {\n children?: ReactNode;\n CustomPageWrapper?: FC<{ children?: ReactNode }>;\n};\n\n/**\n * Component wrapping a TechDocs page with Page and Header components\n *\n * @public\n */\nexport const TechDocsPageWrapper = (props: TechDocsPageWrapperProps) => {\n const { children, CustomPageWrapper } = props;\n const configApi = useApi(configApiRef);\n const generatedSubtitle = `Documentation available in ${\n configApi.getOptionalString('organization.name') ?? 'Backstage'\n }`;\n\n return (\n <>\n {CustomPageWrapper ? (\n <CustomPageWrapper>{children}</CustomPageWrapper>\n ) : (\n <PageWithHeader\n title=\"Documentation\"\n subtitle={generatedSubtitle}\n themeId=\"documentation\"\n >\n {children}\n </PageWithHeader>\n )}\n </>\n );\n};\n"],"names":[],"mappings":";;;;AAoCa,MAAA,mBAAA,GAAsB,CAAC,KAAoC,KAAA;AACtE,EAAM,MAAA,EAAE,QAAU,EAAA,iBAAA,EAAsB,GAAA,KAAA;AACxC,EAAM,MAAA,SAAA,GAAY,OAAO,YAAY,CAAA;AACrC,EAAA,MAAM,oBAAoB,CACxB,2BAAA,EAAA,SAAA,CAAU,iBAAkB,CAAA,mBAAmB,KAAK,WACtD,CAAA,CAAA;AAEA,EAAA,uBAEK,GAAA,CAAA,QAAA,EAAA,EAAA,QAAA,EAAA,iBAAA,mBACE,GAAA,CAAA,iBAAA,EAAA,EAAmB,UAAS,CAE7B,mBAAA,GAAA;AAAA,IAAC,cAAA;AAAA,IAAA;AAAA,MACC,KAAM,EAAA,eAAA;AAAA,MACN,QAAU,EAAA,iBAAA;AAAA,MACV,OAAQ,EAAA,eAAA;AAAA,MAEP;AAAA;AAAA,GAGP,EAAA,CAAA;AAEJ;;;;"}
package/dist/index.d.ts CHANGED
@@ -3,8 +3,9 @@ import { CompoundEntityRef, Entity } from '@backstage/catalog-model';
3
3
  import * as _backstage_core_plugin_api from '@backstage/core-plugin-api';
4
4
  import { DiscoveryApi, FetchApi, IdentityApi } from '@backstage/core-plugin-api';
5
5
  import { Config } from '@backstage/config';
6
- import * as React from 'react';
7
- import React__default, { ReactNode, PropsWithChildren } from 'react';
6
+ import * as react_jsx_runtime from 'react/jsx-runtime';
7
+ import * as react from 'react';
8
+ import { ReactNode, PropsWithChildren, FC } from 'react';
8
9
  import { ThemeOptions } from '@material-ui/core/styles';
9
10
  import { ToolbarProps } from '@material-ui/core/Toolbar';
10
11
  import { TableColumn, TableProps, TableOptions } from '@backstage/core-components';
@@ -203,7 +204,7 @@ type TechDocsReaderProviderProps = {
203
204
  *
204
205
  * @public
205
206
  */
206
- declare const TechDocsReaderProvider: (props: TechDocsReaderProviderProps) => React__default.JSX.Element;
207
+ declare const TechDocsReaderProvider: (props: TechDocsReaderProviderProps) => react_jsx_runtime.JSX.Element;
207
208
 
208
209
  /**
209
210
  * Props for {@link TechDocsReaderLayout}
@@ -223,7 +224,7 @@ type TechDocsReaderLayoutProps = {
223
224
  * Default TechDocs reader page structure composed with a header and content
224
225
  * @public
225
226
  */
226
- declare const TechDocsReaderLayout: (props: TechDocsReaderLayoutProps) => React__default.JSX.Element;
227
+ declare const TechDocsReaderLayout: (props: TechDocsReaderLayoutProps) => react_jsx_runtime.JSX.Element;
227
228
  /**
228
229
  * @public
229
230
  */
@@ -250,7 +251,7 @@ type TechDocsReaderPageHeaderProps = PropsWithChildren<{
250
251
  * the Tech Docs add-ons to customize it
251
252
  * @public
252
253
  */
253
- declare const TechDocsReaderPageHeader: (props: TechDocsReaderPageHeaderProps) => React__default.JSX.Element | null;
254
+ declare const TechDocsReaderPageHeader: (props: TechDocsReaderPageHeaderProps) => react_jsx_runtime.JSX.Element | null;
254
255
 
255
256
  /**
256
257
  * Props for {@link TechDocsReaderPageContent}
@@ -281,13 +282,13 @@ type TechDocsReaderPageContentProps = {
281
282
  * Renders the reader page content
282
283
  * @public
283
284
  */
284
- declare const TechDocsReaderPageContent: (props: TechDocsReaderPageContentProps) => React__default.JSX.Element;
285
+ declare const TechDocsReaderPageContent: (props: TechDocsReaderPageContentProps) => react_jsx_runtime.JSX.Element;
285
286
  /**
286
287
  * Component responsible for rendering TechDocs documentation
287
288
  * @public
288
289
  * @deprecated use `TechDocsReaderPageContent` component instead.
289
290
  */
290
- declare const Reader: (props: TechDocsReaderPageContentProps) => React__default.JSX.Element;
291
+ declare const Reader: (props: TechDocsReaderPageContentProps) => react_jsx_runtime.JSX.Element;
291
292
 
292
293
  /**
293
294
  * Renders the reader page subheader.
@@ -296,7 +297,7 @@ declare const Reader: (props: TechDocsReaderPageContentProps) => React__default.
296
297
  */
297
298
  declare const TechDocsReaderPageSubheader: (props: {
298
299
  toolbarProps?: ToolbarProps;
299
- }) => React__default.JSX.Element | null;
300
+ }) => react_jsx_runtime.JSX.Element | null;
300
301
 
301
302
  /**
302
303
  * Props for {@link TechDocsSearch}
@@ -314,7 +315,7 @@ type TechDocsSearchProps = {
314
315
  *
315
316
  * @public
316
317
  */
317
- declare const TechDocsSearch: (props: TechDocsSearchProps) => React__default.JSX.Element;
318
+ declare const TechDocsSearch: (props: TechDocsSearchProps) => react_jsx_runtime.JSX.Element;
318
319
 
319
320
  /**
320
321
  * Props for {@link EntityListDocsGrid}
@@ -322,7 +323,7 @@ declare const TechDocsSearch: (props: TechDocsSearchProps) => React__default.JSX
322
323
  * @public
323
324
  */
324
325
  type DocsGroupConfig = {
325
- title: React__default.ReactNode;
326
+ title: ReactNode;
326
327
  filterPredicate: ((entity: Entity) => boolean) | string;
327
328
  };
328
329
  /**
@@ -338,7 +339,7 @@ type EntityListDocsGridPageProps = {
338
339
  *
339
340
  * @public
340
341
  */
341
- declare const EntityListDocsGrid: (props: EntityListDocsGridPageProps) => React__default.JSX.Element;
342
+ declare const EntityListDocsGrid: (props: EntityListDocsGridPageProps) => react_jsx_runtime.JSX.Element;
342
343
 
343
344
  /**
344
345
  * Props for {@link DocsCardGrid}
@@ -353,7 +354,7 @@ type DocsCardGridProps = {
353
354
  *
354
355
  * @public
355
356
  */
356
- declare const DocsCardGrid: (props: DocsCardGridProps) => React__default.JSX.Element | null;
357
+ declare const DocsCardGrid: (props: DocsCardGridProps) => react_jsx_runtime.JSX.Element | null;
357
358
 
358
359
  /** @public */
359
360
  type InfoCardGridClassKey = 'linkSpacer' | 'readMoreLink';
@@ -372,7 +373,7 @@ type InfoCardGridProps = {
372
373
  *
373
374
  * @public
374
375
  */
375
- declare const InfoCardGrid: (props: InfoCardGridProps) => React__default.JSX.Element | null;
376
+ declare const InfoCardGrid: (props: InfoCardGridProps) => react_jsx_runtime.JSX.Element | null;
376
377
 
377
378
  /**
378
379
  * Generic representing the metadata structure for a docs table row.
@@ -404,7 +405,7 @@ type EntityListDocsTableProps = {
404
405
  * @public
405
406
  */
406
407
  declare const EntityListDocsTable: {
407
- (props: EntityListDocsTableProps): React__default.JSX.Element;
408
+ (props: EntityListDocsTableProps): react_jsx_runtime.JSX.Element;
408
409
  columns: {
409
410
  createTitleColumn(options?: {
410
411
  hidden?: boolean;
@@ -416,7 +417,7 @@ declare const EntityListDocsTable: {
416
417
  };
417
418
  actions: {
418
419
  createCopyDocsUrlAction(copyToClipboard: Function): (row: DocsTableRow) => {
419
- icon: () => React__default.JSX.Element;
420
+ icon: () => react_jsx_runtime.JSX.Element;
420
421
  tooltip: string;
421
422
  onClick: () => any;
422
423
  };
@@ -424,7 +425,7 @@ declare const EntityListDocsTable: {
424
425
  cellStyle: {
425
426
  paddingLeft: string;
426
427
  };
427
- icon: () => React__default.JSX.Element;
428
+ icon: () => react_jsx_runtime.JSX.Element;
428
429
  tooltip: string;
429
430
  onClick: () => any;
430
431
  };
@@ -450,7 +451,7 @@ type DocsTableProps = {
450
451
  * @public
451
452
  */
452
453
  declare const DocsTable: {
453
- (props: DocsTableProps): React__default.JSX.Element | null;
454
+ (props: DocsTableProps): react_jsx_runtime.JSX.Element | null;
454
455
  columns: {
455
456
  createTitleColumn(options?: {
456
457
  hidden?: boolean;
@@ -462,7 +463,7 @@ declare const DocsTable: {
462
463
  };
463
464
  actions: {
464
465
  createCopyDocsUrlAction(copyToClipboard: Function): (row: DocsTableRow) => {
465
- icon: () => React__default.JSX.Element;
466
+ icon: () => react_jsx_runtime.JSX.Element;
466
467
  tooltip: string;
467
468
  onClick: () => any;
468
469
  };
@@ -470,7 +471,7 @@ declare const DocsTable: {
470
471
  cellStyle: {
471
472
  paddingLeft: string;
472
473
  };
473
- icon: () => React__default.JSX.Element;
474
+ icon: () => react_jsx_runtime.JSX.Element;
474
475
  tooltip: string;
475
476
  onClick: () => any;
476
477
  };
@@ -489,8 +490,8 @@ type TechDocsIndexPageProps = {
489
490
  ownerPickerMode?: EntityOwnerPickerProps['mode'];
490
491
  pagination?: EntityListPagination;
491
492
  options?: TableOptions<DocsTableRow>;
492
- PageWrapper?: React__default.FC;
493
- CustomHeader?: React__default.FC;
493
+ PageWrapper?: FC;
494
+ CustomHeader?: FC;
494
495
  };
495
496
 
496
497
  /**
@@ -505,7 +506,7 @@ type DefaultTechDocsHomeProps = TechDocsIndexPageProps;
505
506
  *
506
507
  * @public
507
508
  */
508
- declare const DefaultTechDocsHome: (props: TechDocsIndexPageProps) => React__default.JSX.Element;
509
+ declare const DefaultTechDocsHome: (props: TechDocsIndexPageProps) => react_jsx_runtime.JSX.Element;
509
510
 
510
511
  /**
511
512
  * Available panel types
@@ -522,8 +523,8 @@ interface PanelProps {
522
523
  options?: TableOptions<DocsTableRow>;
523
524
  linkContent?: string | JSX.Element;
524
525
  linkDestination?: (entity: Entity) => string | undefined;
525
- PageWrapper?: React__default.FC;
526
- CustomHeader?: React__default.FC;
526
+ PageWrapper?: FC;
527
+ CustomHeader?: FC;
527
528
  }
528
529
  /**
529
530
  * Type representing a TechDocsCustomHome panel.
@@ -562,7 +563,7 @@ declare const CustomDocsPanel: ({ config, entities, index, }: {
562
563
  config: PanelConfig;
563
564
  entities: Entity[];
564
565
  index: number;
565
- }) => React__default.JSX.Element;
566
+ }) => react_jsx_runtime.JSX.Element;
566
567
  /**
567
568
  * Props for {@link TechDocsCustomHome}
568
569
  *
@@ -571,7 +572,7 @@ declare const CustomDocsPanel: ({ config, entities, index, }: {
571
572
  type TechDocsCustomHomeProps = {
572
573
  tabsConfig: TabsConfig;
573
574
  filter?: EntityFilterQuery;
574
- CustomPageWrapper?: React__default.FC;
575
+ CustomPageWrapper?: FC;
575
576
  };
576
577
 
577
578
  /**
@@ -580,9 +581,9 @@ type TechDocsCustomHomeProps = {
580
581
  * @public
581
582
  */
582
583
  type TechDocsPageWrapperProps = {
583
- children?: React__default.ReactNode;
584
- CustomPageWrapper?: React__default.FC<{
585
- children?: React__default.ReactNode;
584
+ children?: ReactNode;
585
+ CustomPageWrapper?: FC<{
586
+ children?: ReactNode;
586
587
  }>;
587
588
  };
588
589
  /**
@@ -590,7 +591,7 @@ type TechDocsPageWrapperProps = {
590
591
  *
591
592
  * @public
592
593
  */
593
- declare const TechDocsPageWrapper: (props: TechDocsPageWrapperProps) => React__default.JSX.Element;
594
+ declare const TechDocsPageWrapper: (props: TechDocsPageWrapperProps) => react_jsx_runtime.JSX.Element;
594
595
 
595
596
  /**
596
597
  * Component responsible for updating TechDocs filters
@@ -634,33 +635,33 @@ declare const techdocsPlugin: _backstage_core_plugin_api.BackstagePlugin<{
634
635
  *
635
636
  * @public
636
637
  */
637
- declare const TechdocsPage: () => React.JSX.Element;
638
+ declare const TechdocsPage: () => react_jsx_runtime.JSX.Element;
638
639
  /**
639
640
  * Routable extension used to render docs on Entity page
640
641
  *
641
642
  * @public
642
643
  */
643
- declare const EntityTechdocsContent: ({ children, withSearch, }: React.PropsWithChildren<{
644
+ declare const EntityTechdocsContent: ({ children, withSearch, }: react.PropsWithChildren<{
644
645
  withSearch?: boolean;
645
- }>) => React.JSX.Element;
646
+ }>) => react_jsx_runtime.JSX.Element;
646
647
  /**
647
648
  * Component which takes a custom tabs config object and renders a documentation landing page.
648
649
  *
649
650
  * @public
650
651
  */
651
- declare const TechDocsCustomHome: (props: TechDocsCustomHomeProps) => React.JSX.Element;
652
+ declare const TechDocsCustomHome: (props: TechDocsCustomHomeProps) => react_jsx_runtime.JSX.Element;
652
653
  /**
653
654
  * Responsible for rendering the provided router element
654
655
  *
655
656
  * @public
656
657
  */
657
- declare const TechDocsIndexPage: (props: TechDocsIndexPageProps) => React.JSX.Element;
658
+ declare const TechDocsIndexPage: (props: TechDocsIndexPageProps) => react_jsx_runtime.JSX.Element;
658
659
  /**
659
660
  * Component responsible for composing a TechDocs reader page experience
660
661
  *
661
662
  * @public
662
663
  */
663
- declare const TechDocsReaderPage: (props: TechDocsReaderPageProps) => React.JSX.Element;
664
+ declare const TechDocsReaderPage: (props: TechDocsReaderPageProps) => react_jsx_runtime.JSX.Element;
664
665
  /**
665
666
  * React extension used to render results on Search page or modal
666
667
  *
@@ -679,7 +680,7 @@ declare const isTechDocsAvailable: (entity: Entity) => boolean;
679
680
  *
680
681
  * @public
681
682
  */
682
- declare const Router: () => React__default.JSX.Element;
683
+ declare const Router: () => react_jsx_runtime.JSX.Element;
683
684
  /**
684
685
  * Responsible for registering route to view docs on Entity page
685
686
  *
@@ -687,7 +688,7 @@ declare const Router: () => React__default.JSX.Element;
687
688
  */
688
689
  declare const LegacyEmbeddedDocsRouter: ({ children, withSearch, }: PropsWithChildren<{
689
690
  withSearch?: boolean;
690
- }>) => React__default.JSX.Element;
691
+ }>) => react_jsx_runtime.JSX.Element;
691
692
 
692
693
  /** @public */
693
694
  type CatalogReactComponentsNameToClassKey = {
@@ -1,3 +1,4 @@
1
+ import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
1
2
  import { LogViewer } from '@backstage/core-components';
2
3
  import Button from '@material-ui/core/Button';
3
4
  import Drawer from '@material-ui/core/Drawer';
@@ -6,7 +7,7 @@ import IconButton from '@material-ui/core/IconButton';
6
7
  import Typography from '@material-ui/core/Typography';
7
8
  import { makeStyles, createStyles } from '@material-ui/core/styles';
8
9
  import Close from '@material-ui/icons/Close';
9
- import React, { useState } from 'react';
10
+ import { useState } from 'react';
10
11
 
11
12
  const useDrawerStyles = makeStyles(
12
13
  (theme) => createStyles({
@@ -35,59 +36,66 @@ const TechDocsBuildLogsDrawerContent = ({
35
36
  }) => {
36
37
  const classes = useDrawerStyles();
37
38
  const logText = buildLog.length === 0 ? "Waiting for logs..." : buildLog.join("\n");
38
- return /* @__PURE__ */ React.createElement(
39
+ return /* @__PURE__ */ jsxs(
39
40
  Grid,
40
41
  {
41
42
  container: true,
42
43
  direction: "column",
43
44
  className: classes.root,
44
45
  spacing: 0,
45
- wrap: "nowrap"
46
- },
47
- /* @__PURE__ */ React.createElement(
48
- Grid,
49
- {
50
- item: true,
51
- container: true,
52
- justifyContent: "space-between",
53
- alignItems: "center",
54
- spacing: 0,
55
- wrap: "nowrap"
56
- },
57
- /* @__PURE__ */ React.createElement(Typography, { variant: "h5" }, "Build Details"),
58
- /* @__PURE__ */ React.createElement(
59
- IconButton,
60
- {
61
- key: "dismiss",
62
- title: "Close the drawer",
63
- onClick: onClose,
64
- color: "inherit"
65
- },
66
- /* @__PURE__ */ React.createElement(Close, null)
67
- )
68
- ),
69
- /* @__PURE__ */ React.createElement(Grid, { item: true, xs: true }, /* @__PURE__ */ React.createElement(LogViewer, { text: logText, classes: { root: classes.logs } }))
46
+ wrap: "nowrap",
47
+ children: [
48
+ /* @__PURE__ */ jsxs(
49
+ Grid,
50
+ {
51
+ item: true,
52
+ container: true,
53
+ justifyContent: "space-between",
54
+ alignItems: "center",
55
+ spacing: 0,
56
+ wrap: "nowrap",
57
+ children: [
58
+ /* @__PURE__ */ jsx(Typography, { variant: "h5", children: "Build Details" }),
59
+ /* @__PURE__ */ jsx(
60
+ IconButton,
61
+ {
62
+ title: "Close the drawer",
63
+ onClick: onClose,
64
+ color: "inherit",
65
+ children: /* @__PURE__ */ jsx(Close, {})
66
+ },
67
+ "dismiss"
68
+ )
69
+ ]
70
+ }
71
+ ),
72
+ /* @__PURE__ */ jsx(Grid, { item: true, xs: true, children: /* @__PURE__ */ jsx(LogViewer, { text: logText, classes: { root: classes.logs } }) })
73
+ ]
74
+ }
70
75
  );
71
76
  };
72
77
  const TechDocsBuildLogs = ({ buildLog }) => {
73
78
  const classes = useDrawerStyles();
74
79
  const [open, setOpen] = useState(false);
75
- return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Button, { color: "inherit", onClick: () => setOpen(true) }, "Show Build Logs"), /* @__PURE__ */ React.createElement(
76
- Drawer,
77
- {
78
- classes: { paper: classes.paper },
79
- anchor: "right",
80
- open,
81
- onClose: () => setOpen(false)
82
- },
83
- /* @__PURE__ */ React.createElement(
84
- TechDocsBuildLogsDrawerContent,
80
+ return /* @__PURE__ */ jsxs(Fragment, { children: [
81
+ /* @__PURE__ */ jsx(Button, { color: "inherit", onClick: () => setOpen(true), children: "Show Build Logs" }),
82
+ /* @__PURE__ */ jsx(
83
+ Drawer,
85
84
  {
86
- buildLog,
87
- onClose: () => setOpen(false)
85
+ classes: { paper: classes.paper },
86
+ anchor: "right",
87
+ open,
88
+ onClose: () => setOpen(false),
89
+ children: /* @__PURE__ */ jsx(
90
+ TechDocsBuildLogsDrawerContent,
91
+ {
92
+ buildLog,
93
+ onClose: () => setOpen(false)
94
+ }
95
+ )
88
96
  }
89
97
  )
90
- ));
98
+ ] });
91
99
  };
92
100
 
93
101
  export { TechDocsBuildLogs, TechDocsBuildLogsDrawerContent };
@@ -1 +1 @@
1
- {"version":3,"file":"TechDocsBuildLogs.esm.js","sources":["../../../src/reader/components/TechDocsBuildLogs.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 { LogViewer } from '@backstage/core-components';\nimport Button from '@material-ui/core/Button';\nimport Drawer from '@material-ui/core/Drawer';\nimport Grid from '@material-ui/core/Grid';\nimport IconButton from '@material-ui/core/IconButton';\nimport Typography from '@material-ui/core/Typography';\nimport { createStyles, makeStyles, Theme } from '@material-ui/core/styles';\nimport Close from '@material-ui/icons/Close';\nimport React, { useState } from 'react';\n\nconst useDrawerStyles = makeStyles((theme: Theme) =>\n createStyles({\n paper: {\n width: '100%',\n [theme.breakpoints.up('sm')]: {\n width: '75%',\n },\n [theme.breakpoints.up('md')]: {\n width: '50%',\n },\n padding: theme.spacing(2.5),\n },\n root: {\n height: '100%',\n overflow: 'hidden',\n },\n logs: {\n background: theme.palette.background.default,\n },\n }),\n);\n\nexport const TechDocsBuildLogsDrawerContent = ({\n buildLog,\n onClose,\n}: {\n buildLog: string[];\n onClose: () => void;\n}) => {\n const classes = useDrawerStyles();\n const logText =\n buildLog.length === 0 ? 'Waiting for logs...' : buildLog.join('\\n');\n return (\n <Grid\n container\n direction=\"column\"\n className={classes.root}\n spacing={0}\n wrap=\"nowrap\"\n >\n <Grid\n item\n container\n justifyContent=\"space-between\"\n alignItems=\"center\"\n spacing={0}\n wrap=\"nowrap\"\n >\n <Typography variant=\"h5\">Build Details</Typography>\n <IconButton\n key=\"dismiss\"\n title=\"Close the drawer\"\n onClick={onClose}\n color=\"inherit\"\n >\n <Close />\n </IconButton>\n </Grid>\n <Grid item xs>\n <LogViewer text={logText} classes={{ root: classes.logs }} />\n </Grid>\n </Grid>\n );\n};\n\nexport const TechDocsBuildLogs = ({ buildLog }: { buildLog: string[] }) => {\n const classes = useDrawerStyles();\n const [open, setOpen] = useState(false);\n\n return (\n <>\n <Button color=\"inherit\" onClick={() => setOpen(true)}>\n Show Build Logs\n </Button>\n <Drawer\n classes={{ paper: classes.paper }}\n anchor=\"right\"\n open={open}\n onClose={() => setOpen(false)}\n >\n <TechDocsBuildLogsDrawerContent\n buildLog={buildLog}\n onClose={() => setOpen(false)}\n />\n </Drawer>\n </>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;AA0BA,MAAM,eAAkB,GAAA,UAAA;AAAA,EAAW,CAAC,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;AAAA,QACA,OAAA,EAAS,MAAM,OAAA,CAAQ,KAAK;AAAA;AAAA;AAC9B,GAEJ,CAAA;AAEJ;;;;"}
1
+ {"version":3,"file":"TechDocsBuildLogs.esm.js","sources":["../../../src/reader/components/TechDocsBuildLogs.tsx"],"sourcesContent":["/*\n * Copyright 2021 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 { LogViewer } from '@backstage/core-components';\nimport Button from '@material-ui/core/Button';\nimport Drawer from '@material-ui/core/Drawer';\nimport Grid from '@material-ui/core/Grid';\nimport IconButton from '@material-ui/core/IconButton';\nimport Typography from '@material-ui/core/Typography';\nimport { createStyles, makeStyles, Theme } from '@material-ui/core/styles';\nimport Close from '@material-ui/icons/Close';\nimport { useState } from 'react';\n\nconst useDrawerStyles = makeStyles((theme: Theme) =>\n createStyles({\n paper: {\n width: '100%',\n [theme.breakpoints.up('sm')]: {\n width: '75%',\n },\n [theme.breakpoints.up('md')]: {\n width: '50%',\n },\n padding: theme.spacing(2.5),\n },\n root: {\n height: '100%',\n overflow: 'hidden',\n },\n logs: {\n background: theme.palette.background.default,\n },\n }),\n);\n\nexport const TechDocsBuildLogsDrawerContent = ({\n buildLog,\n onClose,\n}: {\n buildLog: string[];\n onClose: () => void;\n}) => {\n const classes = useDrawerStyles();\n const logText =\n buildLog.length === 0 ? 'Waiting for logs...' : buildLog.join('\\n');\n return (\n <Grid\n container\n direction=\"column\"\n className={classes.root}\n spacing={0}\n wrap=\"nowrap\"\n >\n <Grid\n item\n container\n justifyContent=\"space-between\"\n alignItems=\"center\"\n spacing={0}\n wrap=\"nowrap\"\n >\n <Typography variant=\"h5\">Build Details</Typography>\n <IconButton\n key=\"dismiss\"\n title=\"Close the drawer\"\n onClick={onClose}\n color=\"inherit\"\n >\n <Close />\n </IconButton>\n </Grid>\n <Grid item xs>\n <LogViewer text={logText} classes={{ root: classes.logs }} />\n </Grid>\n </Grid>\n );\n};\n\nexport const TechDocsBuildLogs = ({ buildLog }: { buildLog: string[] }) => {\n const classes = useDrawerStyles();\n const [open, setOpen] = useState(false);\n\n return (\n <>\n <Button color=\"inherit\" onClick={() => setOpen(true)}>\n Show Build Logs\n </Button>\n <Drawer\n classes={{ paper: classes.paper }}\n anchor=\"right\"\n open={open}\n onClose={() => setOpen(false)}\n >\n <TechDocsBuildLogsDrawerContent\n buildLog={buildLog}\n onClose={() => setOpen(false)}\n />\n </Drawer>\n </>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;AA0BA,MAAM,eAAkB,GAAA,UAAA;AAAA,EAAW,CAAC,UAClC,YAAa,CAAA;AAAA,IACX,KAAO,EAAA;AAAA,MACL,KAAO,EAAA,MAAA;AAAA,MACP,CAAC,KAAM,CAAA,WAAA,CAAY,EAAG,CAAA,IAAI,CAAC,GAAG;AAAA,QAC5B,KAAO,EAAA;AAAA,OACT;AAAA,MACA,CAAC,KAAM,CAAA,WAAA,CAAY,EAAG,CAAA,IAAI,CAAC,GAAG;AAAA,QAC5B,KAAO,EAAA;AAAA,OACT;AAAA,MACA,OAAA,EAAS,KAAM,CAAA,OAAA,CAAQ,GAAG;AAAA,KAC5B;AAAA,IACA,IAAM,EAAA;AAAA,MACJ,MAAQ,EAAA,MAAA;AAAA,MACR,QAAU,EAAA;AAAA,KACZ;AAAA,IACA,IAAM,EAAA;AAAA,MACJ,UAAA,EAAY,KAAM,CAAA,OAAA,CAAQ,UAAW,CAAA;AAAA;AACvC,GACD;AACH,CAAA;AAEO,MAAM,iCAAiC,CAAC;AAAA,EAC7C,QAAA;AAAA,EACA;AACF,CAGM,KAAA;AACJ,EAAA,MAAM,UAAU,eA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UAAU,eAAgB,EAAA;AAChC,EAAA,MAAM,CAAC,IAAA,EAAM,OAAO,CAAA,GAAI,SAAS,KAAK,CAAA;AAEtC,EAAA,uBAEI,IAAA,CAAA,QAAA,EAAA,EAAA,QAAA,EAAA;AAAA,oBAAC,GAAA,CAAA,MAAA,EAAA,EAAO,OAAM,SAAU,EAAA,OAAA,EAAS,MAAM,OAAQ,CAAA,IAAI,GAAG,QAEtD,EAAA,iBAAA,EAAA,CAAA;AAAA,oBACA,GAAA;AAAA,MAAC,MAAA;AAAA,MAAA;AAAA,QACC,OAAS,EAAA,EAAE,KAAO,EAAA,OAAA,CAAQ,KAAM,EAAA;AAAA,QAChC,MAAO,EAAA,OAAA;AAAA,QACP,IAAA;AAAA,QACA,OAAA,EAAS,MAAM,OAAA,CAAQ,KAAK,CAAA;AAAA,QAE5B,QAAA,kBAAA,GAAA;AAAA,UAAC,8BAAA;AAAA,UAAA;AAAA,YACC,QAAA;AAAA,YACA,OAAA,EAAS,MAAM,OAAA,CAAQ,KAAK;AAAA;AAAA;AAC9B;AAAA;AACF,GACF,EAAA,CAAA;AAEJ;;;;"}
@@ -1,4 +1,5 @@
1
- import React, { useEffect } from 'react';
1
+ import { jsx } from 'react/jsx-runtime';
2
+ import { useEffect } from 'react';
2
3
  import { useApi, configApiRef, useAnalytics } from '@backstage/core-plugin-api';
3
4
  import { ErrorPage } from '@backstage/core-components';
4
5
  import { useTechDocsReaderPage } from '@backstage/plugin-techdocs-react';
@@ -19,7 +20,7 @@ const TechDocsNotFound = ({ errorMessage }) => {
19
20
  if (![void 0, "local"].includes(techdocsBuilder)) {
20
21
  additionalInfo = "Note that techdocs.builder is not set to 'local' in your config, which means this Backstage app will not generate docs if they are not found. Make sure the project's docs are generated and published by some external process (e.g. CI/CD pipeline). Or change techdocs.builder to 'local' to generate docs from this Backstage instance.";
21
22
  }
22
- return /* @__PURE__ */ React.createElement(
23
+ return /* @__PURE__ */ jsx(
23
24
  ErrorPage,
24
25
  {
25
26
  status: "404",
@@ -1 +1 @@
1
- {"version":3,"file":"TechDocsNotFound.esm.js","sources":["../../../src/reader/components/TechDocsNotFound.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 React, { useEffect } from 'react';\nimport { useApi, configApiRef, useAnalytics } from '@backstage/core-plugin-api';\nimport { ErrorPage } from '@backstage/core-components';\nimport { useTechDocsReaderPage } from '@backstage/plugin-techdocs-react';\nimport { useLocation } from 'react-router-dom';\n\ntype Props = {\n errorMessage?: string;\n};\n\nexport const TechDocsNotFound = ({ errorMessage }: Props) => {\n const techdocsBuilder =\n useApi(configApiRef).getOptionalString('techdocs.builder');\n const analyticsApi = useAnalytics();\n const { entityRef } = useTechDocsReaderPage();\n const location = useLocation();\n\n useEffect(() => {\n const { pathname, search, hash } = location;\n analyticsApi.captureEvent('not-found', `${pathname}${search}${hash}`, {\n attributes: entityRef,\n });\n }, [analyticsApi, entityRef, location]);\n\n let additionalInfo = '';\n if (![undefined, 'local'].includes(techdocsBuilder)) {\n additionalInfo =\n \"Note that techdocs.builder is not set to 'local' in your config, which means this Backstage app will not \" +\n \"generate docs if they are not found. Make sure the project's docs are generated and published by some external \" +\n \"process (e.g. CI/CD pipeline). Or change techdocs.builder to 'local' to generate docs from this Backstage \" +\n 'instance.';\n }\n\n return (\n <ErrorPage\n status=\"404\"\n statusMessage={errorMessage || 'Documentation not found'}\n additionalInfo={additionalInfo}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;AA0BO,MAAM,gBAAmB,GAAA,CAAC,EAAE,YAAA,EAA0B,KAAA;AAC3D,EAAA,MAAM,eACJ,GAAA,MAAA,CAAO,YAAY,CAAA,CAAE,kBAAkB,kBAAkB,CAAA;AAC3D,EAAA,MAAM,eAAe,YAAa,EAAA;AAClC,EAAM,MAAA,EAAE,SAAU,EAAA,GAAI,qBAAsB,EAAA;AAC5C,EAAA,MAAM,WAAW,WAAY,EAAA;AAE7B,EAAA,SAAA,CAAU,MAAM;AACd,IAAA,MAAM,EAAE,QAAA,EAAU,MAAQ,EAAA,IAAA,EAAS,GAAA,QAAA;AACnC,IAAa,YAAA,CAAA,YAAA,CAAa,aAAa,CAAG,EAAA,QAAQ,GAAG,MAAM,CAAA,EAAG,IAAI,CAAI,CAAA,EAAA;AAAA,MACpE,UAAY,EAAA;AAAA,KACb,CAAA;AAAA,GACA,EAAA,CAAC,YAAc,EAAA,SAAA,EAAW,QAAQ,CAAC,CAAA;AAEtC,EAAA,IAAI,cAAiB,GAAA,EAAA;AACrB,EAAA,IAAI,CAAC,CAAC,KAAA,CAAA,EAAW,OAAO,CAAE,CAAA,QAAA,CAAS,eAAe,CAAG,EAAA;AACnD,IACE,cAAA,GAAA,6UAAA;AAAA;AAMJ,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,SAAA;AAAA,IAAA;AAAA,MACC,MAAO,EAAA,KAAA;AAAA,MACP,eAAe,YAAgB,IAAA,yBAAA;AAAA,MAC/B;AAAA;AAAA,GACF;AAEJ;;;;"}
1
+ {"version":3,"file":"TechDocsNotFound.esm.js","sources":["../../../src/reader/components/TechDocsNotFound.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 { useEffect } from 'react';\nimport { useApi, configApiRef, useAnalytics } from '@backstage/core-plugin-api';\nimport { ErrorPage } from '@backstage/core-components';\nimport { useTechDocsReaderPage } from '@backstage/plugin-techdocs-react';\nimport { useLocation } from 'react-router-dom';\n\ntype Props = {\n errorMessage?: string;\n};\n\nexport const TechDocsNotFound = ({ errorMessage }: Props) => {\n const techdocsBuilder =\n useApi(configApiRef).getOptionalString('techdocs.builder');\n const analyticsApi = useAnalytics();\n const { entityRef } = useTechDocsReaderPage();\n const location = useLocation();\n\n useEffect(() => {\n const { pathname, search, hash } = location;\n analyticsApi.captureEvent('not-found', `${pathname}${search}${hash}`, {\n attributes: entityRef,\n });\n }, [analyticsApi, entityRef, location]);\n\n let additionalInfo = '';\n if (![undefined, 'local'].includes(techdocsBuilder)) {\n additionalInfo =\n \"Note that techdocs.builder is not set to 'local' in your config, which means this Backstage app will not \" +\n \"generate docs if they are not found. Make sure the project's docs are generated and published by some external \" +\n \"process (e.g. CI/CD pipeline). Or change techdocs.builder to 'local' to generate docs from this Backstage \" +\n 'instance.';\n }\n\n return (\n <ErrorPage\n status=\"404\"\n statusMessage={errorMessage || 'Documentation not found'}\n additionalInfo={additionalInfo}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;AA0BO,MAAM,gBAAmB,GAAA,CAAC,EAAE,YAAA,EAA0B,KAAA;AAC3D,EAAA,MAAM,eACJ,GAAA,MAAA,CAAO,YAAY,CAAA,CAAE,kBAAkB,kBAAkB,CAAA;AAC3D,EAAA,MAAM,eAAe,YAAa,EAAA;AAClC,EAAM,MAAA,EAAE,SAAU,EAAA,GAAI,qBAAsB,EAAA;AAC5C,EAAA,MAAM,WAAW,WAAY,EAAA;AAE7B,EAAA,SAAA,CAAU,MAAM;AACd,IAAA,MAAM,EAAE,QAAA,EAAU,MAAQ,EAAA,IAAA,EAAS,GAAA,QAAA;AACnC,IAAa,YAAA,CAAA,YAAA,CAAa,aAAa,CAAG,EAAA,QAAQ,GAAG,MAAM,CAAA,EAAG,IAAI,CAAI,CAAA,EAAA;AAAA,MACpE,UAAY,EAAA;AAAA,KACb,CAAA;AAAA,GACA,EAAA,CAAC,YAAc,EAAA,SAAA,EAAW,QAAQ,CAAC,CAAA;AAEtC,EAAA,IAAI,cAAiB,GAAA,EAAA;AACrB,EAAA,IAAI,CAAC,CAAC,KAAA,CAAA,EAAW,OAAO,CAAE,CAAA,QAAA,CAAS,eAAe,CAAG,EAAA;AACnD,IACE,cAAA,GAAA,6UAAA;AAAA;AAMJ,EACE,uBAAA,GAAA;AAAA,IAAC,SAAA;AAAA,IAAA;AAAA,MACC,MAAO,EAAA,KAAA;AAAA,MACP,eAAe,YAAgB,IAAA,yBAAA;AAAA,MAC/B;AAAA;AAAA,GACF;AAEJ;;;;"}
@@ -1,4 +1,5 @@
1
- import React, { Children } from 'react';
1
+ import { jsxs, jsx } from 'react/jsx-runtime';
2
+ import { Children } from 'react';
2
3
  import { useOutlet } from 'react-router-dom';
3
4
  import { Page } from '@backstage/core-components';
4
5
  import { TECHDOCS_ADDONS_WRAPPER_KEY, TECHDOCS_ADDONS_KEY, TechDocsReaderPageProvider } from '@backstage/plugin-techdocs-react';
@@ -12,7 +13,11 @@ import { styled, useTheme, createTheme, ThemeProvider } from '@material-ui/core/
12
13
 
13
14
  const TechDocsReaderLayout = (props) => {
14
15
  const { withSearch, withHeader = true } = props;
15
- return /* @__PURE__ */ React.createElement(Page, { themeId: "documentation" }, withHeader && /* @__PURE__ */ React.createElement(TechDocsReaderPageHeader, null), /* @__PURE__ */ React.createElement(TechDocsReaderPageSubheader, null), /* @__PURE__ */ React.createElement(TechDocsReaderPageContent, { withSearch }));
16
+ return /* @__PURE__ */ jsxs(Page, { themeId: "documentation", children: [
17
+ withHeader && /* @__PURE__ */ jsx(TechDocsReaderPageHeader, {}),
18
+ /* @__PURE__ */ jsx(TechDocsReaderPageSubheader, {}),
19
+ /* @__PURE__ */ jsx(TechDocsReaderPageContent, { withSearch })
20
+ ] });
16
21
  };
17
22
  const StyledPage = styled(Page)({
18
23
  height: "inherit",
@@ -35,21 +40,21 @@ const TechDocsReaderPage = (props) => {
35
40
  const page = grandChildren.find(
36
41
  (grandChild) => !getComponentData(grandChild, TECHDOCS_ADDONS_WRAPPER_KEY) && !getComponentData(grandChild, TECHDOCS_ADDONS_KEY)
37
42
  );
38
- return /* @__PURE__ */ React.createElement(ThemeProvider, { theme: readerPageTheme }, /* @__PURE__ */ React.createElement(CookieAuthRefreshProvider, { pluginId: "techdocs" }, /* @__PURE__ */ React.createElement(TechDocsReaderPageProvider, { entityRef }, page || /* @__PURE__ */ React.createElement(TechDocsReaderLayout, null))));
43
+ return /* @__PURE__ */ jsx(ThemeProvider, { theme: readerPageTheme, children: /* @__PURE__ */ jsx(CookieAuthRefreshProvider, { pluginId: "techdocs", children: /* @__PURE__ */ jsx(TechDocsReaderPageProvider, { entityRef, children: page || /* @__PURE__ */ jsx(TechDocsReaderLayout, {}) }) }) });
39
44
  }
40
- return /* @__PURE__ */ React.createElement(ThemeProvider, { theme: readerPageTheme }, /* @__PURE__ */ React.createElement(CookieAuthRefreshProvider, { pluginId: "techdocs" }, /* @__PURE__ */ React.createElement(TechDocsReaderPageProvider, { entityRef }, ({ metadata, entityMetadata, onReady }) => /* @__PURE__ */ React.createElement(
45
+ return /* @__PURE__ */ jsx(ThemeProvider, { theme: readerPageTheme, children: /* @__PURE__ */ jsx(CookieAuthRefreshProvider, { pluginId: "techdocs", children: /* @__PURE__ */ jsx(TechDocsReaderPageProvider, { entityRef, children: ({ metadata, entityMetadata, onReady }) => /* @__PURE__ */ jsx(
41
46
  StyledPage,
42
47
  {
43
48
  themeId: "documentation",
44
- className: "techdocs-reader-page"
45
- },
46
- children instanceof Function ? children({
47
- entityRef,
48
- techdocsMetadataValue: metadata.value,
49
- entityMetadataValue: entityMetadata.value,
50
- onReady
51
- }) : children
52
- ))));
49
+ className: "techdocs-reader-page",
50
+ children: children instanceof Function ? children({
51
+ entityRef,
52
+ techdocsMetadataValue: metadata.value,
53
+ entityMetadataValue: entityMetadata.value,
54
+ onReady
55
+ }) : children
56
+ }
57
+ ) }) }) });
53
58
  };
54
59
 
55
60
  export { TechDocsReaderLayout, TechDocsReaderPage };