Kendo-grid with dynamic data having groupby, pagination, expand and collapse functionality in Angular 12

I have a kendo grid which loads the data dynamically. Grid is grouped by one parameter also has pagination implemented. There is a group data added to every column using

"kendoGridGroupHeaderColumnTemplate"

Issue I am facing for the expand and collapse functionality when I collapse all the rows it also hides the details which are in

kendoGridGroupHeaderColumnTemplate

I have tried below code in HTML and TS files

 <kendo-grid
            [kendoGridBinding]="data"
            [height]="480"
            [group]="groups"
            [isGroupExpanded]="isGroupExpanded"
            (groupCollapse)="toggleGroup($event)"
            (groupExpand)="toggleGroup($event)" >
            <ng-template kendoGridToolbarTemplate>
                <button kendoButton (click)="expandAll()">Expand All Groups</button>
                <button kendoButton (click)="collapseAll()">Collapse All Groups</button>
            </ng-template>
             <kendo-grid-column  *ngFor="let item of cols; let i = index" field="{{ item.columnField }}" title="{{ item.columnTitle }}"  [width]="item.width">
            <ng-template kendoGridCellTemplate let-dataItem>
                <div class="cell-container">

                <span *ngIf="item.columnField === 'ProductID'">
                {{dataItem[item.columnField]}}

                </span>
                <span *ngIf="item.columnField === 'ProductName'">
                {{dataItem[item.columnField]}}
                <ng-template kendoGridGroupHeaderColumnTemplate let-group="group" let-aggregates="aggregates">Group level 1 </ng-template>
                </span>
                <span *ngIf="item.columnField === 'UnitPrice'">
                {{dataItem[item.columnField]}}
                <ng-template kendoGridGroupHeaderColumnTemplate let-group="group" let-aggregates="aggregates">
                Group level 2 </ng-template>
                </span>
                <span *ngIf="item.columnField === 'Category.CategoryName'">
                <ng-template kendoGridGroupHeaderTemplate let-value="value">
                    {{ value }}
                </ng-template>
                </span>
                </div>
            </ng-template>
            </kendo-grid-column>
        </kendo-grid>

TS:

export class AppComponent {
  cols = [
    {
      columnField: 'ProductID',
      columnTitle: 'Id',
      width: 80,
    },
    {
      columnField: 'ProductName',
      columnTitle: 'Name',
      width: 300,
    },
    {
      columnField: 'UnitPrice',
      columnTitle: 'Unit Price',
      width: 120,
    },
    {
      columnField: 'Category.CategoryName',
      columnTitle: '',
      width: 0,
    },
  ];
  public groups: GroupDescriptor[] = [{ field: 'Category.CategoryName' }];

  public data: Product[] = products;

  public expandedKeys: { field: string; value: string }[] = [
    { field: 'Category.CategoryName', value: 'Beverages' },
  ];

  public isGroupExpanded = (rowArgs: GroupRowArgs): boolean => {
    const matchKey = this.expandedKeys.some(
      (groupKey) =>
        groupKey.field === rowArgs.group.field &&
        groupKey.value === rowArgs.group.value
    );

    return (
      (this.initiallyExpanded && !matchKey) ||
      (!this.initiallyExpanded && matchKey)
    );
  };

  private initiallyExpanded = false;

  public expandAll(): void {
    this.initiallyExpanded = true;
    this.expandedKeys = [];
  }

  public collapseAll(): void {
    this.initiallyExpanded = false;
    this.expandedKeys = [];
  }

  public toggleGroup(rowArgs: GroupRowArgs): void {
    
    const keyIndex = this.expandedKeys.findIndex(
      (groupKey) =>
        groupKey.field === rowArgs.group.field &&
        groupKey.value === rowArgs.group.value
    );

    if (keyIndex === -1) {
      this.expandedKeys.push({
        field: rowArgs.group.field,
        value: rowArgs.group.value,
      });
    } 
    else {
      this.expandedKeys.splice(keyIndex, 1);
    }
  }

}

Here is the image attached:
As shown in the image, red marked data is group level data, which is visible when one of the group is expanded. enter image description here

Below is the image when I click on collapse all button
As shown in image after collapse, the data added for the group is not visible. This is the issue
enter image description here

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật