A Sphinx theme for Faculty projects.
Project description
faculty-sphinx-theme is a Sphinx theme for Faculty projects. It’s based on the Read the Docs theme, but with Faculty branding and an optional navigation bar for use in the Faculty platform docs.
Installation
pip install faculty-sphinx-theme
Usage
Install faculty-sphinx-theme and configure your Sphinx project to use the theme. In your project’s conf.py, add faculty_sphinx_theme to the list of enabled extensions:
extensions = [
"faculty_sphinx_theme",
# Plus any other extensions you are using
]
and modify the html_theme setting to:
html_theme = "faculty-sphinx-theme"
Theme options
The theme provides an optional extra navbar with custom links. To enable it, use the navbar settings. You’ll probably also want to set the navbar_root setting which defines the link on the “Faculty logo”:
html_theme_options = {
"navbar": True,
"navbar_root": "https://docs.faculty.ai/",
}
To add entries to the navbar, use the navbar_{0,1,2,3,4}_heading settings. It’s expected to be a string with the heading and linked URL separated by a space, for example:
html_theme_options = {
"navbar": True,
"navbar_root": "https://docs.faculty.ai/",
"navbar_0_heading": "Other https://other.faculty.ai/",
"navbar_1_heading": "More https://more.faculty.ai/",
}
You can also add menu items that appear under navbar entries with the navbar_{0,1,2,3,4}_content settings. They are in the same format as the _heading settings, with comma separation, for example:
html_theme_options = {
"navbar": True,
"navbar_root": "https://docs.faculty.ai/",
"navbar_0_heading": "Other https://other.faculty.ai/",
"navbar_0_content": "Sub 1 https://other.faculty.ai/one, Sub 2 https://other.faculty.ai/two",
"navbar_1_heading": "More https://more.faculty.ai/",
}
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for faculty-sphinx-theme-0.3.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 96c17e248e3dc74d2ac9342276ef5bf2eaddae4c69d641aa25a94415f4062a35 |
|
MD5 | 6414ed42a027dd41f2ccfdb560313aaf |
|
BLAKE2b-256 | b2288c95a9b029007bfa7518dcc9e027bcf20ab7919684911f33ddbac82d9c7c |
Hashes for faculty_sphinx_theme-0.3.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9633e096f73ed57d8e5f99d8102500a70098d967df3095cd6b86c6a9f0c76182 |
|
MD5 | 695b552f155285d4a4b4626f8e179a37 |
|
BLAKE2b-256 | cf4452b693e5332ebb1f889808ed8c9345ae2c712a34c3b28133a4256b8c0252 |