Skip to content

Commit

Permalink
Added categories icons
Browse files Browse the repository at this point in the history
  • Loading branch information
unimonkiez committed Apr 20, 2016
1 parent 8ee5e52 commit ebee201
Show file tree
Hide file tree
Showing 24 changed files with 145 additions and 14 deletions.
2 changes: 1 addition & 1 deletion example/example.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
import EmojiPanel from 'emoji-panel';

new EmojiPanel(document.getElementById('panel-example-1'), { imageSet: EmojiPanel.IMAGE_SET.GOOGLE });
new EmojiPanel(document.getElementById('panel-example-1'));
4 changes: 4 additions & 0 deletions example/example.scss
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
@import '~emoji-panel.css';

#panel-example-1 {
height: 600px;
}
48 changes: 48 additions & 0 deletions src/categories-icons/apple.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
@font-face {
font-family: 'apple-category';
src: url('../src/categories-icons/apple.ttf') format('truetype');
font-weight: normal;
font-style: normal;
}

.cat {
font-family: 'apple-category' !important;
speak: none;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
line-height: 1;

/* Better Font Rendering =========== */
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}

.cat-0:before {
content: "\e900";
}
.cat-1:before {
content: "\e901";
}
.cat-2:before {
content: "\e902";
}
.cat-4:before {
content: "\e903";
}
.cat-8:before {
content: "\e904";
}
.cat-16:before {
content: "\e905";
}
.cat-128:before {
content: "\e906";
}
.cat-64:before {
content: "\e907";
}
.cat-32:before {
content: "\e908";
}
Binary file added src/categories-icons/apple.eot
Binary file not shown.
19 changes: 19 additions & 0 deletions src/categories-icons/apple.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/categories-icons/apple.ttf
Binary file not shown.
Binary file added src/categories-icons/apple.woff
Binary file not shown.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/activity.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/flags.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/food.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/input.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/nature.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/objects.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/people.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/recent.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/symbols.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/categories-icons/apple/travel.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions src/create-panel.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import getPanelTemplate from './get-panel-template';
import setEventsForTemplate from './set-events-for-template';

export default ({ imageSet, size } = {}) => {
export default ({ imageSet, size, animationDuration } = {}) => {
const panelEl = document.createElement('div');
panelEl.setAttribute('class', 'ep-container');
const panelTemplate = getPanelTemplate({ imageSet, size });
panelEl.innerHTML = panelTemplate;
setEventsForTemplate(panelEl);
setEventsForTemplate(panelEl, { animationDuration });

return panelEl;
};
Loading

0 comments on commit ebee201

Please sign in to comment.