From: Claromes Date: Tue, 18 Jun 2024 09:37:05 +0000 (-0300) Subject: add opengraph X-Git-Url: https://git.claromes.com/?a=commitdiff_plain;h=5b130450fd4adff553b59aaafc166e200afa659b;p=waybacktweets.git add opengraph --- diff --git a/.gitignore b/.gitignore index 96edbee..335d0bf 100644 --- a/.gitignore +++ b/.gitignore @@ -8,4 +8,5 @@ waybacktweets/config/__pycache__ waybacktweets/exceptions/__pycache__ waybacktweets/utils/__pycache__ +dist/ docs/_build/ diff --git a/docs/conf.py b/docs/conf.py index b261555..fa48dd1 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -20,6 +20,7 @@ extensions = [ "sphinx_new_tab_link", "sphinx_click.ext", "sphinx_autodoc_typehints", + "sphinxext.opengraph", ] templates_path = ["_templates"] @@ -51,3 +52,12 @@ html_favicon = "../assets/parthenon.svg" html_logo = "../assets/parthenon.svg" html_title = f"Wayback Tweets Documentation ({version})" html_show_sourcelink = False + + +# -- Options for Open Graph ------------------------------------------------- + +ogp_site_url = "https://claromes.github.io/waybacktweets/" +ogp_image = "./assets/parthenon.svg" +ogp_description_length = 300 + +ogp_enable_meta_description = True diff --git a/poetry.lock b/poetry.lock index 740b153..ffc3ebd 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1509,6 +1509,20 @@ lint = ["docutils-stubs", "flake8", "mypy"] standalone = ["Sphinx (>=5)"] test = ["pytest"] +[[package]] +name = "sphinxext-opengraph" +version = "0.9.1" +description = "Sphinx Extension to enable OGP support" +optional = false +python-versions = ">=3.8" +files = [ + {file = "sphinxext-opengraph-0.9.1.tar.gz", hash = "sha256:dd2868a1e7c9497977fbbf44cc0844a42af39ca65fe1bb0272518af225d06fc5"}, + {file = "sphinxext_opengraph-0.9.1-py3-none-any.whl", hash = "sha256:b3b230cc6a5b5189139df937f0d9c7b23c7c204493b22646273687969dcb760e"}, +] + +[package.dependencies] +sphinx = ">=4.0" + [[package]] name = "streamlit" version = "1.35.0" @@ -1707,4 +1721,4 @@ watchmedo = ["PyYAML (>=3.10)"] [metadata] lock-version = "2.0" python-versions = "^3.11" -content-hash = "37fcbc9255674bf67e65a2db35dbd71355fc97751141e739f31bb50fe708aa04" +content-hash = "fcc3601115ffc7aa7fdbdf7b30d3b627108bfe4f0f6f8521fbc0a99e687befb2" diff --git a/pyproject.toml b/pyproject.toml index dfc3e15..f32e26c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,6 +46,7 @@ sphinxcontrib-mermaid = "^0.9.2" sphinx-new-tab-link = "^0.4.0" sphinx-click = "^6.0.0" sphinx-autodoc-typehints = "^2.1.1" +sphinxext-opengraph = "^0.9.1" [tool.poetry.group.dev.dependencies] black = "^24.4.2"