@backstage/plugin-scaffolder 0.0.0-nightly-20220621024649 → 0.0.0-nightly-20220622024934
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 +34 -4
- package/alpha/package.json +1 -1
- package/dist/esm/{Router-548144af.esm.js → Router-a85c58bd.esm.js} +16 -10
- package/dist/esm/Router-a85c58bd.esm.js.map +1 -0
- package/dist/esm/{default-9277b79f.esm.js → default-a3df1f11.esm.js} +2 -2
- package/dist/esm/{default-9277b79f.esm.js.map → default-a3df1f11.esm.js.map} +1 -1
- package/dist/esm/{index-48d8c9ad.esm.js → index-470abc37.esm.js} +3 -3
- package/dist/esm/{index-48d8c9ad.esm.js.map → index-470abc37.esm.js.map} +1 -1
- package/dist/esm/{index-f4bd4a7a.esm.js → index-eff50288.esm.js} +3 -3
- package/dist/esm/{index-f4bd4a7a.esm.js.map → index-eff50288.esm.js.map} +1 -1
- package/dist/index.esm.js +1 -1
- package/package.json +17 -17
- package/dist/esm/Router-548144af.esm.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @backstage/plugin-scaffolder
|
|
2
2
|
|
|
3
|
-
## 0.0.0-nightly-
|
|
3
|
+
## 0.0.0-nightly-20220622024934
|
|
4
4
|
|
|
5
5
|
### Minor Changes
|
|
6
6
|
|
|
@@ -10,11 +10,41 @@
|
|
|
10
10
|
|
|
11
11
|
### Patch Changes
|
|
12
12
|
|
|
13
|
+
- 37539e29d8: The template editor now shows the cause of request errors that happen during a dry-run.
|
|
14
|
+
- 842282ecf9: Bumped `codemirror` dependencies to `v6.0.0`.
|
|
15
|
+
- 464bb0e6c8: The max content size for dry-run files has been reduced from 256k to 64k.
|
|
13
16
|
- a7c0b34d70: Swap usage of `MaterialTable` with `Table` from `core-components`
|
|
14
17
|
- Updated dependencies
|
|
15
|
-
- @backstage/catalog-model@0.0.0-nightly-
|
|
16
|
-
- @backstage/core-components@0.0.0-nightly-
|
|
17
|
-
- @backstage/integration@0.0.0-nightly-
|
|
18
|
+
- @backstage/catalog-model@0.0.0-nightly-20220622024934
|
|
19
|
+
- @backstage/core-components@0.0.0-nightly-20220622024934
|
|
20
|
+
- @backstage/integration@0.0.0-nightly-20220622024934
|
|
21
|
+
- @backstage/catalog-client@0.0.0-nightly-20220622024934
|
|
22
|
+
- @backstage/integration-react@0.0.0-nightly-20220622024934
|
|
23
|
+
- @backstage/plugin-catalog-react@0.0.0-nightly-20220622024934
|
|
24
|
+
- @backstage/plugin-scaffolder-common@0.0.0-nightly-20220622024934
|
|
25
|
+
|
|
26
|
+
## 1.4.0-next.0
|
|
27
|
+
|
|
28
|
+
### Minor Changes
|
|
29
|
+
|
|
30
|
+
- 3500c13a33: A new template editor has been added which is accessible via the context menu on the top right hand corner of the Create page. It allows you to load a template from a local directory, edit it with a preview, execute it in dry-run mode, and view the results. Note that the [File System Access API](https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API) must be supported by your browser for this to be available.
|
|
31
|
+
|
|
32
|
+
To support the new template editor the `ScaffolderApi` now has an optional `dryRun` method, which is implemented by the default `ScaffolderClient`.
|
|
33
|
+
|
|
34
|
+
### Patch Changes
|
|
35
|
+
|
|
36
|
+
- 37539e29d8: The template editor now shows the cause of request errors that happen during a dry-run.
|
|
37
|
+
- 842282ecf9: Bumped `codemirror` dependencies to `v6.0.0`.
|
|
38
|
+
- 464bb0e6c8: The max content size for dry-run files has been reduced from 256k to 64k.
|
|
39
|
+
- a7c0b34d70: Swap usage of `MaterialTable` with `Table` from `core-components`
|
|
40
|
+
- Updated dependencies
|
|
41
|
+
- @backstage/catalog-model@1.1.0-next.0
|
|
42
|
+
- @backstage/core-components@0.9.6-next.0
|
|
43
|
+
- @backstage/integration@1.2.2-next.0
|
|
44
|
+
- @backstage/catalog-client@1.0.4-next.0
|
|
45
|
+
- @backstage/plugin-catalog-react@1.1.2-next.0
|
|
46
|
+
- @backstage/plugin-scaffolder-common@1.1.2-next.0
|
|
47
|
+
- @backstage/integration-react@1.1.2-next.0
|
|
18
48
|
|
|
19
49
|
## 1.3.0
|
|
20
50
|
|
package/alpha/package.json
CHANGED
|
@@ -3,7 +3,7 @@ import { useNavigate, Navigate, useOutlet, Routes, Route, useParams as useParams
|
|
|
3
3
|
import { ItemCardHeader, MarkdownContent, Button, ContentHeader, Progress, WarningPanel, Link as Link$1, Content, ItemCardGrid, Page, Header, CreateButton, SupportButton, StructuredMetadataTable, InfoCard, ErrorPage, ErrorPanel, LogViewer, StatusError, StatusOK, StatusPending, Lifecycle, EmptyState, Table as Table$1 } from '@backstage/core-components';
|
|
4
4
|
import { useRouteRef, useApi, errorApiRef, featureFlagsApiRef, useApiHolder, alertApiRef, useElementFilter } from '@backstage/core-plugin-api';
|
|
5
5
|
import { getEntityRelations, getEntitySourceLocation, FavoriteEntity, EntityRefLinks, useEntityList, EntityListProvider, CatalogFilterLayout, EntitySearchBar, EntityKindPicker, UserListPicker, EntityTagPicker, catalogApiRef, humanizeEntityRef, EntityRefLink } from '@backstage/plugin-catalog-react';
|
|
6
|
-
import { s as selectedTemplateRouteRef, e as editRouteRef, a as actionsRouteRef, b as scaffolderListTaskRouteRef, r as registerComponentRouteRef, T as TemplateTypePicker, S as SecretsContext, c as scaffolderApiRef, d as scaffolderTaskRouteRef, f as rootRouteRef, g as TaskStatusStepper, h as TaskPageLinks, F as FIELD_EXTENSION_WRAPPER_KEY, i as FIELD_EXTENSION_KEY, l as legacySelectedTemplateRouteRef, j as SecretsContextProvider, k as TaskPage } from './index-
|
|
6
|
+
import { s as selectedTemplateRouteRef, e as editRouteRef, a as actionsRouteRef, b as scaffolderListTaskRouteRef, r as registerComponentRouteRef, T as TemplateTypePicker, S as SecretsContext, c as scaffolderApiRef, d as scaffolderTaskRouteRef, f as rootRouteRef, g as TaskStatusStepper, h as TaskPageLinks, F as FIELD_EXTENSION_WRAPPER_KEY, i as FIELD_EXTENSION_KEY, l as legacySelectedTemplateRouteRef, j as SecretsContextProvider, k as TaskPage } from './index-470abc37.esm.js';
|
|
7
7
|
import { RELATION_OWNED_BY, parseEntityRef, stringifyEntityRef } from '@backstage/catalog-model';
|
|
8
8
|
import { makeStyles, useTheme, Card, CardMedia, CardContent, Box, Typography, Chip, CardActions, IconButton, Tooltip, Link, Stepper, Step, StepLabel, StepContent, Button as Button$1, Paper, LinearProgress, TableContainer, Table, TableHead, TableRow, TableCell, TableBody, Divider as Divider$1, FormControl, InputLabel, Select, MenuItem as MenuItem$1, List as List$2, ListItemIcon as ListItemIcon$1, ListItemText as ListItemText$1 } from '@material-ui/core';
|
|
9
9
|
import { scmIntegrationsApiRef, ScmIntegrationIcon } from '@backstage/integration-react';
|
|
@@ -66,7 +66,7 @@ import SettingsIcon from '@material-ui/icons/Settings';
|
|
|
66
66
|
import AllIcon from '@material-ui/icons/FontDownload';
|
|
67
67
|
import { DateTime, Interval } from 'luxon';
|
|
68
68
|
import humanizeDuration from 'humanize-duration';
|
|
69
|
-
import { D as DEFAULT_SCAFFOLDER_FIELD_EXTENSIONS } from './default-
|
|
69
|
+
import { D as DEFAULT_SCAFFOLDER_FIELD_EXTENSIONS } from './default-a3df1f11.esm.js';
|
|
70
70
|
import '@backstage/errors';
|
|
71
71
|
import 'zen-observable';
|
|
72
72
|
import '@material-ui/core/FormControl';
|
|
@@ -1148,8 +1148,8 @@ function DirectoryEditorProvider(props) {
|
|
|
1148
1148
|
}, props.children);
|
|
1149
1149
|
}
|
|
1150
1150
|
|
|
1151
|
-
const MAX_CONTENT_SIZE =
|
|
1152
|
-
const CHUNK_SIZE =
|
|
1151
|
+
const MAX_CONTENT_SIZE = 64 * 1024;
|
|
1152
|
+
const CHUNK_SIZE = 32 * 1024;
|
|
1153
1153
|
const DryRunContext = createContext(void 0);
|
|
1154
1154
|
function base64EncodeContent(content) {
|
|
1155
1155
|
if (content.length > MAX_CONTENT_SIZE) {
|
|
@@ -1775,11 +1775,17 @@ function TemplateEditorFormDirectoryEditorDryRun(props) {
|
|
|
1775
1775
|
if (!selectedFile) {
|
|
1776
1776
|
return;
|
|
1777
1777
|
}
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1778
|
+
try {
|
|
1779
|
+
await dryRun.execute({
|
|
1780
|
+
templateContent: selectedFile.content,
|
|
1781
|
+
values: data,
|
|
1782
|
+
files: directoryEditor.files
|
|
1783
|
+
});
|
|
1784
|
+
setErrorText();
|
|
1785
|
+
} catch (e) {
|
|
1786
|
+
setErrorText(String(e.cause || e));
|
|
1787
|
+
throw e;
|
|
1788
|
+
}
|
|
1783
1789
|
};
|
|
1784
1790
|
const content = selectedFile && selectedFile.path.match(/\.ya?ml$/) ? selectedFile.content : void 0;
|
|
1785
1791
|
return /* @__PURE__ */ React.createElement(TemplateEditorForm, {
|
|
@@ -2388,4 +2394,4 @@ const Router = (props) => {
|
|
|
2388
2394
|
};
|
|
2389
2395
|
|
|
2390
2396
|
export { Router };
|
|
2391
|
-
//# sourceMappingURL=Router-
|
|
2397
|
+
//# sourceMappingURL=Router-a85c58bd.esm.js.map
|