Skip to content

Commit 6ef1537

Browse files
ellessuomjdalton
authored andcommitted
Added collapsible-behaviour to docs title (#184)
Adds a css class to every doc title when rendering it
1 parent ba7f514 commit 6ef1537

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

assets/css/_docs.scss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,5 +279,10 @@ html.docs {
279279
.subtle-punctuation {
280280
opacity: 0.4;
281281
}
282+
283+
.collapsible-title {
284+
cursor: pointer;
285+
user-select: none;
286+
}
282287
}
283288
}

assets/js/docs.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,11 @@
268268
},
269269
React.createElement(
270270
'h2',
271-
null,
271+
{
272+
'className': 'collapsible-title',
273+
'onClick': expanderClick,
274+
'onKeyPress': expanderClick
275+
},
272276
React.createElement(
273277
'i',
274278
{

0 commit comments

Comments
 (0)