@backstage-community/plugin-azure-devops 0.4.4 → 0.4.7

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.
Files changed (124) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/alpha/package.json +2 -2
  3. package/dist/alpha/plugin.esm.js +69 -0
  4. package/dist/alpha/plugin.esm.js.map +1 -0
  5. package/dist/alpha.esm.js +1 -68
  6. package/dist/alpha.esm.js.map +1 -1
  7. package/dist/api/AzureDevOpsApi.esm.js +8 -0
  8. package/dist/api/AzureDevOpsApi.esm.js.map +1 -0
  9. package/dist/{esm/AzureDevOpsApi-GBxs-uQ7.esm.js → api/AzureDevOpsClient.esm.js} +11 -36
  10. package/dist/api/AzureDevOpsClient.esm.js.map +1 -0
  11. package/dist/components/AzureGitTagsIcon/AzureGitTagsIcon.esm.js +7 -0
  12. package/dist/components/AzureGitTagsIcon/AzureGitTagsIcon.esm.js.map +1 -0
  13. package/dist/components/AzurePipelinesIcon/AzurePipelinesIcon.esm.js +27 -0
  14. package/dist/components/AzurePipelinesIcon/AzurePipelinesIcon.esm.js.map +1 -0
  15. package/dist/{esm/AzurePullRequestsIcon-DOAkj-X3.esm.js → components/AzurePullRequestsIcon/AzurePullRequestsIcon.esm.js} +2 -2
  16. package/dist/components/AzurePullRequestsIcon/AzurePullRequestsIcon.esm.js.map +1 -0
  17. package/dist/{esm/index-Bwu2-Sgs.esm.js → components/BuildTable/BuildTable.esm.js} +7 -107
  18. package/dist/components/BuildTable/BuildTable.esm.js.map +1 -0
  19. package/dist/components/EntityPageAzureGitTags/EntityPageAzureGitTags.esm.js +22 -0
  20. package/dist/components/EntityPageAzureGitTags/EntityPageAzureGitTags.esm.js.map +1 -0
  21. package/dist/components/EntityPageAzureGitTags/index.esm.js +2 -0
  22. package/dist/components/EntityPageAzureGitTags/index.esm.js.map +1 -0
  23. package/dist/components/EntityPageAzurePipelines/EntityPageAzurePipelines.esm.js +32 -0
  24. package/dist/components/EntityPageAzurePipelines/EntityPageAzurePipelines.esm.js.map +1 -0
  25. package/dist/components/EntityPageAzurePipelines/index.esm.js +2 -0
  26. package/dist/components/EntityPageAzurePipelines/index.esm.js.map +1 -0
  27. package/dist/components/EntityPageAzurePullRequests/EntityPageAzurePullRequests.esm.js +22 -0
  28. package/dist/components/EntityPageAzurePullRequests/EntityPageAzurePullRequests.esm.js.map +1 -0
  29. package/dist/components/EntityPageAzurePullRequests/index.esm.js +2 -0
  30. package/dist/components/EntityPageAzurePullRequests/index.esm.js.map +1 -0
  31. package/dist/components/GitTagTable/GitTagTable.esm.js +53 -0
  32. package/dist/components/GitTagTable/GitTagTable.esm.js.map +1 -0
  33. package/dist/components/PullRequestStatusButtonGroup/PullRequestStatusButtonGroup.esm.js +41 -0
  34. package/dist/components/PullRequestStatusButtonGroup/PullRequestStatusButtonGroup.esm.js.map +1 -0
  35. package/dist/components/PullRequestTable/PullRequestTable.esm.js +90 -0
  36. package/dist/components/PullRequestTable/PullRequestTable.esm.js.map +1 -0
  37. package/dist/components/PullRequestsPage/PullRequestsPage.esm.js +79 -0
  38. package/dist/components/PullRequestsPage/PullRequestsPage.esm.js.map +1 -0
  39. package/dist/components/PullRequestsPage/index.esm.js +6 -0
  40. package/dist/components/PullRequestsPage/index.esm.js.map +1 -0
  41. package/dist/components/PullRequestsPage/lib/AutoCompleteIcon/AutoCompleteIcon.esm.js +16 -0
  42. package/dist/components/PullRequestsPage/lib/AutoCompleteIcon/AutoCompleteIcon.esm.js.map +1 -0
  43. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCard.esm.js +85 -0
  44. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCard.esm.js.map +1 -0
  45. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicies.esm.js +10 -0
  46. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicies.esm.js.map +1 -0
  47. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicy.esm.js +66 -0
  48. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardPolicy.esm.js.map +1 -0
  49. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewer.esm.js +33 -0
  50. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewer.esm.js.map +1 -0
  51. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.esm.js +17 -0
  52. package/dist/components/PullRequestsPage/lib/PullRequestCard/PullRequestCardReviewers.esm.js.map +1 -0
  53. package/dist/components/PullRequestsPage/lib/PullRequestGrid/PullRequestGrid.esm.js +29 -0
  54. package/dist/components/PullRequestsPage/lib/PullRequestGrid/PullRequestGrid.esm.js.map +1 -0
  55. package/dist/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.esm.js +50 -0
  56. package/dist/components/PullRequestsPage/lib/PullRequestGridColumn/PullRequestGridColumn.esm.js.map +1 -0
  57. package/dist/components/PullRequestsPage/lib/filters/allFilter.esm.js +6 -0
  58. package/dist/components/PullRequestsPage/lib/filters/allFilter.esm.js.map +1 -0
  59. package/dist/components/PullRequestsPage/lib/filters/assignedToTeamFilter.esm.js +17 -0
  60. package/dist/components/PullRequestsPage/lib/filters/assignedToTeamFilter.esm.js.map +1 -0
  61. package/dist/components/PullRequestsPage/lib/filters/assignedToTeamsFilter.esm.js +20 -0
  62. package/dist/components/PullRequestsPage/lib/filters/assignedToTeamsFilter.esm.js.map +1 -0
  63. package/dist/components/PullRequestsPage/lib/filters/assignedToUserFilter.esm.js +20 -0
  64. package/dist/components/PullRequestsPage/lib/filters/assignedToUserFilter.esm.js.map +1 -0
  65. package/dist/components/PullRequestsPage/lib/filters/createFilter.esm.js +45 -0
  66. package/dist/components/PullRequestsPage/lib/filters/createFilter.esm.js.map +1 -0
  67. package/dist/components/PullRequestsPage/lib/filters/createdByTeamFilter.esm.js +17 -0
  68. package/dist/components/PullRequestsPage/lib/filters/createdByTeamFilter.esm.js.map +1 -0
  69. package/dist/components/PullRequestsPage/lib/filters/createdByTeamsFilter.esm.js +32 -0
  70. package/dist/components/PullRequestsPage/lib/filters/createdByTeamsFilter.esm.js.map +1 -0
  71. package/dist/components/PullRequestsPage/lib/filters/createdByUserFilter.esm.js +18 -0
  72. package/dist/components/PullRequestsPage/lib/filters/createdByUserFilter.esm.js.map +1 -0
  73. package/dist/components/PullRequestsPage/lib/filters/types.esm.js +17 -0
  74. package/dist/components/PullRequestsPage/lib/filters/types.esm.js.map +1 -0
  75. package/dist/components/PullRequestsPage/lib/hooks/useFilterProcessor.esm.js +37 -0
  76. package/dist/components/PullRequestsPage/lib/hooks/useFilterProcessor.esm.js.map +1 -0
  77. package/dist/components/PullRequestsPage/lib/utils.esm.js +47 -0
  78. package/dist/components/PullRequestsPage/lib/utils.esm.js.map +1 -0
  79. package/dist/{esm/index-BJ_pWnMh.esm.js → components/ReadmeCard/ReadmeCard.esm.js} +8 -31
  80. package/dist/components/ReadmeCard/ReadmeCard.esm.js.map +1 -0
  81. package/dist/components/ReadmeCard/index.esm.js +2 -0
  82. package/dist/components/ReadmeCard/index.esm.js.map +1 -0
  83. package/dist/hooks/useBuildRuns.esm.js +37 -0
  84. package/dist/hooks/useBuildRuns.esm.js.map +1 -0
  85. package/dist/hooks/useDashboardPullRequests.esm.js +43 -0
  86. package/dist/hooks/useDashboardPullRequests.esm.js.map +1 -0
  87. package/dist/hooks/useGitTags.esm.js +30 -0
  88. package/dist/hooks/useGitTags.esm.js.map +1 -0
  89. package/dist/hooks/usePullRequests.esm.js +41 -0
  90. package/dist/hooks/usePullRequests.esm.js.map +1 -0
  91. package/dist/hooks/useReadme.esm.js +32 -0
  92. package/dist/hooks/useReadme.esm.js.map +1 -0
  93. package/dist/hooks/useUserEmail.esm.js +11 -0
  94. package/dist/hooks/useUserEmail.esm.js.map +1 -0
  95. package/dist/hooks/useUserTeamIds.esm.js +23 -0
  96. package/dist/hooks/useUserTeamIds.esm.js.map +1 -0
  97. package/dist/index.esm.js +7 -92
  98. package/dist/index.esm.js.map +1 -1
  99. package/dist/plugin.esm.js +68 -0
  100. package/dist/plugin.esm.js.map +1 -0
  101. package/dist/routes.esm.js +17 -0
  102. package/dist/routes.esm.js.map +1 -0
  103. package/dist/utils/arrayHas.esm.js +15 -0
  104. package/dist/utils/arrayHas.esm.js.map +1 -0
  105. package/dist/utils/equalsIgnoreCase.esm.js +6 -0
  106. package/dist/utils/equalsIgnoreCase.esm.js.map +1 -0
  107. package/dist/{esm/getAnnotationValuesFromEntity-G8YVs-3R.esm.js → utils/getAnnotationValuesFromEntity.esm.js} +7 -8
  108. package/dist/utils/getAnnotationValuesFromEntity.esm.js.map +1 -0
  109. package/dist/utils/getDurationFromDates.esm.js +34 -0
  110. package/dist/utils/getDurationFromDates.esm.js.map +1 -0
  111. package/package.json +19 -13
  112. package/dist/esm/AzureDevOpsApi-GBxs-uQ7.esm.js.map +0 -1
  113. package/dist/esm/AzurePullRequestsIcon-DOAkj-X3.esm.js.map +0 -1
  114. package/dist/esm/PullRequestsPage-CkhRQsgx.esm.js +0 -610
  115. package/dist/esm/PullRequestsPage-CkhRQsgx.esm.js.map +0 -1
  116. package/dist/esm/getAnnotationValuesFromEntity-G8YVs-3R.esm.js.map +0 -1
  117. package/dist/esm/index-1Rl7C23d.esm.js +0 -102
  118. package/dist/esm/index-1Rl7C23d.esm.js.map +0 -1
  119. package/dist/esm/index-BJ_pWnMh.esm.js.map +0 -1
  120. package/dist/esm/index-Bo-6jkQA.esm.js +0 -178
  121. package/dist/esm/index-Bo-6jkQA.esm.js.map +0 -1
  122. package/dist/esm/index-Bwu2-Sgs.esm.js.map +0 -1
  123. package/dist/esm/index-W1pvc5vi.esm.js +0 -25
  124. package/dist/esm/index-W1pvc5vi.esm.js.map +0 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,32 @@
