Board templates
The Template Center's 20 whiteboard templates are short descriptions in one file. Change them, remove them or add your own, and they fill in for a customer without extra work.
How templates are built
Every template lives in src/lib/whiteboard/templates.ts. A template doesn't list positions. It describes rows of sections, each with a title, a sticky colour and sample notes, and buildTemplate lays them out:
- A title, and a How to use this board note on the left from
howTo. - Sections as frames, with their notes in a grid (
colsper row, 2 by default) and an optional backgroundtint. - Arrows from section to section in the rows listed in
flow. - With
records: trueand a customer, a From the CRM section with live cards for the customer, two contacts and two contracts.
Add a template
Add an entry to TEMPLATES. Its spec is a function, so the notes can use the customer's details (next section):
Save. It shows in the Template Center straight away, with a preview, its sections listed under "What's inside", and in search.
Sticky colours are the 12 in StickyColor (src/lib/whiteboard/types.ts): yellow, orange, red, pink, violet, blue, cyan, teal, green, lime, gray and white. Their light and dark values are the --sticky-* tokens in globals.css.
Fill in for a customer
When someone picks a customer, spec receives a TemplateContext with:
| Field | What it holds |
|---|---|
customer | The customer's id and name, or null for a blank template |
contacts | Their contacts, primary contact first: id, name and role |
contracts | Their contracts that haven't ended: id, title, status, yearly value and end date |
owner | The person making the board |
The words(ctx) helper turns these into ready-made phrases with sensible text when there's no customer, such as w.co ("Pinnacle Software" or "the customer"), w.champion, w.contract, w.value and w.renewal. Use them in notes, and add records: true to bring the customer's records onto the board as live cards.
Categories and removing templates
- Categories are
TEMPLATE_CATEGORIESat the top of the file. Add, rename or reorder them there; the Template Center's list and counts follow. - Remove a template by deleting its entry. If you remove
renewal-planorstakeholder-map, also remove the sample boards built from them insrc/lib/data/whiteboards.ts. - Change the look of every template (note size, gaps, section padding) with the constants above
buildTemplate.
Suggestions on a new board
An empty board suggests three templates. They're the ids in EmptyBoard, in components/whiteboards/board-page.tsx: one list for boards linked to a customer, one for the rest.
Teach Rune a template
When someone asks Rune for a board, src/lib/board-ai.ts picks the template whose name, or one of its ALIASES, appears in the question, and the customer whose name does. Add the words people use for your template to ALIASES, under its id:
This matching is simple on purpose, for the demo. With a real model connected (see AI models), give it the template list and let it choose, and even write the notes.