mirror of
https://github.com/FortAwesome/Font-Awesome.git
synced 2025-01-13 00:30:29 +08:00
Add note about pseudoelements not working
parent
48c27a7340
commit
3bb47b8534
@ -23,13 +23,15 @@ In the following examples, I'm going to use add to Font Awesome 5 the `fa-list`
|
||||
|
||||
#### With local/CDN `fontawesome/all.js`
|
||||
|
||||
⚠️ Pseudoelements will not work with this method!
|
||||
|
||||
JavaScript:
|
||||
```js
|
||||
// replace 1568, 1568 with your SVG viewbox
|
||||
// e001 is the unicode point which represents this custom icon. Increment this value for other icons
|
||||
// replace 'M256...' with your single-path SVG
|
||||
var faListOldStyle = {
|
||||
prefix: 'fas',
|
||||
prefix: 'fac',
|
||||
iconName: 'list-old-style',
|
||||
icon: [1568, 1568, [], 'e001', 'M256 1312v192q0 13-9.5 22.5t-22.5 9.5h-192q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h192q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-192q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h192q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-192q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h192q13 0 22.5 9.5t9.5 22.5zm1536 768v192q0 13-9.5 22.5t-22.5 9.5h-1344q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1344q13 0 22.5 9.5t9.5 22.5zm-1536-1152v192q0 13-9.5 22.5t-22.5 9.5h-192q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h192q13 0 22.5 9.5t9.5 22.5zm1536 768v192q0 13-9.5 22.5t-22.5 9.5h-1344q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1344q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1344q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1344q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1344q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1344q13 0 22.5 9.5t9.5 22.5z']
|
||||
}
|
||||
@ -41,7 +43,7 @@ FontAwesome.library.add(
|
||||
|
||||
HTML:
|
||||
```html
|
||||
<span class="fas fa-list-old-style"></span>
|
||||
<span class="fac fa-list-old-style"></span>
|
||||
```
|
||||
|
||||
Example: https://jsfiddle.net/tagliala/we7gtcvk/1/
|
||||
|
Loading…
Reference in New Issue
Block a user