fix flash of unstyled content in browser extension
Created by: sqs
The elements were being injected before the stylesheet finished loading (even though it is a local stylesheet, it still takes a brief moment to load). This fixes it so that the injection waits until the styles are loaded.
fix #4033
before and after videos
- BEFORE (video): Watch for the jitter in the top navbar of Bitbucket Server and GitHub.
- AFTER (video): No jitter!