Skip to content

Commit b705f0c

Browse files
committed
Improve sidebar.
- Add icons - Prevent scrollbar from being shown
1 parent 57c62b7 commit b705f0c

File tree

4 files changed

+30
-29
lines changed

4 files changed

+30
-29
lines changed

app/components/graph/graph.html

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3,53 +3,53 @@
33
<div class="row">
44

55
<!-- Graph view -->
6-
76
<div class="col-sm-9 col-md-10 main">
87
<div id="graph" node-link-graph margin="10" on-click="onClick(item)">
98
</div>
109
</div>
1110

1211
<!-- Sidebar for details -->
13-
1412
<div class="col-sm-3 col-md-2 sidebar">
15-
<uib-accordion close-others="false">
16-
13+
<uib-accordion>
1714
<uib-accordion-group is-open="showSelection">
18-
1915
<uib-accordion-heading>
2016
<span class="glyphicon glyphicon-screenshot" aria-hidden="true"></span> Selection
2117
</uib-accordion-heading>
22-
2318
<selection-group></selection-group>
24-
2519
</uib-accordion-group>
20+
</uib-accordion>
2621

22+
<uib-accordion>
2723
<uib-accordion-group is-open="false">
28-
2924
<uib-accordion-heading>
3025
<span class="glyphicon glyphicon-filter" aria-hidden="true"></span> Filters
3126
</uib-accordion-heading>
32-
3327
<filter-group></filter-group>
34-
3528
</uib-accordion-group>
3629

37-
<uib-accordion-group heading="Graph">
30+
<uib-accordion-group>
31+
<uib-accordion-heading>
32+
<span class="glyphicon glyphicon-cog" aria-hidden="true"></span> Graph
33+
</uib-accordion-heading>
3834
<graph-settings-group></graph-settings-group>
3935
</uib-accordion-group>
4036

41-
<uib-accordion-group heading="Namespaces">
37+
<uib-accordion-group>
38+
<uib-accordion-heading>
39+
<span class="glyphicon glyphicon-list" aria-hidden="true"></span> Namespaces
40+
</uib-accordion-heading>
4241
<namespace-group></namespace-group>
43-
</uib-accordion-group><!-- end of namespace prefix group -->
42+
</uib-accordion-group>
43+
</uib-accordion>
4444

45-
<uib-accordion-group heading="Endpoint" is-open="true">
45+
<uib-accordion>
46+
<uib-accordion-group is-open="true">
47+
<uib-accordion-heading>
48+
<span class="glyphicon glyphicon-transfer" aria-hidden="true"></span> Endpoint
49+
</uib-accordion-heading>
4650
<endpoint-group></endpoint-group>
4751
</uib-accordion-group>
48-
4952
</uib-accordion>
50-
51-
<p class="footer">&copy; 2015 by Marc Weise</p>
52-
5353
</div><!--end of sidebar -->
5454
</div><!-- end of .row -->
5555
</div><!-- end of .container-fluid -->

app/components/sidebar/graph-settings-group.html

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,13 @@
1010
</label>
1111
</div>
1212

13-
<p><strong>Distances</strong></p>
14-
1513
<p>
16-
<label for="ctEdgeLength">Class to Class: {{ ccEdgeLength }}</label>
14+
<label for="ctEdgeLength">Class - Class Distance: {{ ccEdgeLength }}</label>
1715
<div id="ccEdgeLength" slider class="cdbl-slider" model="ccEdgeLength" min="10" max="100"></div>
1816
</p>
1917

2018
<p>
21-
<label for="ctEdgeLength">Class to Type: {{ ctEdgeLength }}</label>
19+
<label for="ctEdgeLength">Class - Type Distance: {{ ctEdgeLength }}</label>
2220
<div id="ctEdgeLength" slider class="cdbl-slider" model="ctEdgeLength" min="10" max="100"></div>
2321
</p>
2422

app/services/model/properties.srv.js

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -169,20 +169,19 @@ module.exports = function ($interval, $log) {
169169
var nodesToRemove = [];
170170

171171
while (i < self.properties.length) {
172-
var currentProp = self.properties[i];
173-
if (currentProp.source === classId && currentProp.type === "disjointProperty") {
174-
nodesToRemove.push(currentProp.target);
172+
var adjacentProp = self.properties[i];
173+
if (adjacentProp.source === classId && adjacentProp.type === "disjointProperty") {
174+
nodesToRemove.push(adjacentProp.target);
175175
self.properties.splice(i, 1);
176176
} else {
177177
i++;
178178
}
179179
}
180180

181181
i = 0;
182-
183182
while (i < self.properties.length) {
184-
var currentProp = self.properties[i];
185-
if (currentProp.type === "disjointProperty" && nodesToRemove.indexOf(currentProp.target) !== -1) {
183+
var otherProp = self.properties[i];
184+
if (otherProp.type === "disjointProperty" && nodesToRemove.indexOf(otherProp.target) !== -1) {
186185
self.properties.splice(i, 1);
187186
} else {
188187
i++;

app/styles/main.css

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,14 @@ ul.properties {
3232
}
3333

3434
div.prop-list {
35-
max-height: 300px;
35+
max-height: 200px;
3636
overflow-y: auto;
3737
}
3838

39+
div.panel-group {
40+
margin-bottom: 5px;
41+
}
42+
3943
.browsehappy {
4044
margin: 0.2em 0;
4145
background: #ccc;

0 commit comments

Comments
 (0)