Skip to content

Commit 5184971

Browse files
committed
collapsed category as default
1 parent 68d63ee commit 5184971

2 files changed

Lines changed: 14 additions & 13 deletions

File tree

css/stylesheet.css

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -52,18 +52,6 @@ button.active {
5252
background: rgb(44, 44, 44);
5353
}
5454

55-
button.category {
56-
background: rgba(0, 0, 0, .10);
57-
}
58-
59-
button.indent {
60-
padding-left: 28px;
61-
}
62-
63-
button.fold {
64-
display: none !important;
65-
}
66-
6755
.divider {
6856
position: absolute !important;
6957
z-index: 3;
@@ -127,6 +115,19 @@ button input {
127115
text-align: left;
128116
}
129117

118+
button.category {
119+
background: rgba(0, 0, 0, .10);
120+
}
121+
122+
button.indent {
123+
padding-left: 28px;
124+
display: none;
125+
}
126+
127+
button.collapse {
128+
display: block;
129+
}
130+
130131
.workspace {
131132
position: absolute;
132133
top: 30px;

js/script.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ $.getJSON('./algorithm/category.json', function (data) {
155155
(function (category) {
156156
var $category = $('<button class="category">').append(list[category].name);
157157
$category.click(function () {
158-
$('[data-category="' + category + '"]').toggleClass('fold');
158+
$('[data-category="' + category + '"]').toggleClass('collapse');
159159
});
160160
$('#list').append($category);
161161
var subList = list[category].list;

0 commit comments

Comments
 (0)