Skip to content

Commit

Permalink
minor doxygen tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
marzer committed Apr 5, 2020
1 parent 16911e5 commit 3f04e12
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 5 deletions.
31 changes: 28 additions & 3 deletions docs/tomlplusplus.css
Original file line number Diff line number Diff line change
Expand Up @@ -192,13 +192,37 @@ pre.m-code + pre.m-console span
/* github badges (index.html) */
.gh-badges
{
padding-bottom: 0.75rem;
padding-bottom: 0.25rem;
margin-left: -0.9rem;
margin-right: -0.9rem;
margin-top: -0.5rem;
}
.gh-badges a

@media screen and (min-width: 992px)
{
.gh-badges
{
display: flex;
justify-content: space-between;
}
.gh-badges br
{
display: none;
}
}
@media screen and (max-width: 991px)
{
margin-right: 0.3rem;
.gh-badges
{
text-align: center;
line-height: 1.75rem;
}
.gh-badges a
{
margin-left: 0.2rem;
margin-right: 0.2rem;
margin-bottom: 0.4rem;
}
}

/* page category subheading ("module" etc) */
Expand All @@ -215,5 +239,6 @@ main > article > .m-container.m-container-inflatable > .m-row > div.m-col-l-10.m
border-width: 0.1rem;
margin-left: -1rem;
margin-right: -1rem;
margin-top: -1.75rem;
max-width: calc(100% + 2rem);
}
8 changes: 6 additions & 2 deletions python/generate_documentation.py
Original file line number Diff line number Diff line change
Expand Up @@ -477,6 +477,7 @@ class IndexPageFix(object):
'badge-TOML.svg',
'https://github.com/toml-lang/toml/blob/master/README.md'
),
(None, None, None), # <br>
(
'MIT License',
'badge-license-MIT.svg',
Expand All @@ -503,8 +504,11 @@ def __call__(self, file, doc):
parent('h1')[0].replace_with(banner)
parent = doc.new_tag('div', class_='gh-badges', after=banner)
for (alt, src, href) in self.__badges:
anchor = doc.new_tag('a', parent=parent, href=href, target='_blank')
doc.new_tag('img', parent=anchor, src=src, alt=alt)
if alt is None and src is None and href is None:
doc.new_tag('br', parent=parent)
else:
anchor = doc.new_tag('a', parent=parent, href=href, target='_blank')
doc.new_tag('img', parent=anchor, src=src, alt=alt)
return True


Expand Down

0 comments on commit 3f04e12

Please sign in to comment.