angular / angular/components

a wrong height style with cdk-virtual-scroll-spacer (cdk-virtual-scroll-viewport)

オープン
#26,348 コメント 3 件 リアクション 2 件 担当者 0 名 GitHub で見る
area: cdk/scrolling P3 regression
主要言語
TypeScript
スター
25k
フォーク
6.8k
平均マージ
1日 8時間
マージ済み PR(30日)
91

説明

### Is this a regression?

- [X] Yes, this behavior used to work in the previous version

### The previous version in which this bug was not present was

14.0.3

### Description

After I updated angular material to 14.2.7 from 14.0.3 I start to get wrong height style with the div element that has the css class .cdk-virtual-scroll-spacer

### Reproduction

Steps to reproduce:
1. install the angular material 14.2.7
2. use the cdk-virtual-scroll-viewport

My Example code
```





```

### Expected Behavior

To get the correct style height on the div element that has the css class .cdk-virtual-scroll-spacer

### Actual Behavior

The div element that has the cs class .cdk-virtual-scroll-spacer get a style height which create a big space when I scroll to the end

### Environment

- Angular:
Angular CLI: 14.2.10
Node: 16.10.0
Package Manager: npm 7.10.0
OS: darwin x64

Angular: 14.2.12
... common, core

Package Version
-------------------------------------------------------------
@angular-devkit/architect 0.1402.10
@angular-devkit/build-angular 14.2.10
@angular-devkit/core 14.2.10
@angular-devkit/schematics 14.2.10
@angular/animations 14.0.3
@angular/cdk 14.2.7
@angular/cli 14.2.10
@angular/compiler 14.0.3
@angular/compiler-cli 14.0.3
@angular/forms 14.0.3
@angular/language-service 14.0.3
@angular/material 14.2.7
@angular/platform-browser 14.0.3
@angular/platform-browser-dynamic 14.0.3
@angular/platform-server 14.0.3
@angular/router 14.0.3
@angular/service-worker 14.0.3
@schematics/angular 14.2.10
rxjs 7.8.0
typescript 4.7.4

- CDK/Material: 14.2.7
- Browser(s): any
- Operating System (e.g. Windows, macOS, Ubuntu): macOS

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

まず、Angular CDK 14.2.7 で報告された cdk-virtual-scroll-viewport の例を再現し、その .cdk-virtual-scroll-spacer の高さをバージョン 14.0.3 のものと比較します。virtual-scroll viewport と spacer の動作を追跡してリグレッションを特定します。完了の条件は、末尾までスクロールしても過剰な空白が生成されず、spacer の高さが正しいことです。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
angular, typescript
領域
frontend
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。