@backstage/plugin-techdocs 0.11.2 → 0.12.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,77 @@
1
1
  # @backstage/plugin-techdocs
2
2
 
3
+ ## 0.12.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 76fef740fe: Refactored `<Reader />` component internals to support future extensibility.
8
+ - Updated dependencies
9
+ - @backstage/plugin-catalog-react@0.6.0
10
+ - @backstage/plugin-catalog@0.7.1
11
+ - @backstage/integration@0.6.8
12
+ - @backstage/core-components@0.7.0
13
+ - @backstage/theme@0.2.11
14
+ - @backstage/plugin-search@0.4.15
15
+ - @backstage/integration-react@0.1.12
16
+
17
+ ## 0.12.1
18
+
19
+ ### Patch Changes
20
+
21
+ - 81a41ec249: Added a `name` key to all extensions in order to improve Analytics API metadata.
22
+ - Updated dependencies
23
+ - @backstage/core-components@0.6.1
24
+ - @backstage/core-plugin-api@0.1.10
25
+ - @backstage/plugin-catalog@0.7.0
26
+ - @backstage/plugin-catalog-react@0.5.2
27
+ - @backstage/catalog-model@0.9.4
28
+ - @backstage/integration@0.6.7
29
+ - @backstage/plugin-search@0.4.14
30
+
31
+ ## 0.12.0
32
+
33
+ ### Minor Changes
34
+
35
+ - 82bb0842a3: Adds support for being able to customize and compose your TechDocs reader page in the App.
36
+
37
+ You can likely upgrade to this version without issue. If, however, you have
38
+ imported the `<Reader />` component in your custom code, the name of a property
39
+ has changed. You will need to make the following change anywhere you use it:
40
+
41
+ ```diff
42
+ -<Reader entityId={value} />
43
+ +<Reader entityRef={value} />
44
+ ```
45
+
46
+ ### Patch Changes
47
+
48
+ - 79ebee7a6b: Add "data-testid" for e2e tests and fix techdocs entity not found error.
49
+ - 3df2e8532b: Fixed the URL for the "Click to copy documentation link to clipboard" action
50
+ - 0a8bec0877: Added a check for the TechDocs annotation on the entity
51
+ - Updated dependencies
52
+ - @backstage/integration@0.6.6
53
+ - @backstage/core-plugin-api@0.1.9
54
+ - @backstage/core-components@0.6.0
55
+ - @backstage/integration-react@0.1.11
56
+ - @backstage/plugin-catalog@0.6.17
57
+ - @backstage/plugin-catalog-react@0.5.1
58
+ - @backstage/plugin-search@0.4.13
59
+
60
+ ## 0.11.3
61
+
62
+ ### Patch Changes
63
+
64
+ - be13dfe61a: Make techdocs context search bar width adjust on smaller screens.
65
+ - Updated dependencies
66
+ - @backstage/core-components@0.5.0
67
+ - @backstage/integration@0.6.5
68
+ - @backstage/plugin-catalog@0.6.16
69
+ - @backstage/plugin-catalog-react@0.5.0
70
+ - @backstage/catalog-model@0.9.3
71
+ - @backstage/config@0.1.10
72
+ - @backstage/integration-react@0.1.10
73
+ - @backstage/plugin-search@0.4.12
74
+
3
75
  ## 0.11.2
4
76
 
5
77
  ### Patch Changes
package/README.md CHANGED
@@ -2,12 +2,12 @@
2
2
 
3
3
  ## Getting started
4
4
 
5
- Set up Backstage and TechDocs by follow our guide on [Getting Started](../../docs/features/techdocs/getting-started.md).
5
+ Set up Backstage and TechDocs by following our guide on [Getting Started](../../docs/features/techdocs/getting-started.md).
6
6
 
7
7
  ## Configuration
8
8
 
9
- http://backstage.io/docs/features/techdocs/configuration
9
+ Refer to our [configuration reference](../../docs/features/techdocs/configuration.md) for a complete listing of configuration options.
10
10
 
11
- ### TechDocs Storage Api
11
+ ### TechDocs Storage API
12
12
 
