font-awesome

Font Awesome 5 shows empty square when using the JS+SVG version

一个人想着一个人 提交于 2019-12-16 20:26:50
问题 Attempting to replace the bullet type on an list item tag with a Font Awesome icon but I am getting an empty square: ul { list-style: none; } .testitems { line-height: 2em; } .testitems:before { font-family: "Font Awesome 5 Free"; content: "\f058"; margin: 0 5px 0 -15px; color: #004d00; display: inline-block; } <script src="https://use.fontawesome.com/releases/v5.8.1/js/all.js"></script> <ul> <li class="testitems">List Item 1</li> <li class="testitems">List Item 2</li> <li class="testitems"

Font Awesome 5 shows empty square when using the JS+SVG version

こ雲淡風輕ζ 提交于 2019-12-16 20:26:23
问题 Attempting to replace the bullet type on an list item tag with a Font Awesome icon but I am getting an empty square: ul { list-style: none; } .testitems { line-height: 2em; } .testitems:before { font-family: "Font Awesome 5 Free"; content: "\f058"; margin: 0 5px 0 -15px; color: #004d00; display: inline-block; } <script src="https://use.fontawesome.com/releases/v5.8.1/js/all.js"></script> <ul> <li class="testitems">List Item 1</li> <li class="testitems">List Item 2</li> <li class="testitems"

Font Awesome 5 on pseudo elements shows square instead of icon

淺唱寂寞╮ 提交于 2019-12-16 19:50:21
问题 I am trying to change the content of a span with a Font Awesome icon directly from the CSS page but can't seem to make it work properly. 1) I have imported FA from the documentation and in the <head> <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.0.9/css/all.css" integrity="sha384-5SOiIsAziJl6AWe0HWRKTXlfcSHKmYV4RBF18PPJ173Kzn7jzMyFuTtk8JA7QQG1" crossorigin="anonymous"> 2) My html looks like this : <span class='myClass'>Movies</span> 3) Let's now say I would like to

font-awesome fonts are not loaded into angular project

橙三吉。 提交于 2019-12-14 03:52:25
问题 I've been using angular 5 for a while now and it seems that I can't load any font-awesome icons into my built project. I followed the steps thoroughly as mentioned in the link below. https://www.npmjs.com/package/angular-font-awesome It appears that the CSS file is included in the project but it's not able to load the fonts as I checked in the network section of my browser's developer tools. All I'm seeing in the rendered page is square icons instead of font-awesome icons. I would really

Stacked icons with one css class

南笙酒味 提交于 2019-12-14 03:47:31
问题 In new FontAwesome 4.0.0 there is css styles for stacked items. <span class="fa-stack"> <i class="fa fa-square-o fa-stack-2x"></i> <i class="fa fa-twitter fa-stack-1x"></i> </span> .fa-stack { position: relative; display: inline-block; width: 2em; height: 2em; line-height: 2em; vertical-align: middle; } .fa-stack-1x, .fa-stack-2x { position: absolute; width: 100%; text-align: center; } .fa-stack-1x { line-height: inherit; } .fa-stack-2x { font-size: 2em; } .fa-square-o:before { content: "

How to create checkbox looks like font-awesome glyphicon

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-14 03:32:38
问题 I want to create a font-awesome glyph-icon which act like checkbox, this means that I need to create a checkbox, which need to disguise as font-awesome icon. I don't need to have a label for current checkbox,just font-awesome icon which turn on and off. check state, icon is on color one. uncheck state icon is on color two. check state: uncheck state: How can I do it?! 回答1: You can do achieve this even without Javascript. #checkbox{ background:#2f8cab; display:inline-block; padding:15px 18px;

how to draw fontawesome(version >=5.0) in canvas?

烂漫一生 提交于 2019-12-14 01:00:26
问题 I want to draw fontawesome icons on the canvas. Below is my code: <canvas id="canvas" width="400" height="400" style="border:1px solid #d3d3d3;"></canvas> <script> var content = '\uF006'; var context = document.getElementById('canvas').getContext('2d'); context.font = '48px Material Design Icons'; context.fillText(content, 100, 100); context.strokeText(content, 100, 100); </script> I have imported the font files and linked it. But it doesn't works: it just show a rectangle which is empty. can

Google Translate messes up Font Awesome Icons

早过忘川 提交于 2019-12-13 16:53:23
问题 I use font awesome icons on my website. (http://fortawesome.github.io/Font-Awesome/) I am also thinking of adding the google translate widget to my website as a little tab at the bottom that prompts the user to translate the page if they need to. (https://translate.google.com/manager/website/) However, if I run my site through google translate, all of the font awesome icons gets messed up. I'm thinking that google tries to translate the icons (since it's essentially just a font type). Does

jQuery mobile- How to change the icon of select to a custom icon?

有些话、适合烂在心里 提交于 2019-12-13 16:29:26
问题 I have to change the select icon in <select> to a fa icon. The code I use: <select class="sortBy" name="sortBy" data-url="${url}" data-icon="ui-icon-arrow-sort"> <option value="">Sort By</option> <option value="new" selected="selected">Newest</option> <option value="old">Oldest</option> </select> The CSS is: .ui-icon-arrow-sort{ content: "\f0dd"; display: inline-block; font: normal normal normal 14px/1 FontAwesome; font-size: inherit; text-rendering: auto; -webkit-font-smoothing: antialiased;

Font-Awesome icons showing up as square boxes

a 夏天 提交于 2019-12-13 13:48:54
问题 Why is my code not showing me the icons ? <ul> <li><a href="#" class="facebook" data-toggle="tooltip" data-placement="top" title="Facebook"><i class="fa fa-facebook"></i></a></li> <li><a href="#" class="twitter" data-toggle="tooltip" data-placement="top" title="Twitter"><i class="fa fa-twitter"></i></a></li> </ul> 回答1: Had the same problem, where some of the icons showing up as square boxes. it only happened with a local reference of font awesome to my web app. when i investigate the URL, i