Commit Graph
1251 Commits
Author SHA1 Message Date
Anthony Johnson e6bd3f0fc5 Don't use extension to add sphinx_version_info tuple to build context 2021-07-14 19:39:16 -06:00
Anthony Johnson ee32a53ae2 Add a CI test for unbuilt assets
Many of our PRs have out of date assets, making it hard to test the
latest changes. This will at least throw an error on the PR when build
assets aren't updated.
2021-07-14 18:24:14 -06:00
Anthony Johnson c1aa1b2c6b Rebuild assets 2021-07-14 18:23:36 -06:00
Aaron Carlisle 796e78bdf7 Make font usage conistent with sphinx<4.0
This fixes the different spacing issues that were noted.
2021-07-14 16:48:17 -04:00
Anthony Johnson 6597b25257 Fix styles on code block line numbers on Sphinx 4+ 2021-07-14 00:18:33 -06:00
Anthony Johnson 6f9501293b Fix tests, missing theme extension 2021-07-13 22:45:43 -06:00
Aaron Carlisle 037890d1d1 Merge branch 'Blendify/sphinx4' of github.com:readthedocs/sphinx_rtd_theme into Blendify/sphinx4 2021-07-13 21:04:18 -04:00
Aaron Carlisle da20decbbb Compare sphinx version using a tuple 2021-07-13 21:04:16 -04:00
Aaron Carlisle d93528ef3e Tests: Add missing sphinx version 2021-07-13 19:47:25 -04:00
Aaron Carlisle e1716574e9 Merge branch 'master' into Blendify/sphinx4 2021-07-13 19:44:47 -04:00
Aaron Carlisle 2ab605a455 Tests: Fix deprecation warning with new sphinx versions (#1105)
* Tests: Fix deprecation warning with new sphinx versions

These builders where split in sphinx and the old import path will be removed in the upcoming Sphinx 4 release.

This patch requires sphinx 2 so this will be committed into the v2 release.

* Fix imports

* Use try/except for backwards compatibility
2021-07-13 05:16:47 -04:00
Aaron Carlisle 0ef60e7841 Tests: run against sphinx 4.1 2021-07-12 20:49:30 -04:00
Aaron Carlisle 15d91096b1 Fix api docs css for sphinx4 2021-07-12 20:27:15 -04:00
Aaron Carlisle 1f45c113b6 Fix user-select line numbers class name 2021-07-12 18:57:53 -04:00
Aaron Carlisle b47f8b343b Merge branch 'master' into Blendify/sphinx4 2021-07-12 18:36:08 -04:00
Aaron CarlisleandAnthony e94984caec Make sphinx version comparison constistent
Co-authored-by: Anthony <aj@ohess.org>
2021-07-12 18:36:03 -04:00
Juan Luis Cano Rodríguez bc6e9f0766 Merge pull request #1093 from readthedocs/Blendify/python-compat
Add python version requirements to setup.py
2021-06-23 07:32:21 +02:00
Aaron Carlisle 09e9e1004c Merge branch 'master' into Blendify/sphinx4 2021-06-22 18:50:15 -04:00
Aaron Carlisle b2323ce07f Merge branch 'master' into Blendify/python-compat 2021-06-22 18:47:00 -04:00
Joe Nelson 71d6d182cf Maintain aria-expanded along with .current in menu (#1151)
Use jquery setter chaining for speed
2021-06-22 17:46:45 -04:00
ThomasTNOandAaron Carlisle ef9a0584ef Added support for gtag (#1129)
* Added support for gtag

* Fix missing curly braces

* Simplify gtag script import

* Fix tag

* Add gtag to docs

Co-authored-by: Aaron Carlisle <carlisle.b3d@gmail.com>
2021-06-18 13:59:46 -04:00
Joe NelsonandAaron Carlisle a2997e8888 Allow keyboard to toggle menu expansion (#1167)
Co-authored-by: Aaron Carlisle <carlisle.b3d@gmail.com>
2021-06-18 10:16:05 -04:00
Joe Nelson da86e4dc62 Allow keyboard to activate permalink (#1162)
* Allow keyboard to activate permalink

* Change permalink icon with Blendify's suggestion

* Set permalink icon properly across Sphinx versions

* Match prior style better
2021-06-18 09:57:56 -04:00
Benjamin Balder BachandAaron Carlisle 05807985d6 Simplify example but add clarity. (#1144)
Some people might add the example code to the top of the file, in which case `alabaster` will overwrite later. Also, localization is important but not so important for people using this for the first time. My concern is that many people end up with Alabaster on RTD deployments after Sphinx 4 made it the default.

Co-authored-by: Aaron Carlisle <carlisle.b3d@gmail.com>
2021-06-10 17:26:13 -04:00
Aaron Carlisle bd9010f14d Update layout.html 2021-06-09 20:26:36 -04:00
Joe Nelson 392daf5047 Show keyboard focus on buttons (#1161) 2021-06-09 20:22:07 -04:00
Anders Kaseorg 671703c3fb Remove discouraged type="text/javascript" from scripts (#1140)
type="text/javascript" is unnecessary and even discouraged by the
specification: “Authors should omit the type attribute instead of
redundantly setting it.”

https://html.spec.whatwg.org/multipage/scripting.html#attr-script-type

It causes the validator to raise warnings, too.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2021-04-30 21:50:03 -04:00
Erik Moqvist 2026bb61dd Make mobile top navigation bar have the same background color as the side navigation header. (#1132) 2021-04-18 18:08:16 -04:00
Aaron Carlisle b73b67eb33 Revert "Test with official beta"
This reverts commit db302055b9.
2021-04-12 19:34:18 -04:00
Aaron Carlisle db302055b9 Test with official beta 2021-04-12 19:09:41 -04:00
Aaron Carlisle 836467e4b9 Add compatibility for sphinx4
Sphinx 4.x moves javascript and css declarations to `script_files` and `css_files`. This patch fixes duplicatd link and script tags when using sphinx4

Sphinx 4.x changes the default setting of html_codeblock_linenos_style to 'inline' and deprecates `html_codeblock_linenos_style`. The css for `.hll` to make the hightling span the full line cause the line number and code to be split on seperate lines. I could not get the highlight to span the full line so it was removed completely. I also made line numbers not selectible by the user.

This changes also adds the needed changes to the tox testing enviorment alhough, sphinx4 is not officially released to pypi yet. You will need to test these changes locally using: `pip install git+https://github.com/sphinx-doc/sphinx@master`
2021-04-10 16:50:34 -04:00
Aaron Carlisle 3db4e2fbfe Cleanup: Sass formatting (#1119)
* Cleanup: Sass formatting

This patch addresses some sass formatting to make the code easier to read:

- Use leading zeros on decimals less than 1
- Use parentheses around math for css propeties with multiply arguments
- Spaces after commas in arguments

In the future it would be nice to automatically format this with a tool like style lint.

* Revert Extra Tabbing

* Add back missing line

* Add whitespace back

* Fix whitespace 2
2021-04-08 23:31:36 -04:00
Aaron Carlisle 2f12da38c6 Add Missing version bumps for 0.5.2 (#1120)
Found while looking into #1117
2021-04-08 20:40:33 -04:00
Aaron Carlisle 60a094bb13 Merge branch 'master' into Blendify/python-compat 2021-04-08 17:19:58 -04:00
Santos Gallegos 9df65f15c5 Fix backport of requirements (#1118)
This was fixed before releasing 0.5.2,
but looks like the change was lost after merging it to master.
2021-04-06 18:06:31 -05:00
Eric HolscherandAaron Carlisle ca2719b32f Merge Release 0.5.2 Changelog into master (#1114)
* Setup: Require docutils<0.17'

Docutils 0.17 changes some rendering of properties, until support is added we should probably pin to use an older version.

I may not be a bad idea to keep a pinned version in the theme to prevent this issue in the future.

* Release 0.5.2

Include a changelog and bump versions

* Fix changelog

Co-authored-by: Aaron Carlisle <carlisle.b3d@gmail.com>
2021-04-05 13:14:49 -04:00
Aaron Carlisle aa28eecc3a Docs: Fix intersphinx_mapping (#1110)
Sphinx documentation has moved from https://www.sphinx-doc.org/en/stable/ to https://www.sphinx-doc.org/en/master/

Fixes the command line message:
```
intersphinx inventory has moved: https://www.sphinx-doc.org/en/stable/objects.inv -> https://www.sphinx-doc.org/en/master/objects.inv
```
2021-04-02 12:21:54 -04:00
Aaron Carlisle bba36677de Merge branch 'master' into Blendify/python-compat 2021-03-31 22:09:45 -04:00
Aaron Carlisle c984d08dae Cleanup: Use page_source_suffix (#1104)
Use `page_source_suffix` instead of checking `source_suffix`

Since we now require sphinx 1.6 we can cleanup this old workaround for old sphinx versions.
2021-03-30 12:42:04 -04:00
Aaron Carlisle fe934ec0d4 Merge branch 'master' into Blendify/python-compat 2021-03-29 22:08:21 -04:00
Aaron Carlisle 7417ff92bd Update Changelog for v1.0 (#1103)
This includes all major affecting changes that have already been committed to master since the last release.
2021-03-29 19:08:22 -04:00
Aaron Carlisle 65723affd8 Merge branch 'master' into Blendify/python-compat 2021-03-29 17:15:34 -04:00
Aaron CarlisleandSantos Gallegos 3693d4c325 Add deprecation warning for dropping Sphinx 2 and Python 2 support (#1099)
* Add deprecation warning for dropping Sphinx 2 and Python 2 support

Fixes #1092

* Cleanup version imports

* Update __init__.py

* Update sphinx_rtd_theme/__init__.py

Co-authored-by: Santos Gallegos <santos_g@outlook.com>

Co-authored-by: Santos Gallegos <santos_g@outlook.com>
2021-03-29 15:57:14 -04:00
Aaron Carlisle 6f684828ed npm: Update dependencies (simple) (#1096)
This simply runs `npm update` so there are no breaking changes.
2021-03-22 13:26:56 -04:00
Aaron Carlisle 4d196ce134 Add python version requirements to setup.py
This is need in the future so we can gracefully remove python 2.7 support.
See #1075.
2021-03-17 18:29:02 -04:00
Aaron Carlisle 114fb85b44 Require Sphinx 1.6 deprecate html4 (#1091)
Sphinx 1.6 is required for de76c03824 we also do not test against versions lower than 1.6 so we should safely drop it.

This is similar to #1076 and #1075 but less strict
2021-03-15 18:05:20 -04:00
Aaron Carlisle 68d4b8aac7 Javascript: Add support for deep toc levels (#1089)
In ca015a5704 support was added for tox levels up to 10.
This only fixed the css side, this commit makes a similar fix for the js side.

Fixes #893
2021-03-15 13:51:06 -05:00
Santos Gallegos f8e71bf312 Don't require npm to build from source (#1039) 2021-03-15 10:12:50 -05:00
Aaron Carlisle 85f23c9edc Docs: Add text before config api type information (#1090)
* Docs: Add text before config api type information

This makes it more clear what the confval is for without having to read through the type information.

This matches usual sphinx autodoc behavior.

* Only use one space above headings
2021-03-15 09:49:13 -05:00
Aaron Carlisle b33d06444e npm: Add a few missing package fields (#1079)
* npm: Add a few missing package fields

This fixes these warnings when running `npm install`:

```
npm WARN sphinx_rtd_theme@0.5.1 No repository field.
npm WARN sphinx_rtd_theme@0.5.1 No license field.
```

* 0.5.2

* Revert version bump

* Revert version bump
2021-03-12 18:12:31 -05:00