fix: Remove React import form notification and scaffolder plugin

Signed-off-by: mario ma <mario.ma.node@gmail.com>
This commit is contained in:
mario ma
2025-06-09 15:02:12 +08:00
parent 5247c13d74
commit b00c160f42
5 changed files with 19 additions and 15 deletions
+6
View File
@@ -0,0 +1,6 @@
---
'@backstage/plugin-notifications': patch
'@backstage/plugin-scaffolder': patch
---
Remove React import form notification and scaffolder plugin
@@ -14,7 +14,6 @@
* limitations under the License.
*/
import React from 'react';
import {
ChannelSetting,
isNotificationsEnabledFor,
@@ -14,7 +14,6 @@
* limitations under the License.
*/
import React from 'react';
import {
isNotificationsEnabledFor,
NotificationSettings,
@@ -26,7 +26,7 @@ import { ClassNameMap } from '@material-ui/core/styles/withStyles';
import Typography from '@material-ui/core/Typography';
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
import classNames from 'classnames';
import React, { ReactElement, useState } from 'react';
import { cloneElement, Fragment, ReactElement, useState } from 'react';
import { scaffolderTranslationRef } from '../../translation';
import { Expanded, RenderSchema, SchemaRenderContext } from '../RenderSchema';
import { ScaffolderUsageExamplesTable } from '../ScaffolderUsageExamplesTable';
@@ -60,7 +60,7 @@ const FilterDetailContent = ({
headings: [<Typography variant="h6" component="h4" />],
};
return (
<React.Fragment key={`${name}.detail`}>
<Fragment key={`${name}.detail`}>
{filter.description && <MarkdownContent content={filter.description} />}
<Box pb={2}>
<Typography variant="h5" component="h3">
@@ -84,7 +84,7 @@ const FilterDetailContent = ({
const [argSchema, required] = inspectFunctionArgSchema(arg);
return (
<React.Fragment key={i}>
<Fragment key={i}>
<div
className={classNames({ [classes.argRequired]: required })}
>
@@ -101,7 +101,7 @@ const FilterDetailContent = ({
}}
schema={argSchema}
/>
</React.Fragment>
</Fragment>
);
})}
</Box>
@@ -133,7 +133,7 @@ const FilterDetailContent = ({
</AccordionDetails>
</Accordion>
)}
</React.Fragment>
</Fragment>
);
};
@@ -178,7 +178,7 @@ export const TemplateFilters = ({
>
{name}
</Typography>
{React.cloneElement(baseLink, {
{cloneElement(baseLink, {
to: `${baseLink.props.to}#${fragment}`,
})}
<FilterDetailContent {...{ t, classes, name, filter }} />
@@ -26,7 +26,7 @@ import { ClassNameMap } from '@material-ui/core/styles/withStyles';
import Typography from '@material-ui/core/Typography';
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
import classNames from 'classnames';
import React, { ReactElement, useState } from 'react';
import { cloneElement, Fragment, ReactElement, useState } from 'react';
import { scaffolderTranslationRef } from '../../translation';
import { Expanded, RenderSchema, SchemaRenderContext } from '../RenderSchema';
import { ScaffolderUsageExamplesTable } from '../ScaffolderUsageExamplesTable';
@@ -60,7 +60,7 @@ const FunctionDetailContent = ({
headings: [<Typography variant="h6" component="h4" />],
};
return (
<React.Fragment key={`${name}.detail`}>
<Fragment key={`${name}.detail`}>
{fn.description && <MarkdownContent content={fn.description} />}
{schema?.arguments?.length && (
<Box key={`${name}.args`} pb={2}>
@@ -71,7 +71,7 @@ const FunctionDetailContent = ({
const [argSchema, required] = inspectFunctionArgSchema(arg);
return (
<React.Fragment key={i}>
<Fragment key={i}>
<div
className={classNames({ [classes.argRequired]: required })}
>
@@ -89,7 +89,7 @@ const FunctionDetailContent = ({
}}
schema={argSchema}
/>
</React.Fragment>
</Fragment>
);
})}
</Box>
@@ -121,7 +121,7 @@ const FunctionDetailContent = ({
</AccordionDetails>
</Accordion>
)}
</React.Fragment>
</Fragment>
);
};
@@ -166,7 +166,7 @@ export const TemplateGlobalFunctions = ({
>
{name}
</Typography>
{React.cloneElement(baseLink, {
{cloneElement(baseLink, {
to: `${baseLink.props.to}#${fragment}`,
})}
<FunctionDetailContent {...{ classes, name, fn, t }} />
@@ -218,7 +218,7 @@ export const TemplateGlobalValues = ({
>
{name}
</Typography>
{React.cloneElement(baseLink, {
{cloneElement(baseLink, {
to: `${baseLink.props.to}#${fragment}`,
})}
{gv.description && <MarkdownContent content={gv.description} />}