Misc Widgets#

class GravatarWidget(gravatar_url: Optional[str] = None, size: Optional[Union[int, str]] = None, fullname: Optional[str] = None, **kwargs)[source]#

Bases: Image

block: str = 'rounded-circle'#

block is the official wildewidgets name of the block; it can’t be changed by constructor kwargs

fullname: Optional[str] = None#

The person’s name. This will be used as the alt tag on the image

gravatar_url: Optional[str] = None#

The gravatar URL

size: Union[int, str] = 28#

The length in pixels that will used as the height and width of the image

class InitialsAvatarWidget(*args, initials: Optional[str] = None, size: Optional[int] = None, color: Optional[str] = None, background_color: Optional[str] = None, fullname: Optional[str] = None, **kwargs)[source]#

Bases: TemplateWidget

background_color: str = '#626976'#

The background color for the gravatar

color: str = 'white'#

The foreground color for the gravatar

size: int = 28#

The length in pixels that will used as the height and width of the gravatar

template_name: str = 'wildewidgets/initials_avatar.html'#

The name of the template to use to render this widget

class KeyValueListBlock(*blocks, tag: Optional[str] = None, name: Optional[str] = None, modifier: Optional[str] = None, css_class: Optional[str] = None, css_id: Optional[str] = None, empty: Optional[bool] = None, script: Optional[str] = None, attributes: Optional[Dict[str, str]] = None, data_attributes: Optional[Dict[str, str]] = None, aria_attributes: Optional[Dict[str, str]] = None)[source]#

Bases: Block

block: str = 'list-group'#

block is the official wildewidgets name of the block; it can’t be changed by constructor kwargs

tag: str = 'ul'#

The name of the HTML element to use as our tag, e.g. div