diff --git a/docs/conf.py b/docs/conf.py index 10d0b21a..f01fe632 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -11,14 +11,14 @@ # serve to show the default. import os -import edx_theme +import sphinx_book_theme +from datetime import datetime # If you wish to publish docs to readthedocs.org you'll need to make sure to # follow the steps here: # https://edx-sphinx-theme.readthedocs.io/en/latest/readme.html#read-the-docs-configuration -html_theme = 'edx_theme' -html_theme_path = [edx_theme.get_html_theme_path()] +html_theme = 'sphinx_book_theme' # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the @@ -30,10 +30,6 @@ # If your documentation needs a minimal Sphinx version, state it here. # needs_sphinx = '1.0' -# Add any Sphinx extension module names here, as strings. They can be extensions -# coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = ['edx_theme'] - # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] @@ -48,8 +44,8 @@ # General information about the project. project = 'designer' -copyright = edx_theme.COPYRIGHT -author = 'edX' +copyright = f'{datetime.now().year}, edX LLC' +author = 'edX LLC' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the @@ -123,7 +119,11 @@ # The name of an image file (within the static path) to use as favicon of the # docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 # pixels large. -html_favicon = os.path.join(html_theme_path[0], 'edx_theme', 'static', 'css', 'favicon.ico') +html_logo = "https://logos.openedx.org/open-edx-logo-color.png" +html_favicon = "https://logos.openedx.org/open-edx-favicon.ico" + +if not os.environ.get('DJANGO_SETTINGS_MODULE'): + os.environ['DJANGO_SETTINGS_MODULE'] = 'test_utils.test_settings' # 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, diff --git a/requirements/doc.in b/requirements/doc.in index b33df915..24445e0b 100644 --- a/requirements/doc.in +++ b/requirements/doc.in @@ -3,6 +3,6 @@ -r test.txt # Core and testing dependencies for this package doc8 # reStructuredText style checker -edx_sphinx_theme # edX theme for Sphinx output +sphinx-book-theme # edX theme for Sphinx output readme_renderer # Validates README.rst for usage on PyPI Sphinx # Documentation builder diff --git a/requirements/doc.txt b/requirements/doc.txt index 1cd59a77..31175eba 100644 --- a/requirements/doc.txt +++ b/requirements/doc.txt @@ -4,6 +4,8 @@ # # make upgrade # +accessible-pygments==0.0.5 + # via pydata-sphinx-theme alabaster==0.7.16 # via sphinx anyascii==0.3.2 @@ -22,9 +24,14 @@ astroid==3.3.5 # pylint-celery babel==2.16.0 # via sphinx +backports-zoneinfo==0.2.1 ; python_version < "3.9" + # via + # pydata-sphinx-theme + # sphinx beautifulsoup4==4.12.3 # via # -r requirements/test.txt + # pydata-sphinx-theme # wagtail boto3==1.35.45 # via -r requirements/test.txt @@ -174,6 +181,7 @@ doc8==1.1.2 docutils==0.21.2 # via # doc8 + # pydata-sphinx-theme # readme-renderer # restructuredtext-lint # sphinx @@ -210,8 +218,6 @@ edx-opaque-keys==2.11.0 # edx-drf-extensions edx-rest-api-client==4.0.1 # via -r requirements/test.txt -edx-sphinx-theme==3.1.0 - # via -r requirements/doc.in et-xmlfile==1.1.0 # via # -r requirements/test.txt @@ -304,6 +310,7 @@ packaging==24.1 # via # -r requirements/test.txt # drf-yasg + # pydata-sphinx-theme # pyproject-api # pytest # sphinx @@ -340,9 +347,13 @@ pycparser==2.22 # via # -r requirements/test.txt # cffi +pydata-sphinx-theme==0.15.4 + # via sphinx-book-theme pygments==2.18.0 # via + # accessible-pygments # doc8 + # pydata-sphinx-theme # readme-renderer # sphinx pyjwt[crypto]==2.9.0 @@ -451,7 +462,6 @@ six==1.16.0 # edx-auth-backends # edx-django-release-util # edx-lint - # edx-sphinx-theme # l18n # python-dateutil slumber==0.7.1 @@ -473,10 +483,13 @@ soupsieve==2.6 # via # -r requirements/test.txt # beautifulsoup4 -sphinx==3.5.3 +sphinx==7.4.7 # via # -r requirements/doc.in - # edx-sphinx-theme + # pydata-sphinx-theme + # sphinx-book-theme +sphinx-book-theme==1.1.3 + # via -r requirements/doc.in sphinxcontrib-applehelp==2.0.0 # via sphinx sphinxcontrib-devhelp==2.0.0 @@ -508,6 +521,16 @@ text-unidecode==1.3 # via # -r requirements/test.txt # python-slugify +tomli==2.0.1 + # via + # -r requirements/test.txt + # coverage + # doc8 + # pylint + # pyproject-api + # pytest + # sphinx + # tox tomlkit==0.13.2 # via # -r requirements/test.txt @@ -522,6 +545,8 @@ typing-extensions==4.12.2 # via # -r requirements/test.txt # edx-opaque-keys + # pydata-sphinx-theme + # pylint # faker # typeguard uritemplate==4.1.1