mat-icon shows text before showing properly
- 主要言語
- TypeScript
- スター
- 25k
- フォーク
- 6.8k
- 平均マージ
- 1日 8時間
- マージ済み PR(30日)
- 91
説明
#### Bug, feature request, or proposal:
Bug or feature request.
#### What is the expected behavior?
When using `home`, nothing should be displayed until the icon is loaded properly. As soon as the icon is loaded, it should render.
#### What is the current behavior?
Depending on the speed of your connection, it is possible, that you see the text (for example `home`) instead of the icon.
#### What are the steps to reproduce?
1. Start the Angular Material Icon example in [Stackblitz](https://stackblitz.com/angular/yogqmggjokx).
It might be better to open it in it's own tab.
2. Open the Developer-Tools (in Chrome) and under the `Network`-Tab choose a very slow network throttling profile. This is needed, as the sample app is very small and therefore the problem is not noticeable with normal connections.
3. Reload the page and wait until it is loaded. You will see something like this:

After some time it shows the icon:

#### What is the use-case or motivation for changing an existing behavior?
In an app I am currently working on, this happens pretty often. Even if I only change the route (which does not trigger a reload of the page) I often see the text of the icons before the icon is displayed properly, so it does not seem to be related to the loading of the icon font.
#### Which versions of Angular, Material, OS, TypeScript, browsers are affected?
I am using @angular/material 6.3.1 together with TypeScript 2.7.2 on a Windows 10 PC.
The problem occures at least on Chrome, Opera, Firefox and Edge.
コントリビューションガイド
調査の方向性
非常に遅いネットワークプロファイルを使用して、リンク先の StackBlitz の例から問題を再現し、mat-icon コンポーネントとその読み込み動作に注目してください。中間テキストの表示を確認し、報告されたすべてのブラウザーで、アイコンの準備が完了するまでアイコンのテキストが非表示のままになることを確認してください。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- angular, typescript
- 領域
- frontend
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 42/100