betty.project.extension package¶
Subpackages¶
- betty.project.extension.cotton_candy package
- Submodules
- betty.project.extension.cotton_candy.config module
ColorConfiguration
CottonCandyConfiguration
CottonCandyConfiguration.DEFAULT_LINK_ACTIVE_COLOR
CottonCandyConfiguration.DEFAULT_LINK_INACTIVE_COLOR
CottonCandyConfiguration.DEFAULT_PRIMARY_ACTIVE_COLOR
CottonCandyConfiguration.DEFAULT_PRIMARY_INACTIVE_COLOR
CottonCandyConfiguration.__init__()
CottonCandyConfiguration.dump()
CottonCandyConfiguration.featured_entities
CottonCandyConfiguration.link_active_color
CottonCandyConfiguration.link_inactive_color
CottonCandyConfiguration.load()
CottonCandyConfiguration.primary_active_color
CottonCandyConfiguration.primary_inactive_color
CottonCandyConfiguration.update()
- betty.project.extension.cotton_candy.search module
- betty.project.extension.cotton_candy.config module
- Module contents
CottonCandy
CottonCandy.assets_directory_path()
CottonCandy.comes_after()
CottonCandy.default_configuration()
CottonCandy.depends_on()
CottonCandy.filters
CottonCandy.public_css_paths
CottonCandy.register_event_handlers()
CottonCandy.webpack_entry_point_cache_keys()
CottonCandy.webpack_entry_point_directory_path()
associated_file_references()
person_descendant_families()
person_timeline_events()
- Submodules
- betty.project.extension.demo package
- betty.project.extension.deriver package
- betty.project.extension.gramps package
- Submodules
- betty.project.extension.gramps.config module
FamilyTreeConfiguration
FamilyTreeConfiguration.__init__()
FamilyTreeConfiguration.dump()
FamilyTreeConfiguration.event_types
FamilyTreeConfiguration.file_path
FamilyTreeConfiguration.genders
FamilyTreeConfiguration.load()
FamilyTreeConfiguration.place_types
FamilyTreeConfiguration.presence_roles
FamilyTreeConfiguration.update()
FamilyTreeConfigurationSequence
GrampsConfiguration
PluginMapping
- betty.project.extension.gramps.config module
- Module contents
- Submodules
- betty.project.extension.http_api_doc package
- betty.project.extension.maps package
- betty.project.extension.privatizer package
- betty.project.extension.trees package
- betty.project.extension.webpack package
- betty.project.extension.wikipedia package
Submodules¶
Module contents¶
Provide Betty’s extension API.
- class betty.project.extension.ConfigurableExtension[source]¶
Bases:
Extension
,Generic
[_ConfigurationT
],Configurable
[_ConfigurationT
]A configurable extension.
- exception betty.project.extension.CyclicDependencyError[source]¶
Bases:
ExtensionError
,RuntimeError
Raised when extensions define a cyclic dependency, e.g. two extensions depend on each other.
- betty.project.extension.EXTENSION_REPOSITORY: PluginRepository[Extension] = <betty.plugin.entry_point.EntryPointPluginRepository object>¶
The project extension plugin repository.
Read more about Extension plugins.
- class betty.project.extension.Extension[source]¶
Bases:
Plugin
,CoreComponent
,ProjectDependentFactory
Integrate optional functionality with Betty :py:class:`betty.project.Project`s.
Read more about Extension plugins.
To test your own subclasses, use
betty.test_utils.project.extension.ExtensionTestBase
.- classmethod assets_directory_path() Path | None [source]¶
Return the path on disk where the extension’s assets are located.
This may be anywhere in your Python package.
- classmethod comes_after() set[type[Extension] | str] [source]¶
The extensions that this one comes after.
The other extensions may or may not be enabled.
- classmethod comes_before() set[type[Extension] | str] [source]¶
The extensions that this one comes before.
The other extensions may or may not be enabled.
- classmethod depends_on() set[type[Extension] | str] [source]¶
The extensions this one depends on, and comes after.
- disable_requirement() Requirement [source]¶
Define the requirement for this extension to be disabled.
This defaults to the extension’s dependents.
- classmethod enable_requirement() Requirement [source]¶
Define the requirement for this extension to be enabled.
This defaults to the extension’s dependencies.
- async classmethod new_for_project(project: Project) Self [source]¶
Create a new instance using the given project.
- register_event_handlers(registry: EventHandlerRegistry) None [source]¶
Register event handlers with the project.
- exception betty.project.extension.ExtensionError[source]¶
Bases:
BaseException
A generic extension API error.