Theme Service¶
Overview¶
The ThemeService manages document themes used for categorising and organising content. It loads themes from a configuration file and provides methods to retrieve and manipulate theme data.
Key Methods¶
getStructuredThemes¶
Converts raw theme configuration into structured theme objects:
- Generates unique IDs for each theme
- Formats themes with name and description
- Returns themes indexed by name
getThemesByNames¶
Retrieves themes by their names:
- Filters themes based on provided names
- Returns an array of matching theme objects
- Ignores names that don't match existing themes
getAllThemes¶
Retrieves all available themes:
- Returns an array of all theme objects
- Includes ID, name, and description for each theme