1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-07-26 13:48:33 +02:00

Fix invalid dom nesting error and remove redundant braces (#10115)

Fixes a console log about invalid dom nesting:

<img width="1256" alt="image"
src="https://github.com/user-attachments/assets/0849103c-6901-4b64-a124-00eaf8cc7dde"
/>

I've changed the offending div to a span. We set `display: flex` on it,
anyway, so it shouldn't make a difference.

I've also removed some redundant functions and braces that we don't
need.
This commit is contained in:
Thomas Heartman 2025-06-11 12:21:11 +02:00 committed by GitHub
parent 4e283dc579
commit fa28ee2d6a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 18 additions and 20 deletions

View File

@ -217,28 +217,26 @@ export const FeatureStrategyMenu = ({
maxWidth='md'
PaperProps={{
sx: {
borderRadius: (theme) => '12px',
borderRadius: '12px',
},
}}
>
{
<FeatureStrategyMenuCards
projectId={projectId}
featureId={featureId}
environmentId={environmentId}
onlyReleasePlans={onlyReleasePlans}
onAddReleasePlan={(template) => {
setSelectedTemplate(template);
addReleasePlan(template);
}}
onReviewReleasePlan={(template) => {
setSelectedTemplate(template);
setAddReleasePlanOpen(true);
onClose();
}}
onClose={onClose}
/>
}
<FeatureStrategyMenuCards
projectId={projectId}
featureId={featureId}
environmentId={environmentId}
onlyReleasePlans={onlyReleasePlans}
onAddReleasePlan={(template) => {
setSelectedTemplate(template);
addReleasePlan(template);
}}
onReviewReleasePlan={(template) => {
setSelectedTemplate(template);
setAddReleasePlanOpen(true);
onClose();
}}
onClose={onClose}
/>
</Dialog>
{selectedTemplate && (
<ReleasePlanReviewDialog

View File

@ -91,7 +91,7 @@ const StyledInfoIcon = styled(InfoOutlinedIcon)(({ theme }) => ({
color: theme.palette.text.secondary,
}));
const StyledIcon = styled('div')(({ theme }) => ({
const StyledIcon = styled('span')(({ theme }) => ({
width: theme.spacing(3),
'& > svg': {
fill: theme.palette.primary.main,