Giter Club home page Giter Club logo

Comments (3)

rhyneav avatar rhyneav commented on June 6, 2024

Hey @John-H-Smith, I think some update here makes sense. What does your current override look like? We currently conditionally import the Google font based on if it is set:

// _config.scss

// The src for fonts (false to disable)
$font-src: 'https://fonts.googleapis.com/css?family=Neucha|Patrick+Hand+SC&display=swap' !default;

// Imports
@if $font-src {
  @import url($font-src);
}

I wonder if making a switch over to something like Font Source and totally leaving the Google ecosystem would be a good step forward, but curious to hear what would work best for you and other EU website owners.

from papercss.

John-H-Smith avatar John-H-Smith commented on June 6, 2024

Hi @rhyneav , thank you for your answer!
For my current workaround, I downloaded the sources of the font-families 'neucha' and 'Patrick Hand SC' and set the font-family in a custom css file like so:

/* latin */
@font-face {
  font-family: 'Neucha';
  font-style: normal;
  font-weight: 400;
  src: url(/fonts/neucha.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin */
@font-face {
  font-family: 'Patrick Hand SC';
  font-style: normal;
  font-weight: 400;
  src: url(/fonts/Patrick_hand_sc.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

I know it's not a great way, but it works for the moment.

Moving to Font Source or something else is sadly no option. In the EU, you have to actively accept the loading of ANY data from a cdn, doesn't matter if it's google or something else. So for using papercss, currently every website has to include a cookie banner which allows you to accept the loading of the fonts.
The only way to get rid of that permission thing is to self-host the font on the same site.

from papercss.

Oli8 avatar Oli8 commented on June 6, 2024

https://gwfh.mranftl.com/fonts might be worth looking into

from papercss.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.