Server : Apache System : Linux iad1-shared-b8-43 6.6.49-grsec-jammy+ #10 SMP Thu Sep 12 23:23:08 UTC 2024 x86_64 User : dh_edsupp ( 6597262) PHP Version : 8.2.26 Disable Function : NONE Directory : /lib/python3/dist-packages/sphinx/environment/adapters/ |
Upload File : |
""" sphinx.environment.adapters.asset ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Assets adapter for sphinx.environment. :copyright: Copyright 2007-2021 by the Sphinx team, see AUTHORS. :license: BSD, see LICENSE for details. """ from sphinx.environment import BuildEnvironment class ImageAdapter: def __init__(self, env: BuildEnvironment) -> None: self.env = env def get_original_image_uri(self, name: str) -> str: """Get the original image URI.""" while name in self.env.original_image_uri: name = self.env.original_image_uri[name] return name