0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

CSS で作ったバルーンがちらついたときの話

0
Posted at

概要

はてなマークのバルーン(ホバーしたら説明が出てくるあれ)をCSSで実装したのですが、キャッシュを読み込んでから最初のホバーのときになぜかちらついてしまいました。

背景

会社のアプリケーションのフロントを新しく作り変えるという業務の最中、上記のようなことが起きました。JSを使っているわけでもないので、まったくわかりませんでした。

解決法

Chromeで検証をしたところ、事前に読み込まれているはずのフォントの設定ファイルが、ホバーした時にもう一度読み込まれているようです。
ヘッダーを確認したところ。同じ記述のあるファイルが2度読み込まれていました。
片方を読み込まないようにしたら無事正しい挙動をしてくれました。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?