App Script HtmlService use with font like Google Web Fonts?

老子叫甜甜 提交于 2019-12-12 15:10:17

问题


I trying to do one (!) page with the app script HtmlService but want to have specific web fonts.

I added the CSS code for the web fonts, and integrated it with my CSS. It's not working.

I suspect Google Caja (HtmlService is going through the Caja filter) not being able to work with web fonts. Would you know if I am doing something wrong with HtmlService, or if there is any other way to have web fonts through the filtering of Caja?

<link href='http://fonts.googleapis.com/css?family=Fugaz+One' rel='stylesheet' type='text/css'>

回答1:


The stylesheet you refer to uses @font-face to load a font. Caja does not currently support @font-face, since it refers to external content (the font data) which Caja does not implement sanitization of and has not reviewed the risks of allowing through unchanged.

If you would like to have @font-face support, please file an issue on Caja's public issue tracker requesting it.

(I am a developer on the Caja team.)



来源:https://stackoverflow.com/questions/12808007/app-script-htmlservice-use-with-font-like-google-web-fonts

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!