@red-hat-developer-hub/backstage-plugin-scorecard 2.7.5 → 2.7.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @red-hat-developer-hub/backstage-plugin-scorecard
2
2
 
3
+ ## 2.7.7
4
+
5
+ ### Patch Changes
6
+
7
+ - 8414dbe: Fixes severity threshold category translation for custom thresholds
8
+ - @red-hat-developer-hub/backstage-plugin-scorecard-common@2.7.7
9
+
10
+ ## 2.7.6
11
+
12
+ ### Patch Changes
13
+
14
+ - 4b07772: Translations updated for de/es/fr/it/ja
15
+ - @red-hat-developer-hub/backstage-plugin-scorecard-common@2.7.6
16
+
3
17
  ## 2.7.5
4
18
 
5
19
  ### Patch Changes
@@ -4,6 +4,9 @@ import Stack from '@mui/material/Stack';
4
4
  import Typography from '@mui/material/Typography';
5
5
  import { TooltipContent, formatAggregationScoreDetail } from './TooltipContent.esm.js';
6
6
  import { useTranslation } from '../../../hooks/useTranslation.esm.js';
7
+ import 'date-fns';
8
+ import { getTranslatedStatus } from '../../../utils/statusUtils.esm.js';
9
+ import '@red-hat-developer-hub/backstage-plugin-scorecard-common';
7
10
 
