Commit 7fb798f5 authored by jcollins-g's avatar jcollins-g Committed by GitHub

Upgrade dartdoc to 0.12.0 (#10296)

* update the docs css style so the generated dartdoc matches the new flutter.io

* Change to 0.12.0 dartdoc

* Review comment
parent 7566f73d
...@@ -8,7 +8,7 @@ set -e ...@@ -8,7 +8,7 @@ set -e
bin/flutter --version bin/flutter --version
# Install dartdoc. # Install dartdoc.
bin/cache/dart-sdk/bin/pub global activate dartdoc 0.11.1 bin/cache/dart-sdk/bin/pub global activate dartdoc 0.12.0
# This script generates a unified doc set, and creates # This script generates a unified doc set, and creates
# a custom index.html, placing everything into dev/docs/doc. # a custom index.html, placing everything into dev/docs/doc.
......
<!-- style overrides for dartdoc --> <!-- style overrides for dartdoc -->
<style> <style>
@import 'https://fonts.googleapis.com/css?family=Roboto:100i'; @import 'https://fonts.googleapis.com/css?family=Roboto:500,400italic,300,400,100i';
</style> </style>
<style> <style>
body { body {
font-size: 15px; font-size: 15px;
font-family: Roboto, sans-serif;
line-height: 1.5; line-height: 1.5;
color: #111; color: #111;
background-color: #fdfdfd; background-color: #fdfdfd;
...@@ -14,7 +15,17 @@ ...@@ -14,7 +15,17 @@
} }
header { header {
background-color: #01579b; background-color: white;
color: #424242;
}
nav.navbar {
min-height: 57px;
padding: 6px 0;
}
header.header-fixed nav.navbar-fixed-top {
box-shadow: 0 1px 4px 0 rgba(0, 0, 0, 0.37);
} }
h1, h2 { h1, h2 {
...@@ -36,7 +47,7 @@ ...@@ -36,7 +47,7 @@
h2 { h2 {
color: #111; color: #111;
font-size: 26px; font-size: 24px;
} }
.markdown h2 { .markdown h2 {
...@@ -44,7 +55,7 @@ ...@@ -44,7 +55,7 @@
} }
section.summary h2 { section.summary h2 {
font-size: 32px; font-size: 24px;
color: inherit; color: inherit;
border-bottom: none; border-bottom: none;
} }
...@@ -54,10 +65,6 @@ ...@@ -54,10 +65,6 @@
font-size: inherit; font-size: inherit;
} }
.sidebar-offcanvas-left {
background-color: #fdfdfd;
}
@media screen and (max-width: 768px) { @media screen and (max-width: 768px) {
.sidebar-offcanvas-left.active { .sidebar-offcanvas-left.active {
padding: 10px; padding: 10px;
...@@ -68,31 +75,23 @@ ...@@ -68,31 +75,23 @@
padding: 0 16px 16px 0; padding: 0 16px 16px 0;
} }
.sidebar h5 {
display: none;
}
.sidebar-offcanvas-left h5 { .sidebar-offcanvas-left h5 {
border-bottom: none; display: none;
padding: 0 0 16px 0;
}
.sidebar-offcanvas-left h5:last-of-type {
padding: 0 0 16px 0;
} }
pre, pre,
pre.prettyprint, pre.prettyprint,
pre > code { pre > code {
font-size: 15px; font-size: 14px;
} }
pre, pre,
pre.prettyprint { pre.prettyprint {
background: inherit; background: #f5f2f0;
border: none;
margin: 0 0 15px 0; margin: 0 0 15px 0;
padding: 8px 12px; padding: 8px 12px;
border: 1px solid #cccccc;
border-radius: 4px;
} }
code { code {
...@@ -103,19 +102,19 @@ ...@@ -103,19 +102,19 @@
padding-right: 0; padding-right: 0;
} }
dl.dl-horizontal dt { #search-box {
color: inherit; color: #555;
} background-color: #fff;
background-image: none;
footer { border: 1px solid #ccc;
border-top: 1px solid #e8e8e8; border-radius: 2px;
height: inherit; font-family: inherit;
padding-bottom: 15px; padding: 4px 6px;
text-transform: lowercase; font-size: 15px;
} }
footer p { dl.dl-horizontal dt {
color: #828282; color: inherit;
} }
/* Line the material icons up with their labels */ /* Line the material icons up with their labels */
......
...@@ -84,7 +84,7 @@ dependencies: ...@@ -84,7 +84,7 @@ dependencies:
'global', 'run', 'dartdoc', 'global', 'run', 'dartdoc',
'--header', 'styles.html', '--header', 'styles.html',
'--header', 'analytics.html', '--header', 'analytics.html',
'--footer', 'lib/footer.html', '--footer-text', 'lib/footer.html',
'--exclude', 'temp_doc', '--exclude', 'temp_doc',
'--favicon=favicon.ico', '--favicon=favicon.ico',
'--use-categories', '--use-categories',
...@@ -120,8 +120,8 @@ void createFooter(String footerPath) { ...@@ -120,8 +120,8 @@ void createFooter(String footerPath) {
final String timestamp = new DateFormat('yyyy-MM-dd HH:mm').format(new DateTime.now()); final String timestamp = new DateFormat('yyyy-MM-dd HH:mm').format(new DateTime.now());
new File(footerPath).writeAsStringSync( new File(footerPath).writeAsStringSync(
'<p class="text-center" style="font-size: 10px">' '• </span class="no-break">$timestamp<span> '
'Generated on $timestamp - Version $gitHead</p>' '• </span class="no-break">$gitHead</span>'
); );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment