@backstage-community/plugin-azure-devops 0.6.2 → 0.6.3
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 +6 -0
- package/alpha/package.json +1 -1
- package/dist/components/AzureGitTagsIcon/AzureGitTagsIcon.esm.js +1 -1
- package/dist/components/AzureGitTagsIcon/AzureGitTagsIcon.esm.js.map +1 -1
- package/dist/components/AzurePipelinesIcon/AzurePipelinesIcon.esm.js +1 -1
- package/dist/components/AzurePipelinesIcon/AzurePipelinesIcon.esm.js.map +1 -1
- package/dist/components/AzurePullRequestsIcon/AzurePullRequestsIcon.esm.js +1 -1
- package/dist/components/AzurePullRequestsIcon/AzurePullRequestsIcon.esm.js.map +1 -1
- package/dist/components/BuildTable/BuildTable.esm.js +2 -2
- package/dist/components/BuildTable/BuildTable.esm.js.map +1 -1
- package/dist/components/GitTagTable/GitTagTable.esm.js +1 -1
- package/dist/components/GitTagTable/GitTagTable.esm.js.map +1 -1
- package/dist/components/PullRequestStatusButtonGroup/PullRequestStatusButtonGroup.esm.js +5 -5
- package/dist/components/PullRequestStatusButtonGroup/PullRequestStatusButtonGroup.esm.js.map +1 -1
- package/dist/components/PullRequestTable/PullRequestTable.esm.js +2 -2
- package/dist/components/PullRequestTable/PullRequestTable.esm.js.map +1 -1
- package/dist/components/PullRequestsPage/lib/AutoCompleteIcon/AutoCompleteIcon.esm.js +2 -2
- package/dist/components/PullRequestsPage/lib/AutoCompleteIcon/AutoCompleteIcon.esm.js.map +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCard.esm.js +6 -6
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCard.esm.js.map +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicy.esm.js +5 -6
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicy.esm.js.map +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewer.esm.js +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewer.esm.js.map +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.esm.js +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.esm.js.map +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestGrid/PullRequestGrid.esm.js +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestGrid/PullRequestGrid.esm.js.map +1 -1
- package/dist/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.esm.js +4 -5
- package/dist/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.esm.js.map +1 -1
- package/dist/components/ReadmeCard/ReadmeCard.esm.js +3 -3
- package/dist/components/ReadmeCard/ReadmeCard.esm.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/package.json +3 -4
package/CHANGELOG.md
CHANGED
package/alpha/package.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import SvgIcon from '@
|
|
1
|
+
import SvgIcon from '@material-ui/core/SvgIcon';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
|
|
4
4
|
const AzureGitTagsIcon = (props) => /* @__PURE__ */ React.createElement(SvgIcon, { ...props, viewBox: "0 0 32 32" }, /* @__PURE__ */ React.createElement("path", { d: "M22.5 12C23.8807 12 25 10.8807 25 9.5C25 8.11929 23.8807 7 22.5 7C21.1193 7 20 8.11929 20 9.5C20 10.8807 21.1193 12 22.5 12ZM18.6842 3C17.6695 3 16.6927 3.38568 15.9516 4.07892L3.77041 15.4742C2.01578 17.1157 1.96966 19.8841 3.66863 21.5831L9.99455 27.909C11.6543 29.5687 14.3452 29.5687 16.005 27.909L27.8282 16.0858C28.5783 15.3356 28.9998 14.3182 28.9998 13.2574V6.5C28.9998 4.567 27.4328 3 25.4998 3H18.6842ZM17.3179 5.53946C17.6884 5.19284 18.1769 5 18.6842 5H25.4998C26.3282 5 26.9998 5.67157 26.9998 6.5V13.2574C26.9998 13.7878 26.789 14.2965 26.414 14.6716L14.5907 26.4948C13.7121 27.3735 12.2874 27.3735 11.4088 26.4948L5.08284 20.1689C4.18339 19.2694 4.20781 17.8038 5.13673 16.9348L17.3179 5.53946Z" }));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AzureGitTagsIcon.esm.js","sources":["../../../src/components/AzureGitTagsIcon/AzureGitTagsIcon.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 SvgIcon, { SvgIconProps } from '@
|
|
1
|
+
{"version":3,"file":"AzureGitTagsIcon.esm.js","sources":["../../../src/components/AzureGitTagsIcon/AzureGitTagsIcon.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 SvgIcon, { SvgIconProps } from '@material-ui/core/SvgIcon';\n\nimport React from 'react';\n\n// From https://github.com/microsoft/fluentui-system-icons/blob/30a3e3c458883a1d63a43a951407f30e6b32b60c/assets/Tag/SVG/ic_fluent_tag_32_regular.svg\nexport const AzureGitTagsIcon = (props: SvgIconProps) => (\n <SvgIcon {...props} viewBox=\"0 0 32 32\">\n <path d=\"M22.5 12C23.8807 12 25 10.8807 25 9.5C25 8.11929 23.8807 7 22.5 7C21.1193 7 20 8.11929 20 9.5C20 10.8807 21.1193 12 22.5 12ZM18.6842 3C17.6695 3 16.6927 3.38568 15.9516 4.07892L3.77041 15.4742C2.01578 17.1157 1.96966 19.8841 3.66863 21.5831L9.99455 27.909C11.6543 29.5687 14.3452 29.5687 16.005 27.909L27.8282 16.0858C28.5783 15.3356 28.9998 14.3182 28.9998 13.2574V6.5C28.9998 4.567 27.4328 3 25.4998 3H18.6842ZM17.3179 5.53946C17.6884 5.19284 18.1769 5 18.6842 5H25.4998C26.3282 5 26.9998 5.67157 26.9998 6.5V13.2574C26.9998 13.7878 26.789 14.2965 26.414 14.6716L14.5907 26.4948C13.7121 27.3735 12.2874 27.3735 11.4088 26.4948L5.08284 20.1689C4.18339 19.2694 4.20781 17.8038 5.13673 16.9348L17.3179 5.53946Z\" />\n </SvgIcon>\n);\n"],"names":[],"mappings":";;;AAqBO,MAAM,gBAAmB,GAAA,CAAC,KAC/B,qBAAA,KAAA,CAAA,aAAA,CAAC,OAAS,EAAA,EAAA,GAAG,KAAO,EAAA,OAAA,EAAQ,WAC1B,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,MAAK,EAAA,EAAA,CAAA,EAAE,ysBAAwsB,CACltB;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import SvgIcon from '@
|
|
1
|
+
import SvgIcon from '@material-ui/core/SvgIcon';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
|
|
4
4
|
const AzurePipelinesIcon = (props) => /* @__PURE__ */ React.createElement(SvgIcon, { ...props, viewBox: "0 0 512 512" }, /* @__PURE__ */ React.createElement(
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AzurePipelinesIcon.esm.js","sources":["../../../src/components/AzurePipelinesIcon/AzurePipelinesIcon.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 SvgIcon, { SvgIconProps } from '@
|
|
1
|
+
{"version":3,"file":"AzurePipelinesIcon.esm.js","sources":["../../../src/components/AzurePipelinesIcon/AzurePipelinesIcon.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 SvgIcon, { SvgIconProps } from '@material-ui/core/SvgIcon';\n\nimport React from 'react';\n\nexport const AzurePipelinesIcon = (props: SvgIconProps) => (\n <SvgIcon {...props} viewBox=\"0 0 512 512\">\n <path\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth=\"32\"\n d=\"M461.81 53.81a4.4 4.4 0 00-3.3-3.39c-54.38-13.3-180 34.09-248.13 102.17a294.9 294.9 0 00-33.09 39.08c-21-1.9-42-.3-59.88 7.5-50.49 22.2-65.18 80.18-69.28 105.07a9 9 0 009.8 10.4l81.07-8.9a180.29 180.29 0 001.1 18.3 18.15 18.15 0 005.3 11.09l31.39 31.39a18.15 18.15 0 0011.1 5.3 179.91 179.91 0 0018.19 1.1l-8.89 81a9 9 0 0010.39 9.79c24.9-4 83-18.69 105.07-69.17 7.8-17.9 9.4-38.79 7.6-59.69a293.91 293.91 0 0039.19-33.09c68.38-68 115.47-190.86 102.37-247.95zM298.66 213.67a42.7 42.7 0 1160.38 0 42.65 42.65 0 01-60.38 0z\"\n />\n <path\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth=\"32\"\n d=\"M109.64 352a45.06 45.06 0 00-26.35 12.84C65.67 382.52 64 448 64 448s65.52-1.67 83.15-19.31A44.73 44.73 0 00160 402.32\"\n />\n </SvgIcon>\n);\n"],"names":[],"mappings":";;;AAoBa,MAAA,kBAAA,GAAqB,CAAC,KACjC,qBAAA,KAAA,CAAA,aAAA,CAAC,WAAS,GAAG,KAAA,EAAO,SAAQ,aAC1B,EAAA,kBAAA,KAAA,CAAA,aAAA;AAAA,EAAC,MAAA;AAAA,EAAA;AAAA,IACC,IAAK,EAAA,MAAA;AAAA,IACL,MAAO,EAAA,cAAA;AAAA,IACP,aAAc,EAAA,OAAA;AAAA,IACd,cAAe,EAAA,OAAA;AAAA,IACf,WAAY,EAAA,IAAA;AAAA,IACZ,CAAE,EAAA,2gBAAA;AAAA,GAAA;AACJ,CACA,kBAAA,KAAA,CAAA,aAAA;AAAA,EAAC,MAAA;AAAA,EAAA;AAAA,IACC,IAAK,EAAA,MAAA;AAAA,IACL,MAAO,EAAA,cAAA;AAAA,IACP,aAAc,EAAA,OAAA;AAAA,IACd,cAAe,EAAA,OAAA;AAAA,IACf,WAAY,EAAA,IAAA;AAAA,IACZ,CAAE,EAAA,uHAAA;AAAA,GAAA;AACJ,CACF;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import SvgIcon from '@
|
|
2
|
+
import SvgIcon from '@material-ui/core/SvgIcon';
|
|
3
3
|
|
|
4
4
|
const AzurePullRequestsIcon = (props) => /* @__PURE__ */ React.createElement(SvgIcon, { ...props, viewBox: "0 0 512 512" }, /* @__PURE__ */ React.createElement(
|
|
5
5
|
"circle",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AzurePullRequestsIcon.esm.js","sources":["../../../src/components/AzurePullRequestsIcon/AzurePullRequestsIcon.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 SvgIcon, { SvgIconProps } from '@
|
|
1
|
+
{"version":3,"file":"AzurePullRequestsIcon.esm.js","sources":["../../../src/components/AzurePullRequestsIcon/AzurePullRequestsIcon.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 SvgIcon, { SvgIconProps } from '@material-ui/core/SvgIcon';\n\n/** @public */\nexport const AzurePullRequestsIcon = (props: SvgIconProps) => (\n <SvgIcon {...props} viewBox=\"0 0 512 512\">\n <circle\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth=\"32\"\n cx=\"128\"\n cy=\"416\"\n r=\"48\"\n />\n <path\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth=\"32\"\n d=\"M128 144v224M288 160l-64-64 64-64\"\n />\n <circle\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth=\"32\"\n cx=\"128\"\n cy=\"96\"\n r=\"48\"\n />\n <circle\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth=\"32\"\n cx=\"384\"\n cy=\"416\"\n r=\"48\"\n />\n <path\n fill=\"none\"\n stroke=\"currentColor\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n strokeWidth=\"32\"\n d=\"M240 96h84a60 60 0 0160 60v212\"\n />\n </SvgIcon>\n);\n"],"names":[],"mappings":";;;AAoBa,MAAA,qBAAA,GAAwB,CAAC,KACpC,qBAAA,KAAA,CAAA,aAAA,CAAC,WAAS,GAAG,KAAA,EAAO,SAAQ,aAC1B,EAAA,kBAAA,KAAA,CAAA,aAAA;AAAA,EAAC,QAAA;AAAA,EAAA;AAAA,IACC,IAAK,EAAA,MAAA;AAAA,IACL,MAAO,EAAA,cAAA;AAAA,IACP,aAAc,EAAA,OAAA;AAAA,IACd,cAAe,EAAA,OAAA;AAAA,IACf,WAAY,EAAA,IAAA;AAAA,IACZ,EAAG,EAAA,KAAA;AAAA,IACH,EAAG,EAAA,KAAA;AAAA,IACH,CAAE,EAAA,IAAA;AAAA,GAAA;AACJ,CACA,kBAAA,KAAA,CAAA,aAAA;AAAA,EAAC,MAAA;AAAA,EAAA;AAAA,IACC,IAAK,EAAA,MAAA;AAAA,IACL,MAAO,EAAA,cAAA;AAAA,IACP,aAAc,EAAA,OAAA;AAAA,IACd,cAAe,EAAA,OAAA;AAAA,IACf,WAAY,EAAA,IAAA;AAAA,IACZ,CAAE,EAAA,mCAAA;AAAA,GAAA;AACJ,CACA,kBAAA,KAAA,CAAA,aAAA;AAAA,EAAC,QAAA;AAAA,EAAA;AAAA,IACC,IAAK,EAAA,MAAA;AAAA,IACL,MAAO,EAAA,cAAA;AAAA,IACP,aAAc,EAAA,OAAA;AAAA,IACd,cAAe,EAAA,OAAA;AAAA,IACf,WAAY,EAAA,IAAA;AAAA,IACZ,EAAG,EAAA,KAAA;AAAA,IACH,EAAG,EAAA,IAAA;AAAA,IACH,CAAE,EAAA,IAAA;AAAA,GAAA;AACJ,CACA,kBAAA,KAAA,CAAA,aAAA;AAAA,EAAC,QAAA;AAAA,EAAA;AAAA,IACC,IAAK,EAAA,MAAA;AAAA,IACL,MAAO,EAAA,cAAA;AAAA,IACP,aAAc,EAAA,OAAA;AAAA,IACd,cAAe,EAAA,OAAA;AAAA,IACf,WAAY,EAAA,IAAA;AAAA,IACZ,EAAG,EAAA,KAAA;AAAA,IACH,EAAG,EAAA,KAAA;AAAA,IACH,CAAE,EAAA,IAAA;AAAA,GAAA;AACJ,CACA,kBAAA,KAAA,CAAA,aAAA;AAAA,EAAC,MAAA;AAAA,EAAA;AAAA,IACC,IAAK,EAAA,MAAA;AAAA,IACL,MAAO,EAAA,cAAA;AAAA,IACP,aAAc,EAAA,OAAA;AAAA,IACd,cAAe,EAAA,OAAA;AAAA,IACf,WAAY,EAAA,IAAA;AAAA,IACZ,CAAE,EAAA,gCAAA;AAAA,GAAA;AACJ,CACF;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import Box from '@
|
|
2
|
-
import Typography from '@
|
|
1
|
+
import Box from '@material-ui/core/Box';
|
|
2
|
+
import Typography from '@material-ui/core/Typography';
|
|
3
3
|
import { BuildStatus, BuildResult } from '@backstage-community/plugin-azure-devops-common';
|
|
4
4
|
import { ResponseErrorPanel, Table, Link, StatusWarning, StatusAborted, StatusPending, StatusRunning, StatusError, StatusOK } from '@backstage/core-components';
|
|
5
5
|
import { AzurePipelinesIcon } from '../AzurePipelinesIcon/AzurePipelinesIcon.esm.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BuildTable.esm.js","sources":["../../../src/components/BuildTable/BuildTable.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 Box from '@
|
|
1
|
+
{"version":3,"file":"BuildTable.esm.js","sources":["../../../src/components/BuildTable/BuildTable.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 Box from '@material-ui/core/Box';\nimport Typography from '@material-ui/core/Typography';\nimport {\n BuildResult,\n BuildRun,\n BuildStatus,\n} from '@backstage-community/plugin-azure-devops-common';\nimport {\n Link,\n ResponseErrorPanel,\n StatusAborted,\n StatusError,\n StatusOK,\n StatusPending,\n StatusRunning,\n StatusWarning,\n Table,\n TableColumn,\n} from '@backstage/core-components';\n\nimport { AzurePipelinesIcon } from '../AzurePipelinesIcon';\nimport { DateTime } from 'luxon';\nimport React from 'react';\nimport { getDurationFromDates } from '../../utils/getDurationFromDates';\n\nexport const getBuildResultComponent = (result: number | undefined) => {\n switch (result) {\n case BuildResult.Succeeded:\n return (\n <Typography component=\"span\">\n <StatusOK /> Succeeded\n </Typography>\n );\n case BuildResult.PartiallySucceeded:\n return (\n <Typography component=\"span\">\n <StatusWarning /> Partially Succeeded\n </Typography>\n );\n case BuildResult.Failed:\n return (\n <Typography component=\"span\">\n <StatusError /> Failed\n </Typography>\n );\n case BuildResult.Canceled:\n return (\n <Typography component=\"span\">\n <StatusAborted /> Canceled\n </Typography>\n );\n case BuildResult.None:\n default:\n return (\n <Typography component=\"span\">\n <StatusWarning /> Unknown\n </Typography>\n );\n }\n};\n\nexport const getBuildStateComponent = (\n status: number | undefined,\n result: number | undefined,\n) => {\n switch (status) {\n case BuildStatus.InProgress:\n return (\n <Typography component=\"span\">\n <StatusRunning /> In Progress\n </Typography>\n );\n case BuildStatus.Completed:\n return getBuildResultComponent(result);\n case BuildStatus.Cancelling:\n return (\n <Typography component=\"span\">\n <StatusAborted /> Cancelling\n </Typography>\n );\n case BuildStatus.Postponed:\n return (\n <Typography component=\"span\">\n <StatusPending /> Postponed\n </Typography>\n );\n case BuildStatus.NotStarted:\n return (\n <Typography component=\"span\">\n <StatusAborted /> Not Started\n </Typography>\n );\n case BuildStatus.None:\n default:\n return (\n <Typography component=\"span\">\n <StatusWarning /> Unknown\n </Typography>\n );\n }\n};\n\nconst columns: TableColumn[] = [\n {\n title: 'ID',\n field: 'id',\n highlight: false,\n width: 'auto',\n },\n {\n title: 'Build',\n field: 'title',\n width: 'auto',\n render: (row: Partial<BuildRun>) => (\n <Link to={row.link || ''}>{row.title}</Link>\n ),\n },\n {\n title: 'Source',\n field: 'source',\n width: 'auto',\n },\n {\n title: 'State',\n width: 'auto',\n render: (row: Partial<BuildRun>) => (\n <Box display=\"flex\" alignItems=\"center\">\n <Typography variant=\"button\">\n {getBuildStateComponent(row.status, row.result)}\n </Typography>\n </Box>\n ),\n },\n {\n title: 'Duration',\n field: 'queueTime',\n width: 'auto',\n render: (row: Partial<BuildRun>) => (\n <Box display=\"flex\" alignItems=\"center\">\n <Typography>\n {getDurationFromDates(row.startTime, row.finishTime)}\n </Typography>\n </Box>\n ),\n },\n {\n title: 'Age',\n field: 'queueTime',\n width: 'auto',\n render: (row: Partial<BuildRun>) =>\n (row.queueTime\n ? DateTime.fromISO(row.queueTime)\n : DateTime.now()\n ).toRelative(),\n },\n];\n\ntype BuildTableProps = {\n items?: BuildRun[];\n loading: boolean;\n error?: Error;\n};\n\nexport const BuildTable = ({ items, loading, error }: BuildTableProps) => {\n if (error) {\n return (\n <div>\n <ResponseErrorPanel error={error} />\n </div>\n );\n }\n\n return (\n <Table\n isLoading={loading}\n columns={columns}\n options={{\n search: true,\n paging: true,\n pageSize: 5,\n showEmptyDataSourceMessage: !loading,\n }}\n title={\n <Box display=\"flex\" alignItems=\"center\">\n <AzurePipelinesIcon style={{ fontSize: 30 }} />\n <Box mr={1} />\n Azure Pipelines - Builds ({items ? items.length : 0})\n </Box>\n }\n data={items ?? []}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;;;AAyCa,MAAA,uBAAA,GAA0B,CAAC,MAA+B,KAAA;AACrE,EAAA,QAAQ,MAAQ;AAAA,IACd,KAAK,WAAY,CAAA,SAAA;AACf,MAAA,2CACG,UAAW,EAAA,EAAA,SAAA,EAAU,0BACnB,KAAA,CAAA,aAAA,CAAA,QAAA,EAAA,IAAS,GAAE,YACd,CAAA,CAAA;AAAA,IAEJ,KAAK,WAAY,CAAA,kBAAA;AACf,MAAA,2CACG,UAAW,EAAA,EAAA,SAAA,EAAU,0BACnB,KAAA,CAAA,aAAA,CAAA,aAAA,EAAA,IAAc,GAAE,sBACnB,CAAA,CAAA;AAAA,IAEJ,KAAK,WAAY,CAAA,MAAA;AACf,MAAA,2CACG,UAAW,EAAA,EAAA,SAAA,EAAU,0BACnB,KAAA,CAAA,aAAA,CAAA,WAAA,EAAA,IAAY,GAAE,SACjB,CAAA,CAAA;AAAA,IAEJ,KAAK,WAAY,CAAA,QAAA;AACf,MAAA,2CACG,UAAW,EAAA,EAAA,SAAA,EAAU,0BACnB,KAAA,CAAA,aAAA,CAAA,aAAA,EAAA,IAAc,GAAE,WACnB,CAAA,CAAA;AAAA,IAEJ,KAAK,WAAY,CAAA,IAAA,CAAA;AAAA,IACjB;AACE,MAAA,2CACG,UAAW,EAAA,EAAA,SAAA,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,SAAS,CAAA,GAC9B,QAAS,CAAA,GAAA,IACX,UAAW,EAAA;AAAA,GACjB;AACF,CAAA,CAAA;AAQO,MAAM,aAAa,CAAC,EAAE,KAAO,EAAA,OAAA,EAAS,OAA6B,KAAA;AACxE,EAAA,IAAI,KAAO,EAAA;AACT,IAAA,uBACG,KAAA,CAAA,aAAA,CAAA,KAAA,EAAA,IAAA,kBACE,KAAA,CAAA,aAAA,CAAA,kBAAA,EAAA,EAAmB,OAAc,CACpC,CAAA,CAAA;AAAA,GAEJ;AAEA,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,SAAW,EAAA,OAAA;AAAA,MACX,OAAA;AAAA,MACA,OAAS,EAAA;AAAA,QACP,MAAQ,EAAA,IAAA;AAAA,QACR,MAAQ,EAAA,IAAA;AAAA,QACR,QAAU,EAAA,CAAA;AAAA,QACV,4BAA4B,CAAC,OAAA;AAAA,OAC/B;AAAA,MACA,KAAA,kBACG,KAAA,CAAA,aAAA,CAAA,GAAA,EAAA,EAAI,OAAQ,EAAA,MAAA,EAAO,YAAW,QAC7B,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,kBAAmB,EAAA,EAAA,KAAA,EAAO,EAAE,QAAA,EAAU,IAAM,EAAA,CAAA,kBAC5C,KAAA,CAAA,aAAA,CAAA,GAAA,EAAA,EAAI,EAAI,EAAA,CAAA,EAAG,CAAE,EAAA,4BAAA,EACa,KAAQ,GAAA,KAAA,CAAM,MAAS,GAAA,CAAA,EAAE,GACtD,CAAA;AAAA,MAEF,IAAA,EAAM,SAAS,EAAC;AAAA,KAAA;AAAA,GAClB,CAAA;AAEJ;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GitTagTable.esm.js","sources":["../../../src/components/GitTagTable/GitTagTable.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 Box from '@
|
|
1
|
+
{"version":3,"file":"GitTagTable.esm.js","sources":["../../../src/components/GitTagTable/GitTagTable.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 Box from '@material-ui/core/Box';\nimport {\n Link,\n ResponseErrorPanel,\n Table,\n TableColumn,\n} from '@backstage/core-components';\nimport { GitTag } from '@backstage-community/plugin-azure-devops-common';\nimport React from 'react';\n\nimport { AzureGitTagsIcon } from '../AzureGitTagsIcon';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport { useGitTags } from '../../hooks/useGitTags';\n\nconst columns: TableColumn[] = [\n {\n title: 'Tag',\n field: 'name',\n highlight: false,\n defaultSort: 'desc',\n width: 'auto',\n render: (row: Partial<GitTag>) => (\n <Box display=\"flex\" alignItems=\"center\">\n <Link to={row.link ?? ''}>{row.name}</Link>\n </Box>\n ),\n },\n {\n title: 'Commit',\n field: 'peeledObjectId',\n width: 'auto',\n render: (row: Partial<GitTag>) => (\n <Box display=\"flex\" alignItems=\"center\">\n <Link to={row.commitLink ?? ''}>{row.peeledObjectId}</Link>\n </Box>\n ),\n },\n {\n title: 'Created By',\n field: 'createdBy',\n width: 'auto',\n },\n];\n\nexport const GitTagTable = () => {\n const { entity } = useEntity();\n\n const { items, loading, error } = useGitTags(entity);\n\n if (error) {\n return <ResponseErrorPanel error={error} />;\n }\n\n return (\n <Table\n isLoading={loading}\n columns={columns}\n options={{\n search: true,\n paging: true,\n pageSize: 5,\n showEmptyDataSourceMessage: !loading,\n }}\n title={\n <Box display=\"flex\" alignItems=\"center\">\n <AzureGitTagsIcon style={{ fontSize: 30 }} />\n <Box mr={1} />\n Azure Repos - Git Tags ({items ? items.length : 0})\n </Box>\n }\n data={items ?? []}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;AA8BA,MAAM,OAAyB,GAAA;AAAA,EAC7B;AAAA,IACE,KAAO,EAAA,KAAA;AAAA,IACP,KAAO,EAAA,MAAA;AAAA,IACP,SAAW,EAAA,KAAA;AAAA,IACX,WAAa,EAAA,MAAA;AAAA,IACb,KAAO,EAAA,MAAA;AAAA,IACP,QAAQ,CAAC,GAAA,qBACN,KAAA,CAAA,aAAA,CAAA,GAAA,EAAA,EAAI,SAAQ,MAAO,EAAA,UAAA,EAAW,QAC7B,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,QAAK,EAAI,EAAA,GAAA,CAAI,QAAQ,EAAK,EAAA,EAAA,GAAA,CAAI,IAAK,CACtC,CAAA;AAAA,GAEJ;AAAA,EACA;AAAA,IACE,KAAO,EAAA,QAAA;AAAA,IACP,KAAO,EAAA,gBAAA;AAAA,IACP,KAAO,EAAA,MAAA;AAAA,IACP,QAAQ,CAAC,GAAA,qBACN,KAAA,CAAA,aAAA,CAAA,GAAA,EAAA,EAAI,SAAQ,MAAO,EAAA,UAAA,EAAW,QAC7B,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,QAAK,EAAI,EAAA,GAAA,CAAI,cAAc,EAAK,EAAA,EAAA,GAAA,CAAI,cAAe,CACtD,CAAA;AAAA,GAEJ;AAAA,EACA;AAAA,IACE,KAAO,EAAA,YAAA;AAAA,IACP,KAAO,EAAA,WAAA;AAAA,IACP,KAAO,EAAA,MAAA;AAAA,GACT;AACF,CAAA,CAAA;AAEO,MAAM,cAAc,MAAM;AAC/B,EAAM,MAAA,EAAE,MAAO,EAAA,GAAI,SAAU,EAAA,CAAA;AAE7B,EAAA,MAAM,EAAE,KAAO,EAAA,OAAA,EAAS,KAAM,EAAA,GAAI,WAAW,MAAM,CAAA,CAAA;AAEnD,EAAA,IAAI,KAAO,EAAA;AACT,IAAO,uBAAA,KAAA,CAAA,aAAA,CAAC,sBAAmB,KAAc,EAAA,CAAA,CAAA;AAAA,GAC3C;AAEA,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,SAAW,EAAA,OAAA;AAAA,MACX,OAAA;AAAA,MACA,OAAS,EAAA;AAAA,QACP,MAAQ,EAAA,IAAA;AAAA,QACR,MAAQ,EAAA,IAAA;AAAA,QACR,QAAU,EAAA,CAAA;AAAA,QACV,4BAA4B,CAAC,OAAA;AAAA,OAC/B;AAAA,MACA,KAAA,kBACG,KAAA,CAAA,aAAA,CAAA,GAAA,EAAA,EAAI,OAAQ,EAAA,MAAA,EAAO,YAAW,QAC7B,EAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,gBAAiB,EAAA,EAAA,KAAA,EAAO,EAAE,QAAA,EAAU,IAAM,EAAA,CAAA,kBAC1C,KAAA,CAAA,aAAA,CAAA,GAAA,EAAA,EAAI,EAAI,EAAA,CAAA,EAAG,CAAE,EAAA,0BAAA,EACW,KAAQ,GAAA,KAAA,CAAM,MAAS,GAAA,CAAA,EAAE,GACpD,CAAA;AAAA,MAEF,IAAA,EAAM,SAAS,EAAC;AAAA,KAAA;AAAA,GAClB,CAAA;AAEJ;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import Button from '@
|
|
2
|
-
import ButtonGroup from '@
|
|
1
|
+
import Button from '@material-ui/core/Button';
|
|
2
|
+
import ButtonGroup from '@material-ui/core/ButtonGroup';
|
|
3
3
|
import { PullRequestStatus } from '@backstage-community/plugin-azure-devops-common';
|
|
4
4
|
import React from 'react';
|
|
5
5
|
|
|
@@ -10,7 +10,7 @@ const PullRequestStatusButtonGroup = ({
|
|
|
10
10
|
return /* @__PURE__ */ React.createElement(ButtonGroup, { "aria-label": "outlined button group" }, /* @__PURE__ */ React.createElement(
|
|
11
11
|
Button,
|
|
12
12
|
{
|
|
13
|
-
color: status === PullRequestStatus.Active ? "
|
|
13
|
+
color: status === PullRequestStatus.Active ? "primary" : "default",
|
|
14
14
|
onClick: () => {
|
|
15
15
|
setStatus(PullRequestStatus.Active);
|
|
16
16
|
}
|
|
@@ -19,7 +19,7 @@ const PullRequestStatusButtonGroup = ({
|
|
|
19
19
|
), /* @__PURE__ */ React.createElement(
|
|
20
20
|
Button,
|
|
21
21
|
{
|
|
22
|
-
color: status === PullRequestStatus.Completed ? "
|
|
22
|
+
color: status === PullRequestStatus.Completed ? "primary" : "default",
|
|
23
23
|
onClick: () => {
|
|
24
24
|
setStatus(PullRequestStatus.Completed);
|
|
25
25
|
}
|
|
@@ -28,7 +28,7 @@ const PullRequestStatusButtonGroup = ({
|
|
|
28
28
|
), /* @__PURE__ */ React.createElement(
|
|
29
29
|
Button,
|
|
30
30
|
{
|
|
31
|
-
color: status === PullRequestStatus.Abandoned ? "
|
|
31
|
+
color: status === PullRequestStatus.Abandoned ? "primary" : "default",
|
|
32
32
|
onClick: () => {
|
|
33
33
|
setStatus(PullRequestStatus.Abandoned);
|
|
34
34
|
}
|
package/dist/components/PullRequestStatusButtonGroup/PullRequestStatusButtonGroup.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestStatusButtonGroup.esm.js","sources":["../../../src/components/PullRequestStatusButtonGroup/PullRequestStatusButtonGroup.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 Button from '@
|
|
1
|
+
{"version":3,"file":"PullRequestStatusButtonGroup.esm.js","sources":["../../../src/components/PullRequestStatusButtonGroup/PullRequestStatusButtonGroup.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 Button from '@material-ui/core/Button';\nimport ButtonGroup from '@material-ui/core/ButtonGroup';\n\nimport { PullRequestStatus } from '@backstage-community/plugin-azure-devops-common';\nimport React from 'react';\n\nexport const PullRequestStatusButtonGroup = ({\n status,\n setStatus,\n}: {\n status: PullRequestStatus;\n setStatus: (pullRequestStatus: PullRequestStatus) => void;\n}) => {\n return (\n <ButtonGroup aria-label=\"outlined button group\">\n <Button\n color={status === PullRequestStatus.Active ? 'primary' : 'default'}\n onClick={() => {\n setStatus(PullRequestStatus.Active);\n }}\n >\n Active\n </Button>\n <Button\n color={status === PullRequestStatus.Completed ? 'primary' : 'default'}\n onClick={() => {\n setStatus(PullRequestStatus.Completed);\n }}\n >\n Completed\n </Button>\n <Button\n color={status === PullRequestStatus.Abandoned ? 'primary' : 'default'}\n onClick={() => {\n setStatus(PullRequestStatus.Abandoned);\n }}\n >\n Abandoned\n </Button>\n </ButtonGroup>\n );\n};\n"],"names":[],"mappings":";;;;;AAsBO,MAAM,+BAA+B,CAAC;AAAA,EAC3C,MAAA;AAAA,EACA,SAAA;AACF,CAGM,KAAA;AACJ,EACE,uBAAA,KAAA,CAAA,aAAA,CAAC,WAAY,EAAA,EAAA,YAAA,EAAW,uBACtB,EAAA,kBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,MAAA;AAAA,IAAA;AAAA,MACC,KAAO,EAAA,MAAA,KAAW,iBAAkB,CAAA,MAAA,GAAS,SAAY,GAAA,SAAA;AAAA,MACzD,SAAS,MAAM;AACb,QAAA,SAAA,CAAU,kBAAkB,MAAM,CAAA,CAAA;AAAA,OACpC;AAAA,KAAA;AAAA,IACD,QAAA;AAAA,GAGD,kBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,MAAA;AAAA,IAAA;AAAA,MACC,KAAO,EAAA,MAAA,KAAW,iBAAkB,CAAA,SAAA,GAAY,SAAY,GAAA,SAAA;AAAA,MAC5D,SAAS,MAAM;AACb,QAAA,SAAA,CAAU,kBAAkB,SAAS,CAAA,CAAA;AAAA,OACvC;AAAA,KAAA;AAAA,IACD,WAAA;AAAA,GAGD,kBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,MAAA;AAAA,IAAA;AAAA,MACC,KAAO,EAAA,MAAA,KAAW,iBAAkB,CAAA,SAAA,GAAY,SAAY,GAAA,SAAA;AAAA,MAC5D,SAAS,MAAM;AACb,QAAA,SAAA,CAAU,kBAAkB,SAAS,CAAA,CAAA;AAAA,OACvC;AAAA,KAAA;AAAA,IACD,WAAA;AAAA,GAGH,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import Box from '@
|
|
2
|
-
import Chip from '@
|
|
1
|
+
import Box from '@material-ui/core/Box';
|
|
2
|
+
import Chip from '@material-ui/core/Chip';
|
|
3
3
|
import { ResponseErrorPanel, Table, Link } from '@backstage/core-components';
|
|
4
4
|
import { PullRequestStatus } from '@backstage-community/plugin-azure-devops-common';
|
|
5
5
|
import React, { useState } from 'react';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestTable.esm.js","sources":["../../../src/components/PullRequestTable/PullRequestTable.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 Box from '@
|
|
1
|
+
{"version":3,"file":"PullRequestTable.esm.js","sources":["../../../src/components/PullRequestTable/PullRequestTable.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 Box from '@material-ui/core/Box';\nimport Chip from '@material-ui/core/Chip';\nimport {\n Link,\n ResponseErrorPanel,\n Table,\n TableColumn,\n} from '@backstage/core-components';\nimport {\n PullRequest,\n PullRequestStatus,\n} from '@backstage-community/plugin-azure-devops-common';\nimport React, { useState } from 'react';\n\nimport { AzurePullRequestsIcon } from '../AzurePullRequestsIcon';\nimport { DateTime } from 'luxon';\nimport { PullRequestStatusButtonGroup } from '../PullRequestStatusButtonGroup';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport { usePullRequests } from '../../hooks/usePullRequests';\n\nconst columns: TableColumn[] = [\n {\n title: 'ID',\n field: 'pullRequestId',\n highlight: false,\n width: 'auto',\n },\n {\n title: 'Title',\n field: 'title',\n width: 'auto',\n render: (row: Partial<PullRequest>) => (\n <Box display=\"flex\" alignItems=\"center\">\n <Link to={row.link ?? ''}>{row.title}</Link>\n {row.isDraft && (\n <Box paddingLeft={1}>\n <Chip\n label=\"Draft\"\n variant=\"outlined\"\n color=\"secondary\"\n size=\"small\"\n />\n </Box>\n )}\n </Box>\n ),\n },\n {\n title: 'Source',\n field: 'sourceRefName',\n width: 'auto',\n },\n {\n title: 'Target',\n field: 'targetRefName',\n width: 'auto',\n },\n {\n title: 'Created By',\n field: 'createdBy',\n width: 'auto',\n },\n {\n title: 'Created',\n field: 'creationDate',\n width: 'auto',\n render: (row: Partial<PullRequest>) =>\n (row.creationDate\n ? DateTime.fromISO(row.creationDate)\n : DateTime.now()\n ).toRelative(),\n },\n];\n\ntype PullRequestTableProps = {\n defaultLimit?: number;\n};\n\nexport const PullRequestTable = ({ defaultLimit }: PullRequestTableProps) => {\n const [pullRequestStatusState, setPullRequestStatusState] =\n useState<PullRequestStatus>(PullRequestStatus.Active);\n const { entity } = useEntity();\n\n const { items, loading, error } = usePullRequests(\n entity,\n defaultLimit,\n pullRequestStatusState,\n );\n\n if (error) {\n return <ResponseErrorPanel error={error} />;\n }\n\n return (\n <Table\n isLoading={loading}\n columns={columns}\n options={{\n search: true,\n paging: true,\n pageSize: 5,\n showEmptyDataSourceMessage: !loading,\n }}\n title={\n <Box display=\"flex\" alignItems=\"center\">\n <AzurePullRequestsIcon style={{ fontSize: 30 }} />\n <Box mr={1} />\n Azure Repos - Pull Requests ({items ? items.length : 0})\n <Box position=\"absolute\" right={320} top={20}>\n <PullRequestStatusButtonGroup\n status={pullRequestStatusState}\n setStatus={setPullRequestStatusState}\n />\n </Box>\n </Box>\n }\n data={items ?? []}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;AAoCA,MAAM,OAAyB,GAAA;AAAA,EAC7B;AAAA,IACE,KAAO,EAAA,IAAA;AAAA,IACP,KAAO,EAAA,eAAA;AAAA,IACP,SAAW,EAAA,KAAA;AAAA,IACX,KAAO,EAAA,MAAA;AAAA,GACT;AAA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EAAA,kBAAA,KAAA,CAAA,aAAA;AAAA,QAAC,4BAAA;AAAA,QAAA;AAAA,UACC,MAAQ,EAAA,sBAAA;AAAA,UACR,SAAW,EAAA,yBAAA;AAAA,SAAA;AAAA,OAEf,CACF,CAAA;AAAA,MAEF,IAAA,EAAM,SAAS,EAAC;AAAA,KAAA;AAAA,GAClB,CAAA;AAEJ;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import DoneAllIcon from '@
|
|
1
|
+
import DoneAllIcon from '@material-ui/icons/DoneAll';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import makeStyles from '@
|
|
3
|
+
import { makeStyles } from '@material-ui/core/styles';
|
|
4
4
|
|
|
5
5
|
const useStyles = makeStyles((theme) => ({
|
|
6
6
|
root: (props) => ({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AutoCompleteIcon.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/AutoCompleteIcon/AutoCompleteIcon.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 DoneAllIcon from '@
|
|
1
|
+
{"version":3,"file":"AutoCompleteIcon.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/AutoCompleteIcon/AutoCompleteIcon.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 DoneAllIcon from '@material-ui/icons/DoneAll';\nimport React from 'react';\nimport { makeStyles } from '@material-ui/core/styles';\n\nconst useStyles = makeStyles(theme => ({\n root: (props: { hasAutoComplete: boolean }) => ({\n color: props.hasAutoComplete\n ? theme.palette.success.main\n : theme.palette.grey[400],\n }),\n}));\n\nexport const AutoCompleteIcon = (props: { hasAutoComplete: boolean }) => {\n const classes = useStyles(props);\n return <DoneAllIcon className={classes.root} />;\n};\n"],"names":[],"mappings":";;;;AAoBA,MAAM,SAAA,GAAY,WAAW,CAAU,KAAA,MAAA;AAAA,EACrC,IAAA,EAAM,CAAC,KAAyC,MAAA;AAAA,IAC9C,KAAA,EAAO,KAAM,CAAA,eAAA,GACT,KAAM,CAAA,OAAA,CAAQ,QAAQ,IACtB,GAAA,KAAA,CAAM,OAAQ,CAAA,IAAA,CAAK,GAAG,CAAA;AAAA,GAC5B,CAAA;AACF,CAAE,CAAA,CAAA,CAAA;AAEW,MAAA,gBAAA,GAAmB,CAAC,KAAwC,KAAA;AACvE,EAAM,MAAA,OAAA,GAAU,UAAU,KAAK,CAAA,CAAA;AAC/B,EAAA,uBAAQ,KAAA,CAAA,aAAA,CAAA,WAAA,EAAA,EAAY,SAAW,EAAA,OAAA,CAAQ,IAAM,EAAA,CAAA,CAAA;AAC/C;;;;"}
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { Link, Avatar } from '@backstage/core-components';
|
|
2
|
-
import Card from '@
|
|
3
|
-
import CardContent from '@
|
|
4
|
-
import CardHeader from '@
|
|
5
|
-
import Typography from '@
|
|
2
|
+
import Card from '@material-ui/core/Card';
|
|
3
|
+
import CardContent from '@material-ui/core/CardContent';
|
|
4
|
+
import CardHeader from '@material-ui/core/CardHeader';
|
|
5
|
+
import Typography from '@material-ui/core/Typography';
|
|
6
6
|
import { AutoCompleteIcon } from '../AutoCompleteIcon/AutoCompleteIcon.esm.js';
|
|
7
7
|
import { DateTime } from 'luxon';
|
|
8
8
|
import { PullRequestCardPolicies } from './PullRequestCardPolicies.esm.js';
|
|
9
9
|
import { PullRequestCardReviewers } from './PullRequestCardReviewers.esm.js';
|
|
10
10
|
import React from 'react';
|
|
11
|
-
import makeStyles from '@
|
|
11
|
+
import { makeStyles } from '@material-ui/core/styles';
|
|
12
12
|
|
|
13
13
|
const useStyles = makeStyles(
|
|
14
14
|
(theme) => ({
|
|
15
15
|
card: {
|
|
16
|
-
backgroundColor: theme.palette.
|
|
16
|
+
backgroundColor: theme.palette.type === "dark" ? theme.palette.grey[700] : theme.palette.common.white
|
|
17
17
|
},
|
|
18
18
|
cardHeaderSimplified: {
|
|
19
19
|
paddingBottom: theme.spacing(2)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestCard.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCard.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 { Avatar, Link } from '@backstage/core-components';\nimport Card from '@
|
|
1
|
+
{"version":3,"file":"PullRequestCard.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCard.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 { Avatar, Link } from '@backstage/core-components';\nimport Card from '@material-ui/core/Card';\nimport CardContent from '@material-ui/core/CardContent';\nimport CardHeader from '@material-ui/core/CardHeader';\nimport Typography from '@material-ui/core/Typography';\n\nimport { AutoCompleteIcon } from '../AutoCompleteIcon';\nimport { DashboardPullRequest } from '@backstage-community/plugin-azure-devops-common';\nimport { DateTime } from 'luxon';\nimport { PullRequestCardPolicies } from './PullRequestCardPolicies';\nimport { PullRequestCardReviewers } from './PullRequestCardReviewers';\nimport React from 'react';\nimport { makeStyles } from '@material-ui/core/styles';\n\nconst useStyles = makeStyles(\n theme => ({\n card: {\n backgroundColor:\n theme.palette.type === 'dark'\n ? theme.palette.grey[700]\n : theme.palette.common.white,\n },\n cardHeaderSimplified: {\n paddingBottom: theme.spacing(2),\n },\n cardHeaderAction: {\n display: 'flex',\n alignSelf: 'center',\n margin: 0,\n },\n content: {\n display: 'flex',\n flexDirection: 'row',\n },\n policies: {\n flex: 1,\n },\n avatar: { width: '2.5rem', height: '2.5rem' },\n avatarText: { fontSize: '1rem' },\n }),\n { name: 'PullRequestCard' },\n);\n\ntype PullRequestCardProps = {\n pullRequest: DashboardPullRequest;\n simplified?: boolean;\n};\n\nexport const PullRequestCard = ({\n pullRequest,\n simplified,\n}: PullRequestCardProps) => {\n const classes = useStyles();\n\n const title = (\n <Link to={pullRequest.link ?? ''} title={pullRequest.description}>\n {pullRequest.title}\n </Link>\n );\n\n const repoLink = (\n <Link to={pullRequest.repository?.url ?? ''} color=\"inherit\">\n {pullRequest.repository?.name}\n </Link>\n );\n\n const creationDate = pullRequest.creationDate\n ? DateTime.fromISO(pullRequest.creationDate).toRelative()\n : undefined;\n\n const subheader = (\n <Typography component=\"span\">\n {repoLink} · {creationDate}\n </Typography>\n );\n\n const avatar = (\n <Avatar\n displayName={pullRequest.createdBy?.displayName}\n picture={pullRequest.createdBy?.imageUrl}\n classes={{ avatar: classes.avatar, avatarText: classes.avatarText }}\n />\n );\n\n return (\n <Card\n classes={{ root: classes.card }}\n data-pull-request-id={pullRequest.pullRequestId}\n >\n <CardHeader\n avatar={avatar}\n title={title}\n subheader={subheader}\n action={\n <AutoCompleteIcon hasAutoComplete={pullRequest.hasAutoComplete} />\n }\n classes={{\n ...(simplified && { root: classes.cardHeaderSimplified }),\n action: classes.cardHeaderAction,\n }}\n />\n\n {!simplified && (\n <CardContent className={classes.content}>\n {pullRequest.policies && (\n <PullRequestCardPolicies\n policies={pullRequest.policies}\n className={classes.policies}\n />\n )}\n\n {pullRequest.reviewers && (\n <PullRequestCardReviewers reviewers={pullRequest.reviewers} />\n )}\n </CardContent>\n )}\n </Card>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;;AA8BA,MAAM,SAAY,GAAA,UAAA;AAAA,EAChB,CAAU,KAAA,MAAA;AAAA,IACR,IAAM,EAAA;AAAA,MACJ,eACE,EAAA,KAAA,CAAM,OAAQ,CAAA,IAAA,KAAS,MACnB,GAAA,KAAA,CAAM,OAAQ,CAAA,IAAA,CAAK,GAAG,CAAA,GACtB,KAAM,CAAA,OAAA,CAAQ,MAAO,CAAA,KAAA;AAAA,KAC7B;AAAA,IACA,oBAAsB,EAAA;AAAA,MACpB,aAAA,EAAe,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,KAChC;AAAA,IACA,gBAAkB,EAAA;AAAA,MAChB,OAAS,EAAA,MAAA;AAAA,MACT,SAAW,EAAA,QAAA;AAAA,MACX,MAAQ,EAAA,CAAA;AAAA,KACV;AAAA,IACA,OAAS,EAAA;AAAA,MACP,OAAS,EAAA,MAAA;AAAA,MACT,aAAe,EAAA,KAAA;AAAA,KACjB;AAAA,IACA,QAAU,EAAA;AAAA,MACR,IAAM,EAAA,CAAA;AAAA,KACR;AAAA,IACA,MAAQ,EA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A;AAAA,KAAA;AAAA,GACpE,CAAA;AAGF,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,IAAA;AAAA,IAAA;AAAA,MACC,OAAS,EAAA,EAAE,IAAM,EAAA,OAAA,CAAQ,IAAK,EAAA;AAAA,MAC9B,wBAAsB,WAAY,CAAA,aAAA;AAAA,KAAA;AAAA,oBAElC,KAAA,CAAA,aAAA;AAAA,MAAC,UAAA;AAAA,MAAA;AAAA,QACC,MAAA;AAAA,QACA,KAAA;AAAA,QACA,SAAA;AAAA,QACA,MACE,kBAAA,KAAA,CAAA,aAAA,CAAC,gBAAiB,EAAA,EAAA,eAAA,EAAiB,YAAY,eAAiB,EAAA,CAAA;AAAA,QAElE,OAAS,EAAA;AAAA,UACP,GAAI,UAAA,IAAc,EAAE,IAAA,EAAM,QAAQ,oBAAqB,EAAA;AAAA,UACvD,QAAQ,OAAQ,CAAA,gBAAA;AAAA,SAClB;AAAA,OAAA;AAAA,KACF;AAAA,IAEC,CAAC,8BACC,KAAA,CAAA,aAAA,CAAA,WAAA,EAAA,EAAY,WAAW,OAAQ,CAAA,OAAA,EAAA,EAC7B,YAAY,QACX,oBAAA,KAAA,CAAA,aAAA;AAAA,MAAC,uBAAA;AAAA,MAAA;AAAA,QACC,UAAU,WAAY,CAAA,QAAA;AAAA,QACtB,WAAW,OAAQ,CAAA,QAAA;AAAA,OAAA;AAAA,KACrB,EAGD,YAAY,SACX,oBAAA,KAAA,CAAA,aAAA,CAAC,4BAAyB,SAAW,EAAA,WAAA,CAAY,WAAW,CAEhE,CAAA;AAAA,GAEJ,CAAA;AAEJ;;;;"}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { PolicyType, PolicyEvaluationStatus } from '@backstage-community/plugin-azure-devops-common';
|
|
2
|
-
import { styled } from '@
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import GroupWorkIcon from '@mui/icons-material/GroupWork';
|
|
2
|
+
import { withStyles, styled } from '@material-ui/core/styles';
|
|
3
|
+
import Typography from '@material-ui/core/Typography';
|
|
4
|
+
import CancelIcon from '@material-ui/icons/Cancel';
|
|
5
|
+
import GroupWorkIcon from '@material-ui/icons/GroupWork';
|
|
7
6
|
import React from 'react';
|
|
8
|
-
import WatchLaterIcon from '@
|
|
7
|
+
import WatchLaterIcon from '@material-ui/icons/WatchLater';
|
|
9
8
|
|
|
10
9
|
const PolicyRequiredIcon = withStyles(
|
|
11
10
|
(theme) => ({
|
package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicy.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestCardPolicy.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicy.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 {\n Policy,\n PolicyEvaluationStatus,\n PolicyType,\n} from '@backstage-community/plugin-azure-devops-common';\nimport { styled } from '@
|
|
1
|
+
{"version":3,"file":"PullRequestCardPolicy.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicy.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 {\n Policy,\n PolicyEvaluationStatus,\n PolicyType,\n} from '@backstage-community/plugin-azure-devops-common';\nimport { styled, withStyles } from '@material-ui/core/styles';\nimport Typography from '@material-ui/core/Typography';\n\nimport CancelIcon from '@material-ui/icons/Cancel';\nimport GroupWorkIcon from '@material-ui/icons/GroupWork';\nimport React from 'react';\nimport WatchLaterIcon from '@material-ui/icons/WatchLater';\n\nconst PolicyRequiredIcon = withStyles(\n theme => ({\n root: {\n color: theme.palette.info.main,\n },\n }),\n { name: 'PolicyRequiredIcon' },\n)(WatchLaterIcon);\n\nconst PolicyIssueIcon = withStyles(\n theme => ({\n root: {\n color: theme.palette.error.main,\n },\n }),\n { name: 'PolicyIssueIcon' },\n)(CancelIcon);\n\nconst PolicyInProgressIcon = withStyles(\n theme => ({\n root: {\n color: theme.palette.info.main,\n },\n }),\n { name: 'PolicyInProgressIcon' },\n)(GroupWorkIcon);\n\nfunction getPolicyIcon(policy: Policy): React.JSX.Element | null {\n switch (policy.type) {\n case PolicyType.Build:\n switch (policy.status) {\n case PolicyEvaluationStatus.Running:\n return <PolicyInProgressIcon />;\n case PolicyEvaluationStatus.Rejected:\n return <PolicyIssueIcon />;\n case PolicyEvaluationStatus.Queued:\n return <PolicyRequiredIcon />;\n default:\n return null;\n }\n case PolicyType.MinimumReviewers:\n case PolicyType.RequiredReviewers:\n return <PolicyRequiredIcon />;\n case PolicyType.Status:\n case PolicyType.Comments:\n return <PolicyIssueIcon />;\n default:\n return null;\n }\n}\n\nconst PullRequestCardPolicyContainer = styled('div')({\n display: 'flex',\n alignItems: 'center',\n flexWrap: 'wrap',\n});\n\ntype PullRequestCardPolicyProps = {\n policy: Policy;\n};\n\nexport const PullRequestCardPolicy = ({\n policy,\n}: PullRequestCardPolicyProps) => (\n <PullRequestCardPolicyContainer>\n {getPolicyIcon(policy)}{' '}\n <Typography component=\"span\">{policy.text}</Typography>\n </PullRequestCardPolicyContainer>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,UAAO,OAAA,IAAA,CAAA;AAAA,OACX;AAAA,IACF,KAAK,UAAW,CAAA,gBAAA,CAAA;AAAA,IAChB,KAAK,UAAW,CAAA,iBAAA;AACd,MAAA,2CAAQ,kBAAmB,EAAA,IAAA,CAAA,CAAA;AAAA,IAC7B,KAAK,UAAW,CAAA,MAAA,CAAA;AAAA,IAChB,KAAK,UAAW,CAAA,QAAA;AACd,MAAA,2CAAQ,eAAgB,EAAA,IAAA,CAAA,CAAA;AAAA,IAC1B;AACE,MAAO,OAAA,IAAA,CAAA;AAAA,GACX;AACF,CAAA;AAEA,MAAM,8BAAA,GAAiC,MAAO,CAAA,KAAK,CAAE,CAAA;AAAA,EACnD,OAAS,EAAA,MAAA;AAAA,EACT,UAAY,EAAA,QAAA;AAAA,EACZ,QAAU,EAAA,MAAA;AACZ,CAAC,CAAA,CAAA;AAMM,MAAM,wBAAwB,CAAC;AAAA,EACpC,MAAA;AACF,CAAA,qBACG,KAAA,CAAA,aAAA,CAAA,8BAAA,EAAA,IAAA,EACE,aAAc,CAAA,MAAM,CAAG,EAAA,GAAA,kBACvB,KAAA,CAAA,aAAA,CAAA,UAAA,EAAA,EAAW,SAAU,EAAA,MAAA,EAAA,EAAQ,MAAO,CAAA,IAAK,CAC5C;;;;"}
|
package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewer.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestCardReviewer.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewer.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 { Avatar } from '@backstage/core-components';\nimport React from 'react';\nimport { Reviewer } from '@backstage-community/plugin-azure-devops-common';\nimport makeStyles from '@
|
|
1
|
+
{"version":3,"file":"PullRequestCardReviewer.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewer.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 { Avatar } from '@backstage/core-components';\nimport React from 'react';\nimport { Reviewer } from '@backstage-community/plugin-azure-devops-common';\nimport { makeStyles } from '@material-ui/core/styles';\n\ntype PullRequestCardReviewerProps = {\n reviewer: Reviewer;\n};\n\nconst useStyles = makeStyles(\n {\n avatar: {\n width: '2.5rem',\n height: '2.5rem',\n border: '0.3rem solid silver',\n },\n avatarText: {\n fontSize: '1rem',\n },\n },\n { name: 'PullRequestCardReviewer' },\n);\n\nexport const PullRequestCardReviewer = ({\n reviewer,\n}: PullRequestCardReviewerProps) => {\n const classes = useStyles();\n\n return (\n <Avatar\n displayName={reviewer.displayName}\n picture={reviewer.imageUrl}\n classes={classes}\n />\n );\n};\n"],"names":[],"mappings":";;;;AAyBA,MAAM,SAAY,GAAA,UAAA;AAAA,EAChB;AAAA,IACE,MAAQ,EAAA;AAAA,MACN,KAAO,EAAA,QAAA;AAAA,MACP,MAAQ,EAAA,QAAA;AAAA,MACR,MAAQ,EAAA,qBAAA;AAAA,KACV;AAAA,IACA,UAAY,EAAA;AAAA,MACV,QAAU,EAAA,MAAA;AAAA,KACZ;AAAA,GACF;AAAA,EACA,EAAE,MAAM,yBAA0B,EAAA;AACpC,CAAA,CAAA;AAEO,MAAM,0BAA0B,CAAC;AAAA,EACtC,QAAA;AACF,CAAoC,KAAA;AAClC,EAAA,MAAM,UAAU,SAAU,EAAA,CAAA;AAE1B,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,MAAA;AAAA,IAAA;AAAA,MACC,aAAa,QAAS,CAAA,WAAA;AAAA,MACtB,SAAS,QAAS,CAAA,QAAA;AAAA,MAClB,OAAA;AAAA,KAAA;AAAA,GACF,CAAA;AAEJ;;;;"}
|
package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.esm.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { PullRequestCardReviewer } from './PullRequestCardReviewer.esm.js';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { reviewerFilter } from '../utils.esm.js';
|
|
4
|
-
import { styled } from '@
|
|
4
|
+
import { styled } from '@material-ui/core/styles';
|
|
5
5
|
|
|
6
6
|
const PullRequestCardReviewersContainer = styled("div")({
|
|
7
7
|
"& > *": {
|
package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestCardReviewers.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.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 { PullRequestCardReviewer } from './PullRequestCardReviewer';\nimport React from 'react';\nimport { Reviewer } from '@backstage-community/plugin-azure-devops-common';\nimport { reviewerFilter } from '../utils';\nimport { styled } from '@
|
|
1
|
+
{"version":3,"file":"PullRequestCardReviewers.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.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 { PullRequestCardReviewer } from './PullRequestCardReviewer';\nimport React from 'react';\nimport { Reviewer } from '@backstage-community/plugin-azure-devops-common';\nimport { reviewerFilter } from '../utils';\nimport { styled } from '@material-ui/core/styles';\n\nconst PullRequestCardReviewersContainer = styled('div')({\n '& > *': {\n marginTop: 4,\n marginBottom: 4,\n },\n});\n\ntype PullRequestCardReviewersProps = {\n reviewers: Reviewer[];\n};\n\nexport const PullRequestCardReviewers = ({\n reviewers,\n}: PullRequestCardReviewersProps) => (\n <PullRequestCardReviewersContainer>\n {reviewers.filter(reviewerFilter).map(reviewer => (\n <PullRequestCardReviewer key={reviewer.id} reviewer={reviewer} />\n ))}\n </PullRequestCardReviewersContainer>\n);\n"],"names":[],"mappings":";;;;;AAsBA,MAAM,iCAAA,GAAoC,MAAO,CAAA,KAAK,CAAE,CAAA;AAAA,EACtD,OAAS,EAAA;AAAA,IACP,SAAW,EAAA,CAAA;AAAA,IACX,YAAc,EAAA,CAAA;AAAA,GAChB;AACF,CAAC,CAAA,CAAA;AAMM,MAAM,2BAA2B,CAAC;AAAA,EACvC,SAAA;AACF,CAAA,qBACG,KAAA,CAAA,aAAA,CAAA,iCAAA,EAAA,IAAA,EACE,SAAU,CAAA,MAAA,CAAO,cAAc,CAAE,CAAA,GAAA,CAAI,CACpC,QAAA,qBAAA,KAAA,CAAA,aAAA,CAAC,2BAAwB,GAAK,EAAA,QAAA,CAAS,EAAI,EAAA,QAAA,EAAoB,CAChE,CACH;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { PullRequestGridColumn } from '../PullRequestGridColumn/PullRequestGridColumn.esm.js';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { styled } from '@
|
|
3
|
+
import { styled } from '@material-ui/core/styles';
|
|
4
4
|
|
|
5
5
|
const GridDiv = styled("div")(({ theme }) => ({
|
|
6
6
|
display: "flex",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestGrid.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestGrid/PullRequestGrid.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 { PullRequestGridColumn } from '../PullRequestGridColumn';\nimport { PullRequestGroup } from '../types';\nimport React from 'react';\nimport { styled } from '@
|
|
1
|
+
{"version":3,"file":"PullRequestGrid.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestGrid/PullRequestGrid.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 { PullRequestGridColumn } from '../PullRequestGridColumn';\nimport { PullRequestGroup } from '../types';\nimport React from 'react';\nimport { styled } from '@material-ui/core/styles';\n\nconst GridDiv = styled('div')(({ theme }) => ({\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n '& > *': {\n marginRight: theme.spacing(2),\n },\n '& > :last-of-type': {\n marginRight: 0,\n },\n}));\n\ntype PullRequestGridProps = {\n pullRequestGroups: PullRequestGroup[];\n};\n\nexport const PullRequestGrid = ({\n pullRequestGroups,\n}: PullRequestGridProps) => {\n return (\n <GridDiv>\n {pullRequestGroups.map((pullRequestGroup, index) => (\n <PullRequestGridColumn\n key={index}\n pullRequestGroup={pullRequestGroup}\n />\n ))}\n </GridDiv>\n );\n};\n"],"names":[],"mappings":";;;;AAqBA,MAAM,UAAU,MAAO,CAAA,KAAK,EAAE,CAAC,EAAE,OAAa,MAAA;AAAA,EAC5C,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,KAAA;AAAA,EACf,cAAgB,EAAA,eAAA;AAAA,EAChB,OAAS,EAAA;AAAA,IACP,WAAA,EAAa,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,GAC9B;AAAA,EACA,mBAAqB,EAAA;AAAA,IACnB,WAAa,EAAA,CAAA;AAAA,GACf;AACF,CAAE,CAAA,CAAA,CAAA;AAMK,MAAM,kBAAkB,CAAC;AAAA,EAC9B,iBAAA;AACF,CAA4B,KAAA;AAC1B,EAAA,2CACG,OACE,EAAA,IAAA,EAAA,iBAAA,CAAkB,GAAI,CAAA,CAAC,kBAAkB,KACxC,qBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,qBAAA;AAAA,IAAA;AAAA,MACC,GAAK,EAAA,KAAA;AAAA,MACL,gBAAA;AAAA,KAAA;AAAA,GAEH,CACH,CAAA,CAAA;AAEJ;;;;"}
|
package/dist/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.esm.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import Paper from '@
|
|
2
|
-
import Typography from '@
|
|
3
|
-
import { styled } from '@
|
|
4
|
-
import withStyles from '@mui/styles/withStyles';
|
|
1
|
+
import Paper from '@material-ui/core/Paper';
|
|
2
|
+
import Typography from '@material-ui/core/Typography';
|
|
3
|
+
import { withStyles, styled } from '@material-ui/core/styles';
|
|
5
4
|
import { PullRequestCard } from '../PullRequestCard/PullRequestCard.esm.js';
|
|
6
5
|
import React from 'react';
|
|
7
6
|
|
|
@@ -11,7 +10,7 @@ const ColumnPaper = withStyles((theme) => ({
|
|
|
11
10
|
flexDirection: "column",
|
|
12
11
|
flex: 1,
|
|
13
12
|
padding: theme.spacing(2),
|
|
14
|
-
backgroundColor: theme.palette.
|
|
13
|
+
backgroundColor: theme.palette.type === "dark" ? theme.palette.grey[800] : theme.palette.grey[300],
|
|
15
14
|
height: "100%"
|
|
16
15
|
}
|
|
17
16
|
}))(Paper);
|
package/dist/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PullRequestGridColumn.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.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 Paper from '@
|
|
1
|
+
{"version":3,"file":"PullRequestGridColumn.esm.js","sources":["../../../../../src/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.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 Paper from '@material-ui/core/Paper';\nimport Typography from '@material-ui/core/Typography';\nimport { styled, withStyles } from '@material-ui/core/styles';\n\nimport { PullRequestCard } from '../PullRequestCard';\nimport { PullRequestGroup } from '../types';\nimport React from 'react';\n\nconst ColumnPaper = withStyles(theme => ({\n root: {\n display: 'flex',\n flexDirection: 'column',\n flex: 1,\n padding: theme.spacing(2),\n backgroundColor:\n theme.palette.type === 'dark'\n ? theme.palette.grey[800]\n : theme.palette.grey[300],\n height: '100%',\n },\n}))(Paper);\n\nconst ColumnTitleDiv = styled('div')(({ theme }) => ({\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginBottom: theme.spacing(2),\n}));\n\nexport const PullRequestCardContainer = styled('div')(({ theme }) => ({\n display: 'flex',\n flexDirection: 'column',\n '& > *': {\n marginBottom: theme.spacing(2),\n },\n '& > :last-of-type': {\n marginBottom: 0,\n },\n}));\n\ntype PullRequestGridColumnProps = {\n pullRequestGroup: PullRequestGroup;\n};\n\nexport const PullRequestGridColumn = ({\n pullRequestGroup,\n}: PullRequestGridColumnProps) => {\n const columnTitle = (\n <ColumnTitleDiv>\n <Typography variant=\"h5\">{pullRequestGroup.title}</Typography>\n </ColumnTitleDiv>\n );\n\n const pullRequests = (\n <PullRequestCardContainer>\n {pullRequestGroup.pullRequests.map(pullRequest => (\n <PullRequestCard\n key={pullRequest.pullRequestId}\n pullRequest={pullRequest}\n simplified={pullRequest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C,gBAAA;AACF,CAAkC,KAAA;AAChC,EAAM,MAAA,WAAA,uCACH,cACC,EAAA,IAAA,kBAAA,KAAA,CAAA,aAAA,CAAC,cAAW,OAAQ,EAAA,IAAA,EAAA,EAAM,gBAAiB,CAAA,KAAM,CACnD,CAAA,CAAA;AAGF,EAAA,MAAM,+BACH,KAAA,CAAA,aAAA,CAAA,wBAAA,EAAA,IAAA,EACE,gBAAiB,CAAA,YAAA,CAAa,IAAI,CACjC,WAAA,qBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,eAAA;AAAA,IAAA;AAAA,MACC,KAAK,WAAY,CAAA,aAAA;AAAA,MACjB,WAAA;AAAA,MACA,YAAY,gBAAiB,CAAA,UAAA;AAAA,KAAA;AAAA,GAEhC,CACH,CAAA,CAAA;AAGF,EACE,uBAAA,KAAA,CAAA,aAAA,CAAC,WACE,EAAA,IAAA,EAAA,WAAA,EACA,YACH,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import Box from '@
|
|
2
|
-
import Button from '@
|
|
3
|
-
import makeStyles from '@
|
|
1
|
+
import Box from '@material-ui/core/Box';
|
|
2
|
+
import Button from '@material-ui/core/Button';
|
|
3
|
+
import { makeStyles } from '@material-ui/core/styles';
|
|
4
4
|
import { Progress, InfoCard, MarkdownContent, EmptyState, ErrorPanel } from '@backstage/core-components';
|
|
5
5
|
import { useEntity } from '@backstage/plugin-catalog-react';
|
|
6
6
|
import React from 'react';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ReadmeCard.esm.js","sources":["../../../src/components/ReadmeCard/ReadmeCard.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 Box from '@
|
|
1
|
+
{"version":3,"file":"ReadmeCard.esm.js","sources":["../../../src/components/ReadmeCard/ReadmeCard.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 Box from '@material-ui/core/Box';\nimport Button from '@material-ui/core/Button';\nimport { makeStyles } from '@material-ui/core/styles';\nimport {\n InfoCard,\n Progress,\n MarkdownContent,\n EmptyState,\n ErrorPanel,\n} from '@backstage/core-components';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport React from 'react';\n\nimport { useReadme } from '../../hooks';\n\nconst useStyles = makeStyles(theme => ({\n readMe: {\n overflowY: 'auto',\n paddingRight: theme.spacing(1),\n '&::-webkit-scrollbar-track': {\n backgroundColor: '#F5F5F5',\n borderRadius: '5px',\n },\n '&::-webkit-scrollbar': {\n width: '5px',\n backgroundColor: '#F5F5F5',\n borderRadius: '5px',\n },\n '&::-webkit-scrollbar-thumb': {\n border: '1px solid #555555',\n backgroundColor: '#555',\n borderRadius: '4px',\n },\n },\n}));\n\ntype Props = {\n maxHeight?: number;\n};\n\ntype ErrorProps = {\n error: Error;\n};\n\nfunction isNotFoundError(error: any): boolean {\n return error?.response?.status === 404;\n}\n\nconst ReadmeCardError = ({ error }: ErrorProps) => {\n if (isNotFoundError(error)) {\n return (\n <EmptyState\n title=\"No README available for this entity\"\n missing=\"field\"\n description=\"You can add a README to your entity by following the Azure DevOps documentation.\"\n action={\n <Button\n variant=\"contained\"\n color=\"primary\"\n href=\"https://docs.microsoft.com/en-us/azure/devops/repos/git/create-a-readme?view=azure-devops\"\n >\n Read more\n </Button>\n }\n />\n );\n }\n return <ErrorPanel title={error.message} error={error} />;\n};\n\nexport const ReadmeCard = (props: Props) => {\n const classes = useStyles();\n const { entity } = useEntity();\n const { loading, error, item: value } = useReadme(entity);\n\n if (loading) {\n return <Progress />;\n } else if (error) {\n return <ReadmeCardError error={error} />;\n }\n\n return (\n <InfoCard\n title=\"Readme\"\n deepLink={{\n link: value!.url,\n title: 'Readme',\n }}\n >\n <Box className={classes.readMe} sx={{ maxHeight: props.maxHeight }}>\n <MarkdownContent content={value?.content ?? ''} />\n </Box>\n </InfoCard>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AA+BA,MAAM,SAAA,GAAY,WAAW,CAAU,KAAA,MAAA;AAAA,EACrC,MAAQ,EAAA;AAAA,IACN,SAAW,EAAA,MAAA;AAAA,IACX,YAAA,EAAc,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,IAC7B,4BAA8B,EAAA;AAAA,MAC5B,eAAiB,EAAA,SAAA;AAAA,MACjB,YAAc,EAAA,KAAA;AAAA,KAChB;AAAA,IACA,sBAAwB,EAAA;AAAA,MACtB,KAAO,EAAA,KAAA;AAAA,MACP,eAAiB,EAAA,SAAA;AAAA,MACjB,YAAc,EAAA,KAAA;AAAA,KAChB;AAAA,IACA,4BAA8B,EAAA;AAAA,MAC5B,MAAQ,EAAA,mBAAA;AAAA,MACR,eAAiB,EAAA,MAAA;AAAA,MACjB,YAAc,EAAA,KAAA;AAAA,KAChB;AAAA,GACF;AACF,CAAE,CAAA,CAAA,CAAA;AAUF,SAAS,gBAAgB,KAAqB,EAAA;AAC5C,EAAO,OAAA,KAAA,EAAO,UAAU,MAAW,KAAA,GAAA,CAAA;AACrC,CAAA;AAEA,MAAM,eAAkB,GAAA,CAAC,EAAE,KAAA,EAAwB,KAAA;AACjD,EAAI,IAA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AA,EAAA,SAAA,EAAW,OAAQ,CAAA,MAAA,EAAQ,IAAI,EAAE,SAAA,EAAW,KAAM,CAAA,SAAA,sBACpD,KAAA,CAAA,aAAA,CAAA,eAAA,EAAA,EAAgB,SAAS,KAAO,EAAA,OAAA,IAAW,IAAI,CAClD,CAAA;AAAA,GACF,CAAA;AAEJ;;;;"}
|
package/dist/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ import { DashboardPullRequest, RepoBuildOptions, RepoBuild, GitTag, PullRequestO
|
|
|
5
5
|
import * as _backstage_core_plugin_api from '@backstage/core-plugin-api';
|
|
6
6
|
import { DiscoveryApi, FetchApi } from '@backstage/core-plugin-api';
|
|
7
7
|
import { Entity } from '@backstage/catalog-model';
|
|
8
|
-
import { SvgIconProps } from '@
|
|
8
|
+
import { SvgIconProps } from '@material-ui/core/SvgIcon';
|
|
9
9
|
|
|
10
10
|
/** @public */
|
|
11
11
|
type AllFilter = BaseFilter & {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage-community/plugin-azure-devops",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.3",
|
|
4
4
|
"backstage": {
|
|
5
5
|
"role": "frontend-plugin",
|
|
6
6
|
"pluginId": "azure-devops",
|
|
@@ -60,9 +60,8 @@
|
|
|
60
60
|
"@backstage/frontend-plugin-api": "^0.9.0",
|
|
61
61
|
"@backstage/plugin-catalog-react": "^1.14.0",
|
|
62
62
|
"@backstage/plugin-permission-react": "^0.4.27",
|
|
63
|
-
"@
|
|
64
|
-
"@
|
|
65
|
-
"@mui/styles": "^5.16.7",
|
|
63
|
+
"@material-ui/core": "^4.12.2",
|
|
64
|
+
"@material-ui/icons": "^4.9.1",
|
|
66
65
|
"@types/react": "^16.13.1 || ^17.0.0 || ^18.0.0",
|
|
67
66
|
"humanize-duration": "^3.27.0",
|
|
68
67
|
"luxon": "^3.0.0",
|