Applied a map to avoid hard coded cases

Signed-off-by: Andre Wanlin <awanlin@spotify.com>
This commit is contained in:
Andre Wanlin
2023-12-22 11:41:47 -06:00
parent 74f5794387
commit 834d2f530e
2 changed files with 70 additions and 22 deletions
@@ -91,6 +91,11 @@ import { styled, withStyles } from '@material-ui/core/styles';`,
errors: [{ messageId: 'topLevelImport' }],
output: `import { styled } from '@material-ui/core/styles';`,
},
{
code: `import { SvgIcon, SvgIconProps } from '@material-ui/core';`,
errors: [{ messageId: 'topLevelImport' }],
output: `import SvgIcon, { SvgIconProps } from '@material-ui/core/SvgIcon';`,
},
{
code: `import { TabProps } from '@material-ui/core';`,
errors: [{ messageId: 'topLevelImport' }],