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

Separate out Typography examples, speed up docs, and be pretty about it #175

Merged
merged 7 commits into from
May 24, 2019

Conversation

lazd
Copy link
Member

@lazd lazd commented May 22, 2019

Description

This PR enables support for compiling .yml files in examples/whatever.yml as separate topdoc pages, available at dist/docs/whatever.index.html. This allows us to break out cross-component examples or slow-loading examples as their own pages.

It also adds support for using a smaller Typekit package is lang isn't present on any element and moves the Typekit JS file to the top of the doc, but waits for DOMContentLoaded before loading fonts so it knows if it needs the gigantic kit with all the languages or not. Though this doesn't make the gigantic docs page load much faster in most cases, this takes the total number of requests from 64 to 36, and the resource size from ~14mb to ~7mb.

Finally, it adds a cute little loader while fonts are coming down the pipe.

Related Issue

Related to #7
Closes #174
Closes #173

Screenshots (if appropriate):

image

Types of changes

  • Docs updates

…ss we have a lang attribute somewhere on the page
lazd added 2 commits May 22, 2019 17:00
Put the spectrum--scale class on the body

Support HTML-only standalone examples

Add a new Switcher class that can be used to switch Spectrum CSS files out
@lazd lazd merged commit 50eb95a into master May 24, 2019
@GarthDB GarthDB deleted the examples branch September 21, 2020 22:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Docs show a flicker of Action Bar while loading Support generation of separate examples in Spectrum CSS docs
1 participant