• Hello!

    I noticed that the preview for variable fonts is missing (btw, I also noticed that variable fonts are missing size files).

    I also have some questions.

    1. How to set font-display to other values like swup? Now the default is font-dispaly: fallback.
    2. Is it possible to preview (wght font axis, wdth font axis, etc.) after uploading the file to the server? Now these settings are only visible once before the file is uploaded to the server.

    Thanks!

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Matias Benedetto

    (@mmaattiiaass)

    Hi, @gyurmey

    1. Right now we are not adding the fontDisplay setting in the fontFamilies added to the theme.json created using the plugin. At this moment if you want to change that you would need to edit the theme.json file manually to set the value you want.

    2. The preview controls for the variable axes of fonts are currently only available on the “Upload local fonts” section of the plugin. They are not available in the other sections because in the other sections, you can display several font families at the same time and the variable axes preview controls should be specific for each font file.

    Both are enhancements that we could add in the future. Thanks for your question.

    Cheers.

    Thread Starter Gyurmey

    (@gyurmey)

    @mmaattiiaass, thanks for the answers. And is there a chance that the variable fonts after uploading to the server at least have a preview?

    Plugin Author Matias Benedetto

    (@mmaattiiaass)

    @gyurmey, not sure if I understood your last question. Variable fonts have preview controls as any other font family but those controls are only the basic ones (font size and demo text). Variable axes preview controls are only available in the upload local font screen.

    Thread Starter Gyurmey

    (@gyurmey)

    @mmaattiiaass, what I mean is that variable fonts, once uploaded to the server, have no preview.

    Before:

    After:

    And live example.

    Plugin Author Matias Benedetto

    (@mmaattiiaass)

    gotcha @gyurmey thanks for the link to debug. In this case the problem is that the font was uploaded with wrong filename and path (it contains a white space that should not be there). I submitted a fix for this: https://github.com/WordPress/create-block-theme/pull/401

    It will be solved when the next version of CBT is launched.
    When is launched it you could remove the font family and re-upload it and the problem will be solved.

    If you want to solve it right now and you are able to edit the files of your theme you could replace the font family asset path in theme.json file by replacing the last part of the asset path “…100 900.ttf” by “100-900.ttf” (a dash instead of the white space). Apart from that you should update the name of the font file in your assets folder in the same way.

    Thread Starter Gyurmey

    (@gyurmey)

    @mmaattiiaass, the font file loaded without any spaces, but now I see what the problem is (no spaces between the font weight values). Thanks for the clarification.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Problem with local variable fonts’ is closed to new replies.