diff --git a/docs/conf.py b/docs/conf.py index c1c8560..e1aa708 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,6 +1,6 @@ import os import sys -import edx_theme +from datetime import datetime # If extensions (or modules to document with autodoc) are in another directory, @@ -12,7 +12,7 @@ # Add any Sphinx extension module names here, as strings. They can be extensions # coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode', 'sphinx.ext.napoleon', 'edx_theme'] +extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode', 'sphinx.ext.napoleon'] # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] @@ -32,8 +32,8 @@ # General information about the project. project = 'bok-choy' -copyright = edx_theme.COPYRIGHT -author = edx_theme.AUTHOR +copyright = f'{datetime.now().year}, edX Inc.' # pylint: disable=redefined-builtin +author = 'edX Inc.' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the @@ -56,13 +56,46 @@ # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. -html_theme = 'edx_theme' -html_theme_path = [edx_theme.get_html_theme_path()] -html_favicon = os.path.join(html_theme_path[0], 'edx_theme', 'static', 'css', 'favicon.ico') +html_theme = 'sphinx_book_theme' +# html_theme_path = [] +html_logo = "https://logos.openedx.org/open-edx-logo-color.png" +html_favicon = "https://logos.openedx.org/open-edx-favicon.ico" # Output file base name for HTML help builder. htmlhelp_basename = 'bok-choydoc' +html_theme_options = { + "repository_url": "https://github.com/openedx/bok-choy", + "repository_branch": "master", + "path_to_docs": "docs/", + "home_page_in_toc": True, + "use_repository_button": True, + "use_issues_button": True, + "use_edit_page_button": True, + # Please don't change unless you know what you're doing. + "extra_footer": """ + + Creative Commons License + +
+ These works by + The Center for Reimagining Learning + are licensed under a + Creative Commons Attribution-ShareAlike 4.0 International License. + """ +} + # -- Options for LaTeX output -------------------------------------------------- diff --git a/requirements/doc.in b/requirements/doc.in index 496d317..245d043 100644 --- a/requirements/doc.in +++ b/requirements/doc.in @@ -4,6 +4,6 @@ -r base.txt # Core bok-choy dependencies -edx-sphinx-theme # edX theme for Sphinx output +sphinx-book-theme # Common theme for all Open edX projects readme_renderer # Validates README.rst for usage on PyPI sphinx # Documentation builder diff --git a/requirements/doc.txt b/requirements/doc.txt index 3f6b0f5..766a125 100644 --- a/requirements/doc.txt +++ b/requirements/doc.txt @@ -2,12 +2,18 @@ # This file is autogenerated by pip-compile with Python 3.8 # by the following command: # -# make upgrade +# pip-compile --output-file=requirements/doc.txt requirements/doc.in # +accessible-pygments==0.0.4 + # via pydata-sphinx-theme alabaster==0.7.13 # via sphinx babel==2.12.1 - # via sphinx + # via + # pydata-sphinx-theme + # sphinx +beautifulsoup4==4.12.0 + # via pydata-sphinx-theme bleach==6.0.0 # via readme-renderer certifi==2022.12.7 @@ -16,15 +22,14 @@ charset-normalizer==3.1.0 # via requests docutils==0.19 # via + # pydata-sphinx-theme # readme-renderer # sphinx -edx-sphinx-theme==3.1.0 - # via -r requirements/doc.in idna==3.4 # via requests imagesize==1.4.1 # via sphinx -importlib-metadata==6.0.0 +importlib-metadata==6.1.0 # via sphinx jinja2==3.1.2 # via sphinx @@ -33,12 +38,18 @@ lazy==1.5 markupsafe==2.1.2 # via jinja2 packaging==23.0 - # via sphinx + # via + # pydata-sphinx-theme + # sphinx +pydata-sphinx-theme==0.13.1 + # via sphinx-book-theme pygments==2.14.0 # via + # accessible-pygments + # pydata-sphinx-theme # readme-renderer # sphinx -pytz==2022.7.1 +pytz==2023.2 # via babel readme-renderer==37.3 # via -r requirements/doc.in @@ -47,16 +58,19 @@ requests==2.28.2 selenium==3.141.0 # via -r requirements/base.txt six==1.16.0 - # via - # bleach - # edx-sphinx-theme + # via bleach snowballstemmer==2.2.0 # via sphinx +soupsieve==2.4 + # via beautifulsoup4 sphinx==5.3.0 # via # -c https://raw.githubusercontent.com/edx/edx-lint/master/edx_lint/files/common_constraints.txt # -r requirements/doc.in - # edx-sphinx-theme + # pydata-sphinx-theme + # sphinx-book-theme +sphinx-book-theme==1.0.0 + # via -r requirements/doc.in sphinxcontrib-applehelp==1.0.4 # via sphinx sphinxcontrib-devhelp==1.0.2