Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change the way of preloading fonts #21599

Merged
merged 2 commits into from
Mar 15, 2023
Merged

Conversation

valentinpalkovic
Copy link
Contributor

@valentinpalkovic valentinpalkovic commented Mar 14, 2023

Closes #21315

What I did

I have changed the way of how fonts were preloaded. Using preloading resulted in a browser warning because the resource was not used after a couple of seconds after the window.load event.

How to test

  1. Create a sandbox
  2. Open Storybook
  3. There shouldn't be a warning saying the Nunito Sans font was preloaded but not used within a few seconds after the window.load event

Checklist

  • Make sure your changes are tested (stories and/or unit, integration, or end-to-end tests)
  • Make sure to add/update documentation regarding your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Maintainers

  • If this PR should be tested against many or all sandboxes,
    make sure to add the ci:merged or ci:daily GH label to it.
  • Make sure this PR contains one of the labels below.

["cleanup", "BREAKING CHANGE", "feature request", "bug", "documentation", "maintenance", "dependencies", "other"]

@valentinpalkovic valentinpalkovic changed the title Fetch the way of preloading fonts Change the way of preloading fonts Mar 15, 2023
@ndelangen ndelangen merged commit a7b5625 into next Mar 15, 2023
@ndelangen ndelangen deleted the valentin/fix-preloading-for-fonts branch March 15, 2023 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants