Skip to content

Commit

Permalink
added folder icons
Browse files Browse the repository at this point in the history
  • Loading branch information
Roman committed Jun 29, 2016
1 parent 4d51c85 commit 0c8b6a6
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 7 deletions.
20 changes: 13 additions & 7 deletions lib/main.ts
Expand Up @@ -72,15 +72,21 @@ const createIcon = (data: Icon, secondary: boolean) => {
};

const provider = (entry) => {
var data;
if (!entry.isFile) {
return;
data = [{
color: "#666",
icon: "ion-android-folder",
size: 15
}];
}

const data = findInDictionary(icons, entry.name, icons.secondary, (a, b) => {
if (a === b) return true;
if (a === undefined || b === undefined) return false;
return a.color === b.color && a.icon === b.icon && a.size === b.size;
});
else {
data = findInDictionary(icons, entry.name, icons.secondary, (a, b) => {
if (a === b) return true;
if (a === undefined || b === undefined) return false;
return a.color === b.color && a.icon === b.icon && a.size === b.size;
});
}

const $icon = $('<ins>');
$icon.addClass('file-icon-box')
Expand Down
5 changes: 5 additions & 0 deletions styles/style.css
Expand Up @@ -45,3 +45,8 @@ ins.file-icon-box {
transform: rotate(90deg);
-webkit-transform: rotate(90deg);
}

.jstree-open>a,
.jstree-closed>a {
margin-left: 13px;
}

0 comments on commit 0c8b6a6

Please sign in to comment.