1
1
  # @backstage-community/plugin-azure-devops
2
2
 
3
+ ## 0.4.7
4
+
5
+ ### Patch Changes
6
+
7
+ - 31aba58: Added package metadata
8
+ - Updated dependencies [31aba58]
9
+ - @backstage-community/plugin-azure-devops-common@0.4.5
10
+
11
+ ## 0.4.6
12
+
13
+ ### Patch Changes
14
+
15
+ - 8276458: Fixed bug in AzureDevOpsClient where multiple entityRef query parameters were appended in case of multiple build definitions, which caused 400 Bad Request error.
16
+ - 2deaaa0: Backstage v1.28.4 version bump
17
+ - Updated dependencies [2deaaa0]
18
+ - @backstage-community/plugin-azure-devops-common@0.4.4
19
+
20
+ ## 0.4.5
21
+
22
+ ### Patch Changes
23
+
24
+ - 0a6bae4: Backstage `1.27.6` version bump
25
+ - 0032b05: Updated dependencies
26
+ - Updated dependencies [0a6bae4]
27
+ - Updated dependencies [0032b05]
28
+ - @backstage-community/plugin-azure-devops-common@0.4.3
29
+
3
30
  ## 0.4.4
4
31
 
5
32
  ### Patch Changes
@@ -1,6 +1,6 @@
1
1
  {
2
- "name": "@backstage-community/plugin-azure-devops",
3
- "version": "0.4.4",
2
+ "name": "@backstage-community/plugin-azure-devops__alpha",
3
+ "version": "0.4.7",
4
4
  "main": "../dist/alpha.esm.js",
5
5
  "module": "../dist/alpha.esm.js",
6
6
  "types": "../dist/alpha.d.ts"
@@ -0,0 +1,69 @@
1
+ import React from 'react';
2
+ import { createApiExtension, createApiFactory, discoveryApiRef, fetchApiRef, createPageExtension, createPlugin } from '@backstage/frontend-plugin-api';
3
+ import { azureDevOpsApiRef } from '../api/AzureDevOpsApi.esm.js';
4
+ import { AzureDevOpsClient } from '../api/AzureDevOpsClient.esm.js';
5
+ import { convertLegacyRouteRef, compatWrapper } from '@backstage/core-compat-api';
6
+ import { createEntityContentExtension, createEntityCardExtension } from '@backstage/plugin-catalog-react/alpha';
7
+ import { azurePullRequestDashboardRouteRef } from '../routes.esm.js';
8
+
9
+ const azureDevOpsApi = createApiExtension({
10
+ factory: createApiFactory({
11
+ api: azureDevOpsApiRef,
12
+ deps: {
13
+ discoveryApi: discoveryApiRef,
14
+ fetchApi: fetchApiRef
15
+ },
16
+ factory: ({ discoveryApi, fetchApi }) => new AzureDevOpsClient({ discoveryApi, fetchApi })
17
+ })
18
+ });
19
+ const azureDevOpsPullRequestPage = createPageExtension({
20
+ defaultPath: "/azure-pull-requests",
21
+ routeRef: convertLegacyRouteRef(azurePullRequestDashboardRouteRef),
22
+ loader: () => import('../components/PullRequestsPage/index.esm.js').then(
23
+ (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.PullRequestsPage, null))
24
+ )
25
+ });
26
+ const azureDevOpsPipelinesEntityContent = createEntityContentExtension({
27
+ name: "pipelines",
28
+ defaultPath: "/pipelines",
29
+ defaultTitle: "Pipelines",
30
+ loader: () => import('../components/EntityPageAzurePipelines/index.esm.js').then(
31
+ (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.EntityPageAzurePipelines, null))
32
+ )
33
+ });
34
+ const azureDevOpsGitTagsEntityContent = createEntityContentExtension({
35
+ name: "git-tags",
36
+ defaultPath: "/git-tags",
37
+ defaultTitle: "Git Tags",
38
+ loader: () => import('../components/EntityPageAzureGitTags/index.esm.js').then(
39
+ (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.EntityPageAzureGitTags, null))
40
+ )
41
+ });
42
+ const azureDevOpsPullRequestsEntityContent = createEntityContentExtension({
43
+ name: "pull-requests",
44
+ defaultPath: "/pull-requests",
45
+ defaultTitle: "Pull Requests",
46
+ loader: () => import('../components/EntityPageAzurePullRequests/index.esm.js').then(
47
+ (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.EntityPageAzurePullRequests, null))
48
+ )
49
+ });
50
+ const azureDevOpsReadmeEntityCard = createEntityCardExtension({
51
+ name: "readme",
52
+ loader: async () => import('../components/ReadmeCard/index.esm.js').then(
53
+ (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.ReadmeCard, null))
54
+ )
55
+ });
56
+ var plugin = createPlugin({
57
+ id: "azure-devops",
58
+ extensions: [
59
+ azureDevOpsApi,
60
+ azureDevOpsReadmeEntityCard,
61
+ azureDevOpsPipelinesEntityContent,
62
+ azureDevOpsGitTagsEntityContent,
63
+ azureDevOpsPullRequestsEntityContent,
64
+ azureDevOpsPullRequestPage
65
+ ]
66
+ });
67
+
68
+ export { azureDevOpsApi, azureDevOpsGitTagsEntityContent, azureDevOpsPipelinesEntityContent, azureDevOpsPullRequestPage, azureDevOpsPullRequestsEntityContent, azureDevOpsReadmeEntityCard, plugin as default };
69
+ //# sourceMappingURL=plugin.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.esm.js","sources":["../../src/alpha/plugin.tsx"],"sourcesContent":["/*\n * Copyright 2023 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 {\n createApiExtension,\n createApiFactory,\n createPageExtension,\n createPlugin,\n discoveryApiRef,\n fetchApiRef,\n} from '@backstage/frontend-plugin-api';\nimport { azureDevOpsApiRef, AzureDevOpsClient } from '../api';\nimport {\n compatWrapper,\n convertLegacyRouteRef,\n} from '@backstage/core-compat-api';\nimport {\n createEntityCardExtension,\n createEntityContentExtension,\n} from '@backstage/plugin-catalog-react/alpha';\nimport { azurePullRequestDashboardRouteRef } from '../routes';\n\n/** @alpha */\nexport const azureDevOpsApi = createApiExtension({\n factory: createApiFactory({\n api: azureDevOpsApiRef,\n deps: {\n discoveryApi: discoveryApiRef,\n fetchApi: fetchApiRef,\n },\n factory: ({ discoveryApi, fetchApi }) =>\n new AzureDevOpsClient({ discoveryApi, fetchApi }),\n }),\n});\n\n/** @alpha */\nexport const azureDevOpsPullRequestPage = createPageExtension({\n defaultPath: '/azure-pull-requests',\n routeRef: convertLegacyRouteRef(azurePullRequestDashboardRouteRef),\n loader: () =>\n import('../components/PullRequestsPage').then(m =>\n compatWrapper(<m.PullRequestsPage />),\n ),\n});\n\n/** @alpha */\nexport const azureDevOpsPipelinesEntityContent = createEntityContentExtension({\n name: 'pipelines',\n defaultPath: '/pipelines',\n defaultTitle: 'Pipelines',\n loader: () =>\n import('../components/EntityPageAzurePipelines').then(m =>\n compatWrapper(<m.EntityPageAzurePipelines />),\n ),\n});\n\n/** @alpha */\nexport const azureDevOpsGitTagsEntityContent = createEntityContentExtension({\n name: 'git-tags',\n defaultPath: '/git-tags',\n defaultTitle: 'Git Tags',\n loader: () =>\n import('../components/EntityPageAzureGitTags').then(m =>\n compatWrapper(<m.EntityPageAzureGitTags />),\n ),\n});\n\n/** @alpha */\nexport const azureDevOpsPullRequestsEntityContent =\n createEntityContentExtension({\n name: 'pull-requests',\n defaultPath: '/pull-requests',\n defaultTitle: 'Pull Requests',\n loader: () =>\n import('../components/EntityPageAzurePullRequests').then(m =>\n compatWrapper(<m.EntityPageAzurePullRequests />),\n ),\n });\n\n/** @alpha */\nexport const azureDevOpsReadmeEntityCard = createEntityCardExtension({\n name: 'readme',\n loader: async () =>\n import('../components/ReadmeCard').then(m =>\n compatWrapper(<m.ReadmeCard />),\n ),\n});\n\n/** @alpha */\nexport default createPlugin({\n id: 'azure-devops',\n extensions: [\n azureDevOpsApi,\n azureDevOpsReadmeEntityCard,\n azureDevOpsPipelinesEntityContent,\n azureDevOpsGitTagsEntityContent,\n azureDevOpsPullRequestsEntityContent,\n azureDevOpsPullRequestPage,\n ],\n});\n"],"names":[],"mappings":";;;;;;;;AAqCO,MAAM,iBAAiB,kBAAmB,CAAA;AAAA,EAC/C,SAAS,gBAAiB,CAAA;AAAA,IACxB,GAAK,EAAA,iBAAA;AAAA,IACL,IAAM,EAAA;AAAA,MACJ,YAAc,EAAA,eAAA;AAAA,MACd,QAAU,EAAA,WAAA;AAAA,KACZ;AAAA,IACA,OAAA,EAAS,CAAC,EAAE,YAAc,EA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AAA;AAAA,IAAK,OACvD,aAAc,iBAAA,KAAA,CAAA,aAAA,CAAC,CAAE,CAAA,2BAAA,EAAF,IAA8B,CAAE,CAAA;AAAA,GACjD;AACJ,CAAC,EAAA;AAGI,MAAM,8BAA8B,yBAA0B,CAAA;AAAA,EACnE,IAAM,EAAA,QAAA;AAAA,EACN,MAAQ,EAAA,YACN,OAAO,uCAA0B,CAAE,CAAA,IAAA;AAAA,IAAK,OACtC,aAAc,iBAAA,KAAA,CAAA,aAAA,CAAC,CAAE,CAAA,UAAA,EAAF,IAAa,CAAE,CAAA;AAAA,GAChC;AACJ,CAAC,EAAA;AAGD,aAAe,YAAa,CAAA;AAAA,EAC1B,EAAI,EAAA,cAAA;AAAA,EACJ,UAAY,EAAA;AAAA,IACV,cAAA;AAAA,IACA,2BAAA;AAAA,IACA,iCAAA;AAAA,IACA,+BAAA;AAAA,IACA,oCAAA;AAAA,IACA,0BAAA;AAAA,GACF;AACF,CAAC,CAAA;;;;"}
package/dist/alpha.esm.js CHANGED
@@ -1,69 +1,2 @@
1
- import React from 'react';
2
- import { createApiExtension, createApiFactory, discoveryApiRef, fetchApiRef, createPageExtension, createPlugin } from '@backstage/frontend-plugin-api';
3
- import { a as azureDevOpsApiRef, A as AzureDevOpsClient, b as azurePullRequestDashboardRouteRef } from './esm/AzureDevOpsApi-GBxs-uQ7.esm.js';
4
- import { convertLegacyRouteRef, compatWrapper } from '@backstage/core-compat-api';
5
- import { createEntityContentExtension, createEntityCardExtension } from '@backstage/plugin-catalog-react/alpha';
6
- import '@backstage/core-plugin-api';
7
- import '@backstage/errors';
8
-
9
- const azureDevOpsApi = createApiExtension({
10
- factory: createApiFactory({
11
- api: azureDevOpsApiRef,
12
- deps: {
13
- discoveryApi: discoveryApiRef,
14
- fetchApi: fetchApiRef
15
- },
16
- factory: ({ discoveryApi, fetchApi }) => new AzureDevOpsClient({ discoveryApi, fetchApi })
17
- })
18
- });
19
- const azureDevOpsPullRequestPage = createPageExtension({
20
- defaultPath: "/azure-pull-requests",
21
- routeRef: convertLegacyRouteRef(azurePullRequestDashboardRouteRef),
22
- loader: () => import('./esm/index-W1pvc5vi.esm.js').then(
23
- (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.PullRequestsPage, null))
24
- )
25
- });
26
- const azureDevOpsPipelinesEntityContent = createEntityContentExtension({
27
- name: "pipelines",
28
- defaultPath: "/pipelines",
29
- defaultTitle: "Pipelines",
30
- loader: () => import('./esm/index-Bwu2-Sgs.esm.js').then(
31
- (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.EntityPageAzurePipelines, null))
32
- )
33
- });
34
- const azureDevOpsGitTagsEntityContent = createEntityContentExtension({
35
- name: "git-tags",
36
- defaultPath: "/git-tags",
37
- defaultTitle: "Git Tags",
38
- loader: () => import('./esm/index-1Rl7C23d.esm.js').then(
39
- (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.EntityPageAzureGitTags, null))
40
- )
41
- });
42
- const azureDevOpsPullRequestsEntityContent = createEntityContentExtension({
43
- name: "pull-requests",
44
- defaultPath: "/pull-requests",
45
- defaultTitle: "Pull Requests",
46
- loader: () => import('./esm/index-Bo-6jkQA.esm.js').then(
47
- (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.EntityPageAzurePullRequests, null))
48
- )
49
- });
50
- const azureDevOpsReadmeEntityCard = createEntityCardExtension({
51
- name: "readme",
52
- loader: async () => import('./esm/index-BJ_pWnMh.esm.js').then(
53
- (m) => compatWrapper(/* @__PURE__ */ React.createElement(m.ReadmeCard, null))
54
- )
55
- });
56
- var plugin = createPlugin({
57
- id: "azure-devops",
58
- extensions: [
59
- azureDevOpsApi,
60
- azureDevOpsReadmeEntityCard,
61
- azureDevOpsPipelinesEntityContent,
62
- azureDevOpsGitTagsEntityContent,
63
- azureDevOpsPullRequestsEntityContent,
64
- azureDevOpsPullRequestPage
65
- ]
66
- });
67
-
68
- export { plugin as default };
1
+ export { default } from './alpha/plugin.esm.js';
69
2
  //# sourceMappingURL=alpha.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"alpha.esm.js","sources":["../src/alpha/plugin.tsx"],"sourcesContent":["/*\n * Copyright 2023 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 {\n createApiExtension,\n createApiFactory,\n createPageExtension,\n createPlugin,\n discoveryApiRef,\n fetchApiRef,\n} from '@backstage/frontend-plugin-api';\nimport { azureDevOpsApiRef, AzureDevOpsClient } from '../api';\nimport {\n compatWrapper,\n convertLegacyRouteRef,\n} from '@backstage/core-compat-api';\nimport {\n createEntityCardExtension,\n createEntityContentExtension,\n} from '@backstage/plugin-catalog-react/alpha';\nimport { azurePullRequestDashboardRouteRef } from '../routes';\n\n/** @alpha */\nexport const azureDevOpsApi = createApiExtension({\n factory: createApiFactory({\n api: azureDevOpsApiRef,\n deps: {\n discoveryApi: discoveryApiRef,\n fetchApi: fetchApiRef,\n },\n factory: ({ discoveryApi, fetchApi }) =>\n new AzureDevOpsClient({ discoveryApi, fetchApi }),\n }),\n});\n\n/** @alpha */\nexport const azureDevOpsPullRequestPage = createPageExtension({\n defaultPath: '/azure-pull-requests',\n routeRef: convertLegacyRouteRef(azurePullRequestDashboardRouteRef),\n loader: () =>\n import('../components/PullRequestsPage').then(m =>\n compatWrapper(<m.PullRequestsPage />),\n ),\n});\n\n/** @alpha */\nexport const azureDevOpsPipelinesEntityContent = createEntityContentExtension({\n name: 'pipelines',\n defaultPath: '/pipelines',\n defaultTitle: 'Pipelines',\n loader: () =>\n import('../components/EntityPageAzurePipelines').then(m =>\n compatWrapper(<m.EntityPageAzurePipelines />),\n ),\n});\n\n/** @alpha */\nexport const azureDevOpsGitTagsEntityContent = createEntityContentExtension({\n name: 'git-tags',\n defaultPath: '/git-tags',\n defaultTitle: 'Git Tags',\n loader: () =>\n import('../components/EntityPageAzureGitTags').then(m =>\n compatWrapper(<m.EntityPageAzureGitTags />),\n ),\n});\n\n/** @alpha */\nexport const azureDevOpsPullRequestsEntityContent =\n createEntityContentExtension({\n name: 'pull-requests',\n defaultPath: '/pull-requests',\n defaultTitle: 'Pull Requests',\n loader: () =>\n import('../components/EntityPageAzurePullRequests').then(m =>\n compatWrapper(<m.EntityPageAzurePullRequests />),\n ),\n });\n\n/** @alpha */\nexport const azureDevOpsReadmeEntityCard = createEntityCardExtension({\n name: 'readme',\n loader: async () =>\n import('../components/ReadmeCard').then(m =>\n compatWrapper(<m.ReadmeCard />),\n ),\n});\n\n/** @alpha */\nexport default createPlugin({\n id: 'azure-devops',\n extensions: [\n azureDevOpsApi,\n azureDevOpsReadmeEntityCard,\n azureDevOpsPipelinesEntityContent,\n azureDevOpsGitTagsEntityContent,\n azureDevOpsPullRequestsEntityContent,\n azureDevOpsPullRequestPage,\n ],\n});\n"],"names":[],"mappings":";;;;;;;;AAqCO,MAAM,iBAAiB,kBAAmB,CAAA;AAAA,EAC/C,SAAS,gBAAiB,CAAA;AAAA,IACxB,GAAK,EAAA,iBAAA;AAAA,IACL,IAAM,EAAA;AAAA,MACJ,YAAc,EAAA,eAAA;AAAA,MACd,QAAU,EAAA,WAAA;AAAA,KACZ;AAAA,IACA,OAAA,EAAS,CAAC,EAAE,YAAc,EAAA,QAAA,EACxB,KAAA,IAAI,iBAAkB,CAAA,EAAE,YAAc,EAAA,QAAA,EAAU,CAAA;AAAA,GACnD,CAAA;AACH,CAAC,CAAA,CAAA;AAGM,MAAM,6BAA6B,mBAAoB,CAAA;AAAA,EAC5D,WAAa,EAAA,sBAAA;AAAA,EACb,QAAA,EAAU,sBAAsB,iCAAiC,CAAA;AAAA,EACjE,MAAQ,EAAA,MACN,OAAO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AA0B,CAAE,CAAA,IAAA;AAAA,IAAK,OACtC,aAAc,iBAAA,KAAA,CAAA,aAAA,CAAC,CAAE,CAAA,UAAA,EAAF,IAAa,CAAE,CAAA;AAAA,GAChC;AACJ,CAAC,CAAA,CAAA;AAGD,aAAe,YAAa,CAAA;AAAA,EAC1B,EAAI,EAAA,cAAA;AAAA,EACJ,UAAY,EAAA;AAAA,IACV,cAAA;AAAA,IACA,2BAAA;AAAA,IACA,iCAAA;AAAA,IACA,+BAAA;AAAA,IACA,oCAAA;AAAA,IACA,0BAAA;AAAA,GACF;AACF,CAAC,CAAA;;;;"}
