Skip to content

Commit

Permalink
feat(icons): add psone controller icon
Browse files Browse the repository at this point in the history
  • Loading branch information
guastallaigor committed Jan 20, 2019
1 parent 1f062e2 commit d905c1b
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/icons.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ stories.add('icon', () => {
'nes-jp-logo': 'nes-jp-logo',
'snes-logo': 'snes-logo',
'snes-jp-logo': 'snes-jp-logo',
'nes-psone': 'nes-psone',
}, 'nes-icon twitter');
const selectedSize = radios('size', {
default: '',
Expand Down
1 change: 1 addition & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -440,6 +440,7 @@ <h3 class="title">Controllers</h3>
<i class="nes-jp-logo"></i>
<i class="snes-logo"></i>
<i class="snes-jp-logo"></i>
<i class="nes-psone"></i>
</div>
</section>
</section>
Expand Down
1 change: 1 addition & 0 deletions scss/pixel-arts/_index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@
@import "smartphone.scss";
@import "mario.scss";
@import "kirby.scss";
@import "psone.scss";
@import "octocat.scss";
33 changes: 33 additions & 0 deletions scss/pixel-arts/psone.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
.nes-psone {
$psone-colors: (#cbcbcb, #b1b1b2, #2a2a2a);

// prettier-ignore
$psone: (
(0,0,0,0,0,0,0,3,0,0,0,0,0,0,0,0),
(0,0,1,1,1,0,0,3,0,0,0,1,1,1,0,0),
(0,1,1,1,1,1,0,0,3,0,1,1,1,1,1,0),
(1,1,1,3,1,1,1,1,1,1,1,1,3,1,1,1),
(1,1,3,1,3,1,1,1,1,1,1,3,1,3,1,1),
(1,1,1,3,1,1,1,1,1,1,1,1,3,1,1,1),
(2,1,1,1,1,1,3,1,1,3,1,1,1,1,1,2),
(2,2,1,1,1,0,0,0,0,0,0,1,1,1,2,2),
(2,2,2,2,0,0,0,0,0,0,0,0,2,2,2,2),
(0,2,2,0,0,0,0,0,0,0,0,0,0,2,2,0)
);

position: relative;
display: inline-block;
width: calc(1em * 16);
height: calc(1em * 11);
font-size: 3px;

&::before {
position: absolute;
top: -1em;
left: -1em;
content: "";
background: transparent;

@include pixelize($psone, $psone-colors);
}
}

0 comments on commit d905c1b

Please sign in to comment.