Skip to main content

Sphinx Extension that creates responsive images.

Project description

sphinxext-photofinish

Photofinish is a sphinx extension for creating responsive images to your Sphinx site. This has several benefits:

  • Lower bandwidth cost for browsers and devices that don't need the higher resolution version
  • Higher resolution images for higher resolution devices

Photofinish can dramatically increase the loading time of your Sphinx website.

Installation

python -m pip install sphinxext-photofinish

Usage

Just add sphinxext-photofinish to your extensions list in your conf.py

extensions = [
    "sphinxext.photofinish",
]

Configuration

Photofinish adds several conf.py options that you can optionally configure:

max_viewport_width - This is maximum "viewable" size of images in your documentation. Typically, it's set to the width of your body. Responsive images are generated up to double of this value. Default is 1000.

width_min - Minimum width of images to generate. Default is 500.

width_step - The resolution to iterate over for generating images. EX: 500, 800, 1100. Default is 300.

photofinish_ci_only - Should this extension only run if the CI environment variable is set? Default is False.

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

sphinxext_photofinish-0.1.12.tar.gz (12.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sphinxext_photofinish-0.1.12-py3-none-any.whl (12.0 kB view details)

Uploaded Python 3

File details

Details for the file sphinxext_photofinish-0.1.12.tar.gz.

File metadata

  • Download URL: sphinxext_photofinish-0.1.12.tar.gz
  • Upload date:
  • Size: 12.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for sphinxext_photofinish-0.1.12.tar.gz
Algorithm Hash digest
SHA256 ea05a78f2ea0a0ece1f4082d2f0318a30ac2a1ee09a5b39fd9fd1fe6a485b75f
MD5 66e92342d11e40f8b8db3f1b45d852f7
BLAKE2b-256 11612a70230ce1b910046f330223bf8eedbc1759f3e9440cf457fa51f1dce6ac

See more details on using hashes here.

File details

Details for the file sphinxext_photofinish-0.1.12-py3-none-any.whl.

File metadata

File hashes

Hashes for sphinxext_photofinish-0.1.12-py3-none-any.whl
Algorithm Hash digest
SHA256 86563500edd76f882a4da4a93d804739040cac39bc4af729015ca17d66e7588e
MD5 bef7842667c4c730971c2b6056553193
BLAKE2b-256 292f734d6fb1bf09fafeeab5bb8a5d84a9ba363915bd83440cc21aea7d030c0c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page