From d56a44ac797a358fe0ad5885f28fec1098d4344d Mon Sep 17 00:00:00 2001 From: krzychb Date: Mon, 9 Apr 2018 05:46:57 +0200 Subject: [PATCH 1/2] Fixed issues with tables --- docs/en/api-guides/wifi.rst | 4 +--- docs/en/get-started/get-started-wrover-kit.rst | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/docs/en/api-guides/wifi.rst b/docs/en/api-guides/wifi.rst index b18fd4ae4..6b8fe9086 100755 --- a/docs/en/api-guides/wifi.rst +++ b/docs/en/api-guides/wifi.rst @@ -772,9 +772,7 @@ Wi-Fi Reason Code The table below shows the reason-code defined in ESP32. The first column is the macro name defined in esp_wifi_types.h. The common prefix *WIFI_REASON* is removed, which means that *UNSPECIFIED* actually stands for *WIFI_REASON_UNSPECIFIED* and so on. The second column is the value of the reason. The third column is the standard value to which this reason is mapped in section 8.4.1.7 of ieee802.11-2012. (For more information, refer to the standard mentioned above.) The last column is a description of the reason. +---------------------------+-------+---------+-------------------------------------------------------------+ -| Reason code | ESP32 |Mapped To| Description | -| | value |Standard | | -| | |Value | | +| Reason code | Value |Mapped To| Description | +===========================+=======+=========+=============================================================+ | UNSPECIFIED | 1 | 1 | Generally, it means an internal failure, e.g., the memory | | | | | runs out, the internal TX fails, or the reason is received | diff --git a/docs/en/get-started/get-started-wrover-kit.rst b/docs/en/get-started/get-started-wrover-kit.rst index 07de495bf..115ba3a5a 100644 --- a/docs/en/get-started/get-started-wrover-kit.rst +++ b/docs/en/get-started/get-started-wrover-kit.rst @@ -118,7 +118,7 @@ There are five jumper headers available to set up the board functionality. Typic | Header | Jumper Setting | Description of Functionality | +--------+------------------+--------------------------------------------------+ | JP7 | |jp7-ext_5v| | Power ESP-WROVER-KIT board from an external | -| | | | power supply | +| | | power supply | +--------+------------------+--------------------------------------------------+ | JP7 | |jp7-usb_5v| | Power ESP-WROVER-KIT board from an USB port | +--------+------------------+--------------------------------------------------+ From 43fb8033ec809164b90f152801e1d4b850c4883f Mon Sep 17 00:00:00 2001 From: krzychb Date: Mon, 9 Apr 2018 05:47:36 +0200 Subject: [PATCH 2/2] ReadTheDocs theme has an annoying bug of text not being wrapped inside table cells. Each row is extended to fit the text as a single line. For a table with multiple columns and long sentences the table may get wide, with long scrollbar underneath and is not convenient to read. This MR makes the text wrap inside table cells. There is an open PR to fix this issue - https://github.com/rtfd/sphinx_rtd_theme/pull/432. --- docs/_static/theme_overrides.css | 13 +++++++++++++ docs/conf_common.py | 7 ++++++- 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 docs/_static/theme_overrides.css diff --git a/docs/_static/theme_overrides.css b/docs/_static/theme_overrides.css new file mode 100644 index 000000000..63ee6cc74 --- /dev/null +++ b/docs/_static/theme_overrides.css @@ -0,0 +1,13 @@ +/* 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; + } +} diff --git a/docs/conf_common.py b/docs/conf_common.py index 1654a1ea8..e5dd9df6e 100644 --- a/docs/conf_common.py +++ b/docs/conf_common.py @@ -185,7 +185,7 @@ html_theme = 'default' # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". -#html_static_path = ['_static'] +html_static_path = ['../_static'] # Add any extra paths that contain custom files (such as robots.txt or # .htaccess) here, relative to this directory. These files are copied @@ -327,3 +327,8 @@ if not on_rtd: # only import and set the theme if we're building docs locally html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] # otherwise, readthedocs.org uses their theme by default, so no need to specify it + +# Override RTD CSS theme to introduce the theme corrections +# https://github.com/rtfd/sphinx_rtd_theme/pull/432 +def setup(app): + app.add_stylesheet('theme_overrides.css')