From aac0927e25220bacaad4209928ceac8bd0fc7f8e Mon Sep 17 00:00:00 2001 From: John Knox Date: Wed, 11 Sep 2019 07:20:17 -0700 Subject: [PATCH] Fix outline icon variant Summary: Icon names including the -outline suffix get stripped out so the local path becomes the filled variant by default. But it's only observable in release builds, because they are the only ones that use local icons. This should fix that by keeping the variant in the local icon path as well. Reviewed By: danielbuechele Differential Revision: D17314646 fbshipit-source-id: b8402d85b1cc690caef7870194e60f22d17dca05 --- src/utils/icons.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/utils/icons.js b/src/utils/icons.js index e35054bad..e102d9850 100644 --- a/src/utils/icons.js +++ b/src/utils/icons.js @@ -79,7 +79,10 @@ module.exports = { variant = 'outline'; } - const localPath = path.join('icons', `${name}-${size}@${density}x.png`); + const localPath = path.join( + 'icons', + `${name}-${variant}-${size}@${density}x.png`, + ); // resolve icon locally if possible if ( remote &&