8
11
  const DonutChartTooltipContent = ({
9
12
  weightedSum,
@@ -11,13 +14,6 @@ const DonutChartTooltipContent = ({
11
14
  statusValues = []
12
15
  }) => {
13
16
  const { t } = useTranslation();
14
- const getStatus = (status) => {
15
- const translatedStatus = t(`thresholds.${status}`, {});
16
- if (translatedStatus === `thresholds.${status}` && status) {
17
- return status.charAt(0).toUpperCase() + status.slice(1);
18
- }
19
- return translatedStatus;
20
- };
21
17
  return /* @__PURE__ */ jsxs(Stack, { spacing: 0.5, sx: { minWidth: 220 }, children: [
22
18
  /* @__PURE__ */ jsxs(Stack, { direction: "row", spacing: 3, children: [
23
19
  /* @__PURE__ */ jsx(
@@ -50,7 +46,7 @@ const DonutChartTooltipContent = ({
50
46
  sx: { color: "text.primary", fontWeight: 500 },
51
47
  children: t("metric.averageCenterTooltipBreakdownRow", {
52
48
  count: row.count,
53
- status: getStatus(row.name),
49
+ status: getTranslatedStatus(row.name, t),
54
50
  score: formatAggregationScoreDetail(row.score ?? 0)
55
51
  })
56
52
  },
@@ -1 +1 @@
1
- {"version":3,"file":"DonutChartTooltipContent.esm.js","sources":["../../../../src/components/AggregatedMetricCards/AverageCard/DonutChartTooltipContent.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { AggregatedMetricValue } from '@red-hat-developer-hub/backstage-plugin-scorecard-common';\nimport Box from '@mui/material/Box';\nimport Stack from '@mui/material/Stack';\nimport Typography from '@mui/material/Typography';\n\nimport { TooltipContent, formatAggregationScoreDetail } from './TooltipContent';\nimport { useTranslation } from '../../../hooks/useTranslation';\n\nexport const DonutChartTooltipContent = ({\n weightedSum,\n maxPossible,\n statusValues = [],\n}: {\n weightedSum: number | undefined;\n maxPossible: number | undefined;\n statusValues?: AggregatedMetricValue[];\n}) => {\n const { t } = useTranslation();\n\n const getStatus = (status: string) => {\n const translatedStatus = t(`thresholds.${status}` as any, {});\n\n if (translatedStatus === `thresholds.${status}` && status) {\n return status.charAt(0).toUpperCase() + status.slice(1);\n }\n\n return translatedStatus;\n };\n\n return (\n <Stack spacing={0.5} sx={{ minWidth: 220 }}>\n <Stack direction=\"row\" spacing={3}>\n <TooltipContent\n label={t('metric.averageCenterTooltipTotalLabel')}\n value={weightedSum}\n />\n <TooltipContent\n label={t('metric.averageCenterTooltipMaxLabel')}\n value={maxPossible}\n />\n </Stack>\n {statusValues.length > 0 ? (\n <Box\n sx={{\n borderTop: 1,\n borderColor: 'divider',\n pt: 1.5,\n }}\n >\n <Stack spacing={0.75}>\n {statusValues.map(row => (\n <Typography\n key={row.name}\n variant=\"body2\"\n sx={{ color: 'text.primary', fontWeight: 500 }}\n >\n {t('metric.averageCenterTooltipBreakdownRow', {\n count: row.count,\n status: getStatus(row.name),\n score: formatAggregationScoreDetail(row.score ?? 0),\n } as any)}\n </Typography>\n ))}\n </Stack>\n </Box>\n ) : null}\n </Stack>\n );\n};\n"],"names":[],"mappings":";;;;;;;AAwBO,MAAM,2BAA2B,CAAC;AAAA,EACvC,WAAA;AAAA,EACA,WAAA;AAAA,EACA,eAAe;AACjB,CAIM,KAAA;AACJ,EAAM,MAAA,EAAE,CAAE,EAAA,GAAI,cAAe,EAAA;AAE7B,EAAM,MAAA,SAAA,GAAY,CAAC,MAAmB,KAAA;AACpC,IAAA,MAAM,mBAAmB,CAAE,CAAA,CAAA,WAAA,EAAc,MAAM,CAAA,CAAA,EAAW,EAAE,CAAA;AAE5D,IAAA,IAAI,gBAAqB,KAAA,CAAA,WAAA,EAAc,MAAM,CAAA,CAAA,IAAM,MAAQ,EAAA;AACzD,MAAO,OAAA,MAAA,CAAO,OAAO,CAAC,CAAA,CAAE,aAAgB,GAAA,MAAA,CAAO,MAAM,CAAC,CAAA;AAAA;AAGxD,IAAO,OAAA,gBAAA;AAAA,GACT;AAEA,EACE,uBAAA,IAAA,CAAC,SAAM,OAAS,EAAA,GAAA,EAAK,IAAI,EAAE,QAAA,EAAU,KACnC,EAAA,QAAA,EAAA;AAAA,oBAAA,IAAA,CAAC,KAAM,EAAA,EAAA,SAAA,EAAU,KAAM,EAAA,OAAA,EAAS,CAC9B,EAAA,QAAA,EAAA;AAAA,sBAAA,GAAA;AAAA,QAAC,cAAA;AAAA,QAAA;AAAA,UACC,KAAA,EAAO,EAAE,uCAAuC,CAAA;AAAA,UAChD,KAAO,EAAA;AAAA;AAAA,OACT;AAAA,sBACA,GAAA;AAAA,QAAC,cAAA;AAAA,QAAA;AAAA,UACC,KAAA,EAAO,EAAE,qCAAqC,CAAA;AAAA,UAC9C,KAAO,EAAA;AAAA;AAAA;AACT,KACF,EAAA,CAAA;AAAA,IACC,YAAA,CAAa,SAAS,CACrB,mBAAA,GAAA;AAAA,MAAC,GAAA;AAAA,MAAA;AAAA,QACC,EAAI,EAAA;AAAA,UACF,SAAW,EAAA,CAAA;AAAA,UACX,WAAa,EAAA,SAAA;AAAA,UACb,EAAI,EAAA;AAAA,SACN;AAAA,QAEA,8BAAC,KAAM,EAAA,EAAA,OAAA,EAAS,IACb,EAAA,QAAA,EAAA,YAAA,CAAa,IAAI,CAChB,GAAA,qBAAA,GAAA;AAAA,UAAC,UAAA;AAAA,UAAA;AAAA,YAEC,OAAQ,EAAA,OAAA;AAAA,YACR,EAAI,EAAA,EAAE,KAAO,EAAA,cAAA,EAAgB,YAAY,GAAI,EAAA;AAAA,YAE5C,YAAE,yCAA2C,EAAA;AAAA,cAC5C,OAAO,GAAI,CAAA,KAAA;AAAA,cACX,MAAA,EAAQ,SAAU,CAAA,GAAA,CAAI,IAAI,CAAA;AAAA,cAC1B,KAAO,EAAA,4BAAA,CAA6B,GAAI,CAAA,KAAA,IAAS,CAAC;AAAA,aAC5C;AAAA,WAAA;AAAA,UARH,GAAI,CAAA;AAAA,SAUZ,CACH,EAAA;AAAA;AAAA,KAEA,GAAA;AAAA,GACN,EAAA,CAAA;AAEJ;;;;"}
1
+ {"version":3,"file":"DonutChartTooltipContent.esm.js","sources":["../../../../src/components/AggregatedMetricCards/AverageCard/DonutChartTooltipContent.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { AggregatedMetricValue } from '@red-hat-developer-hub/backstage-plugin-scorecard-common';\nimport Box from '@mui/material/Box';\nimport Stack from '@mui/material/Stack';\nimport Typography from '@mui/material/Typography';\n\nimport { TooltipContent, formatAggregationScoreDetail } from './TooltipContent';\nimport { useTranslation } from '../../../hooks/useTranslation';\nimport { getTranslatedStatus } from '../../../utils';\n\nexport const DonutChartTooltipContent = ({\n weightedSum,\n maxPossible,\n statusValues = [],\n}: {\n weightedSum: number | undefined;\n maxPossible: number | undefined;\n statusValues?: AggregatedMetricValue[];\n}) => {\n const { t } = useTranslation();\n\n return (\n <Stack spacing={0.5} sx={{ minWidth: 220 }}>\n <Stack direction=\"row\" spacing={3}>\n <TooltipContent\n label={t('metric.averageCenterTooltipTotalLabel')}\n value={weightedSum}\n />\n <TooltipContent\n label={t('metric.averageCenterTooltipMaxLabel')}\n value={maxPossible}\n />\n </Stack>\n {statusValues.length > 0 ? (\n <Box\n sx={{\n borderTop: 1,\n borderColor: 'divider',\n pt: 1.5,\n }}\n >\n <Stack spacing={0.75}>\n {statusValues.map(row => (\n <Typography\n key={row.name}\n variant=\"body2\"\n sx={{ color: 'text.primary', fontWeight: 500 }}\n >\n {t('metric.averageCenterTooltipBreakdownRow', {\n count: row.count,\n status: getTranslatedStatus(row.name, t),\n score: formatAggregationScoreDetail(row.score ?? 0),\n } as any)}\n </Typography>\n ))}\n </Stack>\n </Box>\n ) : null}\n </Stack>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;AAyBO,MAAM,2BAA2B,CAAC;AAAA,EACvC,WAAA;AAAA,EACA,WAAA;AAAA,EACA,eAAe;AACjB,CAIM,KAAA;AACJ,EAAM,MAAA,EAAE,CAAE,EAAA,GAAI,cAAe,EAAA;AAE7B,EACE,uBAAA,IAAA,CAAC,SAAM,OAAS,EAAA,GAAA,EAAK,IAA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+5,7 @@ import { useTheme, styled } from '@mui/material/styles';
5
5
  import { useTranslation } from '../../hooks/useTranslation.esm.js';
6
6
  import { SCORECARD_ERROR_STATE_COLOR } from '../../utils/constants.esm.js';
7
7
  import 'date-fns';
8
- import { resolveStatusColor } from '../../utils/statusUtils.esm.js';
8
+ import { resolveStatusColor, getTranslatedStatus } from '../../utils/statusUtils.esm.js';
9
9
  import { getThresholdRuleColor } from '../../utils/thresholdUtils.esm.js';
10
10
 
11
11
  const StyledLegend = styled(Box)(({ theme }) => ({
@@ -57,10 +57,7 @@ const CustomLegend = (props) => {
57
57
  variant: "body2",
58
58
  sx: { fontSize: "0.875rem", fontWeight: 400 },
59
59
  children: [
60
- (() => {
61
- const translated = t(`thresholds.${ruleKey}`, {});
62
- return translated === `thresholds.${ruleKey}` ? ruleKey.charAt(0).toUpperCase() + ruleKey.slice(1) : translated;
63
- })(),
60
+ getTranslatedStatus(ruleKey, t),
64
61
  ruleExpression && !/^==(?:true|false)$/.test(ruleExpression) && ` ${ruleExpression}`
65
62
  ]
66
63
  }
@@ -1 +1 @@
1
- {"version":3,"file":"CustomLegend.esm.js","sources":["../../../src/components/Scorecard/CustomLegend.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 ThresholdResult,\n ThresholdRule,\n} from '@red-hat-developer-hub/backstage-plugin-scorecard-common';\n\nimport Box from '@mui/material/Box';\nimport Typography from '@mui/material/Typography';\nimport { styled, useTheme } from '@mui/material/styles';\n\nimport { useTranslation } from '../../hooks/useTranslation';\nimport {\n getThresholdRuleColor,\n resolveStatusColor,\n SCORECARD_ERROR_STATE_COLOR,\n} from '../../utils';\n\nconst StyledLegend = styled(Box)(({ theme }) => ({\n display: 'flex',\n flexDirection: 'column',\n gap: theme.spacing(1),\n paddingLeft: theme.spacing(3.2),\n}));\n\nconst StyledLegendItem = styled(Box)(({ theme }) => ({\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(1),\n}));\n\nconst StyledLegendColorBox = styled(Box)<{ color: string }>(({ color }) => ({\n width: '10px',\n height: '10px',\n backgroundColor: color,\n flexShrink: 0,\n}));\n\ntype CustomLegendProps = {\n thresholds?: ThresholdResult;\n};\n\nconst CustomLegend = (props: CustomLegendProps) => {\n const { thresholds } = props;\n const theme = useTheme();\n const { t } = useTranslation();\n\n if (\n !thresholds ||\n thresholds?.definition?.rules?.length === 0 ||\n thresholds?.definition?.rules === undefined\n ) {\n return (\n <StyledLegend>\n <StyledLegendItem>\n <StyledLegendColorBox color={theme.palette.grey['400']} /> --\n </StyledLegendItem>\n </StyledLegend>\n );\n }\n\n return (\n <StyledLegend>\n {thresholds?.definition?.rules?.map(\n ({ key: ruleKey, expression: ruleExpression }: ThresholdRule) => {\n return (\n <StyledLegendItem key={`legend-${ruleKey}`}>\n <StyledLegendColorBox\n data-testid={`legend-colorbox-${ruleKey}`}\n color={resolveStatusColor(\n theme,\n getThresholdRuleColor(\n thresholds.definition?.rules ?? [],\n ruleKey,\n ) ?? SCORECARD_ERROR_STATE_COLOR,\n )}\n />\n <Typography\n variant=\"body2\"\n sx={{ fontSize: '0.875rem', fontWeight: 400 }}\n >\n {(() => {\n const translated = t(`thresholds.${ruleKey}` as any, {});\n // If translation returns the ruleKey itself, fallback to capitalized ruleKey\n return translated === `thresholds.${ruleKey}`\n ? ruleKey.charAt(0).toUpperCase() + ruleKey.slice(1)\n : translated;\n })()}\n {ruleExpression &&\n !/^==(?:true|false)$/.test(ruleExpression) &&\n ` ${ruleExpression}`}\n </Typography>\n </StyledLegendItem>\n );\n },\n )}\n </StyledLegend>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,CAAA;AAAA;AAEJ,GAEJ,EAAA,CAAA;AAEJ;;;;"}
1
+ {"version":3,"file":"CustomLegend.esm.js","sources":["../../../src/components/Scorecard/CustomLegend.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 ThresholdResult,\n ThresholdRule,\n} from '@red-hat-developer-hub/backstage-plugin-scorecard-common';\n\nimport Box from '@mui/material/Box';\nimport Typography from '@mui/material/Typography';\nimport { styled, useTheme } from '@mui/material/styles';\n\nimport { useTranslation } from '../../hooks/useTranslation';\nimport {\n getTranslatedStatus,\n getThresholdRuleColor,\n resolveStatusColor,\n SCORECARD_ERROR_STATE_COLOR,\n} from '../../utils';\n\nconst StyledLegend = styled(Box)(({ theme }) => ({\n display: 'flex',\n flexDirection: 'column',\n gap: theme.spacing(1),\n paddingLeft: theme.spacing(3.2),\n}));\n\nconst StyledLegendItem = styled(Box)(({ theme }) => ({\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(1),\n}));\n\nconst StyledLegendColorBox = styled(Box)<{ color: string }>(({ color }) => ({\n width: '10px',\n height: '10px',\n backgroundColor: color,\n flexShrink: 0,\n}));\n\ntype CustomLegendProps = {\n thresholds?: ThresholdResult;\n};\n\nconst CustomLegend = (props: CustomLegendProps) => {\n const { thresholds } = props;\n const theme = useTheme();\n const { t } = useTranslation();\n\n if (\n !thresholds ||\n thresholds?.definition?.rules?.length === 0 ||\n thresholds?.definition?.rules === undefined\n ) {\n return (\n <StyledLegend>\n <StyledLegendItem>\n <StyledLegendColorBox color={theme.palette.grey['400']} /> --\n </StyledLegendItem>\n </StyledLegend>\n );\n }\n\n return (\n <StyledLegend>\n {thresholds?.definition?.rules?.map(\n ({ key: ruleKey, expression: ruleExpression }: ThresholdRule) => {\n return (\n <StyledLegendItem key={`legend-${ruleKey}`}>\n <StyledLegendColorBox\n data-testid={`legend-colorbox-${ruleKey}`}\n color={resolveStatusColor(\n theme,\n getThresholdRuleColor(\n thresholds.definition?.rules ?? [],\n ruleKey,\n ) ?? SCORECARD_ERROR_STATE_COLOR,\n )}\n />\n <Typography\n variant=\"body2\"\n sx={{ fontSize: '0.875rem', fontWeight: 400 }}\n >\n {getTranslatedStatus(ruleKey, t)}\n {ruleExpression &&\n !/^==(?:true|false)$/.test(ruleExpression) &&\n ` ${ruleExpression}`}\n </Typography>\n </StyledLegendItem>\n );\n },\n )}\n </StyledLegend>\n );\n};\n\nexport default CustomLegend;\n"],"names":[],"mappings":";;;;;;;;;;AAiCA,MAAM,eAAe,MAAO,CAAA,GAAG,EAAE,CAAC,EAAE,OAAa,MAAA;AAAA,EAC/C,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,QAAA;AAAA,EACf,GAAA,EAAK,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,EACpB,WAAA,EAAa,KAAM,CAAA,OAAA,CAAQ,GAAG;AAChC,CAAE,CAAA,CAAA;AAEF,MAAM,mBAAmB,MAAO,CAAA,GAAG,EAAE,CAAC,EAAE,OAAa,MAAA;AAAA,EACnD,OAAS,EAAA,MAAA;AAAA,EACT,UAAY,EAAA,QAAA;AAAA,EACZ,GAAA,EAAK,KAAM,CAAA,OAAA,CAAQ,CAAC;AACtB,CAAE,CAAA,CAAA;AAEF,MAAM,uBAAuB,MAAO,CAAA,GAAG,EAAqB,CAAC,EAAE,OAAa,MAAA;AAAA,EAC1E,KAAO,EAAA,MAAA;AAAA,EACP,MAAQ,EAAA,MAAA;AAAA,EACR,eAAiB,EAAA,KAAA;AAAA,EACjB,UAAY,EAAA;AACd,CAAE,CAAA,C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AAA,YAE3C,QAAA,EAAA;AAAA,cAAA,mBAAA,CAAoB,SAAS,CAAC,CAAA;AAAA,cAC9B,kBACC,CAAC,oBAAA,CAAqB,KAAK,cAAc,CAAA,IACzC,IAAI,cAAc,CAAA;AAAA;AAAA;AAAA;AACtB,OAnBqB,EAAA,EAAA,CAAA,OAAA,EAAU,OAAO,CAoBxC,CAAA,CAAA;AAAA;AAEJ,GAEJ,EAAA,CAAA;AAEJ;;;;"}
@@ -3,6 +3,9 @@ import Box from '@mui/material/Box';
3
3
  import Typography from '@mui/material/Typography';
4
4
  import { styled } from '@mui/material/styles';
5
5
  import { useTranslation } from '../../hooks/useTranslation.esm.js';
6
+ import 'date-fns';
7
+ import { getTranslatedStatus } from '../../utils/statusUtils.esm.js';
8
+ import '@red-hat-developer-hub/backstage-plugin-scorecard-common';
6
9
 
7
10
  const StyledLegend = styled(Box)(({ theme }) => ({
8
11
  display: "flex",
@@ -77,11 +80,7 @@ const CustomLegend = (props) => {
77
80
  {
78
81
  variant: "body2",
79
82
  sx: { fontSize: "0.875rem", fontWeight: 400 },
80
- children: (() => {
81
- const translated = t(`thresholds.${category.name}`, {});
82
- const label = typeof translated === "string" && translated.startsWith("thresholds.") ? category.name : translated;
83
- return label.charAt(0).toUpperCase() + label.slice(1);
84
- })()
83
+ children: getTranslatedStatus(category.name, t)
85
84
  }
86
85
  )
87
86
  ]
@@ -1 +1 @@
1
- {"version":3,"file":"CustomLegend.esm.js","sources":["../../../src/components/ScorecardHomepageSection/CustomLegend.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 '@mui/material/Box';\nimport Typography from '@mui/material/Typography';\nimport { styled } from '@mui/material/styles';\n\nimport type { PieData as PieDataProps } from '../types';\nimport { useTranslation } from '../../hooks/useTranslation';\n\nconst StyledLegend = styled(Box)(({ theme }) => ({\n display: 'flex',\n flexDirection: 'column',\n gap: theme.spacing(1),\n paddingLeft: theme.spacing(3.2),\n}));\n\nconst StyledLegendItem = styled(Box)(({ theme }) => ({\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(1),\n cursor: 'pointer',\n}));\n\nconst StyledLegendColorBox = styled(Box)<{ color?: string }>(\n ({ color = 'success.main' }) => ({\n width: '10px',\n height: '10px',\n backgroundColor: color,\n flexShrink: 0,\n }),\n);\n\ntype CustomLegendProps = {\n pieData: PieDataProps[];\n activeIndex: number | null;\n setActiveIndex: (index: number | null) => void;\n setTooltipPosition: (position: { left: number; top: number } | null) => void;\n};\n\nconst CustomLegend = (props: CustomLegendProps) => {\n const { pieData, activeIndex, setActiveIndex, setTooltipPosition } = props;\n const { t } = useTranslation();\n if (!pieData || pieData.length === 0) return null;\n\n return (\n <StyledLegend\n onMouseLeave={() => {\n setActiveIndex(null);\n setTooltipPosition(null);\n }}\n >\n {pieData.map((category: PieDataProps, index: number) => {\n return (\n <StyledLegendItem\n key={`legend-${category.name}`}\n onMouseEnter={e => {\n if (activeIndex === index) return;\n setActiveIndex(index);\n const rect = e.currentTarget.getBoundingClientRect();\n setTooltipPosition({\n left: rect.left + rect.width / 2,\n top: rect.top,\n });\n }}\n onMouseMove={e => {\n if (activeIndex === index) return;\n const rect = e.currentTarget.getBoundingClientRect();\n setTooltipPosition({\n left: rect.left + rect.width / 2,\n top: rect.top,\n });\n }}\n onMouseLeave={e => {\n const relatedTarget = e.relatedTarget as Node | null;\n const currentTarget = e.currentTarget;\n\n if (\n !relatedTarget ||\n !(relatedTarget instanceof Node) ||\n !currentTarget.contains(relatedTarget)\n ) {\n setActiveIndex(null);\n setTooltipPosition(null);\n }\n }}\n >\n <StyledLegendColorBox\n data-testid={`legend-colorbox-${category.name}`}\n color={category?.color}\n />\n <Typography\n variant=\"body2\"\n sx={{ fontSize: '0.875rem', fontWeight: 400 }}\n >\n {(() => {\n const translated = t(`thresholds.${category.name}` as any, {});\n const label =\n typeof translated === 'string' &&\n translated.startsWith('thresholds.')\n ? category.name\n : translated;\n return label.charAt(0).toUpperCase() + label.slice(1);\n })()}\n </Typography>\n </StyledLegendItem>\n );\n })}\n </StyledLegend>\n );\n};\n\nexport default CustomLegend;\n"],"names":[],"mappings":";;;;;;AAuBA,MAAM,eAAe,MAAO,CAAA,GAAG,EAAE,CAAC,EAAE,OAAa,MAAA;AAAA,EAC/C,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,QAAA;AAAA,EACf,GAAA,EAAK,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,EACpB,WAAA,EAAa,KAAM,CAAA,OAAA,CAAQ,GAAG;AAChC,CAAE,CAAA,CAAA;AAEF,MAAM,mBAAmB,MAAO,CAAA,GAAG,EAAE,CAAC,EAAE,OAAa,MAAA;AAAA,EACnD,OAAS,EAAA,MAAA;AAAA,EACT,UAAY,EAAA,QAAA;AAAA,EACZ,GAAA,EAAK,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,EACpB,MAAQ,EAAA;AACV,CAAE,CAAA,CAAA;AAEF,MAAM,oBAAA,GAAuB,OAAO,GAAG,CAAA;AAAA,EACrC,CAAC,EAAE,KAAQ,GAAA,cAAA,EAAsB,MAAA;AAAA,IAC/B,KAAO,EAAA,MAAA;AAAA,IACP,MAAQ,EAAA,MAAA;AAAA,IACR,eAAiB,EAAA,KAAA;AAAA,IACjB,UAAY,EAAA;AAAA,GACd;AACF,CAAA;AASM,MAAA,YAAA,GAAe,CAAC,KAA6B,KAAA;AACjD,EAAA,MAAM,EAAE,OAAA,EAAS,WAAa,EAAA,cAAA,EAAgB,oBAAuB,GAAA,KAAA;AACrE,EAAM,MAAA,E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E,aAAA,YAAyB,SAC3B,CAAC,aAAA,CAAc,QAAS,CAAA,aAAa,CACrC,EAAA;AACA,gBAAA,cAAA,CAAe,IAAI,CAAA;AACnB,gBAAA,kBAAA,CAAmB,IAAI,CAAA;AAAA;AACzB,aACF;AAAA,YAEA,QAAA,EAAA;AAAA,8BAAA,GAAA;AAAA,gBAAC,oBAAA;AAAA,gBAAA;AAAA,kBACC,aAAA,EAAa,CAAmB,gBAAA,EAAA,QAAA,CAAS,IAAI,CAAA,CAAA;AAAA,kBAC7C,OAAO,QAAU,EAAA;AAAA;AAAA,eACnB;AAAA,8BACA,GAAA;AAAA,gBAAC,UAAA;AAAA,gBAAA;AAAA,kBACC,OAAQ,EAAA,OAAA;AAAA,kBACR,EAAI,EAAA,EAAE,QAAU,EAAA,UAAA,EAAY,YAAY,GAAI,EAAA;AAAA,kBAE1C,QAAM,EAAA,CAAA,MAAA;AACN,oBAAA,MAAM,aAAa,CAAE,CAAA,CAAA,WAAA,EAAc,SAAS,IAAI,CAAA,CAAA,EAAW,EAAE,CAAA;AAC7D,oBAAM,MAAA,KAAA,GACJ,OAAO,UAAe,KAAA,QAAA,IACtB,WAAW,UAAW,CAAA,aAAa,CAC/B,GAAA,QAAA,CAAS,IACT,GAAA,UAAA;AACN,oBAAO,OAAA,KAAA,CAAM,OAAO,CAAC,CAAA,CAAE,aAAgB,GAAA,KAAA,CAAM,MAAM,CAAC,CAAA;AAAA,mBACnD;AAAA;AAAA;AACL;AAAA,WAAA;AAAA,UAjDK,CAAA,OAAA,EAAU,SAAS,IAAI,CAAA;AAAA,SAkD9B;AAAA,OAEH;AAAA;AAAA,GACH;AAEJ;;;;"}
1
+ {"version":3,"file":"CustomLegend.esm.js","sources":["../../../src/components/ScorecardHomepageSection/CustomLegend.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 '@mui/material/Box';\nimport Typography from '@mui/material/Typography';\nimport { styled } from '@mui/material/styles';\n\nimport type { PieData as PieDataProps } from '../types';\nimport { useTranslation } from '../../hooks/useTranslation';\nimport { getTranslatedStatus } from '../../utils';\n\nconst StyledLegend = styled(Box)(({ theme }) => ({\n display: 'flex',\n flexDirection: 'column',\n gap: theme.spacing(1),\n paddingLeft: theme.spacing(3.2),\n}));\n\nconst StyledLegendItem = styled(Box)(({ theme }) => ({\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(1),\n cursor: 'pointer',\n}));\n\nconst StyledLegendColorBox = styled(Box)<{ color?: string }>(\n ({ color = 'success.main' }) => ({\n width: '10px',\n height: '10px',\n backgroundColor: color,\n flexShrink: 0,\n }),\n);\n\ntype CustomLegendProps = {\n pieData: PieDataProps[];\n activeIndex: number | null;\n setActiveIndex: (index: number | null) => void;\n setTooltipPosition: (position: { left: number; top: number } | null) => void;\n};\n\nconst CustomLegend = (props: CustomLegendProps) => {\n const { pieData, activeIndex, setActiveIndex, setTooltipPosition } = props;\n const { t } = useTranslation();\n if (!pieData || pieData.length === 0) return null;\n\n return (\n <StyledLegend\n onMouseLeave={() => {\n setActiveIndex(null);\n setTooltipPosition(null);\n }}\n >\n {pieData.map((category: PieDataProps, index: number) => {\n return (\n <StyledLegendItem\n key={`legend-${category.name}`}\n onMouseEnter={e => {\n if (activeIndex === index) return;\n setActiveIndex(index);\n const rect = e.currentTarget.getBoundingClientRect();\n setTooltipPosition({\n left: rect.left + rect.width / 2,\n top: rect.top,\n });\n }}\n onMouseMove={e => {\n if (activeIndex === index) return;\n const rect = e.currentTarget.getBoundingClientRect();\n setTooltipPosition({\n left: rect.left + rect.width / 2,\n top: rect.top,\n });\n }}\n onMouseLeave={e => {\n const relatedTarget = e.relatedTarget as Node | null;\n const currentTarget = e.currentTarget;\n\n if (\n !relatedTarget ||\n !(relatedTarget instanceof Node) ||\n !currentTarget.contains(relatedTarget)\n ) {\n setActiveIndex(null);\n setTooltipPosition(null);\n }\n }}\n >\n <StyledLegendColorBox\n data-testid={`legend-colorbox-${category.name}`}\n color={category?.color}\n />\n <Typography\n variant=\"body2\"\n sx={{ fontSize: '0.875rem', fontWeight: 400 }}\n >\n {getTranslatedStatus(category.name, t)}\n </Typography>\n </StyledLegendItem>\n );\n })}\n </StyledLegend>\n );\n};\n\nexport default CustomLegend;\n"],"names":[],"mappings":";;;;;;;;;AAwBA,MAAM,eAAe,MAAO,CAAA,GAAG,EAAE,CAAC,EAAE,OAAa,MAAA;AAAA,EAC/C,OAAS,EAAA,MAAA;AAAA,EACT,aAAe,EAAA,QAAA;AAAA,EACf,GAAA,EAAK,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,EACpB,WAAA,EAAa,KAAM,CAAA,OAAA,CAAQ,GAAG;AAChC,CAAE,CAAA,CAAA;AAEF,MAAM,mBAAmB,MAAO,CAAA,GAAG,EAAE,CAAC,EAAE,OAAa,MAAA;AAAA,EACnD,OAAS,EAAA,MAAA;AAAA,EACT,UAAY,EAAA,QAAA;AAAA,EACZ,GAAA,EAAK,KAAM,CAAA,OAAA,CAAQ,CAAC,CAAA;AAAA,EACpB,MAAQ,EAAA;AACV,CAAE,CAAA,CAAA;AAEF,MAAM,oBAAA,GAAuB,OAAO,GAAG,CAAA;AAAA,EACrC,CAAC,EAAE,KAAQ,GAAA,cAAA,EAAsB,MAAA;AAAA,IAC/B,KAAO,EAAA,MAAA;AAAA,IACP,MAAQ,EAAA,MAAA;AAAA,IACR,eAAiB,EAAA,KAAA;AAAA,IACjB,UAAY,EAAA;AAAA,GACd;AACF,CAAA;AASM,MAAA,YAAA,GAAe,CAAC,KAA6B,KAAA;AACjD,EAAA,MAAM,EA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AA;AACxB,cAAA,MAAM,gBAAgB,CAAE,CAAA,aAAA;AAExB,cACE,IAAA,CAAC,iBACD,EAAE,aAAA,YAAyB,SAC3B,CAAC,aAAA,CAAc,QAAS,CAAA,aAAa,CACrC,EAAA;AACA,gBAAA,cAAA,CAAe,IAAI,CAAA;AACnB,gBAAA,kBAAA,CAAmB,IAAI,CAAA;AAAA;AACzB,aACF;AAAA,YAEA,QAAA,EAAA;AAAA,8BAAA,GAAA;AAAA,gBAAC,oBAAA;AAAA,gBAAA;AAAA,kBACC,aAAA,EAAa,CAAmB,gBAAA,EAAA,QAAA,CAAS,IAAI,CAAA,CAAA;AAAA,kBAC7C,OAAO,QAAU,EAAA;AAAA;AAAA,eACnB;AAAA,8BACA,GAAA;AAAA,gBAAC,UAAA;AAAA,gBAAA;AAAA,kBACC,OAAQ,EAAA,OAAA;AAAA,kBACR,EAAI,EAAA,EAAE,QAAU,EAAA,UAAA,EAAY,YAAY,GAAI,EAAA;AAAA,kBAE3C,QAAA,EAAA,mBAAA,CAAoB,QAAS,CAAA,IAAA,EAAM,CAAC;AAAA;AAAA;AACvC;AAAA,WAAA;AAAA,UAzCK,CAAA,OAAA,EAAU,SAAS,IAAI,CAAA;AAAA,SA0C9B;AAAA,OAEH;AAAA;AAAA,GACH;AAEJ;;;;"}
@@ -3,6 +3,9 @@ import Box from '@mui/material/Box';
3
3
  import Paper from '@mui/material/Paper';
4
4
  import Typography from '@mui/material/Typography';
5
5
  import { useTranslation } from '../../hooks/useTranslation.esm.js';
6
+ import 'date-fns';
7
+ import { getTranslatedStatus } from '../../utils/statusUtils.esm.js';
8
+ import '@red-hat-developer-hub/backstage-plugin-scorecard-common';
6
9
 
7
10
  const CustomTooltip = ({
8
11
  payload,
@@ -31,8 +34,8 @@ const CustomTooltip = ({
31
34
  contentElement = /* @__PURE__ */ jsx(Box, { sx: { m: 0 }, children: customContent });
32
35
  }
33
36
  } else if (payload?.[0]?.value === 0 || payload?.[0]?.value === void 0) {
34
- const translatedState = t(`thresholds.${payload?.[0]?.name}`, {});
35
- contentElement = /* @__PURE__ */ jsx(Typography, { sx: { fontSize: "0.875rem", margin: 0, fontWeight: "500" }, children: t("thresholds.noEntities", { category: translatedState }) });
37
+ const translatedStatus = getTranslatedStatus(payload?.[0]?.name, t);
38
+ contentElement = /* @__PURE__ */ jsx(Typography, { sx: { fontSize: "0.875rem", margin: 0, fontWeight: "500" }, children: t("thresholds.noEntities", { category: translatedStatus }) });
36
39
  } else {
37
40
  contentElement = /* @__PURE__ */ jsxs(Fragment, { children: [
38
41
  /* @__PURE__ */ jsx(Typography, { sx: { fontSize: "0.875rem", margin: 0, fontWeight: "500" }, children: t("thresholds.entities", { count: payload?.[0]?.value }) }),
@@ -1 +1 @@
1
- {"version":3,"file":"CustomTooltip.esm.js","sources":["../../../src/components/ScorecardHomepageSection/CustomTooltip.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { ReactNode } from 'react';\nimport type { TooltipProps } from 'recharts';\n\nimport Box from '@mui/material/Box';\nimport Paper from '@mui/material/Paper';\nimport Typography from '@mui/material/Typography';\n\nimport type { PieData } from '../types';\nimport { useTranslation } from '../../hooks/useTranslation';\n\nexport type CustomTooltipPayload = {\n name?: string;\n value?: number;\n payload?: PieData;\n};\n\ntype CustomTooltipProps = TooltipProps<number, string> & {\n payload?: readonly CustomTooltipPayload[];\n pieData: PieData[];\n customContent?: string | React.ReactNode;\n};\n\nexport const CustomTooltip = ({\n payload,\n pieData,\n customContent,\n}: CustomTooltipProps) => {\n const { t } = useTranslation();\n\n const getPercentage = () => {\n if (!Array.isArray(pieData) || pieData.length === 0) return 0;\n if (!payload || payload.length === 0) return 0;\n\n const total = pieData.reduce(\n (acc: number, curr: PieData) => acc + (curr.value || 0),\n 0,\n );\n const threshold = pieData.find(\n (item: PieData) => item.name === payload?.[0]?.name,\n );\n\n const thresholdValue = threshold?.value || 0;\n\n return total > 0 ? Math.round((thresholdValue / total) * 100) : 0;\n };\n\n let contentElement = null;\n\n if (\n customContent !== undefined &&\n customContent !== null &&\n customContent !== ''\n ) {\n if (typeof customContent === 'string') {\n contentElement = (\n <Typography sx={{ fontSize: '0.875rem', margin: 0, fontWeight: '500' }}>\n {customContent}\n </Typography>\n );\n } else {\n contentElement = <Box sx={{ m: 0 }}>{customContent as ReactNode}</Box>;\n }\n } else if (payload?.[0]?.value === 0 || payload?.[0]?.value === undefined) {\n const translatedState = t(`thresholds.${payload?.[0]?.name}` as any, {});\n contentElement = (\n <Typography sx={{ fontSize: '0.875rem', margin: 0, fontWeight: '500' }}>\n {t('thresholds.noEntities', { category: translatedState } as any)}\n </Typography>\n );\n } else {\n contentElement = (\n <>\n <Typography sx={{ fontSize: '0.875rem', margin: 0, fontWeight: '500' }}>\n {t('thresholds.entities', { count: payload?.[0]?.value })}\n </Typography>\n <Typography\n sx={{\n fontSize: '2.5rem',\n margin: 0,\n color: '#37a3a3',\n fontWeight: 500,\n }}\n >\n {getPercentage()}%\n </Typography>\n </>\n );\n }\n\n return (\n <Paper\n elevation={1}\n sx={{\n width:\n payload?.[0]?.value === 0 || payload?.[0]?.value === undefined\n ? '220px'\n : 'auto',\n padding: '16px',\n borderRadius: '12px',\n boxShadow: '0 1px 2px 0 rgba(0, 0, 0, 0.50)',\n border: theme => `1px solid ${theme.palette.grey[300]}`,\n }}\n >\n {contentElement}\n </Paper>\n );\n};\n"],"names":[],"mappings":";;;;;;AAsCO,MAAM,gBAAgB,CAAC;AAAA,EAC5B,OAAA;AAAA,EACA,OAAA;AAAA,EACA;AACF,CAA0B,KAAA;AACxB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AU,CAAK,IAAA,OAAA,GAAU,CAAC,CAAA,EAAG,KAAU,KAAA,MAAA,GACjD,OACA,GAAA,MAAA;AAAA,QACN,OAAS,EAAA,MAAA;AAAA,QACT,YAAc,EAAA,MAAA;AAAA,QACd,SAAW,EAAA,iCAAA;AAAA,QACX,QAAQ,CAAS,KAAA,KAAA,CAAA,UAAA,EAAa,MAAM,OAAQ,CAAA,IAAA,CAAK,GAAG,CAAC,CAAA;AAAA,OACvD;AAAA,MAEC,QAAA,EAAA;AAAA;AAAA,GACH;AAEJ;;;;"}
1
+ {"version":3,"file":"CustomTooltip.esm.js","sources":["../../../src/components/ScorecardHomepageSection/CustomTooltip.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 type { ReactNode } from 'react';\nimport type { TooltipProps } from 'recharts';\n\nimport Box from '@mui/material/Box';\nimport Paper from '@mui/material/Paper';\nimport Typography from '@mui/material/Typography';\n\nimport type { PieData } from '../types';\nimport { useTranslation } from '../../hooks/useTranslation';\nimport { getTranslatedStatus } from '../../utils';\n\nexport type CustomTooltipPayload = {\n name?: string;\n value?: number;\n payload?: PieData;\n};\n\ntype CustomTooltipProps = TooltipProps<number, string> & {\n payload?: readonly CustomTooltipPayload[];\n pieData: PieData[];\n customContent?: string | React.ReactNode;\n};\n\nexport const CustomTooltip = ({\n payload,\n pieData,\n customContent,\n}: CustomTooltipProps) => {\n const { t } = useTranslation();\n\n const getPercentage = () => {\n if (!Array.isArray(pieData) || pieData.length === 0) return 0;\n if (!payload || payload.length === 0) return 0;\n\n const total = pieData.reduce(\n (acc: number, curr: PieData) => acc + (curr.value || 0),\n 0,\n );\n const threshold = pieData.find(\n (item: PieData) => item.name === payload?.[0]?.name,\n );\n\n const thresholdValue = threshold?.value || 0;\n\n return total > 0 ? Math.round((thresholdValue / total) * 100) : 0;\n };\n\n let contentElement = null;\n\n if (\n customContent !== undefined &&\n customContent !== null &&\n customContent !== ''\n ) {\n if (typeof customContent === 'string') {\n contentElement = (\n <Typography sx={{ fontSize: '0.875rem', margin: 0, fontWeight: '500' }}>\n {customContent}\n </Typography>\n );\n } else {\n contentElement = <Box sx={{ m: 0 }}>{customContent as ReactNode}</Box>;\n }\n } else if (payload?.[0]?.value === 0 || payload?.[0]?.value === undefined) {\n const translatedStatus = getTranslatedStatus(payload?.[0]?.name, t);\n contentElement = (\n <Typography sx={{ fontSize: '0.875rem', margin: 0, fontWeight: '500' }}>\n {t('thresholds.noEntities', { category: translatedStatus } as any)}\n </Typography>\n );\n } else {\n contentElement = (\n <>\n <Typography sx={{ fontSize: '0.875rem', margin: 0, fontWeight: '500' }}>\n {t('thresholds.entities', { count: payload?.[0]?.value })}\n </Typography>\n <Typography\n sx={{\n fontSize: '2.5rem',\n margin: 0,\n color: '#37a3a3',\n fontWeight: 500,\n }}\n >\n {getPercentage()}%\n </Typography>\n </>\n );\n }\n\n return (\n <Paper\n elevation={1}\n sx={{\n width:\n payload?.[0]?.value === 0 || payload?.[0]?.value === undefined\n ? '220px'\n : 'auto',\n padding: '16px',\n borderRadius: '12px',\n boxShadow: '0 1px 2px 0 rgba(0, 0, 0, 0.50)',\n border: theme => `1px solid ${theme.palette.grey[300]}`,\n }}\n >\n {contentElement}\n </Paper>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;AAuCO,MAAM,gBAAgB,CAAC;AAAA,EAC5B,OAAA;AAAA,EACA,OAAA;AAAA,EACA;AACF,CAA0B,KAAA;AACxB,EAAM,MAAA,EAAE,CAAE,EAAA,GAAI,cAAe,EAAA;AAE7B,EAAA,MAAM,gBAAgB,MAAM;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;AAAA,QACT,YAAc,EAAA,MAAA;AAAA,QACd,SAAW,EAAA,iCAAA;AAAA,QACX,QAAQ,CAAS,KAAA,KAAA,CAAA,UAAA,EAAa,MAAM,OAAQ,CAAA,IAAA,CAAK,GAAG,CAAC,CAAA;AAAA,OACvD;AAAA,MAEC,QAAA,EAAA;AAAA;AAAA,GACH;AAEJ;;;;"}
@@ -2,7 +2,7 @@ import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { memo } from 'react';
3
3
  import Box from '@mui/material/Box';
4
4
  import 'date-fns';
5
- import { resolveStatusColor } from '../../../../utils/statusUtils.esm.js';
5
+ import { getTranslatedStatus, resolveStatusColor } from '../../../../utils/statusUtils.esm.js';
6
6
  import '@red-hat-developer-hub/backstage-plugin-scorecard-common';
7
7
  import { useTranslation } from '../../../../hooks/useTranslation.esm.js';
8
8
 
@@ -13,10 +13,7 @@ const MetricStatusCell = memo(
13
13
  statusColor
14
14
  }) => {
15
15
  const { t } = useTranslation();
16
- let translatedStatus = t(`thresholds.${status}`, {});
17
- if (translatedStatus === `thresholds.${status}` && status) {
18
- translatedStatus = status?.charAt(0).toUpperCase() + status?.slice(1);
19
- }
16
+ const translatedStatus = getTranslatedStatus(status, t);
20
17
  return /* @__PURE__ */ jsxs(Box, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
21
18
  /* @__PURE__ */ jsx(
22
19
  Box,
@@ -1 +1 @@
1
- {"version":3,"file":"MetricStatusCell.esm.js","sources":["../../../../../src/components/ScorecardPage/EntitiesTable/cells/MetricStatusCell.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { memo } from 'react';\n\nimport Box from '@mui/material/Box';\nimport { resolveStatusColor } from '../../../../utils';\nimport { useTranslation } from '../../../../hooks/useTranslation';\n\nexport const MetricStatusCell = memo(\n ({\n status,\n theme,\n statusColor,\n }: {\n status: string | undefined;\n theme: any;\n statusColor: string;\n }) => {\n const { t } = useTranslation();\n\n let translatedStatus = t(`thresholds.${status}` as any, {});\n if (translatedStatus === `thresholds.${status}` && status) {\n translatedStatus = status?.charAt(0).toUpperCase() + status?.slice(1);\n }\n\n return (\n <Box sx={{ display: 'flex', alignItems: 'center', gap: 1 }}>\n <Box\n sx={{\n width: 10,\n height: 10,\n backgroundColor: resolveStatusColor(theme, statusColor),\n flexShrink: 0,\n }}\n />\n {(status && translatedStatus) || '--'}\n </Box>\n );\n },\n);\n"],"names":[],"mappings":";;;;;;;;AAsBO,MAAM,gBAAmB,GAAA,IAAA;AAAA,EAC9B,CAAC;AAAA,IACC,MAAA;AAAA,IACA,KAAA;AAAA,IACA;AAAA,GAKI,KAAA;AACJ,IAAM,MAAA,EAAE,CAAE,EAAA,GAAI,cAAe,EAAA;AAE7B,IAAA,IAAI,mBAAmB,CAAE,CAAA,CAAA,WAAA,EAAc,MAAM,CAAA,CAAA,EAAW,EAAE,CAAA;AAC1D,IAAA,IAAI,gBAAqB,KAAA,CAAA,WAAA,EAAc,MAAM,CAAA,CAAA,IAAM,MAAQ,EAAA;AACzD,MAAmB,gBAAA,GAAA,MAAA,EAAQ,OAAO,CAAC,CAAA,CAAE,aAAgB,GAAA,MAAA,EAAQ,MAAM,CAAC,CAAA;AAAA;AAGtE,IACE,uBAAA,IAAA,CAAC,GAAI,EAAA,EAAA,EAAA,EAAI,EAAE,OAAA,EAAS,QAAQ,UAAY,EAAA,QAAA,EAAU,GAAK,EAAA,CAAA,EACrD,EAAA,QAAA,EAAA;AAAA,sBAAA,GAAA;AAAA,QAAC,GAAA;AAAA,QAAA;AAAA,UACC,EAAI,EAAA;AAAA,YACF,KAAO,EAAA,EAAA;AAAA,YACP,MAAQ,EAAA,EAAA;AAAA,YACR,eAAA,EAAiB,kBAAmB,CAAA,KAAA,EAAO,WAAW,CAAA;AAAA,YACtD,UAAY,EAAA;AAAA;AACd;AAAA,OACF;AAAA,MACE,UAAU,gBAAqB,IAAA;AAAA,KACnC,EAAA,CAAA;AAAA;AAGN;;;;"}
1
+ {"version":3,"file":"MetricStatusCell.esm.js","sources":["../../../../../src/components/ScorecardPage/EntitiesTable/cells/MetricStatusCell.tsx"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { memo } from 'react';\n\nimport Box from '@mui/material/Box';\nimport { getTranslatedStatus, resolveStatusColor } from '../../../../utils';\nimport { useTranslation } from '../../../../hooks/useTranslation';\n\nexport const MetricStatusCell = memo(\n ({\n status,\n theme,\n statusColor,\n }: {\n status: string | undefined;\n theme: any;\n statusColor: string;\n }) => {\n const { t } = useTranslation();\n const translatedStatus = getTranslatedStatus(status, t);\n\n return (\n <Box sx={{ display: 'flex', alignItems: 'center', gap: 1 }}>\n <Box\n sx={{\n width: 10,\n height: 10,\n backgroundColor: resolveStatusColor(theme, statusColor),\n flexShrink: 0,\n }}\n />\n {(status && translatedStatus) || '--'}\n </Box>\n );\n },\n);\n"],"names":[],"mappings":";;;;;;;;AAsBO,MAAM,gBAAmB,GAAA,IAAA;AAAA,EAC9B,CAAC;AAAA,IACC,MAAA;AAAA,IACA,KAAA;AAAA,IACA;AAAA,GAKI,KAAA;AACJ,IAAM,MAAA,EAAE,CAAE,EAAA,GAAI,cAAe,EAAA;AAC7B,IAAM,MAAA,gBAAA,GAAmB,mBAAoB,CAAA,MAAA,EAAQ,CAAC,CAAA;AAEtD,IACE,uBAAA,IAAA,CAAC,GAAI,EAAA,EAAA,EAAA,EAAI,EAAE,OAAA,EAAS,QAAQ,UAAY,EAAA,QAAA,EAAU,GAAK,EAAA,CAAA,EACrD,EAAA,QAAA,EAAA;AAAA,sBAAA,GAAA;AAAA,QAAC,GAAA;AAAA,QAAA;AAAA,UACC,EAAI,EAAA;AAAA,YACF,KAAO,EAAA,EAAA;AAAA,YACP,MAAQ,EAAA,EAAA;AAAA,YACR,eAAA,EAAiB,kBAAmB,CAAA,KAAA,EAAO,WAAW,CAAA;AAAA,YACtD,UAAY,EAAA;AAAA;AACd;AAAA,OACF;AAAA,MACE,UAAU,gBAAqB,IAAA;AAAA,KACnC,EAAA,CAAA;AAAA;AAGN;;;;"}
@@ -3,113 +3,104 @@ import { scorecardTranslationRef } from './ref.esm.js';
3
3
 
4
4
  const scorecardTranslationDe = createTranslationMessages({
5
5
  ref: scorecardTranslationRef,
6
- full: true,
7
6
  messages: {
8
- // Empty state translations
9
- "emptyState.title": "Noch keine Scorecards hinzugef\xFCgt",
10
- "emptyState.description": "Scorecards helfen Ihnen, den Zustand der Komponenten auf einen Blick zu \xFCberwachen. Schauen Sie sich zun\xE4chst unsere Dokumentation mit den Einrichtungshinweisen an.",
11
- "emptyState.button": "Dokumentation anzeigen",
7
+ "common.loading": "Ladevorgang",
12
8
  "emptyState.altText": "Keine Scorecards",
13
- // Permission required translations
14
- "permissionRequired.title": "Fehlende Berechtigung",
15
- "permissionRequired.description": "Wenn Sie das Scorecard-Plugin anzeigen m\xF6chten, wenden Sie sich an den Administrator, um die Berechtigung {{permission}} zu erhalten.",
16
- "permissionRequired.button": "Mehr erfahren",
17
- "permissionRequired.altText": "Berechtigung erforderlich",
18
- // Common UI
19
- "common.loading": "Wird geladen",
20
- // Not found state
21
- "notFound.title": "404 Diese Seite wurde nicht gefunden",
22
- "notFound.description": "F\xFCgen Sie eine {{indexFile}}-Datei im Stammverzeichnis des docs-Ordners dieses Repositorys hinzu.",
23
- "notFound.readMore": "Mehr erfahren",
24
- "notFound.goBack": "Zur\xFCck",
25
- "notFound.contactSupport": "Support kontaktieren",
26
- "notFound.altText": "Seite nicht gefunden",
27
- // Error messages
28
- "errors.entityMissingProperties": "F\xFCr die Scorecard-Suche fehlen dem Element die erforderlichen Eigenschaften.",
29
- "errors.missingAggregationId": "Die Scorecard ist falsch konfiguriert; die Eigenschaft \u201EAggregations-ID\u201C (oder \u201EMetrik-ID\u201C) wurde nicht angegeben",
30
- "errors.invalidApiResponse": "Ung\xFCltiges Antwortformat der Scorecard-API",
9
+ "emptyState.button": "Dokumentation anzeigen",
10
+ "emptyState.description": "Scorecards helfen Ihnen, den Zustand der Komponenten auf einen Blick zu \xFCberwachen. Schauen Sie sich zun\xE4chst unsere Dokumentation mit den Einrichtungshinweisen an.",
11
+ "emptyState.title": "Noch keine Scorecards hinzugef\xFCgt.",
12
+ "entitiesPage.entitiesTable.footer.allRows": "Alle Zeilen",
13
+ "entitiesPage.entitiesTable.footer.of": "von",
14
+ "entitiesPage.entitiesTable.footer.rows_one": "{{count}} Zeile",
15
+ "entitiesPage.entitiesTable.footer.rows_other": "{{count}} Zeilen",
16
+ "entitiesPage.entitiesTable.header.entity": "Entity",
17
+ "entitiesPage.entitiesTable.header.kind": "Art",
18
+ "entitiesPage.entitiesTable.header.lastUpdated": "Letzte Aktualisierung",
19
+ "entitiesPage.entitiesTable.header.owner": "Eigent\xFCmer",
20
+ "entitiesPage.entitiesTable.header.status": "Status",
21
+ "entitiesPage.entitiesTable.header.value": "Wert",
22
+ "entitiesPage.entitiesTable.title": "Entit\xE4ten",
23
+ "entitiesPage.entitiesTable.titleWithCount": "Entit\xE4ten ({{count}})",
24
+ "entitiesPage.entitiesTable.unavailable": "Nicht verf\xFCgbar",
25
+ "entitiesPage.metricProviderNotRegistered": "Der Metrikanbieter mit der ID {{metricId}} ist nicht registriert.",
26
+ "entitiesPage.missingPermission": "Um die Kennzahlen der Scorecard einzusehen, muss Ihnen Ihr Administrator die erforderliche Berechtigung erteilen.",
27
+ "entitiesPage.noDataFound": "Um Ihre Daten hier anzuzeigen, \xFCberpr\xFCfen Sie, ob Ihre Entit\xE4ten Werte melden, die sich auf diese Kennzahl beziehen.",
28
+ "entitiesPage.unknownMetric": "Unbekannte Metrik",
29
+ "errors.authenticationError": "Authentifizierungsfehler",
30
+ "errors.authenticationErrorMessage": "Bitte melden Sie sich an, um Ihre Daten einzusehen.",
31
+ "errors.entityMissingProperties": "F\xFCr die Scorecard-Suche fehlen der Entit\xE4t die erforderlichen Eigenschaften.",
31
32
  "errors.fetchError": "Fehler beim Abrufen der Scorecards: {{error}}",
32
- "errors.metricDataUnavailable": "Metrikdaten nicht verf\xFCgbar",
33
+ "errors.invalidApiResponse": "Ung\xFCltiges Antwortformat der Scorecard-API",
33
34
  "errors.invalidThresholds": "Ung\xFCltige Schwellenwerte",
35
+ "errors.metricDataUnavailable": "Metrische Daten nicht verf\xFCgbar",
36
+ "errors.missingAggregationId": "Die Scorecard ist falsch konfiguriert, die Eigenschaft f\xFCr die Aggregations-ID (oder Metrik-ID) fehlt.",
34
37
  "errors.missingPermission": "Fehlende Berechtigung",
38
+ "errors.missingPermissionMessage": "Um die Kennzahlen der Scorecard einzusehen, muss Ihnen Ihr Administrator die erforderliche Berechtigung erteilen.",
35
39
  "errors.noDataFound": "Keine Daten gefunden",
36
- "errors.authenticationError": "Authentifizierungsfehler",
37
- "errors.missingPermissionMessage": "Um die Metriken der Scorecard einzusehen, muss Ihnen der Administrator die erforderliche Berechtigung erteilen.",
38
- "errors.userNotFoundInCatalogMessage": "Benutzer-Element nicht im Katalog gefunden.",
39
- "errors.noDataFoundMessage": "Um Ihre Daten hier anzuzeigen, \xFCberpr\xFCfen Sie, ob Ihre Elemente Werte melden, die mit dieser Metrik in Verbindung stehen.",
40
- "errors.unsupportedAggregationType": "Diese Scorecard verwendet einen Aggregationstyp, der von dieser Plugin-Version nicht unterst\xFCtzt wird.",
41
- "errors.authenticationErrorMessage": "Bitte melden Sie sich an, um Ihre Daten anzuzeigen.",
42
- // Metric translations
43
- "metric.github.open_prs.title": "GitHub PRs offen",
44
- "metric.github.open_prs.description": "Aktuelle Anzahl offener Pull Requests f\xFCr ein bestimmtes GitHub-Repository.",
45
- "metric.jira.open_issues.title": "Jira offene blockierende Tickets",
46
- "metric.jira.open_issues.description": "Hervorhebt die Anzahl der kritischen, blockierenden Probleme, die derzeit in Jira offen sind.",
47
- "metric.sonarqube.quality_gate.title": "SonarQube Quality-Gate-Status",
48
- "metric.sonarqube.quality_gate.description": "Gibt an, ob das Projekt sein SonarQube-Quality-Gate besteht.",
49
- "metric.sonarqube.open_issues.title": "SonarQube offene Probleme",
50
- "metric.sonarqube.open_issues.description": "Anzahl der offenen Probleme (OPEN, CONFIRMED, REOPENED) in SonarQube.",
51
- "metric.sonarqube.security_rating.title": "SonarQube Sicherheitsbewertung",
52
- "metric.sonarqube.security_rating.description": "SonarQube Sicherheitsbewertung.",
53
- "metric.sonarqube.security_issues.title": "SonarQube Sicherheitsprobleme",
54
- "metric.sonarqube.security_issues.description": "Anzahl der offenen Sicherheitsl\xFCcken in SonarQube.",
55
- "metric.sonarqube.security_review_rating.title": "SonarQube Bewertung der Sicherheits\xFCberpr\xFCfung",
56
- "metric.sonarqube.security_review_rating.description": "SonarQube Bewertung der Sicherheits\xFCberpr\xFCfung.",
57
- "metric.sonarqube.security_hotspots.title": "SonarQube Sicherheits-Hotspots",
58
- "metric.sonarqube.security_hotspots.description": "Anzahl der zu \xFCberpr\xFCfenden Sicherheits-Hotspots in SonarQube.",
59
- "metric.sonarqube.reliability_rating.title": "SonarQube Zuverl\xE4ssigkeitsbewertung",
60
- "metric.sonarqube.reliability_rating.description": "SonarQube Zuverl\xE4ssigkeitsbewertung.",
61
- "metric.sonarqube.reliability_issues.title": "SonarQube Zuverl\xE4ssigkeitsprobleme",
62
- "metric.sonarqube.reliability_issues.description": "Anzahl der offenen Fehler in SonarQube.",
63
- "metric.sonarqube.maintainability_rating.title": "SonarQube Wartbarkeitsbewertung",
64
- "metric.sonarqube.maintainability_rating.description": "SonarQube Wartbarkeitsbewertung.",
65
- "metric.sonarqube.maintainability_issues.title": "SonarQube Wartbarkeitsprobleme",
66
- "metric.sonarqube.maintainability_issues.description": "Anzahl der offenen Code Smells in SonarQube.",
67
- "metric.sonarqube.code_coverage.title": "SonarQube Code-Abdeckung",
68
- "metric.sonarqube.code_coverage.description": "Gesamtprozentsatz der Code-Abdeckung in SonarQube.",
69
- "metric.sonarqube.code_duplications.title": "SonarQube Code-Duplikate",
70
- "metric.sonarqube.code_duplications.description": "Prozentsatz der duplizierten Zeilen in SonarQube.",
71
- "metric.filecheck.title": "Dateipr\xFCfung: {{name}}",
72
- "metric.filecheck.description": "Pr\xFCft, ob die Datei {{name}} im Repository vorhanden ist.",
73
- "metric.lastUpdated": "Zuletzt aktualisiert: {{timestamp}}",
74
- "metric.lastUpdatedNotAvailable": "Zuletzt aktualisiert: Nicht verf\xFCgbar",
75
- "metric.someEntitiesNotReportingValues": "Einige Elemente melden keine Werte, die mit dieser Metrik in Verbindung stehen.",
40
+ "errors.noDataFoundMessage": "Um Ihre Daten hier anzuzeigen, \xFCberpr\xFCfen Sie, ob Ihre Entit\xE4ten Werte melden, die sich auf diese Kennzahl beziehen.",
41
+ "errors.unsupportedAggregationType": "Diese Scorecard verwendet einen Aggregationstyp, der von dieser Version des Plugins nicht unterst\xFCtzt wird.",
42
+ "errors.userNotFoundInCatalogMessage": "Benutzerentit\xE4t im Katalog nicht gefunden.",
43
+ "metric.averageCenterTooltipMaxLabel": "Maximal erreichbare Punktzahl",
76
44
  "metric.averageCenterTooltipTotalLabel": "Gesamtpunktzahl",
77
- "metric.averageCenterTooltipMaxLabel": "Maximal m\xF6gliche Punktzahl",
78
- "metric.averageCenterTooltipBreakdownRow_one": "{{status}}: {{count}} Element, Punktzahl: {{score}}",
79
- "metric.averageCenterTooltipBreakdownRow_other": "{{status}}: {{count}} Elemente, Punktzahl: {{score}}",
80
- "metric.averageLegendTooltipEntitiesEach_one": "{{count}} Element, je {{score}}",
81
- "metric.averageLegendTooltipEntitiesEach_other": "{{count}} Elemente, je {{score}}",
45
+ "metric.averageCenterTooltipBreakdownRow_one": "{{status}}: {{count}} entity, score: {{score}}",
46
+ "metric.averageCenterTooltipBreakdownRow_other": "{{status}}: {{count}} entities, score: {{score}}",
47
+ "metric.averageLegendTooltipEntitiesEach_one": "{{count}} Entit\xE4ten, jede {{score}}",
48
+ "metric.averageLegendTooltipEntitiesEach_other": "{{count}} Entit\xE4ten, jeweils {{score}}",
82
49
  "metric.averageLegendTooltipRowTotal": "Gesamtpunktzahl {{total}}",
83
- "metric.drillDownCalculationFailures": "Mindestens ein Element konnte diese Metrik nicht berechnen.",
84
- "metric.homepageEntityHealthRatio": "{{healthy}}/{{total}} Elemente",
85
- "metric.homepageEntityCalculationHealth": "{{healthy}} / {{total}} Elemente ohne Metrik-Berechnungsfehler",
86
- // Threshold translations
87
- "thresholds.success": "Erfolg",
88
- "thresholds.warning": "Warnung",
50
+ "metric.drillDownCalculationFailures": "Bei der Berechnung dieser Kennzahl ist ein oder mehrere Fehler aufgetreten.",
51
+ "metric.filecheck.description": "Pr\xFCft, ob die Datei {{name}} im Repository existiert.",
52
+ "metric.filecheck.title": "Dateipr\xFCfung: {{name}}",
53
+ "metric.github.open_prs.description": "Aktuelle Anzahl offener Pull Requests f\xFCr ein bestimmtes GitHub-Repository.",
54
+ "metric.github.open_prs.title": "GitHub offene PRs",
55
+ "metric.homepageEntityCalculationHealth": "{{healthy}} / {{total}} Entit\xE4ten ohne Metrikberechnungsfehler",
56
+ "metric.homepageEntityHealthRatio": "{{healthy}}/{{total}} Entit\xE4ten",
57
+ "metric.jira.open_issues.description": "Zeigt die Anzahl der kritischen, blockierenden Vorg\xE4nge an, die aktuell in Jira offen sind.",
58
+ "metric.jira.open_issues.title": "Jira-Tickets \xF6ffnen und blockieren",
59
+ "metric.lastUpdated": "Letzte Aktualisierung: {{timestamp}}",
60
+ "metric.lastUpdatedNotAvailable": "Letzte Aktualisierung: Nicht verf\xFCgbar",
61
+ "metric.someEntitiesNotReportingValues": "Einige Organisationen melden keine Werte, die sich auf diese Kennzahl beziehen.",
62
+ "metric.sonarqube.code_coverage.description": "Gesamtcodeabdeckung in SonarQube in Prozent.",
63
+ "metric.sonarqube.code_coverage.title": "SonarQube-Codeabdeckung",
64
+ "metric.sonarqube.code_duplications.description": "Prozentsatz doppelter Zeilen in SonarQube.",
65
+ "metric.sonarqube.code_duplications.title": "SonarQube-Code-Duplizierungen",
66
+ "metric.sonarqube.maintainability_issues.description": "Anzahl offener Code-Smells in SonarQube.",
67
+ "metric.sonarqube.maintainability_issues.title": "SonarQube-Wartbarkeitsprobleme",
68
+ "metric.sonarqube.maintainability_rating.description": "SonarQube-Wartungsbewertung.",
69
+ "metric.sonarqube.maintainability_rating.title": "SonarQube-Wartbarkeitsbewertung",
70
+ "metric.sonarqube.open_issues.description": "Anzahl der offenen Tickets (OFFEN, BEST\xC4TIGT, WIEDERER\xD6FFNET) in SonarQube.",
71
+ "metric.sonarqube.open_issues.title": "Offene Probleme bei SonarQube",
72
+ "metric.sonarqube.quality_gate.description": "Ob das Projekt die SonarQube-Qualit\xE4tspr\xFCfung besteht.",
73
+ "metric.sonarqube.quality_gate.title": "SonarQube Qualit\xE4tsgate-Status",
74
+ "metric.sonarqube.reliability_issues.description": "Anzahl offener Fehler in SonarQube.",
75
+ "metric.sonarqube.reliability_issues.title": "Zuverl\xE4ssigkeitsprobleme von SonarQube",
76
+ "metric.sonarqube.reliability_rating.description": "SonarQube-Zuverl\xE4ssigkeitsbewertung.",
77
+ "metric.sonarqube.reliability_rating.title": "SonarQube-Zuverl\xE4ssigkeitsbewertung",
78
+ "metric.sonarqube.security_hotspots.description": "Anzahl der in SonarQube zu \xFCberpr\xFCfenden Sicherheits-Hotspots.",
79
+ "metric.sonarqube.security_hotspots.title": "SonarQube Sicherheits-Hotspots",
80
+ "metric.sonarqube.security_issues.description": "Anzahl offener Sicherheitsl\xFCcken in SonarQube.",
81
+ "metric.sonarqube.security_issues.title": "SonarQube-Sicherheitsprobleme",
82
+ "metric.sonarqube.security_rating.description": "SonarQube-Sicherheitsbewertung.",
83
+ "metric.sonarqube.security_rating.title": "SonarQube-Sicherheitsbewertung",
84
+ "metric.sonarqube.security_review_rating.description": "SonarQube-Sicherheitsbewertung.",
85
+ "metric.sonarqube.security_review_rating.title": "SonarQube Sicherheitsbewertung",
86
+ "notFound.altText": "Seite nicht gefunden",
87
+ "notFound.contactSupport": "Kontaktieren Sie den Support.",
88
+ "notFound.description": "Versuchen Sie, eine {{indexFile}}-Datei im Stammverzeichnis des docs-Verzeichnisses dieses Repositorys hinzuzuf\xFCgen.",
89
+ "notFound.goBack": "Zur\xFCck",
90
+ "notFound.readMore": "Weitere Informationen",
91
+ "notFound.title": "404 Die Seite konnte nicht gefunden werden.",
92
+ "permissionRequired.altText": "Berechtigung erforderlich",
93
+ "permissionRequired.button": "Weitere Informationen",
94
+ "permissionRequired.description": "Um das Scorecard-Plugin anzuzeigen, wenden Sie sich an Ihren Administrator, um die Berechtigung {{permission}} zu erteilen.",
95
+ "permissionRequired.title": "Fehlende Berechtigung",
96
+ "thresholds.entities_one": "{{count}} Entit\xE4t",
97
+ "thresholds.entities_other": "{{count}} Entit\xE4ten",
89
98
  "thresholds.error": "Fehler",
90
- "thresholds.exist": "Vorhanden",
91
- "thresholds.missing": "Fehlend",
92
- "thresholds.noEntities": "Keine Elemente im {{category}}-Zustand",
93
- "thresholds.entities_one": "{{count}} Element",
94
- "thresholds.entities_other": "{{count}} Elemente",
95
- // Entities page translations
96
- "entitiesPage.unknownMetric": "Unbekannte Metrik",
97
- "entitiesPage.noDataFound": "Um Ihre Daten hier anzuzeigen, \xFCberpr\xFCfen Sie, ob Ihre Elemente Werte melden, die mit dieser Metrik in Verbindung stehen.",
98
- "entitiesPage.missingPermission": "Um die Metriken der Scorecard einzusehen, muss Ihnen der Administrator die erforderliche Berechtigung erteilen.",
99
- "entitiesPage.metricProviderNotRegistered": "Metrik-Anbieter mit ID {{metricId}} ist nicht registriert.",
100
- "entitiesPage.entitiesTable.title": "Elemente",
101
- "entitiesPage.entitiesTable.unavailable": "Nicht verf\xFCgbar",
102
- "entitiesPage.entitiesTable.titleWithCount": "Elemente ({{count}})",
103
- "entitiesPage.entitiesTable.header.status": "Status",
104
- "entitiesPage.entitiesTable.header.value": "Wert",
105
- "entitiesPage.entitiesTable.header.entity": "Element",
106
- "entitiesPage.entitiesTable.header.owner": "Eigent\xFCmer",
107
- "entitiesPage.entitiesTable.header.kind": "Art",
108
- "entitiesPage.entitiesTable.header.lastUpdated": "Zuletzt aktualisiert",
109
- "entitiesPage.entitiesTable.footer.allRows": "Alle Zeilen",
110
- "entitiesPage.entitiesTable.footer.rows_one": "{{count}} Zeile",
111
- "entitiesPage.entitiesTable.footer.rows_other": "{{count}} Zeilen",
112
- "entitiesPage.entitiesTable.footer.of": "von"
99
+ "thresholds.exist": "Existieren",
100
+ "thresholds.missing": "Fehlen",
101
+ "thresholds.noEntities": "Keine Entit\xE4ten im Zustand {{category}}",
102
+ "thresholds.success": "Erfolg",
103
+ "thresholds.warning": "Warnung"
113
104
  }
114
105
  });
115
106
 
@@ -1 +1 @@
1
- {"version":3,"file":"de.esm.js","sources":["../../src/translations/de.ts"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { createTranslationMessages } from '@backstage/core-plugin-api/alpha';\nimport { scorecardTranslationRef } from './ref';\n\n/**\n * de translation for plugin.scorecard.\n * @public\n */\nconst scorecardTranslationDe = createTranslationMessages({\n ref: scorecardTranslationRef,\n full: true,\n messages: {\n // Empty state translations\n 'emptyState.title': 'Noch keine Scorecards hinzugefügt',\n 'emptyState.description':\n 'Scorecards helfen Ihnen, den Zustand der Komponenten auf einen Blick zu überwachen. Schauen Sie sich zunächst unsere Dokumentation mit den Einrichtungshinweisen an.',\n 'emptyState.button': 'Dokumentation anzeigen',\n 'emptyState.altText': 'Keine Scorecards',\n\n // Permission required translations\n 'permissionRequired.title': 'Fehlende Berechtigung',\n 'permissionRequired.description':\n 'Wenn Sie das Scorecard-Plugin anzeigen möchten, wenden Sie sich an den Administrator, um die Berechtigung {{permission}} zu erhalten.',\n 'permissionRequired.button': 'Mehr erfahren',\n 'permissionRequired.altText': 'Berechtigung erforderlich',\n\n // Common UI\n 'common.loading': 'Wird geladen',\n\n // Not found state\n 'notFound.title': '404 Diese Seite wurde nicht gefunden',\n 'notFound.description':\n 'Fügen Sie eine {{indexFile}}-Datei im Stammverzeichnis des docs-Ordners dieses Repositorys hinzu.',\n 'notFound.readMore': 'Mehr erfahren',\n 'notFound.goBack': 'Zurück',\n 'notFound.contactSupport': 'Support kontaktieren',\n 'notFound.altText': 'Seite nicht gefunden',\n\n // Error messages\n 'errors.entityMissingProperties':\n 'Für die Scorecard-Suche fehlen dem Element die erforderlichen Eigenschaften.',\n 'errors.missingAggregationId':\n 'Die Scorecard ist falsch konfiguriert; die Eigenschaft „Aggregations-ID“ (oder „Metrik-ID“) wurde nicht angegeben',\n 'errors.invalidApiResponse': 'Ungültiges Antwortformat der Scorecard-API',\n 'errors.fetchError': 'Fehler beim Abrufen der Scorecards: {{error}}',\n 'errors.metricDataUnavailable': 'Metrikdaten nicht verfügbar',\n 'errors.invalidThresholds': 'Ungültige Schwellenwerte',\n 'errors.missingPermission': 'Fehlende Berechtigung',\n 'errors.noDataFound': 'Keine Daten gefunden',\n 'errors.authenticationError': 'Authentifizierungsfehler',\n 'errors.missingPermissionMessage':\n 'Um die Metriken der Scorecard einzusehen, muss Ihnen der Administrator die erforderliche Berechtigung erteilen.',\n 'errors.userNotFoundInCatalogMessage':\n 'Benutzer-Element nicht im Katalog gefunden.',\n 'errors.noDataFoundMessage':\n 'Um Ihre Daten hier anzuzeigen, überprüfen Sie, ob Ihre Elemente Werte melden, die mit dieser Metrik in Verbindung stehen.',\n 'errors.unsupportedAggregationType':\n 'Diese Scorecard verwendet einen Aggregationstyp, der von dieser Plugin-Version nicht unterstützt wird.',\n 'errors.authenticationErrorMessage':\n 'Bitte melden Sie sich an, um Ihre Daten anzuzeigen.',\n\n // Metric translations\n 'metric.github.open_prs.title': 'GitHub PRs offen',\n 'metric.github.open_prs.description':\n 'Aktuelle Anzahl offener Pull Requests für ein bestimmtes GitHub-Repository.',\n 'metric.jira.open_issues.title': 'Jira offene blockierende Tickets',\n 'metric.jira.open_issues.description':\n 'Hervorhebt die Anzahl der kritischen, blockierenden Probleme, die derzeit in Jira offen sind.',\n 'metric.sonarqube.quality_gate.title': 'SonarQube Quality-Gate-Status',\n 'metric.sonarqube.quality_gate.description':\n 'Gibt an, ob das Projekt sein SonarQube-Quality-Gate besteht.',\n 'metric.sonarqube.open_issues.title': 'SonarQube offene Probleme',\n 'metric.sonarqube.open_issues.description':\n 'Anzahl der offenen Probleme (OPEN, CONFIRMED, REOPENED) in SonarQube.',\n 'metric.sonarqube.security_rating.title': 'SonarQube Sicherheitsbewertung',\n 'metric.sonarqube.security_rating.description':\n 'SonarQube Sicherheitsbewertung.',\n 'metric.sonarqube.security_issues.title': 'SonarQube Sicherheitsprobleme',\n 'metric.sonarqube.security_issues.description':\n 'Anzahl der offenen Sicherheitslücken in SonarQube.',\n 'metric.sonarqube.security_review_rating.title':\n 'SonarQube Bewertung der Sicherheitsüberprüfung',\n 'metric.sonarqube.security_review_rating.description':\n 'SonarQube Bewertung der Sicherheitsüberprüfung.',\n 'metric.sonarqube.security_hotspots.title':\n 'SonarQube Sicherheits-Hotspots',\n 'metric.sonarqube.security_hotspots.description':\n 'Anzahl der zu überprüfenden Sicherheits-Hotspots in SonarQube.',\n 'metric.sonarqube.reliability_rating.title':\n 'SonarQube Zuverlässigkeitsbewertung',\n 'metric.sonarqube.reliability_rating.description':\n 'SonarQube Zuverlässigkeitsbewertung.',\n 'metric.sonarqube.reliability_issues.title':\n 'SonarQube Zuverlässigkeitsprobleme',\n 'metric.sonarqube.reliability_issues.description':\n 'Anzahl der offenen Fehler in SonarQube.',\n 'metric.sonarqube.maintainability_rating.title':\n 'SonarQube Wartbarkeitsbewertung',\n 'metric.sonarqube.maintainability_rating.description':\n 'SonarQube Wartbarkeitsbewertung.',\n 'metric.sonarqube.maintainability_issues.title':\n 'SonarQube Wartbarkeitsprobleme',\n 'metric.sonarqube.maintainability_issues.description':\n 'Anzahl der offenen Code Smells in SonarQube.',\n 'metric.sonarqube.code_coverage.title': 'SonarQube Code-Abdeckung',\n 'metric.sonarqube.code_coverage.description':\n 'Gesamtprozentsatz der Code-Abdeckung in SonarQube.',\n 'metric.sonarqube.code_duplications.title': 'SonarQube Code-Duplikate',\n 'metric.sonarqube.code_duplications.description':\n 'Prozentsatz der duplizierten Zeilen in SonarQube.',\n 'metric.filecheck.title': 'Dateiprüfung: {{name}}',\n 'metric.filecheck.description':\n 'Prüft, ob die Datei {{name}} im Repository vorhanden ist.',\n 'metric.lastUpdated': 'Zuletzt aktualisiert: {{timestamp}}',\n 'metric.lastUpdatedNotAvailable': 'Zuletzt aktualisiert: Nicht verfügbar',\n 'metric.someEntitiesNotReportingValues':\n 'Einige Elemente melden keine Werte, die mit dieser Metrik in Verbindung stehen.',\n 'metric.averageCenterTooltipTotalLabel': 'Gesamtpunktzahl',\n 'metric.averageCenterTooltipMaxLabel': 'Maximal mögliche Punktzahl',\n 'metric.averageCenterTooltipBreakdownRow_one':\n '{{status}}: {{count}} Element, Punktzahl: {{score}}',\n 'metric.averageCenterTooltipBreakdownRow_other':\n '{{status}}: {{count}} Elemente, Punktzahl: {{score}}',\n 'metric.averageLegendTooltipEntitiesEach_one':\n '{{count}} Element, je {{score}}',\n 'metric.averageLegendTooltipEntitiesEach_other':\n '{{count}} Elemente, je {{score}}',\n 'metric.averageLegendTooltipRowTotal': 'Gesamtpunktzahl {{total}}',\n 'metric.drillDownCalculationFailures':\n 'Mindestens ein Element konnte diese Metrik nicht berechnen.',\n 'metric.homepageEntityHealthRatio': '{{healthy}}/{{total}} Elemente',\n 'metric.homepageEntityCalculationHealth':\n '{{healthy}} / {{total}} Elemente ohne Metrik-Berechnungsfehler',\n\n // Threshold translations\n 'thresholds.success': 'Erfolg',\n 'thresholds.warning': 'Warnung',\n 'thresholds.error': 'Fehler',\n 'thresholds.exist': 'Vorhanden',\n 'thresholds.missing': 'Fehlend',\n 'thresholds.noEntities': 'Keine Elemente im {{category}}-Zustand',\n 'thresholds.entities_one': '{{count}} Element',\n 'thresholds.entities_other': '{{count}} Elemente',\n\n // Entities page translations\n 'entitiesPage.unknownMetric': 'Unbekannte Metrik',\n 'entitiesPage.noDataFound':\n 'Um Ihre Daten hier anzuzeigen, überprüfen Sie, ob Ihre Elemente Werte melden, die mit dieser Metrik in Verbindung stehen.',\n 'entitiesPage.missingPermission':\n 'Um die Metriken der Scorecard einzusehen, muss Ihnen der Administrator die erforderliche Berechtigung erteilen.',\n 'entitiesPage.metricProviderNotRegistered':\n 'Metrik-Anbieter mit ID {{metricId}} ist nicht registriert.',\n 'entitiesPage.entitiesTable.title': 'Elemente',\n 'entitiesPage.entitiesTable.unavailable': 'Nicht verfügbar',\n 'entitiesPage.entitiesTable.titleWithCount': 'Elemente ({{count}})',\n 'entitiesPage.entitiesTable.header.status': 'Status',\n 'entitiesPage.entitiesTable.header.value': 'Wert',\n 'entitiesPage.entitiesTable.header.entity': 'Element',\n 'entitiesPage.entitiesTable.header.owner': 'Eigentümer',\n 'entitiesPage.entitiesTable.header.kind': 'Art',\n 'entitiesPage.entitiesTable.header.lastUpdated': 'Zuletzt aktualisiert',\n 'entitiesPage.entitiesTable.footer.allRows': 'Alle Zeilen',\n 'entitiesPage.entitiesTable.footer.rows_one': '{{count}} Zeile',\n 'entitiesPage.entitiesTable.footer.rows_other': '{{count}} Zeilen',\n 'entitiesPage.entitiesTable.footer.of': 'von',\n },\n});\n\nexport default scorecardTranslationDe;\n"],"names":[],"mappings":";;;AAuBA,MAAM,yBAAyB,yBAA0B,CAAA;AAAA,EACvD,GAAK,EAAA,uBAAA;AAAA,EACL,IAAM,EAAA,IAAA;AAAA,EACN,QAAU,EAAA;AAAA;AAAA,IAER,kBAAoB,EAAA,sCAAA;AAAA,IACpB,wBACE,EAAA,4KAAA;AAAA,IACF,mBAAqB,EAAA,wBAAA;AAAA,IACrB,oBAAsB,EAAA,kBAAA;AAAA;AAAA,IAGtB,0BAA4B,EAAA,uBAAA;AAAA,IAC5B,gCACE,EAAA,0IAAA;AAAA,IACF,2BAA6B,EAAA,eAAA;AAAA,IAC7B,4BAA8B,EAAA,2BAAA;AAAA;AAAA,IAG9B,gBAAkB,EAAA,cAAA;AAAA;AAAA,IAGlB,gBAAkB,EAAA,sCAAA;AAAA,IAClB,sBACE,EAAA,sGAAA;AAAA,IACF,mBAAqB,EAAA,eAAA;AAAA,IACrB,iBAAmB,EAAA,WAAA;AAAA,IACnB,yBAA2B,EAAA,sBAAA;AAAA,IAC3B,kBAAoB,EAAA,sBAAA;AAAA;AAAA,IAGpB,gCACE,EAAA,iFAAA;AAAA,IACF,6BACE,EAAA,uIAAA;AAAA,IACF,2BAA6B,EAAA,+CAAA;AAAA,IAC7B,mBAAqB,EAAA,+CAAA;AAAA,IACrB,8BAAgC,EAAA,gCAAA;AAAA,IAChC,0BAA4B,EAAA,6BAAA;AAAA,IAC5B,0BAA4B,EAAA,uBAAA;AAAA,IAC5B,oBAAsB,EAAA,sBAAA;AAAA,IACtB,4BAA8B,EAAA,0BAAA;AAAA,IAC9B,iCACE,EAAA,iHAAA;AA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A,IACvC,6CACE,EAAA,qDAAA;AAAA,IACF,+CACE,EAAA,sDAAA;AAAA,IACF,6CACE,EAAA,iCAAA;AAAA,IACF,+CACE,EAAA,kCAAA;AAAA,IACF,qCAAuC,EAAA,2BAAA;AAAA,IACvC,qCACE,EAAA,6DAAA;AAAA,IACF,kCAAoC,EAAA,gCAAA;AAAA,IACpC,wCACE,EAAA,gEAAA;AAAA;AAAA,IAGF,oBAAsB,EAAA,QAAA;AAAA,IACtB,oBAAsB,EAAA,SAAA;AAAA,IACtB,kBAAoB,EAAA,QAAA;AAAA,IACpB,kBAAoB,EAAA,WAAA;AAAA,IACpB,oBAAsB,EAAA,SAAA;AAAA,IACtB,uBAAyB,EAAA,wCAAA;AAAA,IACzB,yBAA2B,EAAA,mBAAA;AAAA,IAC3B,2BAA6B,EAAA,oBAAA;AAAA;AAAA,IAG7B,4BAA8B,EAAA,mBAAA;AAAA,IAC9B,0BACE,EAAA,iIAAA;AAAA,IACF,gCACE,EAAA,iHAAA;AAAA,IACF,0CACE,EAAA,4DAAA;AAAA,IACF,kCAAoC,EAAA,UAAA;AAAA,IACpC,wCAA0C,EAAA,oBAAA;AAAA,IAC1C,2CAA6C,EAAA,sBAAA;AAAA,IAC7C,0CAA4C,EAAA,QAAA;AAAA,IAC5C,yCAA2C,EAAA,MAAA;AAAA,IAC3C,0CAA4C,EAAA,SAAA;AAAA,IAC5C,yCAA2C,EAAA,eAAA;AAAA,IAC3C,wCAA0C,EAAA,KAAA;AAAA,IAC1C,+CAAiD,EAAA,sBAAA;AAAA,IACjD,2CAA6C,EAAA,aAAA;AAAA,IAC7C,4CAA8C,EAAA,iBAAA;AAAA,IAC9C,8CAAgD,EAAA,kBAAA;AAAA,IAChD,sCAAwC,EAAA;AAAA;AAE5C,CAAC;;;;"}
1
+ {"version":3,"file":"de.esm.js","sources":["../../src/translations/de.ts"],"sourcesContent":["/*\n * Copyright Red Hat, Inc.\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 { createTranslationMessages } from '@backstage/core-plugin-api/alpha';\nimport { scorecardTranslationRef } from './ref';\n\n/**\n * de translation for plugin.scorecard.\n * @public\n */\nconst scorecardTranslationDe = createTranslationMessages({\n ref: scorecardTranslationRef,\n messages: {\n 'common.loading': 'Ladevorgang',\n 'emptyState.altText': 'Keine Scorecards',\n 'emptyState.button': 'Dokumentation anzeigen',\n 'emptyState.description':\n 'Scorecards helfen Ihnen, den Zustand der Komponenten auf einen Blick zu überwachen. Schauen Sie sich zunächst unsere Dokumentation mit den Einrichtungshinweisen an.',\n 'emptyState.title': 'Noch keine Scorecards hinzugefügt.',\n 'entitiesPage.entitiesTable.footer.allRows': 'Alle Zeilen',\n 'entitiesPage.entitiesTable.footer.of': 'von',\n 'entitiesPage.entitiesTable.footer.rows_one': '{{count}} Zeile',\n 'entitiesPage.entitiesTable.footer.rows_other': '{{count}} Zeilen',\n 'entitiesPage.entitiesTable.header.entity': 'Entity',\n 'entitiesPage.entitiesTable.header.kind': 'Art',\n 'entitiesPage.entitiesTable.header.lastUpdated': 'Letzte Aktualisierung',\n 'entitiesPage.entitiesTable.header.owner': 'Eigentümer',\n 'entitiesPage.entitiesTable.header.status': 'Status',\n 'entitiesPage.entitiesTable.header.value': 'Wert',\n 'entitiesPage.entitiesTable.title': 'Entitäten',\n 'entitiesPage.entitiesTable.titleWithCount': 'Entitäten ({{count}})',\n 'entitiesPage.entitiesTable.unavailable': 'Nicht verfügbar',\n 'entitiesPage.metricProviderNotRegistered':\n 'Der Metrikanbieter mit der ID {{metricId}} ist nicht registriert.',\n 'entitiesPage.missingPermission':\n 'Um die Kennzahlen der Scorecard einzusehen, muss Ihnen Ihr Administrator die erforderliche Berechtigung erteilen.',\n 'entitiesPage.noDataFound':\n 'Um Ihre Daten hier anzuzeigen, überprüfen Sie, ob Ihre Entitäten Werte melden, die sich auf diese Kennzahl beziehen.',\n 'entitiesPage.unknownMetric': 'Unbekannte Metrik',\n 'errors.authenticationError': 'Authentifizierungsfehler',\n 'errors.authenticationErrorMessage':\n 'Bitte melden Sie sich an, um Ihre Daten einzusehen.',\n 'errors.entityMissingProperties':\n 'Für die Scorecard-Suche fehlen der Entität die erforderlichen Eigenschaften.',\n 'errors.fetchError': 'Fehler beim Abrufen der Scorecards: {{error}}',\n 'errors.invalidApiResponse': 'Ungültiges Antwortformat der Scorecard-API',\n 'errors.invalidThresholds': 'Ungültige Schwellenwerte',\n 'errors.metricDataUnavailable': 'Metrische Daten nicht verfügbar',\n 'errors.missingAggregationId':\n 'Die Scorecard ist falsch konfiguriert, die Eigenschaft für die Aggregations-ID (oder Metrik-ID) fehlt.',\n 'errors.missingPermission': 'Fehlende Berechtigung',\n 'errors.missingPermissionMessage':\n 'Um die Kennzahlen der Scorecard einzusehen, muss Ihnen Ihr Administrator die erforderliche Berechtigung erteilen.',\n 'errors.noDataFound': 'Keine Daten gefunden',\n 'errors.noDataFoundMessage':\n 'Um Ihre Daten hier anzuzeigen, überprüfen Sie, ob Ihre Entitäten Werte melden, die sich auf diese Kennzahl beziehen.',\n 'errors.unsupportedAggregationType':\n 'Diese Scorecard verwendet einen Aggregationstyp, der von dieser Version des Plugins nicht unterstützt wird.',\n 'errors.userNotFoundInCatalogMessage':\n 'Benutzerentität im Katalog nicht gefunden.',\n 'metric.averageCenterTooltipMaxLabel': 'Maximal erreichbare Punktzahl',\n 'metric.averageCenterTooltipTotalLabel': 'Gesamtpunktzahl',\n 'metric.averageCenterTooltipBreakdownRow_one':\n '{{status}}: {{count}} entity, score: {{score}}',\n 'metric.averageCenterTooltipBreakdownRow_other':\n '{{status}}: {{count}} entities, score: {{score}}',\n 'metric.averageLegendTooltipEntitiesEach_one':\n '{{count}} Entitäten, jede {{score}}',\n 'metric.averageLegendTooltipEntitiesEach_other':\n '{{count}} Entitäten, jeweils {{score}}',\n 'metric.averageLegendTooltipRowTotal': 'Gesamtpunktzahl {{total}}',\n 'metric.drillDownCalculationFailures':\n 'Bei der Berechnung dieser Kennzahl ist ein oder mehrere Fehler aufgetreten.',\n 'metric.filecheck.description':\n 'Prüft, ob die Datei {{name}} im Repository existiert.',\n 'metric.filecheck.title': 'Dateiprüfung: {{name}}',\n 'metric.github.open_prs.description':\n 'Aktuelle Anzahl offener Pull Requests für ein bestimmtes GitHub-Repository.',\n 'metric.github.open_prs.title': 'GitHub offene PRs',\n 'metric.homepageEntityCalculationHealth':\n '{{healthy}} / {{total}} Entitäten ohne Metrikberechnungsfehler',\n 'metric.homepageEntityHealthRatio': '{{healthy}}/{{total}} Entitäten',\n 'metric.jira.open_issues.description':\n 'Zeigt die Anzahl der kritischen, blockierenden Vorgänge an, die aktuell in Jira offen sind.',\n 'metric.jira.open_issues.title': 'Jira-Tickets öffnen und blockieren',\n 'metric.lastUpdated': 'Letzte Aktualisierung: {{timestamp}}',\n 'metric.lastUpdatedNotAvailable': 'Letzte Aktualisierung: Nicht verfügbar',\n 'metric.someEntitiesNotReportingValues':\n 'Einige Organisationen melden keine Werte, die sich auf diese Kennzahl beziehen.',\n 'metric.sonarqube.code_coverage.description':\n 'Gesamtcodeabdeckung in SonarQube in Prozent.',\n 'metric.sonarqube.code_coverage.title': 'SonarQube-Codeabdeckung',\n 'metric.sonarqube.code_duplications.description':\n 'Prozentsatz doppelter Zeilen in SonarQube.',\n 'metric.sonarqube.code_duplications.title': 'SonarQube-Code-Duplizierungen',\n 'metric.sonarqube.maintainability_issues.description':\n 'Anzahl offener Code-Smells in SonarQube.',\n 'metric.sonarqube.maintainability_issues.title':\n 'SonarQube-Wartbarkeitsprobleme',\n 'metric.sonarqube.maintainability_rating.description':\n 'SonarQube-Wartungsbewertung.',\n 'metric.sonarqube.maintainability_rating.title':\n 'SonarQube-Wartbarkeitsbewertung',\n 'metric.sonarqube.open_issues.description':\n 'Anzahl der offenen Tickets (OFFEN, BESTÄTIGT, WIEDERERÖFFNET) in SonarQube.',\n 'metric.sonarqube.open_issues.title': 'Offene Probleme bei SonarQube',\n 'metric.sonarqube.quality_gate.description':\n 'Ob das Projekt die SonarQube-Qualitätsprüfung besteht.',\n 'metric.sonarqube.quality_gate.title': 'SonarQube Qualitätsgate-Status',\n 'metric.sonarqube.reliability_issues.description':\n 'Anzahl offener Fehler in SonarQube.',\n 'metric.sonarqube.reliability_issues.title':\n 'Zuverlässigkeitsprobleme von SonarQube',\n 'metric.sonarqube.reliability_rating.description':\n 'SonarQube-Zuverlässigkeitsbewertung.',\n 'metric.sonarqube.reliability_rating.title':\n 'SonarQube-Zuverlässigkeitsbewertung',\n 'metric.sonarqube.security_hotspots.description':\n 'Anzahl der in SonarQube zu überprüfenden Sicherheits-Hotspots.',\n 'metric.sonarqube.security_hotspots.title':\n 'SonarQube Sicherheits-Hotspots',\n 'metric.sonarqube.security_issues.description':\n 'Anzahl offener Sicherheitslücken in SonarQube.',\n 'metric.sonarqube.security_issues.title': 'SonarQube-Sicherheitsprobleme',\n 'metric.sonarqube.security_rating.description':\n 'SonarQube-Sicherheitsbewertung.',\n 'metric.sonarqube.security_rating.title': 'SonarQube-Sicherheitsbewertung',\n 'metric.sonarqube.security_review_rating.description':\n 'SonarQube-Sicherheitsbewertung.',\n 'metric.sonarqube.security_review_rating.title':\n 'SonarQube Sicherheitsbewertung',\n 'notFound.altText': 'Seite nicht gefunden',\n 'notFound.contactSupport': 'Kontaktieren Sie den Support.',\n 'notFound.description':\n 'Versuchen Sie, eine {{indexFile}}-Datei im Stammverzeichnis des docs-Verzeichnisses dieses Repositorys hinzuzufügen.',\n 'notFound.goBack': 'Zurück',\n 'notFound.readMore': 'Weitere Informationen',\n 'notFound.title': '404 Die Seite konnte nicht gefunden werden.',\n 'permissionRequired.altText': 'Berechtigung erforderlich',\n 'permissionRequired.button': 'Weitere Informationen',\n 'permissionRequired.description':\n 'Um das Scorecard-Plugin anzuzeigen, wenden Sie sich an Ihren Administrator, um die Berechtigung {{permission}} zu erteilen.',\n 'permissionRequired.title': 'Fehlende Berechtigung',\n 'thresholds.entities_one': '{{count}} Entität',\n 'thresholds.entities_other': '{{count}} Entitäten',\n 'thresholds.error': 'Fehler',\n 'thresholds.exist': 'Existieren',\n 'thresholds.missing': 'Fehlen',\n 'thresholds.noEntities': 'Keine Entitäten im Zustand {{category}}',\n 'thresholds.success': 'Erfolg',\n 'thresholds.warning': 'Warnung',\n },\n});\n\nexport default scorecardTranslationDe;\n"],"names":[],"mappings":";;;AAuBA,MAAM,yBAAyB,yBAA0B,CAAA;AAAA,EACvD,GAAK,EAAA,uBAAA;AAAA,EACL,QAAU,EAAA;AAAA,IACR,gBAAkB,EAAA,aAAA;AAAA,IAClB,oBAAsB,EAAA,kBAAA;AAAA,IACtB,mBAAqB,EAAA,wBAAA;AAAA,IACrB,wBACE,EAAA,4KAAA;AAAA,IACF,kBAAoB,EAAA,uCAAA;AAAA,IACpB,2CAA6C,EAAA,aAAA;AAAA,IAC7C,sCAAwC,EAAA,KAAA;AAAA,IACxC,4CAA8C,EAAA,iBAAA;AAAA,IAC9C,8CAAgD,EAAA,kBAAA;AAAA,IAChD,0CAA4C,EAAA,QAAA;AAAA,IAC5C,wCAA0C,EAAA,KAAA;AAAA,IAC1C,+CAAiD,EAAA,uBAAA;AAAA,IACjD,yCAA2C,EAAA,eAAA;AAAA,IAC3C,0CAA4C,EAAA,QAAA;AAAA,IAC5C,yCAA2C,EAAA,MAAA;AAAA,IAC3C,kCAAoC,EAAA,cAAA;AAAA,IACpC,2CAA6C,EAAA,0BAAA;AAAA,IAC7C,wCAA0C,EAAA,oBAAA;AAAA,IAC1C,0CACE,EAAA,mEAAA;AAAA,IACF,gCACE,EAAA,mHAAA;AAAA,IACF,0BACE,EAAA,+HAAA;AAAA,IACF,4BAA8B,EAA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