From a0f2a91675cb2d53965eb2f7e178826737d4eca7 Mon Sep 17 00:00:00 2001 From: Igor Guastalla Date: Sun, 9 Dec 2018 18:46:29 -0200 Subject: [PATCH] feat(icons): add charmander icon (#129) * feat(icons): add charmander icon * docs(icons): add charmander to storybook --- docs/icons.stories.js | 1 + index.html | 3 ++- scss/pixel-arts/_index.scss | 1 + scss/pixel-arts/charmander.scss | 42 +++++++++++++++++++++++++++++++++ 4 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 scss/pixel-arts/charmander.scss diff --git a/docs/icons.stories.js b/docs/icons.stories.js index 9642ba8..72b4b2d 100644 --- a/docs/icons.stories.js +++ b/docs/icons.stories.js @@ -16,6 +16,7 @@ stories.add('icon', () => { 'icon whatsapp': 'icon whatsapp', 'icon close': 'icon close', pokeball: 'pokeball', + charmander: 'charmander', squirtle: 'squirtle', smartphone: 'smartphone', phone: 'phone', diff --git a/index.html b/index.html index 3531089..f71eb5c 100644 --- a/index.html +++ b/index.html @@ -240,7 +240,6 @@ - @@ -269,6 +268,8 @@ + + diff --git a/scss/pixel-arts/_index.scss b/scss/pixel-arts/_index.scss index 72ec369..350011f 100644 --- a/scss/pixel-arts/_index.scss +++ b/scss/pixel-arts/_index.scss @@ -9,6 +9,7 @@ @import "octocat.scss"; @import "mario.scss"; @import "pokeball.scss"; +@import "charmander.scss"; @import "squirtle.scss"; @import "phone.scss"; @import "smartphone.scss"; \ No newline at end of file diff --git a/scss/pixel-arts/charmander.scss b/scss/pixel-arts/charmander.scss new file mode 100644 index 0000000..9adf23b --- /dev/null +++ b/scss/pixel-arts/charmander.scss @@ -0,0 +1,42 @@ +.charmander { + $px: 6px; + // prettier-ignore + $charmander-colors: (#000202, #f77702, #eb2010, + #fdfcff, #e5d70a, #e7d70e); + // prettier-ignore + $charmander: ( + (0,0,0,0,1,1,1,1,0,0,0,0,0,0,0,0,0,1), + (0,0,0,1,2,2,2,2,1,0,0,0,0,0,0,0,1,3,1), + (0,0,1,2,2,2,2,2,2,1,0,0,0,0,0,0,1,3,3,1), + (0,0,1,2,2,2,2,2,2,1,0,0,0,0,0,0,1,3,3,1), + (0,1,2,2,2,2,2,2,2,2,1,0,0,0,0,1,3,3,2,3,1), + (1,2,2,2,2,4,1,2,2,2,1,0,0,0,0,1,3,2,6,3,1), + (1,2,2,2,2,1,1,2,2,2,2,1,0,0,0,1,3,5,5,3,1), + (1,2,2,2,2,1,1,2,2,2,2,1,0,0,0,0,1,5,1,1), + (0,1,2,2,2,2,2,2,2,2,2,2,1,0,0,0,1,2,1), + (0,0,1,1,2,2,2,2,2,2,2,2,2,1,0,1,2,2,1), + (0,0,0,0,1,1,1,2,2,1,2,2,2,1,1,2,2,1), + (0,0,0,0,0,1,6,5,1,2,2,2,2,2,1,2,2,1), + (0,0,0,0,0,1,5,5,5,1,1,2,2,2,1,2,1), + (0,0,0,0,1,4,1,6,5,5,2,2,2,2,1,1), + (0,0,0,0,0,1,1,1,5,5,2,2,2,1,1), + (0,0,0,0,0,0,0,0,1,1,1,0,1,1), + (0,0,0,0,0,0,0,0,0,1,4,0,4,1), + (0,0,0,0,0,0,0,0,0,0,1,1,1,0) + ); + + position: relative; + display: inline-block; + width: $px * 16; + height: $px * 16; + + &::before { + position: absolute; + top: $px * -1; + left: $px * -1; + content: ""; + background: transparent; + + @include pixelize($charmander, $charmander-colors, $px); + } +}