Skip to content

Commit 7940860

Browse files
rueckstiesskangas
authored andcommitted
expandable again
still need padding fixes numbered array items
1 parent 2d5a86c commit 7940860

File tree

2 files changed

+15
-11
lines changed

2 files changed

+15
-11
lines changed

src/document-list/document-list-item.jade

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,14 @@ mixin jsarray(items)
1818
mixin jsproperty(key, value)
1919
- _type = getType(value)
2020
li(class='document-property #{_type.toLowerCase()}')
21-
.document-property-header
22-
if _type === 'Array' || _type === 'Object'
21+
if _type === 'Array' || _type === 'Object'
22+
.document-property-header
2323
.caret
24+
if key
25+
.document-property-key= key
26+
|:
27+
+jsvalue(value, _type)
28+
else
2429
if key
2530
.document-property-key= key
2631
|:

src/document-list/index.less

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,10 @@ ol.document-list {
1616
margin-bottom: 10px;
1717
border-bottom: 1px solid @gray7;
1818

19+
// unstyled for top-level object
1920
> ol.document-property-body {
2021
.list-unstyled;
2122
}
22-
ol.document-property-body > li.document-property-object > ol.document-property-body {
23-
.list-unstyled;
24-
}
2523

2624
ol.document-property-body {
2725
display: block;
@@ -70,23 +68,24 @@ ol.document-list {
7068
display: inline-block;
7169
}
7270
}
73-
ol.document-property.body {
71+
72+
ol.document-property-body {
7473
margin-left: 5px;
7574
padding-left: -5px;
7675
border-left: 1px dotted @gray5;
7776
display: none;
7877
}
79-
ol.document-property.body > a ~ ol {
80-
padding-left: 12px;
81-
display: none;
82-
}
78+
// ol.document-property-body > a ~ ol {
79+
// padding-left: 12px;
80+
// display: none;
81+
// }
8382
&.expanded {
8483
> .document-property-header {
8584
> .caret {
8685
.caret-down;
8786
}
8887
}
89-
> ol.document-property.body {
88+
> ol.document-property-body {
9089
display: block;
9190
}
9291
}

0 commit comments

Comments
 (0)