@red-hat-developer-hub/backstage-plugin-scorecard 3.0.1 → 4.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/README.md +5 -3
  3. package/package.json +10 -2
package/CHANGELOG.md CHANGED
@@ -1,5 +1,30 @@
1
1
  # @red-hat-developer-hub/backstage-plugin-scorecard
2
2
 
3
+ ## 4.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 3af0fb2: This update introduces new scalar aggregation KPIs in the scorecard configuration, including:
8
+
9
+ - **`sum`**: Single numeric total of latest metric values across owned entities
10
+ - **`average`**: Mean of latest metric values across owned entities
11
+ - **`max`**: Maximum latest metric value across owned entities
12
+ - **`min`**: Minimum latest metric value across owned entities
13
+ - **`count`**: Number of entities with a non-null latest stored value
14
+
15
+ ### Patch Changes
16
+
17
+ - Updated dependencies [3af0fb2]
18
+ - @red-hat-developer-hub/backstage-plugin-scorecard-common@4.1.0
19
+
20
+ ## 4.0.0
21
+
22
+ ### Patch Changes
23
+
24
+ - e9b1af3: Add scalprum config and default app configuration example
25
+ - Updated dependencies [8c14679]
26
+ - @red-hat-developer-hub/backstage-plugin-scorecard-common@4.0.0
27
+
3
28
  ## 3.0.1
4
29
 
5
30
  ### Patch Changes
package/README.md CHANGED
@@ -9,7 +9,7 @@ For NFS, register the default `scorecardPlugin` plus `scorecardTranslationsModul
9
9
  **Features:**
10
10
 
11
11
  - **Entity scorecard tab** — View scorecard metrics on catalog entity pages (components, websites, etc.).
12
- - **Scorecard homepage card** — Show aggregated KPIs on the home page (e.g. GitHub open PRs, Jira open issues). Supports **`statusGrouped`** (multi-slice pie) and **`weightedStatusScore`** (weighted health donut) KPI types configured under **`scorecard.aggregationKPIs`**.
12
+ - **Scorecard homepage card** — Show aggregated KPIs on the home page (e.g. GitHub open PRs, Jira open issues).
13
13
  - **Scorecard Entities page** — Drill down from an aggregated metric to see the list of entities contributing to that metric, with entity-level values and status, so you can identify services impacting the KPI and investigate issues.
14
14
  - **Metric group cards (grid layout)** — Group related metrics into cards with threshold bucket tiles, a filterable/sortable data sources dialog, and a Masonry grid layout. Enabled via app-config.yaml.
15
15
 
@@ -452,9 +452,11 @@ The plugin exports **`ScorecardHomepageCard`** from `@red-hat-developer-hub/back
452
452
 
453
453
  Define KPI ids and optional labels under **`scorecard.aggregationKPIs`** so each card can call **`GET /aggregations/<aggregationId>`** with a stable id. See [Scorecard backend README — Aggregation KPIs](../scorecard-backend/README.md#aggregation-kpis-homepage-and-get-aggregations). If you omit a KPI entry, use the **metric id** as `aggregationId` (default status-grouped aggregation).
454
454
 
455
- **`type: weightedStatusScore`** KPIs require **`options.statusScores`** (weights per threshold rule key). Optionally set **`options.thresholds`** so the API returns **`aggregationChartDisplayColor`** for the headline percentage. Behavior, validation, and drill-down notes are described in [aggregation.md](../scorecard-backend/docs/aggregation.md).
455
+ Supported scorecard aggregation types (see [Entity Aggregation Aggregation types](../scorecard-backend/docs/aggregation.md#aggregation-types)):
456
456
 
457
- For **`type: weightedStatusScore`**, the homepage card shows a **centered donut** with the headline percentage. Hovering the **center** opens a tooltip with **total score**, **max possible score**, and a **per-status breakdown** (from aggregation **`result.values`**). There is **no side status legend**; **`statusGrouped`** cards use a multi-slice pie with a legend instead.
457
+ - [`statusGrouped`](../scorecard-backend/docs/aggregation.md#status-grouped-type) counts per status (pie chart).
458
+ - [`weightedStatusScore`](../scorecard-backend/docs/aggregation.md#weighted-status-score-type) — weighted portfolio health percentage (donut); requires `options.statusScores`.
459
+ - Scalar types ([`sum`](../scorecard-backend/docs/aggregation.md#sum-type), [`average`](../scorecard-backend/docs/aggregation.md#average-type), [`max`](../scorecard-backend/docs/aggregation.md#max-type), [`min`](../scorecard-backend/docs/aggregation.md#min-type), [`count`](../scorecard-backend/docs/aggregation.md#count-type)) — roll up latest numeric metric values; number metrics only.
458
460
 
459
461
  #### Card props
460
462
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@red-hat-developer-hub/backstage-plugin-scorecard",
3
- "version": "3.0.1",
3
+ "version": "4.1.0",
4
4
  "license": "Apache-2.0",
5
5
  "main": "./dist/index.esm.js",
6
6
  "types": "./dist/index.d.ts",
@@ -95,7 +95,7 @@
95
95
  "@mui/icons-material": "5.18.0",
96
96
  "@mui/lab": "5.0.0-alpha.177",
97
97
  "@mui/material": "5.18.0",
98
- "@red-hat-developer-hub/backstage-plugin-scorecard-common": "^3.0.1",
98
+ "@red-hat-developer-hub/backstage-plugin-scorecard-common": "^4.1.0",
99
99
  "@tanstack/react-query": "^5.95.2",
100
100
  "date-fns": "^4.1.0",
101
101
  "react-use": "^17.2.4",
@@ -125,6 +125,14 @@
125
125
  "react": "^16.13.1 || ^17.0.0 || ^18.0.0",
126
126
  "react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0"
127
127
  },
128
+ "scalprum": {
129
+ "name": "red-hat-developer-hub.backstage-plugin-scorecard",
130
+ "exposedModules": {
131
+ "PluginRoot": "./src/index.ts",
132
+ "Legacy": "./src/legacyExports.ts",
133
+ "ScorecardTranslationsModule": "./src/scorecardTranslationsModuleExport.ts"
134
+ }
135
+ },
128
136
  "files": [
129
137
  "dist"
130
138
  ],