1
+ {"version":3,"file":"alpha.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,8 @@
1
+ import { createApiRef } from '@backstage/core-plugin-api';
2
+
3
+ const azureDevOpsApiRef = createApiRef({
4
+ id: "plugin.azure-devops.service"
5
+ });
6
+
7
+ export { azureDevOpsApiRef };
8
+ //# sourceMappingURL=AzureDevOpsApi.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AzureDevOpsApi.esm.js","sources":["../../src/api/AzureDevOpsApi.ts"],"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 BuildRun,\n BuildRunOptions,\n DashboardPullRequest,\n GitTag,\n PullRequest,\n PullRequestOptions,\n Readme,\n ReadmeConfig,\n RepoBuild,\n RepoBuildOptions,\n Team,\n} from '@backstage-community/plugin-azure-devops-common';\n\nimport { createApiRef } from '@backstage/core-plugin-api';\n\n/** @public */\nexport const azureDevOpsApiRef = createApiRef<AzureDevOpsApi>({\n id: 'plugin.azure-devops.service',\n});\n\n/** @public */\nexport interface AzureDevOpsApi {\n getRepoBuilds(\n projectName: string,\n repoName: string,\n host?: string,\n org?: string,\n options?: RepoBuildOptions,\n ): Promise<{ items: RepoBuild[] }>;\n\n getGitTags(\n projectName: string,\n repoName: string,\n entityRef: string,\n host?: string,\n org?: string,\n ): Promise<{ items: GitTag[] }>;\n\n getPullRequests(\n projectName: string,\n repoName: string,\n entityRef: string,\n host?: string,\n org?: string,\n options?: PullRequestOptions,\n ): Promise<{ items: PullRequest[] }>;\n\n getDashboardPullRequests(\n projectName: string,\n teamsLimit?: number,\n ): Promise<DashboardPullRequest[]>;\n\n getAllTeams(limit?: number): Promise<Team[]>;\n\n getUserTeamIds(userId: string): Promise<string[]>;\n\n getBuildRuns(\n projectName: string,\n entityRef: string,\n repoName?: string,\n definitionName?: string,\n host?: string,\n org?: string,\n options?: BuildRunOptions,\n ): Promise<{ items: BuildRun[] }>;\n\n getReadme(opts: ReadmeConfig): Promise<Readme>;\n}\n"],"names":[],"mappings":";;AAiCO,MAAM,oBAAoB,YAA6B,CAAA;AAAA,EAC5D,EAAI,EAAA,6BAAA;AACN,CAAC;;;;"}
@@ -1,35 +1,15 @@
1
- import { createRouteRef, createApiRef } from '@backstage/core-plugin-api';
2
1
  import { ResponseError } from '@backstage/errors';
3
2
 
4
- const azurePullRequestDashboardRouteRef = createRouteRef({
5
- id: "azure-pull-request-dashboard"
6
- });
7
- const azurePipelinesEntityContentRouteRef = createRouteRef({
8
- id: "azure-pipelines-entity-content"
9
- });
10
- const azureGitTagsEntityContentRouteRef = createRouteRef({
11
- id: "azure-git-tags-entity-content"
12
- });
13
- const azurePullRequestsEntityContentRouteRef = createRouteRef({
14
- id: "azure-pull-requests-entity-content"
15
- });
16
-
17
- var __defProp = Object.defineProperty;
18
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
19
- var __publicField = (obj, key, value) => {
20
- __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
21
- return value;
22
- };
23
3
  class AzureDevOpsClient {
4
+ discoveryApi;
5
+ fetchApi;
24
6
  constructor(options) {
25
- __publicField(this, "discoveryApi");
26
- __publicField(this, "fetchApi");
27
7
  this.discoveryApi = options.discoveryApi;
28
8
  this.fetchApi = options.fetchApi;
29
9
  }
30
10
  async getRepoBuilds(projectName, repoName, host, org, options) {
31
11
  const queryString = new URLSearchParams();
32
- if (options == null ? void 0 : options.top) {
12
+ if (options?.top) {
33
13
  queryString.append("top", options.top.toString());
34
14
  }
35
15
  if (host) {
@@ -61,13 +41,13 @@ class AzureDevOpsClient {
61
41
  }
62
42
  async getPullRequests(projectName, repoName, entityRef, host, org, options) {
63
43
  const queryString = new URLSearchParams();
64
- if (options == null ? void 0 : options.top) {
44
+ if (options?.top) {
65
45
  queryString.append("top", options.top.toString());
66
46
  }
67
- if (options == null ? void 0 : options.status) {
47
+ if (options?.status) {
68
48
  queryString.append("status", options.status.toString());
69
49
  }
70
- if (options == null ? void 0 : options.teamsLimit) {
50
+ if (options?.teamsLimit) {
71
51
  queryString.append("teamsLimit", options.teamsLimit.toString());
72
52
  }
73
53
  if (host) {
@@ -108,6 +88,7 @@ class AzureDevOpsClient {
108
88
  }
109
89
  async getBuildRuns(projectName, entityRef, repoName, definitionName, host, org, options) {
110
90
  const queryString = new URLSearchParams();
91
+ queryString.append("entityRef", entityRef);
111
92
  if (repoName) {
112
93
  queryString.append("repoName", repoName);
113
94
  }
@@ -123,10 +104,9 @@ class AzureDevOpsClient {
123
104
  const buildRuns = [];
124
105
  for (const name of definitionNames) {
125
106
  queryString.set("definitionName", name.trim());
126
- if (options == null ? void 0 : options.top) {
107
+ if (options?.top) {
127
108
  queryString.set("top", options.top.toString());
128
109
  }
129
- queryString.append("entityRef", entityRef);
130
110
  const urlSegment2 = `builds/${encodeURIComponent(
131
111
  projectName
132
112
  )}?${queryString}`;
@@ -137,10 +117,9 @@ class AzureDevOpsClient {
137
117
  }
138
118
  queryString.append("definitionName", definitionName.trim());
139
119
  }
140
- if (options == null ? void 0 : options.top) {
120
+ if (options?.top) {
141
121
  queryString.append("top", options.top.toString());
142
122
  }
143
- queryString.append("entityRef", entityRef);
144
123
  const urlSegment = `builds/${encodeURIComponent(
145
124
  projectName
146
125
  )}?${queryString}`;
@@ -176,9 +155,5 @@ class AzureDevOpsClient {
176
155
  }
177
156
  }
178
157
 
179
- const azureDevOpsApiRef = createApiRef({
180
- id: "plugin.azure-devops.service"
181
- });
182
-
183
- export { AzureDevOpsClient as A, azureDevOpsApiRef as a, azurePullRequestDashboardRouteRef as b, azurePipelinesEntityContentRouteRef as c, azureGitTagsEntityContentRouteRef as d, azurePullRequestsEntityContentRouteRef as e };
184
- //# sourceMappingURL=AzureDevOpsApi-GBxs-uQ7.esm.js.map
158
+ export { AzureDevOpsClient };
159
+ //# sourceMappingURL=AzureDevOpsClient.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AzureDevOpsClient.esm.js","sources":["../../src/api/AzureDevOpsClient.ts"],"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 BuildRun,\n BuildRunOptions,\n DashboardPullRequest,\n GitTag,\n PullRequest,\n PullRequestOptions,\n Readme,\n ReadmeConfig,\n RepoBuild,\n RepoBuildOptions,\n Team,\n} from '@backstage-community/plugin-azure-devops-common';\nimport { DiscoveryApi, FetchApi } from '@backstage/core-plugin-api';\nimport { ResponseError } from '@backstage/errors';\nimport { AzureDevOpsApi } from './AzureDevOpsApi';\n\n/** @public */\nexport class AzureDevOpsClient implements AzureDevOpsApi {\n private readonly discoveryApi: DiscoveryApi;\n private readonly fetchApi: FetchApi;\n\n public constructor(options: {\n discoveryApi: DiscoveryApi;\n fetchApi: FetchApi;\n }) {\n this.discoveryApi = options.discoveryApi;\n this.fetchApi = options.fetchApi;\n }\n\n public async getRepoBuilds(\n projectName: string,\n repoName: string,\n host?: string,\n org?: string,\n options?: RepoBuildOptions,\n ): Promise<{ items: RepoBuild[] }> {\n const queryString = new URLSearchParams();\n if (options?.top) {\n queryString.append('top', options.top.toString());\n }\n if (host) {\n queryString.append('host', host);\n }\n if (org) {\n queryString.append('org', org);\n }\n const urlSegment = `repo-builds/${encodeURIComponent(\n projectName,\n )}/${encodeURIComponent(repoName)}?${queryString}`;\n\n const items = await this.get<RepoBuild[]>(urlSegment);\n return { items };\n }\n\n public async getGitTags(\n projectName: string,\n repoName: string,\n entityRef: string,\n host?: string,\n org?: string,\n ): Promise<{ items: GitTag[] }> {\n const queryString = new URLSearchParams();\n if (host) {\n queryString.append('host', host);\n }\n if (org) {\n queryString.append('org', org);\n }\n queryString.append('entityRef', entityRef);\n const urlSegment = `git-tags/${encodeURIComponent(\n projectName,\n )}/${encodeURIComponent(repoName)}?${queryString}`;\n\n const items = await this.get<GitTag[]>(urlSegment);\n return { items };\n }\n\n public async getPullRequests(\n projectName: string,\n repoName: string,\n entityRef: string,\n host?: string,\n org?: string,\n options?: PullRequestOptions,\n ): Promise<{ items: PullRequest[] }> {\n const queryString = new URLSearchParams();\n if (options?.top) {\n queryString.append('top', options.top.toString());\n }\n if (options?.status) {\n queryString.append('status', options.status.toString());\n }\n if (options?.teamsLimit) {\n queryString.append('teamsLimit', options.teamsLimit.toString());\n }\n if (host) {\n queryString.append('host', host);\n }\n if (org) {\n queryString.append('org', org);\n }\n queryString.append('entityRef', entityRef);\n const urlSegment = `pull-requests/${encodeURIComponent(\n projectName,\n )}/${encodeURIComponent(repoName)}?${queryString}`;\n\n const items = await this.get<PullRequest[]>(urlSegment);\n return { items };\n }\n\n public getDashboardPullRequests(\n projectName: string,\n teamsLimit?: number,\n ): Promise<DashboardPullRequest[]> {\n const queryString = new URLSearchParams();\n queryString.append('top', '100');\n if (teamsLimit) {\n queryString.append('teamsLimit', teamsLimit.toString());\n }\n const urlSegment = `dashboard-pull-requests/${projectName}?${queryString}`;\n return this.get<DashboardPullRequest[]>(urlSegment);\n }\n\n public getAllTeams(limit?: number): Promise<Team[]> {\n const queryString = new URLSearchParams();\n if (limit) {\n queryString.append('limit', limit.toString());\n }\n let urlSegment = 'all-teams';\n if (queryString.toString()) {\n urlSegment += `?${queryString}`;\n }\n return this.get<Team[]>(urlSegment);\n }\n\n public getUserTeamIds(userId: string): Promise<string[]> {\n return this.get<string[]>(`users/${userId}/team-ids`);\n }\n\n public async getBuildRuns(\n projectName: string,\n entityRef: string,\n repoName?: string,\n definitionName?: string,\n host?: string,\n org?: string,\n options?: BuildRunOptions,\n ): Promise<{ items: BuildRun[] }> {\n const queryString = new URLSearchParams();\n queryString.append('entityRef', entityRef);\n if (repoName) {\n queryString.append('repoName', repoName);\n }\n if (host) {\n queryString.append('host', host);\n }\n if (org) {\n queryString.append('org', org);\n }\n if (definitionName) {\n const definitionNames = definitionName.split(',');\n if (definitionNames.length > 1) {\n const buildRuns: BuildRun[] = [];\n for (const name of definitionNames) {\n queryString.set('definitionName', name.trim());\n if (options?.top) {\n queryString.set('top', options.top.toString());\n }\n const urlSegment = `builds/${encodeURIComponent(\n projectName,\n )}?${queryString}`;\n const items = await this.get<BuildRun[]>(urlSegment);\n buildRuns.push(...items);\n }\n return { items: buildRuns };\n }\n queryString.append('definitionName', definitionName.trim());\n }\n if (options?.top) {\n queryString.append('top', options.top.toString());\n }\n const urlSegment = `builds/${encodeURIComponent(\n projectName,\n )}?${queryString}`;\n const items = await this.get<BuildRun[]>(urlSegment);\n return { items };\n }\n\n public async getReadme(opts: ReadmeConfig): Promise<Readme> {\n const queryString = new URLSearchParams();\n if (opts.host) {\n queryString.append('host', opts.host);\n }\n if (opts.org) {\n queryString.append('org', opts.org);\n }\n if (opts.path) {\n queryString.append('path', opts.path);\n }\n queryString.append('entityRef', opts.entityRef);\n return await this.get(\n `readme/${encodeURIComponent(opts.project)}/${encodeURIComponent(\n opts.repo,\n )}?${queryString}`,\n );\n }\n\n private async get<T>(path: string): Promise<T> {\n const baseUrl = `${await this.discoveryApi.getBaseUrl('azure-devops')}/`;\n const url = new URL(path, baseUrl);\n\n const response = await this.fetchApi.fetch(url.toString());\n\n if (!response.ok) {\n throw await ResponseError.fromResponse(response);\n }\n\n return response.json() as Promise<T>;\n }\n}\n"],"names":["urlSegment","items"],"mappings":";;AAkCO,MAAM,iBAA4C,CAAA;AAAA,EACtC,YAAA,CAAA;AAAA,EACA,QAAA,CAAA;AAAA,EAEV,YAAY,OAGhB,EAAA;AACD,IAAA,IAAA,CAAK,eAAe,OAAQ,CAAA,YAAA,CAAA;AAC5B,IAAA,IAAA,CAAK,WAAW,OAAQ,CAAA,QAAA,CAAA;AAAA,GAC1B;AAAA,EAEA,MAAa,aACX,CAAA,WAAA,EACA,QACA,EAAA,IAAA,EACA,KACA,OACiC,EAAA;AACjC,IAAM,MAAA,WAAA,GAAc,IAAI,eAAgB,EAAA,CAAA;AACxC,IAAA,IAAI,SAAS,GAAK,EAAA;AAChB,MAAA,WAAA,CAAY,MAAO,CAAA,KAAA,EAAO,OAAQ,CAAA,GAAA,CAAI,UAAU,CAAA,CAAA;AAAA,KAClD;AACA,IAAA,IAAI,IAAM,EAAA;AACR,MAAY,WAAA,CAAA,MAAA,CAAO,QAAQ,IAAI,CAAA,CAAA;AAAA,KACjC;AACA,IAAA,IAAI,GAAK,EAAA;AACP,MAAY,WAAA,CAAA,MAAA,CAAO,OAAO,GAAG,CAAA,CAAA;AAAA,KAC/B;AACA,IAAA,MAAM,aAAa,CAAe,YAAA,EAAA,kBAAA;AAAA,MAChC,WAAA;AAAA,KACD,CAAI,CAAA,EAAA,kBAAA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(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" }));
5
+
6
+ export { AzureGitTagsIcon };
7
+ //# sourceMappingURL=AzureGitTagsIcon.esm.js.map
@@ -0,0 +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 '@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;;;;"}
@@ -0,0 +1,27 @@
1
+ import SvgIcon from '@material-ui/core/SvgIcon';
2
+ import React from 'react';
3
+
4
+ const AzurePipelinesIcon = (props) => /* @__PURE__ */ React.createElement(SvgIcon, { ...props, viewBox: "0 0 512 512" }, /* @__PURE__ */ React.createElement(
5
+ "path",
6
+ {
7
+ fill: "none",
8
+ stroke: "currentColor",
9
+ strokeLinecap: "round",
10
+ strokeLinejoin: "round",
11
+ strokeWidth: "32",
12
+ 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"
13
+ }
14
+ ), /* @__PURE__ */ React.createElement(
15
+ "path",
16
+ {
17
+ fill: "none",
18
+ stroke: "currentColor",
19
+ strokeLinecap: "round",
20
+ strokeLinejoin: "round",
21
+ strokeWidth: "32",
22
+ 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"
23
+ }
24
+ ));
25
+
26
+ export { AzurePipelinesIcon };
27
+ //# sourceMappingURL=AzurePipelinesIcon.esm.js.map
@@ -0,0 +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 '@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;;;;"}
@@ -59,5 +59,5 @@ const AzurePullRequestsIcon = (props) => /* @__PURE__ */ React.createElement(Svg
59
59
  }
60
60
  ));
61
61
 
62
- export { AzurePullRequestsIcon as A };
63
- //# sourceMappingURL=AzurePullRequestsIcon-DOAkj-X3.esm.js.map
62
+ export { AzurePullRequestsIcon };
63
+ //# sourceMappingURL=AzurePullRequestsIcon.esm.js.map
@@ -0,0 +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 '@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,97 +1,11 @@
1
1
  import Box from '@material-ui/core/Box';
2
2
  import Typography from '@material-ui/core/Typography';
3
- import { AZURE_DEVOPS_DEFAULT_TOP, BuildStatus, BuildResult, azureDevOpsPipelineReadPermission } from '@backstage-community/plugin-azure-devops-common';
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
- import SvgIcon from '@material-ui/core/SvgIcon';
5
+ import { AzurePipelinesIcon } from '../AzurePipelinesIcon/AzurePipelinesIcon.esm.js';
6
+ import { DateTime } from 'luxon';
6
7
  import React from 'react';
7
- import { DateTime, Interval } from 'luxon';
8
- import humanizeDuration from 'humanize-duration';
9
- import { a as azureDevOpsApiRef } from './AzureDevOpsApi-GBxs-uQ7.esm.js';
10
- import '@backstage/errors';
11
- import { useApi } from '@backstage/core-plugin-api';
12
- import useAsync from 'react-use/esm/useAsync';
13
- import 'react-use/esm/useAsyncRetry';
14
- import 'react-use/esm/useInterval';
15
- import { stringifyEntityRef } from '@backstage/catalog-model';
16
- import { g as getAnnotationValuesFromEntity } from './getAnnotationValuesFromEntity-G8YVs-3R.esm.js';
17
- import { useEntity } from '@backstage/plugin-catalog-react';
18
- import { RequirePermission } from '@backstage/plugin-permission-react';
19
-
20
- const getDurationFromDates = (startTime, finishTime) => {
21
- if (!startTime || !startTime && !finishTime) {
22
- return "";
23
- }
24
- const start = DateTime.fromISO(startTime);
25
- const finish = finishTime ? DateTime.fromISO(finishTime) : DateTime.now();
26
- const formatted = Interval.fromDateTimes(start, finish).toDuration().valueOf();
27
- const shortEnglishHumanizer = humanizeDuration.humanizer({
28
- language: "shortEn",
29
- languages: {
30
- shortEn: {
31
- y: () => "y",
32
- mo: () => "mo",
33
- w: () => "w",
34
- d: () => "d",
35
- h: () => "h",
36
- m: () => "m",
37
- s: () => "s",
38
- ms: () => "ms"
39
- }
40
- }
41
- });
42
- return shortEnglishHumanizer(formatted, {
43
- largest: 2,
44
- round: true,
45
- spacer: ""
46
- });
47
- };
48
-
49
- function useBuildRuns(entity, defaultLimit) {
50
- const top = defaultLimit != null ? defaultLimit : AZURE_DEVOPS_DEFAULT_TOP;
51
- const options = {
52
- top
53
- };
54
- const api = useApi(azureDevOpsApiRef);
55
- const { value, loading, error } = useAsync(() => {
56
- const { project, repo, definition, host, org } = getAnnotationValuesFromEntity(entity);
57
- return api.getBuildRuns(
58
- project,
59
- stringifyEntityRef(entity),
60
- repo,
61
- definition,
62
- host,
63
- org,
64
- options
65
- );
66
- }, [api]);
67
- return {
68
- items: value == null ? void 0 : value.items,
69
- loading,
70
- error
71
- };
72
- }
73
-
74
- const AzurePipelinesIcon = (props) => /* @__PURE__ */ React.createElement(SvgIcon, { ...props, viewBox: "0 0 512 512" }, /* @__PURE__ */ React.createElement(
75
- "path",
76
- {
77
- fill: "none",
78
- stroke: "currentColor",
79
- strokeLinecap: "round",
80
- strokeLinejoin: "round",
81
- strokeWidth: "32",
82
- 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"
83
- }
84
- ), /* @__PURE__ */ React.createElement(
85
- "path",
86
- {
87
- fill: "none",
88
- stroke: "currentColor",
89
- strokeLinecap: "round",
90
- strokeLinejoin: "round",
91
- strokeWidth: "32",
92
- 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"
93
- }
94
- ));
8
+ import { getDurationFromDates } from '../../utils/getDurationFromDates.esm.js';
95
9
 
96
10
  const getBuildResultComponent = (result) => {
97
11
  switch (result) {
@@ -177,24 +91,10 @@ const BuildTable = ({ items, loading, error }) => {
177
91
  showEmptyDataSourceMessage: !loading
178
92
  },
179
93
  title: /* @__PURE__ */ React.createElement(Box, { display: "flex", alignItems: "center" }, /* @__PURE__ */ React.createElement(AzurePipelinesIcon, { style: { fontSize: 30 } }), /* @__PURE__ */ React.createElement(Box, { mr: 1 }), "Azure Pipelines - Builds (", items ? items.length : 0, ")"),
180
- data: items != null ? items : []
94
+ data: items ?? []
181
95
  }
182
96
  );
183
97
  };
184
98
 
185
- const EntityPageAzurePipelines = (props) => {
186
- const { entity } = useEntity();
187
- const { items, loading, error } = useBuildRuns(entity, props.defaultLimit);
188
- return /* @__PURE__ */ React.createElement(
189
- RequirePermission,
190
- {
191
- permission: azureDevOpsPipelineReadPermission,
192
- resourceRef: stringifyEntityRef(entity),
193
- errorPage: null
194
- },
195
- /* @__PURE__ */ React.createElement(BuildTable, { items, loading, error })
196
- );
197
- };
198
-
199
- export { EntityPageAzurePipelines };
200
- //# sourceMappingURL=index-Bwu2-Sgs.esm.js.map
99
+ export { BuildTable, getBuildResultComponent, getBuildStateComponent };
100
+ //# sourceMappingURL=BuildTable.esm.js.map
@@ -0,0 +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 '@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,Q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AA;AAAA,GAClB,CAAA;AAEJ;;;;"}
@@ -0,0 +1,22 @@
1
+ import { azureDevOpsGitTagReadPermission } from '@backstage-community/plugin-azure-devops-common';
2
+ import { GitTagTable } from '../GitTagTable/GitTagTable.esm.js';
3
+ import React from 'react';
4
+ import { stringifyEntityRef } from '@backstage/catalog-model';
5
+ import { useEntity } from '@backstage/plugin-catalog-react';
6
+ import { RequirePermission } from '@backstage/plugin-permission-react';
7
+
8
+ const EntityPageAzureGitTags = () => {
9
+ const { entity } = useEntity();
10
+ return /* @__PURE__ */ React.createElement(
11
+ RequirePermission,
12
+ {
13
+ permission: azureDevOpsGitTagReadPermission,
14
+ resourceRef: stringifyEntityRef(entity),
15
+ errorPage: null
16
+ },
17
+ /* @__PURE__ */ React.createElement(GitTagTable, null)
18
+ );
19
+ };
20
+
21
+ export { EntityPageAzureGitTags };
22
+ //# sourceMappingURL=EntityPageAzureGitTags.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"EntityPageAzureGitTags.esm.js","sources":["../../../src/components/EntityPageAzureGitTags/EntityPageAzureGitTags.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 { azureDevOpsGitTagReadPermission } from '@backstage-community/plugin-azure-devops-common';\nimport { GitTagTable } from '../GitTagTable/GitTagTable';\nimport React from 'react';\nimport { stringifyEntityRef } from '@backstage/catalog-model';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport { RequirePermission } from '@backstage/plugin-permission-react';\n\nexport const EntityPageAzureGitTags = () => {\n const { entity } = useEntity();\n return (\n <RequirePermission\n permission={azureDevOpsGitTagReadPermission}\n resourceRef={stringifyEntityRef(entity)}\n errorPage={null}\n >\n <GitTagTable />\n </RequirePermission>\n );\n};\n"],"names":[],"mappings":";;;;;;;AAuBO,MAAM,yBAAyB,MAAM;AAC1C,EAAM,MAAA,EAAE,MAAO,EAAA,GAAI,SAAU,EAAA,CAAA;AAC7B,EACE,uBAAA,KAAA,CAAA,aAAA;AAAA,IAAC,iBAAA;AAAA,IAAA;AAAA,MACC,UAAY,EAAA,+BAAA;AAAA,MACZ,WAAA,EAAa,mBAAmB,MAAM,CAAA;AAAA,MACtC,SAAW,EAAA,IAAA;AAAA,KAAA;AAAA,wCAEV,WAAY,EAAA,IAAA,CAAA;AAAA,GACf,CAAA;AAEJ;;;;"}
@@ -0,0 +1,2 @@
1
+ export { EntityPageAzureGitTags } from './EntityPageAzureGitTags.esm.js';
2
+ //# sourceMappingURL=index.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}