Merge pull request #9831 from andys-hoodie/nd10/card-md

Render markdown for description in software templates
This commit is contained in:
Patrik Oldsberg
2022-03-03 17:42:35 +01:00
committed by GitHub
2 changed files with 11 additions and 2 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-scaffolder': patch
---
Render markdown for description in software templates
@@ -44,7 +44,11 @@ import WarningIcon from '@material-ui/icons/Warning';
import React from 'react';
import { selectedTemplateRouteRef } from '../../routes';
import { Button, ItemCardHeader } from '@backstage/core-components';
import {
Button,
ItemCardHeader,
MarkdownContent,
} from '@backstage/core-components';
import { useApi, useRouteRef } from '@backstage/core-plugin-api';
const useStyles = makeStyles(theme => ({
@@ -178,7 +182,7 @@ export const TemplateCard = ({ template, deprecated }: TemplateCardProps) => {
<Typography variant="body2" className={classes.label}>
Description
</Typography>
{templateProps.description}
<MarkdownContent content={templateProps.description} />
</Box>
<Box className={classes.box}>
<Typography variant="body2" className={classes.label}>