Bio
A compact author or practitioner strip for an article footer or short about band.
Try it
Article author
A concise author block.
Use it
Working invocation
This code creates the configuration shown above. Copy the template and the required Python context together.
{% include "brickwork_marketing/components/_bio.html" %}
context = {'name': 'Avery Morgan', 'role': 'Design systems lead', 'body': 'Builds accessible interfaces.', 'profile': {'label': 'View profile', 'url': '/people/avery/'}}
Guide
Add it to your project
- Use the public include path "brickwork_marketing/components/_bio.html" from the installed django-brickwork package.
- Include the template where the article footer or small about strip belongs.
- Provide one or more content fields; an entirely empty bio emits no markup.
- Pass image as already-safe portrait HTML and give its image an accessible name.
- Use either profile object or flat profile fields; the object takes precedence.
Options
Public API
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
| image | safe HTML | Not set | No | Small square portrait markup. Constraint: Caller owns escaping and must give any image an accessible name. |
| name | string | Not set | No | Displayed person or plan name. Constraint: No additional template constraint beyond the documented type. |
| role | string | Not set | No | Short attribution or position line below the name. Constraint: No additional template constraint beyond the documented type. |
| body | string | Not set | No | Supporting plain-text paragraph. Constraint: No additional template constraint beyond the documented type. |
| profile | object {label, url} | Not set | No | Profile link; takes precedence over flat fields. Constraint: Use either this object or `profile_label` plus `profile_href`. If both are supplied, this object wins. |
| profile_label | string | Not set | No | Visible label for the flat profile link. Constraint: Supply `profile_href` too; ignored when `profile` is present. |
| profile_href | string | Not set | No | Destination for the flat profile link. Constraint: Supply `profile_label` too; ignored when `profile` is present. |
Named blocks
Fill these only when you extend the component template. They are not values passed to an include or tag.
| Block | What it replaces |
|---|---|
| image | Replaces the conditional image slot with authored markup. |
| name | Replaces the displayed name. |
| role | Replaces the role or attribution line. |
| body | Replaces the supporting body content. |
| profile | Replaces the profile-link region. |
Behaviour
Accessibility and responsive behaviour
- Accessibility
- Name is deliberately not a heading; image markup must supply its own accessible name.
- Responsive
- Horizontal flex row wraps without a breakpoint switch.
- Without JavaScript
- Static HTML; no JavaScript required.
Need help?
Troubleshooting
The profile link is missing.
Provide both `profile_label` and `profile_href`, or a `profile` object with both `label` and `url`; the object wins when both shapes are passed.
Explore next