Skip to content

Commit

Permalink
Release 0.1.15
Browse files Browse the repository at this point in the history
  • Loading branch information
robmadole committed Aug 3, 2021
1 parent 01138dc commit c1122fb
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 6 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,14 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p

---

## [0.1.15](https://github.com/FortAwesome/react-fontawesome/releases/tag/0.1.15) - 2021-08-03

### Fixed

- Skip parse.icon if the icon is imported directly from an icon package

---

## [0.1.14](https://github.com/FortAwesome/react-fontawesome/releases/tag/0.1.14) - 2020-12-22

### Added
Expand Down
3 changes: 2 additions & 1 deletion DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ The following commands are available through `npm run`
1. Add new contributors to the `contributors` section
1. Update the `CHANGELOG.md`
1. Update the `README.md` contributors section
1. `npm run build` and `npm test`
1. `npm run build`
1. `FONTAWESOME_NPM_AUTH_TOKEN=TOKEN npm run test` where `TOKEN` is a valid Pro registry token
1. `npm publish`
1. `npm publish --registry https://npm.fontawesome.com` (publish to Pro registry)
1. `git add . && git commit -m 'Release VERSION'`
Expand Down
8 changes: 7 additions & 1 deletion index.es.js
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,12 @@ function log () {
}

function normalizeIconArgs(icon) {
// this has everything that it needs to be rendered which means it was probably imported
// directly from an icon svg package
if (icon && _typeof(icon) === 'object' && icon.prefix && icon.iconName && icon.icon) {
return icon;
}

if (parse.icon) {
return parse.icon(icon);
} // if the icon is null, there's nothing to do
Expand All @@ -270,7 +276,7 @@ function normalizeIconArgs(icon) {
} // if the icon is an object and has a prefix and an icon name, return it


if (_typeof(icon) === 'object' && icon.prefix && icon.iconName) {
if (icon && _typeof(icon) === 'object' && icon.prefix && icon.iconName) {
return icon;
} // if it's an array with length of two

Expand Down
8 changes: 7 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,12 @@
}

function normalizeIconArgs(icon) {
// this has everything that it needs to be rendered which means it was probably imported
// directly from an icon svg package
if (icon && _typeof(icon) === 'object' && icon.prefix && icon.iconName && icon.icon) {
return icon;
}

if (fontawesomeSvgCore.parse.icon) {
return fontawesomeSvgCore.parse.icon(icon);
} // if the icon is null, there's nothing to do
Expand All @@ -275,7 +281,7 @@
} // if the icon is an object and has a prefix and an icon name, return it


if (_typeof(icon) === 'object' && icon.prefix && icon.iconName) {
if (icon && _typeof(icon) === 'object' && icon.prefix && icon.iconName) {
return icon;
} // if it's an array with length of two

Expand Down
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@fortawesome/react-fontawesome",
"description": "Official React component for Font Awesome 5",
"version": "0.1.14",
"version": "0.1.15",
"main": "index.js",
"module": "index.es.js",
"jsnext:main": "index.es.js",
Expand Down Expand Up @@ -35,9 +35,8 @@
"prettier": "pretty-quick --pattern src/** --staged",
"precommit": "npm run lint && npm run prettier && lint-staged",
"prepack": "npm run dist",
"test": "npm run test.latest && npm run test.next",
"test": "npm run test.latest && npm run test.next.proregistry",
"test.latest": "npm --no-save install @fortawesome/fontawesome-svg-core@latest @fortawesome/free-solid-svg-icons@latest && jest --silent",
"test.next": "npm --no-save install @fortawesome/fontawesome-svg-core@next @fortawesome/free-solid-svg-icons@next && jest --silent",
"test.next.proregistry": "npm --userconfig .npmrc.proregistry --registry https://npm.fontawesome.com install --no-save @fortawesome/fontawesome-svg-core@next @fortawesome/free-solid-svg-icons@next && jest --silent",
"clean": "rm -f index.js && rm -f index.es.js"
},
Expand Down

0 comments on commit c1122fb

Please sign in to comment.