SU-SWS / decanter

A collection of front end web resources.
GNU General Public License v3.0
41 stars 9 forks source link

Switch Source Serif Pro to import from Google Fonts #884

Closed iamrentman closed 2 years ago

iamrentman commented 2 years ago

Switch Source Serif Pro to import from Google Fonts instead of hosted files.

READY FOR REVIEW

Summary

Import all versions of Source Serif Pro from Google Fonts (instead of hosted AWS files) now that they are available from Google. This maintains consistency with how the other fonts are imported to the project.

Needed By (Date)

No specific deadline.

Urgency

Not critical

Steps to Test

  1. Create tests file in the developer directory – you'll need test.twig and test.scss for this
  2. In test.twig add markup for at least one heading and some body text.
  3. Make a portion of each the heading and the body italic by adding an <em> or <i> to a few words.
  4. In test.scss add a rule so your content displays in the Source Serif font – font-family: $su-font-serif;
  5. npm run dev to compile the assets.
  6. npm run start to start the development server and open your test page.
  7. Check your test page in the browser to ensure that it displays the proper serif font – Source Serif Pro – and ensure that the italics display appropriately.
  8. Using dev tools, view the decanter.css file in the Sources tab. Line 2 should now be a longer string that includes all variations of Source Serif Pro.

Affected Projects or Products

Just a helpful update, that's all.

Associated Issues and/or People

I've discussed this change in the #decanter Slack channel with @yvonnetangsu and @sherakama. We agreed that it'd be worthwhile. This is my first PR to Decanter, so lemme know if I missed something. :)

See Also

yvonnetangsu commented 2 years ago

@iamrentman Yay 🎉 Thank you so much! I'll test this out later today 😄

iamrentman commented 2 years ago

@yvonnetangsu I've committed updates to the additional font imports – Roboto, Kalam, and Noto Sans – to match what was there.

When selecting the styles to include for Noto Sans Devanagari, there are no italic versions available, so I only included 400 and 700: https://fonts.google.com/noto/specimen/Noto+Sans+Devanagari. I'm not familiar with this particular font so maybe there is another way to include the italics? Or maybe we're good the way I have it here? Let me know what you think.

yvonnetangsu commented 2 years ago

@yvonnetangsu I've committed updates to the additional font imports – Roboto, Kalam, and Noto Sans – to match what was there.

When selecting the styles to include for Noto Sans Devanagari, there are no italic versions available, so I only included 400 and 700: https://fonts.google.com/noto/specimen/Noto+Sans+Devanagari. I'm not familiar with this particular font so maybe there is another way to include the italics? Or maybe we're good the way I have it here? Let me know what you think.

@iamrentman Thank you - this is perfect. I don't think we support the italic version for Noto Sans/Kalam/Roboto Slab currently so this is great 😄 💯

yvonnetangsu commented 2 years ago

@sherakama Not sure why the autorelease failed - I'm guessing it's because of the PR labeler failed for some reason? 🤔

sherakama commented 2 years ago

Probably missing a key or a permission setting...

Screen Shot 2022-09-14 at 10 57 16 AM

sherakama commented 2 years ago

There you go: https://github.com/SU-SWS/decanter/releases/tag/6.2.9