13
- The default setup of TechDocs assumes your documentation is accessed by reading a page with the format of `<storageUrl>/<entity kind>/<entity namespace>/<entity name>`. If for some reason you want to change this it can be configured by implementing a new techdocs storage API. Do this by implementing TechDocsStorage found in `plugins/techdocs/src/api`. Add your new API to the application in `app/src/apis.ts` (or replace if it's already registered as an API).
13
+ The default setup of TechDocs assumes that your documentation is accessed by reading a page with the format of `<storageUrl>/<entity kind>/<entity namespace>/<entity name>`. This can be configured by [implementing a new techdocs storage API](https://backstage.io/docs/features/techdocs/how-to-guides#how-to-implement-your-own-techdocs-apis).
package/dist/index.d.ts CHANGED
@@ -200,6 +200,17 @@ declare const DocsResultListItem: ({ result, lineClamp, asListItem, asLink, titl
200
200
  title?: string | undefined;
201
201
  }) => JSX.Element;
202
202
 
203
+ declare type TechDocsPageRenderFunction = ({ techdocsMetadataValue, entityMetadataValue, entityRef, }: {
204
+ techdocsMetadataValue?: TechDocsMetadata | undefined;
205
+ entityMetadataValue?: TechDocsEntityMetadata | undefined;
206
+ entityRef: EntityName;
207
+ onReady: () => void;
208
+ }) => JSX.Element;
209
+ declare type TechDocsPageProps = {
210
+ children?: TechDocsPageRenderFunction | React.ReactNode;
211
+ };
212
+ declare const TechDocsPage: ({ children }: TechDocsPageProps) => JSX.Element;
213
+
203
214
  declare const techdocsPlugin: _backstage_core_plugin_api.BackstagePlugin<{
204
215
  root: _backstage_core_plugin_api.RouteRef<undefined>;
205
216
  docRoot: _backstage_core_plugin_api.RouteRef<{
@@ -230,15 +241,23 @@ declare const TechDocsCustomHome: ({ tabsConfig, }: {
230
241
  tabsConfig: TabsConfig;
231
242
  }) => JSX.Element;
232
243
  declare const TechDocsIndexPage: () => JSX.Element;
233
- declare const TechDocsReaderPage: () => JSX.Element;
244
+ declare const TechDocsReaderPage: ({ children }: TechDocsPageProps) => JSX.Element;
234
245
 
235
246
  declare type Props$1 = {
236
- entityId: EntityName;
237
- onReady?: () => void;
247
+ entityRef: EntityName;
238
248
  withSearch?: boolean;
249
+ onReady?: () => void;
250
+ };
251
+ declare const Reader: ({ entityRef, onReady, withSearch, }: Props$1) => JSX.Element;
252
+
253
+ declare type TechDocsPageHeaderProps = {
254
+ entityRef: EntityName;
255
+ entityMetadata?: TechDocsEntityMetadata;
256
+ techDocsMetadata?: TechDocsMetadata;
239
257
  };
240
- declare const Reader: ({ entityId, onReady, withSearch }: Props$1) => JSX.Element;
258
+ declare const TechDocsPageHeader: ({ entityRef, entityMetadata, techDocsMetadata, }: TechDocsPageHeaderProps) => JSX.Element;
241
259
 
260
+ declare const isTechDocsAvailable: (entity: Entity) => boolean;
242
261
  declare const Router: () => JSX.Element;
243
262
  declare type Props = {
244
263
  /** @deprecated The entity is now grabbed from context instead */
@@ -246,4 +265,4 @@ declare type Props = {
246
265
  };
247
266
  declare const EmbeddedDocsRouter: (_props: Props) => JSX.Element;
248
267
 
249
- export { DefaultTechDocsHome, DocsCardGrid, DocsResultListItem, DocsTable, DocsTableRow, EmbeddedDocsRouter, EntityListDocsTable, EntityTechdocsContent, PanelType, Reader, Router, SyncResult, TechDocsApi, TechDocsClient, TechDocsCustomHome, TechDocsIndexPage, TechDocsPageWrapper, TechDocsPicker, TechDocsReaderPage, TechDocsStorageApi, TechDocsStorageClient, TechdocsPage, techdocsPlugin as plugin, techdocsApiRef, techdocsPlugin, techdocsStorageApiRef };
268
+ export { DefaultTechDocsHome, DocsCardGrid, DocsResultListItem, DocsTable, DocsTableRow, EmbeddedDocsRouter, EntityListDocsTable, EntityTechdocsContent, PanelType, Reader, Router, SyncResult, TechDocsApi, TechDocsClient, TechDocsCustomHome, TechDocsIndexPage, TechDocsPage, TechDocsPageHeader, TechDocsPageHeaderProps, TechDocsPageProps, TechDocsPageRenderFunction, TechDocsPageWrapper, TechDocsPicker, TechDocsReaderPage, TechDocsStorageApi, TechDocsStorageClient, TechdocsPage, isTechDocsAvailable, techdocsPlugin as plugin, techdocsApiRef, techdocsPlugin, techdocsStorageApiRef };