File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
packages/devextreme-angular/src/core Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ import { logWarning } from './warning-helper';
55
66const warnedUsages = new Set < string > ( ) ;
77
8- const LEGACY_CLASS_NAME_REGEXP = / ^ D x ( [ i o ] ) ( [ A - Z a - z 0 - 9 ] + ) C o m p o n e n t $ / ;
8+ const NESTED_CLASS_NAME_REGEXP = / ^ ( D x [ i o ] [ A - Z ] \w + ) C o m p o n e n t $ / ;
99
1010type DeprecatedConfigEntry = Record < string , string > ;
1111
@@ -15,15 +15,14 @@ function getLegacySelector(nestedOption: BaseNestedOption): string | undefined {
1515 return undefined ;
1616 }
1717
18- const match = LEGACY_CLASS_NAME_REGEXP . exec ( className ) ;
18+ const match = NESTED_CLASS_NAME_REGEXP . exec ( className ) ;
1919 if ( ! match ) {
2020 return undefined ;
2121 }
2222
23- const [ , type , rest ] = match ;
24- const prefix = type === 'o' ? 'dxo-' : 'dxi-' ;
23+ const [ , legacyName ] = match ;
2524
26- return ` ${ prefix } ${ toKebabCase ( rest ) } ` ;
25+ return toKebabCase ( legacyName ) ;
2726}
2827
2928function getHostMapping ( host : INestedOptionContainer | undefined ) : DeprecatedConfigEntry | undefined {
You can’t perform that action at this time.
0 commit comments