File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed
projects/igniteui-angular/src/lib/buttonGroup Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -462,14 +462,19 @@ export class IgxButtonGroupComponent extends DisplayDensityBase implements After
462462 } ) ;
463463 } ;
464464
465- this . viewButtons . changes . pipe ( takeUntil ( this . queryListNotifier$ ) ) . subscribe ( ( ) => initButtons ( ) ) ;
466- this . templateButtons . changes . pipe ( takeUntil ( this . queryListNotifier$ ) ) . subscribe ( ( ) => initButtons ( ) ) ;
467- initButtons ( ) ;
468-
469- this . _cdr . detectChanges ( ) ;
470-
471465 this . mutationObserver = this . setMutationsObserver ( ) ;
472466
467+ this . viewButtons . changes . pipe ( takeUntil ( this . queryListNotifier$ ) ) . subscribe ( ( ) => {
468+ this . mutationObserver . disconnect ( ) ;
469+ initButtons ( ) ;
470+ } ) ;
471+ this . templateButtons . changes . pipe ( takeUntil ( this . queryListNotifier$ ) ) . subscribe ( ( ) => {
472+ this . mutationObserver . disconnect ( ) ;
473+ initButtons ( ) ;
474+ } ) ;
475+
476+ initButtons ( ) ;
477+ this . _cdr . detectChanges ( ) ;
473478 this . mutationObserver ?. observe ( this . _el . nativeElement , this . observerConfig ) ;
474479 }
475480
You can’t perform that action at this time.
0 commit comments