@backstage/plugin-scaffolder 1.3.0 → 1.4.0-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.
- package/CHANGELOG.md +65 -0
- package/alpha/package.json +1 -1
- package/dist/esm/{Router-2a5afa3f.esm.js → Router-fbba0f54.esm.js} +18 -13
- package/dist/esm/Router-fbba0f54.esm.js.map +1 -0
- package/dist/esm/{default-6ab4a4ed.esm.js → default-a258a462.esm.js} +2 -2
- package/dist/esm/{default-6ab4a4ed.esm.js.map → default-a258a462.esm.js.map} +1 -1
- package/dist/esm/{index-6712a69a.esm.js → index-a2c4b694.esm.js} +61 -66
- package/dist/esm/index-a2c4b694.esm.js.map +1 -0
- package/dist/esm/{index-6ce26c9f.esm.js → index-a72ba1c5.esm.js} +3 -3
- package/dist/esm/{index-6ce26c9f.esm.js.map → index-a72ba1c5.esm.js.map} +1 -1
- package/dist/index.alpha.d.ts +2 -0
- package/dist/index.beta.d.ts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.esm.js +1 -1
- package/package.json +23 -24
- package/dist/esm/Router-2a5afa3f.esm.js.map +0 -1
- package/dist/esm/index-6712a69a.esm.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,70 @@
|
|
|
1
1
|
# @backstage/plugin-scaffolder
|
|
2
2
|
|
|
3
|
+
## 1.4.0-next.2
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- d8eb82f447: Add `allowedRepos` `ui:option` to `RepoUrlPicker` component, and move `repoName` field to own component
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- e2d7b76f43: Upgrade git-url-parse to 12.0.0.
|
|
12
|
+
|
|
13
|
+
Motivation for upgrade is transitively upgrading parse-url which is vulnerable
|
|
14
|
+
to several CVEs detected by Snyk.
|
|
15
|
+
|
|
16
|
+
- SNYK-JS-PARSEURL-2935944
|
|
17
|
+
- SNYK-JS-PARSEURL-2935947
|
|
18
|
+
- SNYK-JS-PARSEURL-2936249
|
|
19
|
+
|
|
20
|
+
- 14146703e5: Add `allowArbitraryValues` to `ui:options` in `OwnedEntityPicker`, similar to `allowArbitraryValues` in `EntityPicker`
|
|
21
|
+
- Updated dependencies
|
|
22
|
+
- @backstage/core-components@0.10.0-next.2
|
|
23
|
+
- @backstage/catalog-model@1.1.0-next.2
|
|
24
|
+
- @backstage/theme@0.2.16-next.1
|
|
25
|
+
- @backstage/integration@1.2.2-next.2
|
|
26
|
+
- @backstage/plugin-catalog-react@1.1.2-next.2
|
|
27
|
+
- @backstage/integration-react@1.1.2-next.2
|
|
28
|
+
|
|
29
|
+
## 1.4.0-next.1
|
|
30
|
+
|
|
31
|
+
### Patch Changes
|
|
32
|
+
|
|
33
|
+
- Updated dependencies
|
|
34
|
+
- @backstage/core-components@0.9.6-next.1
|
|
35
|
+
- @backstage/catalog-model@1.1.0-next.1
|
|
36
|
+
- @backstage/errors@1.1.0-next.0
|
|
37
|
+
- @backstage/theme@0.2.16-next.0
|
|
38
|
+
- @backstage/catalog-client@1.0.4-next.1
|
|
39
|
+
- @backstage/integration@1.2.2-next.1
|
|
40
|
+
- @backstage/integration-react@1.1.2-next.1
|
|
41
|
+
- @backstage/plugin-catalog-common@1.0.4-next.0
|
|
42
|
+
- @backstage/plugin-catalog-react@1.1.2-next.1
|
|
43
|
+
- @backstage/plugin-permission-react@0.4.3-next.0
|
|
44
|
+
|
|
45
|
+
## 1.4.0-next.0
|
|
46
|
+
|
|
47
|
+
### Minor Changes
|
|
48
|
+
|
|
49
|
+
- 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.
|
|
50
|
+
|
|
51
|
+
To support the new template editor the `ScaffolderApi` now has an optional `dryRun` method, which is implemented by the default `ScaffolderClient`.
|
|
52
|
+
|
|
53
|
+
### Patch Changes
|
|
54
|
+
|
|
55
|
+
- 37539e29d8: The template editor now shows the cause of request errors that happen during a dry-run.
|
|
56
|
+
- 842282ecf9: Bumped `codemirror` dependencies to `v6.0.0`.
|
|
57
|
+
- 464bb0e6c8: The max content size for dry-run files has been reduced from 256k to 64k.
|
|
58
|
+
- a7c0b34d70: Swap usage of `MaterialTable` with `Table` from `core-components`
|
|
59
|
+
- Updated dependencies
|
|
60
|
+
- @backstage/catalog-model@1.1.0-next.0
|
|
61
|
+
- @backstage/core-components@0.9.6-next.0
|
|
62
|
+
- @backstage/integration@1.2.2-next.0
|
|
63
|
+
- @backstage/catalog-client@1.0.4-next.0
|
|
64
|
+
- @backstage/plugin-catalog-react@1.1.2-next.0
|
|
65
|
+
- @backstage/plugin-scaffolder-common@1.1.2-next.0
|
|
66
|
+
- @backstage/integration-react@1.1.2-next.0
|
|
67
|
+
|
|
3
68
|
## 1.3.0
|
|
4
69
|
|
|
5
70
|
### Minor Changes
|
package/alpha/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { useState, useContext, useCallback, createContext, useEffect, useRef, useMemo, Children, Component, Fragment } from 'react';
|
|
2
2
|
import { useNavigate, Navigate, useOutlet, Routes, Route, useParams as useParams$1 } from 'react-router';
|
|
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 } from '@backstage/core-components';
|
|
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-a2c4b694.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';
|
|
@@ -62,12 +62,11 @@ import RefreshIcon from '@material-ui/icons/Refresh';
|
|
|
62
62
|
import SaveIcon from '@material-ui/icons/Save';
|
|
63
63
|
import useDebounce from 'react-use/lib/useDebounce';
|
|
64
64
|
import { showPanel } from '@codemirror/view';
|
|
65
|
-
import MaterialTable from '@material-table/core';
|
|
66
65
|
import SettingsIcon from '@material-ui/icons/Settings';
|
|
67
66
|
import AllIcon from '@material-ui/icons/FontDownload';
|
|
68
67
|
import { DateTime, Interval } from 'luxon';
|
|
69
68
|
import humanizeDuration from 'humanize-duration';
|
|
70
|
-
import { D as DEFAULT_SCAFFOLDER_FIELD_EXTENSIONS } from './default-
|
|
69
|
+
import { D as DEFAULT_SCAFFOLDER_FIELD_EXTENSIONS } from './default-a258a462.esm.js';
|
|
71
70
|
import '@backstage/errors';
|
|
72
71
|
import 'zen-observable';
|
|
73
72
|
import '@material-ui/core/FormControl';
|
|
@@ -1149,8 +1148,8 @@ function DirectoryEditorProvider(props) {
|
|
|
1149
1148
|
}, props.children);
|
|
1150
1149
|
}
|
|
1151
1150
|
|
|
1152
|
-
const MAX_CONTENT_SIZE =
|
|
1153
|
-
const CHUNK_SIZE =
|
|
1151
|
+
const MAX_CONTENT_SIZE = 64 * 1024;
|
|
1152
|
+
const CHUNK_SIZE = 32 * 1024;
|
|
1154
1153
|
const DryRunContext = createContext(void 0);
|
|
1155
1154
|
function base64EncodeContent(content) {
|
|
1156
1155
|
if (content.length > MAX_CONTENT_SIZE) {
|
|
@@ -1776,11 +1775,17 @@ function TemplateEditorFormDirectoryEditorDryRun(props) {
|
|
|
1776
1775
|
if (!selectedFile) {
|
|
1777
1776
|
return;
|
|
1778
1777
|
}
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
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
|
+
}
|
|
1784
1789
|
};
|
|
1785
1790
|
const content = selectedFile && selectedFile.path.match(/\.ya?ml$/) ? selectedFile.content : void 0;
|
|
1786
1791
|
return /* @__PURE__ */ React.createElement(TemplateEditorForm, {
|
|
@@ -2268,7 +2273,7 @@ const ListTaskPageContent = (props) => {
|
|
|
2268
2273
|
return /* @__PURE__ */ React.createElement(CatalogFilterLayout, null, /* @__PURE__ */ React.createElement(CatalogFilterLayout.Filters, null, /* @__PURE__ */ React.createElement(OwnerListPicker, {
|
|
2269
2274
|
filter: ownerFilter,
|
|
2270
2275
|
onSelectOwner: (id) => setOwnerFilter(id)
|
|
2271
|
-
})), /* @__PURE__ */ React.createElement(CatalogFilterLayout.Content, null, /* @__PURE__ */ React.createElement(
|
|
2276
|
+
})), /* @__PURE__ */ React.createElement(CatalogFilterLayout.Content, null, /* @__PURE__ */ React.createElement(Table$1, {
|
|
2272
2277
|
data: (_a = value == null ? void 0 : value.tasks) != null ? _a : [],
|
|
2273
2278
|
title: "Tasks",
|
|
2274
2279
|
columns: [
|
|
@@ -2389,4 +2394,4 @@ const Router = (props) => {
|
|
|
2389
2394
|
};
|
|
2390
2395
|
|
|
2391
2396
|
export { Router };
|
|
2392
|
-
//# sourceMappingURL=Router-
|
|
2397
|
+
//# sourceMappingURL=Router-fbba0f54.esm.js.map
|