Skip to content

Commit

Permalink
Fix documentation width
Browse files Browse the repository at this point in the history
  • Loading branch information
Vincent Royer committed Mar 27, 2018
1 parent d84f35d commit 577ea69
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 2 deletions.
31 changes: 31 additions & 0 deletions docs/elassandra/source/_static/theme_overrides.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
/* override table width restrictions */
@media screen and (min-width: 767px) {

.wy-table-responsive table td {
/* !important prevents the common CSS stylesheets from overriding
this as on RTD they are loaded after this stylesheet */
white-space: normal !important;
}

.wy-table-responsive {
overflow: visible !important;
}

.wy-nav-content {
max-width: 1200px !important;
}
}

/* workaround for parsed-literal, see https://github.com/sphinx-doc/sphinx/issues/3306 */
.codeblock, pre.literal-block, .rst-content .literal-block, .rst-content pre.literal-block, div[class^='highlight'] {
font-size: 12px;
line-height: 1.5;
display: block;
overflow: auto;
color: #404040;
padding: 12px 12px;
}

.codeblock,div[class^='highlight'] {
padding: 0;
}
11 changes: 9 additions & 2 deletions docs/elassandra/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@

# General information about the project.
project = u'Elassandra'
copyright = u'2016-2017, Strapdata'
copyright = u'2016-2018, Strapdata'
author = u'Strapdata'

# The version info for the project you're documenting, acts as replacement for
Expand All @@ -67,7 +67,7 @@
# The short X.Y version.
version = u'5.5.0'
# The full version, including alpha/beta/rc tags.
release = u'5.5.0.4'
release = u'5.5.0.14'

tgz_url = "https://github.com/strapdata/elassandra/releases/download/v{0}/elassandra-{0}.tar.gz".format(release)
deb_url = "https://github.com/strapdata/elassandra/releases/download/v{0}/elassandra-{0}.deb".format(release)
Expand Down Expand Up @@ -175,6 +175,13 @@
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']

# tricks from https://rackerlabs.github.io/docs-rackspace/tools/rtd-tables.html
html_context = {
'css_files': [
'_static/theme_overrides.css', # override wide tables in RTD theme
],
}

# Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied
# directly to the root of the documentation.
Expand Down

0 comments on commit 577ea69

Please sign in to comment.