Jump to content

custom css h1 font not appearing on mobile?

Recommended Posts

Hi @ErynnBriggs,

The default font is showing for me (both desktop and mobile):

image.png.f289439a2653e656c6280d08fc043815.png

I noticed a few typos in your CSS. Try this instead:

@font-face {
    font-family: 'white angelica';
    src: url('https://static1.squarespace.com/static/5ac7fe4cc258b4e1cd67c9c2/t/5f909f94732c6b19aa0ad4af/1603313556494/WhiteAngelica.ttf') format('truetype');
}

h1 {
    font-family: 'white angelica' !important
}

With this expected result:

image.png.fb7ae71c958dfeb18cd1371c6a59bd11.png

Hope this helps!
-Tyler

The above post may be outdated. I’m no longer active in the Squarespace ecosystem, so I won’t see your direct messages. For better resources about web accessibility, I’ve documented some of my thoughts on my forum profile.

Link to comment
25 minutes ago, mariyaleona said:

The same thing is happening to me – I see my custom font on desktop but not on mobile

Hi @mariyaleona,

It appears you may have a similar typo in your CSS. When testing your site with multiple browsers, I see Chrome recognizes the Karin font, whereas Edge and mobile browsers do not.

Try this instead - the filename should be wrapped in quotation marks, and it's best to specify the format too:

@font-face {
    font-family: 'KARIN';
    src: url('https://static1.squarespace.com/static/5f7b8d3d7ffdc521ceafbda5/t/5f7b92f5cc6429688a063106/1601934070893/Karin.otf') format('opentype');
}

h1 {
    font-family: 'KARIN';
    letter-spacing: 0px;
    font-size: 45px
}

Hope this helps!
-Tyler

The above post may be outdated. I’m no longer active in the Squarespace ecosystem, so I won’t see your direct messages. For better resources about web accessibility, I’ve documented some of my thoughts on my forum profile.

Link to comment

Hi Tyler - thank you for the support. I updated the code but the font still isn't appearing on mobile on the mobile chrome browser – but it's working on safari. Is there anything else I would need to do to ensure it formats for both browsers?

I did clear my cookies and make sure I have the latest version of the app for chrome, but it's still not showing. Here's screenshots for reference: 

Chrome.PNG

Safari.PNG

Link to comment
  • 5 weeks later...
13 hours ago, AndreaOchoa said:

site url https://www.superpowerss.com/ 

i added a custom css code for H1 but it dosent show in the mobile site i tried the codes above but they dont work

Try this new code

@font-face {
    font-family: 'Turnpike';
    src: url(https://static1.squarespace.com/static/5aef419ff2e6b1f9aa3ea218/t/5fb7df823254445724c133f0/1605885826610/turnpike.ttf);
}

.mobile-bar-wrapper *, h1 {
    font-family: 'Turnpike' !important;
    font-size: 18px
}

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • 8 months later...

This same issue is happening for me. Here is the code I have and it is not working on mobile:

//ADDING REMAN FONT//
@font-face {
  font-family: "Reman";
      src:
url('https://static1.squarespace.com/static/60f1b9ed84bdc3300f23b9cc/t/60f99ced9da0b966a576b8a4/1626971373596/Reman+3.ttf');
}

//ASSIGN REMAN FONT//
h3 {font-family: "Reman"; 
letter-spacing:'2px';    
font-size:120px;
  line-height:.75
}
.mobile-bar-wrapper *, h3 {
    font-family: "Reman" !important;
    font-size: 70px
}

Link to comment
On 8/18/2021 at 9:56 PM, dimauro said:

This same issue is happening for me. Here is the code I have and it is not working on mobile:

//ADDING REMAN FONT//
@font-face {
  font-family: "Reman";
      src:
url('https://static1.squarespace.com/static/60f1b9ed84bdc3300f23b9cc/t/60f99ced9da0b966a576b8a4/1626971373596/Reman+3.ttf');
}

//ASSIGN REMAN FONT//
h3 {font-family: "Reman"; 
letter-spacing:'2px';    
font-size:120px;
  line-height:.75
}
.mobile-bar-wrapper *, h3 {
    font-family: "Reman" !important;
    font-size: 70px
}

Hi. Can you share link to your site? We can check easier

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • 6 months later...

Hi there @tcp13,

I am running into the same issue. It is appearing on desktop, but not mobile. Any suggestions? I just added the bit "format('opentype');" per your suggestion above, but it unfortunately didn't fix the issuse.

++++++++++++++++++++++++++++++

ULR: https://www.ashandaircreative.com/

@font-face {
  font-family: 'Sophillia';
  src: url('https://static1.squarespace.com/static/5e2a0c24a601f10901a27e9d/t/5fa1a2bdcba0b51a3787ef38/1604428478006/Sophillia.otf') format('opentype');
  }

h1,h2 {
  font-family: 'Sophillia';
}

IMG_FA42481DE993-1.jpeg

Screen Shot 2022-03-15 at 10.32.42 PM.png

Edited by AshM13
Link to comment
4 hours ago, AshM13 said:

Hi there @tcp13,

I am running into the same issue. It is appearing on desktop, but not mobile. Any suggestions? I just added the bit "format('opentype');" per your suggestion above, but it unfortunately didn't fix the issuse.

++++++++++++++++++++++++++++++

ULR: https://www.ashandaircreative.com/

@font-face {
  font-family: 'Sophillia';
  src: url('https://static1.squarespace.com/static/5e2a0c24a601f10901a27e9d/t/5fa1a2bdcba0b51a3787ef38/1604428478006/Sophillia.otf') format('opentype');
  }

h1,h2 {
  font-family: 'Sophillia';
}

IMG_FA42481DE993-1.jpeg

Screen Shot 2022-03-15 at 10.32.42 PM.png

Hi. THe font file doesn't exist. Try copy font file url & paste to browser address bar. You will see

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • 5 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.