Links
AI / Agents
Developers
gdtest-config-display
Tests display_name, authors, and funding in config.
Config sets display_name=‘Pretty Display Name’, theme color, authors with roles, and funding info. The site title should show ‘Pretty Display Name’ not the package name. Author info should appear in the sidebar.
Source files
gdtest_config_display/
__init__.py
"""Package with display_name config."""
__version__ = "0.1.0"
__all__ = ["render", "Style"]
def render(template: str, **kwargs) -> str:
"""
Render a template string.
Parameters
----------
template
Template string with placeholders.
**kwargs
Values for placeholders.
Returns
-------
str
Rendered string.
"""
return template.format(**kwargs)
class Style:
"""
Style configuration.
Parameters
----------
color
CSS color value.
font_size
Font size in pixels.
"""
def __init__(self, color: str = "#333", font_size: int = 14):
self.color = color
self.font_size = font_size
def to_css(self) -> str:
"""
Convert to CSS string.
Returns
-------
str
CSS rule string.
"""
return f"color: {self.color}; font-size: {self.font_size}px;"README.md
# gdtest-config-display Tests display_name, authors, and funding in config.
great-docs.yml
display_name: Pretty Display Name
authors:
- name: Jane Doe
email: jane@example.com
role: Creator
github: janedoe
- name: John Smith
email: john@example.com
role: Maintainer
github: johnsmith
funding:
name: Open Source Foundation
roles:
- Sponsor
homepage: "https://example.com/oss-fund"