@@ -718,7 +718,7 @@ function migrateImportDeclaration(node: ts.ImportDeclaration, sourceFile: ts.Sou
718718 const importPath = moduleSpecifier . text ;
719719
720720 // Only process igniteui-angular imports (not already using entry points)
721- if ( importPath !== 'igniteui-angular' ) {
721+ if ( importPath !== 'igniteui-angular' && importPath !== '@infragistics/igniteui-angular' ) {
722722 return null ;
723723 }
724724
@@ -768,7 +768,7 @@ function migrateImportDeclaration(node: ts.ImportDeclaration, sourceFile: ts.Sou
768768 const newImports : string [ ] = [ ] ;
769769 for ( const [ entryPoint , imports ] of entryPointGroups ) {
770770 const sortedImports = imports . sort ( ) ;
771- newImports . push ( `import { ${ sortedImports . join ( ', ' ) } } from 'igniteui-angular /${ entryPoint } ';` ) ;
771+ newImports . push ( `import { ${ sortedImports . join ( ', ' ) } } from '${ importPath } /${ entryPoint } ';` ) ;
772772 }
773773
774774 return {
@@ -799,7 +799,7 @@ function migrateFile(filePath: string, content: string): string {
799799
800800 // Track old type names that were imported
801801 const moduleSpecifier = node . moduleSpecifier ;
802- if ( ts . isStringLiteral ( moduleSpecifier ) && moduleSpecifier . text === 'igniteui-angular' ) {
802+ if ( ts . isStringLiteral ( moduleSpecifier ) && ( moduleSpecifier . text === 'igniteui-angular' || moduleSpecifier . text === '@infragistics/igniteui-angular' ) ) {
803803 const importClause = node . importClause ;
804804 if ( importClause ?. namedBindings && ts . isNamedImports ( importClause . namedBindings ) ) {
805805 for ( const element of importClause . namedBindings . elements ) {
@@ -877,7 +877,8 @@ export default function migrate(): Rule {
877877 const originalContent = content . toString ( ) ;
878878
879879 // Check if file has igniteui-angular imports
880- if ( ! originalContent . includes ( "from 'igniteui-angular'" ) && ! originalContent . includes ( 'from "igniteui-angular"' ) ) {
880+ if ( ! originalContent . includes ( "from 'igniteui-angular'" ) && ! originalContent . includes ( 'from "igniteui-angular"' ) &&
881+ ! originalContent . includes ( "from '@infragistics/igniteui-angular'" ) && ! originalContent . includes ( 'from "@infragistics/igniteui-angular"' ) ) {
881882 return ;
882883 }
883884
0 commit comments