@backstage/plugin-techdocs 0.13.3 → 0.15.0
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 +112 -0
- package/dist/esm/TechDocsCustomHome-4e5e8594.esm.js +143 -0
- package/dist/esm/TechDocsCustomHome-4e5e8594.esm.js.map +1 -0
- package/dist/index.d.ts +349 -123
- package/dist/index.esm.js +1071 -841
- package/dist/index.esm.js.map +1 -1
- package/package.json +29 -26
package/dist/index.d.ts
CHANGED
|
@@ -1,22 +1,32 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { Entity, CompoundEntityRef } from '@backstage/catalog-model';
|
|
2
3
|
import * as _backstage_core_plugin_api from '@backstage/core-plugin-api';
|
|
3
4
|
import { DiscoveryApi, FetchApi, IdentityApi } from '@backstage/core-plugin-api';
|
|
4
|
-
import * as _backstage_catalog_model from '@backstage/catalog-model';
|
|
5
|
-
import { Entity, LocationSpec, EntityName } from '@backstage/catalog-model';
|
|
6
5
|
import { Config } from '@backstage/config';
|
|
7
|
-
import
|
|
6
|
+
import React, { PropsWithChildren } from 'react';
|
|
8
7
|
import { TableColumn, TableProps } from '@backstage/core-components';
|
|
9
8
|
import { UserListFilterKind } from '@backstage/plugin-catalog-react';
|
|
10
9
|
import { CSSProperties } from '@material-ui/styles';
|
|
11
|
-
import React from 'react';
|
|
12
|
-
import * as _material_table_core from '@material-table/core';
|
|
13
10
|
|
|
11
|
+
/**
|
|
12
|
+
* Metadata for TechDocs page
|
|
13
|
+
*
|
|
14
|
+
* @public
|
|
15
|
+
*/
|
|
14
16
|
declare type TechDocsMetadata = {
|
|
15
17
|
site_name: string;
|
|
16
18
|
site_description: string;
|
|
17
19
|
};
|
|
20
|
+
/**
|
|
21
|
+
* Metadata for TechDocs Entity
|
|
22
|
+
*
|
|
23
|
+
* @public
|
|
24
|
+
*/
|
|
18
25
|
declare type TechDocsEntityMetadata = Entity & {
|
|
19
|
-
locationMetadata?:
|
|
26
|
+
locationMetadata?: {
|
|
27
|
+
type: string;
|
|
28
|
+
target: string;
|
|
29
|
+
};
|
|
20
30
|
};
|
|
21
31
|
|
|
22
32
|
/**
|
|
@@ -49,9 +59,9 @@ interface TechDocsStorageApi {
|
|
|
49
59
|
getApiOrigin(): Promise<string>;
|
|
50
60
|
getStorageUrl(): Promise<string>;
|
|
51
61
|
getBuilder(): Promise<string>;
|
|
52
|
-
getEntityDocs(entityId:
|
|
53
|
-
syncEntityDocs(entityId:
|
|
54
|
-
getBaseUrl(oldBaseUrl: string, entityId:
|
|
62
|
+
getEntityDocs(entityId: CompoundEntityRef, path: string): Promise<string>;
|
|
63
|
+
syncEntityDocs(entityId: CompoundEntityRef, logHandler?: (line: string) => void): Promise<SyncResult>;
|
|
64
|
+
getBaseUrl(oldBaseUrl: string, entityId: CompoundEntityRef, path: string): Promise<string>;
|
|
55
65
|
}
|
|
56
66
|
/**
|
|
57
67
|
* API to talk to techdocs-backend.
|
|
@@ -63,8 +73,8 @@ interface TechDocsApi {
|
|
|
63
73
|
* Set to techdocs.requestUrl as the URL for techdocs-backend API.
|
|
64
74
|
*/
|
|
65
75
|
getApiOrigin(): Promise<string>;
|
|
66
|
-
getTechDocsMetadata(entityId:
|
|
67
|
-
getEntityMetadata(entityId:
|
|
76
|
+
getTechDocsMetadata(entityId: CompoundEntityRef): Promise<TechDocsMetadata>;
|
|
77
|
+
getEntityMetadata(entityId: CompoundEntityRef): Promise<TechDocsEntityMetadata>;
|
|
68
78
|
}
|
|
69
79
|
|
|
70
80
|
/**
|
|
@@ -91,7 +101,7 @@ declare class TechDocsClient implements TechDocsApi {
|
|
|
91
101
|
*
|
|
92
102
|
* @param entityId - Object containing entity data like name, namespace, etc.
|
|
93
103
|
*/
|
|
94
|
-
getTechDocsMetadata(entityId:
|
|
104
|
+
getTechDocsMetadata(entityId: CompoundEntityRef): Promise<TechDocsMetadata>;
|
|
95
105
|
/**
|
|
96
106
|
* Retrieve metadata about an entity.
|
|
97
107
|
*
|
|
@@ -100,7 +110,7 @@ declare class TechDocsClient implements TechDocsApi {
|
|
|
100
110
|
*
|
|
101
111
|
* @param entityId - Object containing entity data like name, namespace, etc.
|
|
102
112
|
*/
|
|
103
|
-
getEntityMetadata(entityId:
|
|
113
|
+
getEntityMetadata(entityId: CompoundEntityRef): Promise<TechDocsEntityMetadata>;
|
|
104
114
|
}
|
|
105
115
|
/**
|
|
106
116
|
* API which talks to TechDocs storage to fetch files to render.
|
|
@@ -129,7 +139,7 @@ declare class TechDocsStorageClient implements TechDocsStorageApi {
|
|
|
129
139
|
* @returns HTML content of the docs page as string
|
|
130
140
|
* @throws Throws error when the page is not found.
|
|
131
141
|
*/
|
|
132
|
-
getEntityDocs(entityId:
|
|
142
|
+
getEntityDocs(entityId: CompoundEntityRef, path: string): Promise<string>;
|
|
133
143
|
/**
|
|
134
144
|
* Check if docs are on the latest version and trigger rebuild if not
|
|
135
145
|
*
|
|
@@ -138,83 +148,267 @@ declare class TechDocsStorageClient implements TechDocsStorageApi {
|
|
|
138
148
|
* @returns Whether documents are currently synchronized to newest version
|
|
139
149
|
* @throws Throws error on error from sync endpoint in Techdocs Backend
|
|
140
150
|
*/
|
|
141
|
-
syncEntityDocs(entityId:
|
|
142
|
-
getBaseUrl(oldBaseUrl: string, entityId:
|
|
151
|
+
syncEntityDocs(entityId: CompoundEntityRef, logHandler?: (line: string) => void): Promise<SyncResult>;
|
|
152
|
+
getBaseUrl(oldBaseUrl: string, entityId: CompoundEntityRef, path: string): Promise<string>;
|
|
143
153
|
}
|
|
144
154
|
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
155
|
+
/**
|
|
156
|
+
* Props for {@link Reader}
|
|
157
|
+
*
|
|
158
|
+
* @public
|
|
159
|
+
*/
|
|
160
|
+
declare type ReaderProps = {
|
|
161
|
+
entityRef: CompoundEntityRef;
|
|
162
|
+
withSearch?: boolean;
|
|
163
|
+
onReady?: () => void;
|
|
164
|
+
};
|
|
165
|
+
/**
|
|
166
|
+
* Component responsible for rendering TechDocs documentation
|
|
167
|
+
*
|
|
168
|
+
* @public
|
|
169
|
+
*/
|
|
170
|
+
declare const Reader: (props: ReaderProps) => JSX.Element;
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* Helper function that gives the children of {@link TechDocsReaderPage} access to techdocs and entity metadata
|
|
174
|
+
*
|
|
175
|
+
* @public
|
|
176
|
+
*/
|
|
177
|
+
declare type TechDocsReaderPageRenderFunction = ({ techdocsMetadataValue, entityMetadataValue, entityRef, }: {
|
|
178
|
+
techdocsMetadataValue?: TechDocsMetadata | undefined;
|
|
179
|
+
entityMetadataValue?: TechDocsEntityMetadata | undefined;
|
|
180
|
+
entityRef: CompoundEntityRef;
|
|
181
|
+
onReady: () => void;
|
|
151
182
|
}) => JSX.Element;
|
|
183
|
+
/**
|
|
184
|
+
* Props for {@link TechDocsReaderPage}
|
|
185
|
+
*
|
|
186
|
+
* @public
|
|
187
|
+
*/
|
|
188
|
+
declare type TechDocsReaderPageProps = {
|
|
189
|
+
children?: TechDocsReaderPageRenderFunction | React.ReactNode;
|
|
190
|
+
};
|
|
191
|
+
/**
|
|
192
|
+
* @public
|
|
193
|
+
* @deprecated use {@link TechDocsReaderPage} instead
|
|
194
|
+
*/
|
|
195
|
+
declare const TechDocsPage: (props: TechDocsReaderPageProps) => JSX.Element;
|
|
196
|
+
/**
|
|
197
|
+
* @public
|
|
198
|
+
* @deprecated use {@link TechDocsReaderPageRenderFunction} instead
|
|
199
|
+
*/
|
|
200
|
+
declare type TechDocsPageRenderFunction = TechDocsReaderPageRenderFunction;
|
|
201
|
+
|
|
202
|
+
/**
|
|
203
|
+
* Props for {@link TechDocsReaderPageHeader}
|
|
204
|
+
*
|
|
205
|
+
* @public
|
|
206
|
+
*/
|
|
207
|
+
declare type TechDocsReaderPageHeaderProps = PropsWithChildren<{
|
|
208
|
+
entityRef: CompoundEntityRef;
|
|
209
|
+
entityMetadata?: TechDocsEntityMetadata;
|
|
210
|
+
techDocsMetadata?: TechDocsMetadata;
|
|
211
|
+
}>;
|
|
212
|
+
/**
|
|
213
|
+
* Component responsible for rendering a Header with metadata on TechDocs reader page.
|
|
214
|
+
*
|
|
215
|
+
* @public
|
|
216
|
+
*/
|
|
217
|
+
declare const TechDocsReaderPageHeader: (props: TechDocsReaderPageHeaderProps) => JSX.Element;
|
|
218
|
+
/**
|
|
219
|
+
* @public
|
|
220
|
+
* @deprecated use {@link TechDocsReaderPageHeader} instead
|
|
221
|
+
*/
|
|
222
|
+
declare const TechDocsPageHeader: (props: TechDocsReaderPageHeaderProps) => JSX.Element;
|
|
223
|
+
/**
|
|
224
|
+
* @public
|
|
225
|
+
* @deprecated use {@link TechDocsReaderPageHeader} instead
|
|
226
|
+
*/
|
|
227
|
+
declare type TechDocsPageHeaderProps = TechDocsReaderPageHeaderProps;
|
|
228
|
+
|
|
229
|
+
/**
|
|
230
|
+
* Props for {@link TechDocsSearchResultListItem}.
|
|
231
|
+
*
|
|
232
|
+
* @public
|
|
233
|
+
*/
|
|
234
|
+
declare type TechDocsSearchResultListItemProps = {
|
|
235
|
+
result: any;
|
|
236
|
+
lineClamp?: number;
|
|
237
|
+
asListItem?: boolean;
|
|
238
|
+
asLink?: boolean;
|
|
239
|
+
title?: string;
|
|
240
|
+
};
|
|
241
|
+
/**
|
|
242
|
+
* Component which renders documentation and related metadata.
|
|
243
|
+
*
|
|
244
|
+
* @public
|
|
245
|
+
*/
|
|
246
|
+
declare const TechDocsSearchResultListItem: (props: TechDocsSearchResultListItemProps) => JSX.Element;
|
|
247
|
+
/**
|
|
248
|
+
* @public
|
|
249
|
+
* @deprecated use {@link TechDocsSearchResultListItem} instead
|
|
250
|
+
*/
|
|
251
|
+
declare const DocsResultListItem: (props: TechDocsSearchResultListItemProps) => JSX.Element;
|
|
252
|
+
|
|
253
|
+
/**
|
|
254
|
+
* Props for {@link TechDocsSearch}
|
|
255
|
+
*
|
|
256
|
+
* @public
|
|
257
|
+
*/
|
|
258
|
+
declare type TechDocsSearchProps = {
|
|
259
|
+
entityId: CompoundEntityRef;
|
|
260
|
+
debounceTime?: number;
|
|
261
|
+
};
|
|
262
|
+
/**
|
|
263
|
+
* Component used to render search bar on TechDocs page, scoped to
|
|
264
|
+
*
|
|
265
|
+
* @public
|
|
266
|
+
*/
|
|
267
|
+
declare const TechDocsSearch: (props: TechDocsSearchProps) => JSX.Element;
|
|
152
268
|
|
|
269
|
+
/**
|
|
270
|
+
* Component responsible to get entities from entity list context and pass down to DocsCardGrid
|
|
271
|
+
*
|
|
272
|
+
* @public
|
|
273
|
+
*/
|
|
274
|
+
declare const EntityListDocsGrid: () => JSX.Element;
|
|
275
|
+
|
|
276
|
+
/**
|
|
277
|
+
* Props for {@link DocsCardGrid}
|
|
278
|
+
*
|
|
279
|
+
* @public
|
|
280
|
+
*/
|
|
281
|
+
declare type DocsCardGridProps = {
|
|
282
|
+
entities: Entity[] | undefined;
|
|
283
|
+
};
|
|
284
|
+
/**
|
|
285
|
+
* Component which accepts a list of entities and renders a item card for each entity
|
|
286
|
+
*
|
|
287
|
+
* @public
|
|
288
|
+
*/
|
|
289
|
+
declare const DocsCardGrid: (props: DocsCardGridProps) => JSX.Element | null;
|
|
290
|
+
|
|
291
|
+
/**
|
|
292
|
+
* Generic representing the metadata structure for a docs table row.
|
|
293
|
+
*
|
|
294
|
+
* @public
|
|
295
|
+
*/
|
|
153
296
|
declare type DocsTableRow = {
|
|
154
297
|
entity: Entity;
|
|
155
298
|
resolved: {
|
|
156
299
|
docsUrl: string;
|
|
157
300
|
ownedByRelationsTitle: string;
|
|
158
|
-
ownedByRelations:
|
|
301
|
+
ownedByRelations: CompoundEntityRef[];
|
|
159
302
|
};
|
|
160
303
|
};
|
|
161
304
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
305
|
+
/**
|
|
306
|
+
* Props for {@link EntityListDocsTable}.
|
|
307
|
+
*
|
|
308
|
+
* @public
|
|
309
|
+
*/
|
|
310
|
+
declare type EntityListDocsTableProps = {
|
|
311
|
+
columns?: TableColumn<DocsTableRow>[];
|
|
165
312
|
actions?: TableProps<DocsTableRow>['actions'];
|
|
166
|
-
}) => JSX.Element;
|
|
167
|
-
|
|
168
|
-
declare const EntityListDocsGrid: () => JSX.Element;
|
|
169
|
-
|
|
170
|
-
declare function createCopyDocsUrlAction(copyToClipboard: Function): (row: DocsTableRow) => {
|
|
171
|
-
icon: () => JSX.Element;
|
|
172
|
-
tooltip: string;
|
|
173
|
-
onClick: () => any;
|
|
174
313
|
};
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
314
|
+
/**
|
|
315
|
+
* Component which renders a table with entities from catalog.
|
|
316
|
+
*
|
|
317
|
+
* @public
|
|
318
|
+
*/
|
|
319
|
+
declare const EntityListDocsTable: {
|
|
320
|
+
(props: EntityListDocsTableProps): JSX.Element;
|
|
321
|
+
columns: {
|
|
322
|
+
createNameColumn(): TableColumn<DocsTableRow>;
|
|
323
|
+
createOwnerColumn(): TableColumn<DocsTableRow>;
|
|
324
|
+
createTypeColumn(): TableColumn<DocsTableRow>;
|
|
325
|
+
};
|
|
326
|
+
actions: {
|
|
327
|
+
createCopyDocsUrlAction(copyToClipboard: Function): (row: DocsTableRow) => {
|
|
328
|
+
icon: () => JSX.Element;
|
|
329
|
+
tooltip: string;
|
|
330
|
+
onClick: () => any;
|
|
331
|
+
};
|
|
332
|
+
createStarEntityAction(isStarredEntity: Function, toggleStarredEntity: Function): ({ entity }: DocsTableRow) => {
|
|
333
|
+
cellStyle: {
|
|
334
|
+
paddingLeft: string;
|
|
335
|
+
};
|
|
336
|
+
icon: () => JSX.Element;
|
|
337
|
+
tooltip: string;
|
|
338
|
+
onClick: () => any;
|
|
339
|
+
};
|
|
178
340
|
};
|
|
179
|
-
icon: () => JSX.Element;
|
|
180
|
-
tooltip: string;
|
|
181
|
-
onClick: () => any;
|
|
182
341
|
};
|
|
183
342
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
343
|
+
/**
|
|
344
|
+
* Props for {@link DocsTable}.
|
|
345
|
+
*
|
|
346
|
+
* @public
|
|
347
|
+
*/
|
|
348
|
+
declare type DocsTableProps = {
|
|
349
|
+
entities: Entity[] | undefined;
|
|
350
|
+
title?: string | undefined;
|
|
351
|
+
loading?: boolean | undefined;
|
|
352
|
+
columns?: TableColumn<DocsTableRow>[];
|
|
353
|
+
actions?: TableProps<DocsTableRow>['actions'];
|
|
354
|
+
};
|
|
355
|
+
/**
|
|
356
|
+
* Component which renders a table documents
|
|
357
|
+
*
|
|
358
|
+
* @public
|
|
359
|
+
*/
|
|
360
|
+
declare const DocsTable: {
|
|
361
|
+
(props: DocsTableProps): JSX.Element | null;
|
|
362
|
+
columns: {
|
|
363
|
+
createNameColumn(): TableColumn<DocsTableRow>;
|
|
364
|
+
createOwnerColumn(): TableColumn<DocsTableRow>;
|
|
365
|
+
createTypeColumn(): TableColumn<DocsTableRow>;
|
|
366
|
+
};
|
|
367
|
+
actions: {
|
|
368
|
+
createCopyDocsUrlAction(copyToClipboard: Function): (row: DocsTableRow) => {
|
|
369
|
+
icon: () => JSX.Element;
|
|
370
|
+
tooltip: string;
|
|
371
|
+
onClick: () => any;
|
|
372
|
+
};
|
|
373
|
+
createStarEntityAction(isStarredEntity: Function, toggleStarredEntity: Function): ({ entity }: DocsTableRow) => {
|
|
374
|
+
cellStyle: {
|
|
375
|
+
paddingLeft: string;
|
|
376
|
+
};
|
|
377
|
+
icon: () => JSX.Element;
|
|
378
|
+
tooltip: string;
|
|
379
|
+
onClick: () => any;
|
|
380
|
+
};
|
|
381
|
+
};
|
|
382
|
+
};
|
|
207
383
|
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
384
|
+
/**
|
|
385
|
+
* Props for {@link DefaultTechDocsHome}
|
|
386
|
+
*
|
|
387
|
+
* @public
|
|
388
|
+
*/
|
|
389
|
+
declare type DefaultTechDocsHomeProps = {
|
|
390
|
+
initialFilter?: UserListFilterKind;
|
|
391
|
+
columns?: TableColumn<DocsTableRow>[];
|
|
392
|
+
actions?: TableProps<DocsTableRow>['actions'];
|
|
215
393
|
};
|
|
394
|
+
/**
|
|
395
|
+
* Component which renders a default documentation landing page.
|
|
396
|
+
*
|
|
397
|
+
* @public
|
|
398
|
+
*/
|
|
399
|
+
declare const DefaultTechDocsHome: (props: DefaultTechDocsHomeProps) => JSX.Element;
|
|
216
400
|
|
|
401
|
+
/**
|
|
402
|
+
* Available panel types
|
|
403
|
+
*
|
|
404
|
+
* @public
|
|
405
|
+
*/
|
|
217
406
|
declare type PanelType = 'DocsCardGrid' | 'DocsTable';
|
|
407
|
+
/**
|
|
408
|
+
* Type representing a TechDocsCustomHome panel.
|
|
409
|
+
*
|
|
410
|
+
* @public
|
|
411
|
+
*/
|
|
218
412
|
interface PanelConfig {
|
|
219
413
|
title: string;
|
|
220
414
|
description: string;
|
|
@@ -222,30 +416,57 @@ interface PanelConfig {
|
|
|
222
416
|
panelCSS?: CSSProperties;
|
|
223
417
|
filterPredicate: ((entity: Entity) => boolean) | string;
|
|
224
418
|
}
|
|
419
|
+
/**
|
|
420
|
+
* Type representing a TechDocsCustomHome tab.
|
|
421
|
+
*
|
|
422
|
+
* @public
|
|
423
|
+
*/
|
|
225
424
|
interface TabConfig {
|
|
226
425
|
label: string;
|
|
227
426
|
panels: PanelConfig[];
|
|
228
427
|
}
|
|
428
|
+
/**
|
|
429
|
+
* Type representing a list of TechDocsCustomHome tabs.
|
|
430
|
+
*
|
|
431
|
+
* @public
|
|
432
|
+
*/
|
|
229
433
|
declare type TabsConfig = TabConfig[];
|
|
434
|
+
/**
|
|
435
|
+
* Props for {@link TechDocsCustomHome}
|
|
436
|
+
*
|
|
437
|
+
* @public
|
|
438
|
+
*/
|
|
439
|
+
declare type TechDocsCustomHomeProps = {
|
|
440
|
+
tabsConfig: TabsConfig;
|
|
441
|
+
};
|
|
230
442
|
|
|
231
|
-
|
|
443
|
+
/**
|
|
444
|
+
* Props for {@link TechDocsPageWrapper}
|
|
445
|
+
*
|
|
446
|
+
* @public
|
|
447
|
+
*/
|
|
448
|
+
declare type TechDocsPageWrapperProps = {
|
|
232
449
|
children?: React.ReactNode;
|
|
233
450
|
};
|
|
234
|
-
|
|
451
|
+
/**
|
|
452
|
+
* Component wrapping a techdocs page with Page and Header components
|
|
453
|
+
*
|
|
454
|
+
* @public
|
|
455
|
+
*/
|
|
456
|
+
declare const TechDocsPageWrapper: (props: TechDocsPageWrapperProps) => JSX.Element;
|
|
235
457
|
|
|
458
|
+
/**
|
|
459
|
+
* Component responsible for updating TechDocs filters
|
|
460
|
+
*
|
|
461
|
+
* @public
|
|
462
|
+
*/
|
|
236
463
|
declare const TechDocsPicker: () => null;
|
|
237
464
|
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
}) => JSX.Element;
|
|
244
|
-
declare type TechDocsPageProps = {
|
|
245
|
-
children?: TechDocsPageRenderFunction | React.ReactNode;
|
|
246
|
-
};
|
|
247
|
-
declare const TechDocsPage: ({ children }: TechDocsPageProps) => JSX.Element;
|
|
248
|
-
|
|
465
|
+
/**
|
|
466
|
+
* The Backstage plugin that renders technical documentation for your components
|
|
467
|
+
*
|
|
468
|
+
* @public
|
|
469
|
+
*/
|
|
249
470
|
declare const techdocsPlugin: _backstage_core_plugin_api.BackstagePlugin<{
|
|
250
471
|
root: _backstage_core_plugin_api.RouteRef<undefined>;
|
|
251
472
|
docRoot: _backstage_core_plugin_api.RouteRef<{
|
|
@@ -255,49 +476,54 @@ declare const techdocsPlugin: _backstage_core_plugin_api.BackstagePlugin<{
|
|
|
255
476
|
}>;
|
|
256
477
|
entityContent: _backstage_core_plugin_api.RouteRef<undefined>;
|
|
257
478
|
}, {}>;
|
|
479
|
+
/**
|
|
480
|
+
* Routable extension used to render docs
|
|
481
|
+
*
|
|
482
|
+
* @public
|
|
483
|
+
*/
|
|
258
484
|
declare const TechdocsPage: () => JSX.Element;
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
tabsConfig: TabsConfig;
|
|
277
|
-
}) => JSX.Element;
|
|
485
|
+
/**
|
|
486
|
+
* Routable extension used to render docs on Entity page
|
|
487
|
+
*
|
|
488
|
+
* @public
|
|
489
|
+
*/
|
|
490
|
+
declare const EntityTechdocsContent: () => JSX.Element;
|
|
491
|
+
/**
|
|
492
|
+
* Component which takes a custom tabs config object and renders a documentation landing page.
|
|
493
|
+
*
|
|
494
|
+
* @public
|
|
495
|
+
*/
|
|
496
|
+
declare const TechDocsCustomHome: (props: TechDocsCustomHomeProps) => JSX.Element;
|
|
497
|
+
/**
|
|
498
|
+
* Responsible for rendering the provided router element
|
|
499
|
+
*
|
|
500
|
+
* @public
|
|
501
|
+
*/
|
|
278
502
|
declare const TechDocsIndexPage: () => JSX.Element;
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
};
|
|
286
|
-
declare const Reader: ({ entityRef, onReady, withSearch, }: Props$1) => JSX.Element;
|
|
287
|
-
|
|
288
|
-
declare type TechDocsPageHeaderProps = {
|
|
289
|
-
entityRef: EntityName;
|
|
290
|
-
entityMetadata?: TechDocsEntityMetadata;
|
|
291
|
-
techDocsMetadata?: TechDocsMetadata;
|
|
292
|
-
};
|
|
293
|
-
declare const TechDocsPageHeader: ({ entityRef, entityMetadata, techDocsMetadata, }: TechDocsPageHeaderProps) => JSX.Element;
|
|
503
|
+
/**
|
|
504
|
+
* Component responsible for composing a TechDocs reader page experience
|
|
505
|
+
*
|
|
506
|
+
* @public
|
|
507
|
+
*/
|
|
508
|
+
declare const TechDocsReaderPage: (props: TechDocsReaderPageProps) => JSX.Element;
|
|
294
509
|
|
|
510
|
+
/**
|
|
511
|
+
* Helper that takes in entity and returns true/false if TechDocs is available for the entity
|
|
512
|
+
*
|
|
513
|
+
* @public
|
|
514
|
+
*/
|
|
295
515
|
declare const isTechDocsAvailable: (entity: Entity) => boolean;
|
|
516
|
+
/**
|
|
517
|
+
* Responsible for registering routes for TechDocs, TechDocs Homepage and separate TechDocs page
|
|
518
|
+
*
|
|
519
|
+
* @public
|
|
520
|
+
*/
|
|
296
521
|
declare const Router: () => JSX.Element;
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
522
|
+
/**
|
|
523
|
+
* Responsible for registering route to view docs on Entity page
|
|
524
|
+
*
|
|
525
|
+
* @public
|
|
526
|
+
*/
|
|
527
|
+
declare const EmbeddedDocsRouter: () => JSX.Element;
|
|
302
528
|
|
|
303
|
-
export { DefaultTechDocsHome, DocsCardGrid, DocsResultListItem, DocsTable, DocsTableRow, EmbeddedDocsRouter, EntityListDocsGrid, EntityListDocsTable, EntityTechdocsContent, PanelType, Reader, Router, SyncResult, TechDocsApi, TechDocsClient, TechDocsCustomHome, TechDocsIndexPage, TechDocsPage, TechDocsPageHeader, TechDocsPageHeaderProps,
|
|
529
|
+
export { DefaultTechDocsHome, DefaultTechDocsHomeProps, DocsCardGrid, DocsCardGridProps, DocsResultListItem, DocsTable, DocsTableProps, DocsTableRow, EmbeddedDocsRouter, EntityListDocsGrid, EntityListDocsTable, EntityListDocsTableProps, EntityTechdocsContent, PanelConfig, PanelType, Reader, ReaderProps, Router, SyncResult, TabConfig, TabsConfig, TechDocsApi, TechDocsClient, TechDocsCustomHome, TechDocsCustomHomeProps, TechDocsEntityMetadata, TechDocsIndexPage, TechDocsMetadata, TechDocsPage, TechDocsPageHeader, TechDocsPageHeaderProps, TechDocsPageRenderFunction, TechDocsPageWrapper, TechDocsPageWrapperProps, TechDocsPicker, TechDocsReaderPage, TechDocsReaderPageHeader, TechDocsReaderPageHeaderProps, TechDocsReaderPageProps, TechDocsReaderPageRenderFunction, TechDocsSearch, TechDocsSearchProps, TechDocsSearchResultListItem, TechDocsSearchResultListItemProps, TechDocsStorageApi, TechDocsStorageClient, TechdocsPage, isTechDocsAvailable, techdocsPlugin as plugin, techdocsApiRef, techdocsPlugin, techdocsStorageApiRef };
|