plan
Plan Activity
Recent activity feed sorted by file modification time
Install
- Add the package:
npm install @refrakt-md/plan - Add it to the
pluginsarray inrefrakt.config.json:"plugins": ["@refrakt-md/plan"]
Source
import Markdoc from '@markdoc/markdoc';
const { Tag } = Markdoc;
import {
createContentModelSchema,
createComponentRenderable,
readDeferredBody,
COLLECTION_SENTINEL,
} from '@refrakt-md/runes';
const DEFAULT_PLAN_ACTIVITY_BODY = `# Item
{% link href=$item.url %}**{% $item.id %}** — {% $item.data.title %}{% /link %}
# Type
{% humanize($item.type) %}
# Status
{% humanize($item.data.status) %}
# Modified
{% date($item.data.modified) %}
`;
export const planActivity = createContentModelSchema({
attributes: {
limit: {
type: Number,
required: false,
default: 10,
description: 'Maximum number of recent items to show.',
},
},
deferBody: true,
contentModel: { type: 'sequence', fields: [] },
transform(_resolved, attrs) {
const meta = (field: string, content: string) =>
new Tag('meta', { 'data-field': field, content });
const bodySource = readDeferredBody(attrs) ?? DEFAULT_PLAN_ACTIVITY_BODY;
const limit = attrs.limit ?? 10;
const metas = [
meta('collection-type', 'work,bug,spec,decision,milestone'),
meta('collection-filter', ''),
meta('collection-sort', '-modified'),
meta('collection-group', ''),
meta('collection-limit', String(limit)),
meta('collection-fields', ''),
meta('collection-layout', 'table'),
meta('collection-group-display', 'headings'),
meta('collection-empty', ''),
meta(COLLECTION_SENTINEL, 'true'),
meta('collection-body', bodySource),
];
const placeholder = new Tag('div', { 'data-name': 'items' }, []);
return createComponentRenderable({
rune: 'collection',
tag: 'section',
properties: {},
refs: { items: placeholder },
children: [...metas, placeholder],
});
},
});
Renders a recent activity feed showing the most recently modified plan entities. Each entry displays the modification date, entity type, ID, status, and title. Status badges are color-coded using the plan status palette.
Default (last 10 items)
{% plan-activity /%}<section data-rune="collection">
<meta data-field="collection-type" content="work,bug,spec,decision,milestone">
<meta data-field="collection-filter" content="">
<meta data-field="collection-sort" content="-modified">
<meta data-field="collection-group" content="">
<meta data-field="collection-limit" content="10">
<meta data-field="collection-fields" content="">
<meta data-field="collection-layout" content="table">
<meta data-field="collection-group-display" content="headings">
<meta data-field="collection-empty" content="">
<meta data-field="__collection-sentinel" content="true">
<meta data-field="collection-body" content="# Item
{% link href=$item.url %}**{% $item.id %}** — {% $item.data.title %}{% /link %}
# Type
{% humanize($item.type) %}
# Status
{% humanize($item.data.status) %}
# Modified
{% date($item.data.modified) %}
">
<div data-name="items"></div>
</section>| Item | Type | Status | Modified |
|---|---|---|---|
WORK-9101 — Content model validation errors | Work | Ready | Nov 11, 2026 |
WORK-9102 — Token fallback chain for nested tints | Work | Ready | Nov 11, 2026 |
WORK-9103 — Interactive rune playground | Work | Ready | Nov 11, 2026 |
WORK-9104 — Heading level auto-detection for nested runes | Work | In Progress | Nov 11, 2026 |
WORK-9105 — Snapshot tests for identity transform output | Work | In Progress | Nov 11, 2026 |
WORK-9106 — Add copy button to code fences | Work | Done | Nov 11, 2026 |
WORK-9107 — Theme marketplace architecture | Work | Draft | Nov 11, 2026 |
WORK-9108 — Responsive modifier system | Work | Review | Nov 11, 2026 |
| Work | Ready | Nov 11, 2026 | |
| Work | Blocked | Nov 11, 2026 |
<section class="rf-collection" data-type="work,bug,spec,decision,milestone" data-layout="table" data-rune="collection" data-density="full">
<div data-name="items" class="rf-collection__items">
<table class="rf-collection__table">
<thead>
<tr>
<th>Item</th>
<th>Type</th>
<th>Status</th>
<th>Modified</th>
</tr>
</thead>
<tbody>
<tr data-entity-id="WORK-9101">
<td>
<p>
<strong marker="**">WORK-9101</strong>
—
Content model validation errors
</p>
</td>
<td>Work</td>
<td>Ready</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9102">
<td>
<p>
<strong marker="**">WORK-9102</strong>
—
Token fallback chain for nested tints
</p>
</td>
<td>Work</td>
<td>Ready</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9103">
<td>
<p>
<strong marker="**">WORK-9103</strong>
—
Interactive rune playground
</p>
</td>
<td>Work</td>
<td>Ready</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9104">
<td>
<p>
<strong marker="**">WORK-9104</strong>
—
Heading level auto-detection for nested runes
</p>
</td>
<td>Work</td>
<td>In Progress</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9105">
<td>
<p>
<strong marker="**">WORK-9105</strong>
—
Snapshot tests for identity transform output
</p>
</td>
<td>Work</td>
<td>In Progress</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9106">
<td>
<p>
<strong marker="**">WORK-9106</strong>
—
Add copy button to code fences
</p>
</td>
<td>Work</td>
<td>Done</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9107">
<td>
<p>
<strong marker="**">WORK-9107</strong>
—
Theme marketplace architecture
</p>
</td>
<td>Work</td>
<td>Draft</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9108">
<td>
<p>
<strong marker="**">WORK-9108</strong>
—
Responsive modifier system
</p>
</td>
<td>Work</td>
<td>Review</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9142">
<td>
<p>
<a href="/runes/plan/work">
<strong marker="**">WORK-9142</strong>
—
Implement tint rune dark mode support
</a>
</p>
</td>
<td>Work</td>
<td>Ready</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9215">
<td>
<p>
<a href="/runes/plan/work">
<strong marker="**">WORK-9215</strong>
—
Alignment system migration
</a>
</p>
</td>
<td>Work</td>
<td>Blocked</td>
<td>Nov 11, 2026</td>
</tr>
</tbody>
</table>
</div>
</section>Custom limit
Show fewer or more recent items.
{% plan-activity limit=5 /%}<section data-rune="collection">
<meta data-field="collection-type" content="work,bug,spec,decision,milestone">
<meta data-field="collection-filter" content="">
<meta data-field="collection-sort" content="-modified">
<meta data-field="collection-group" content="">
<meta data-field="collection-limit" content="5">
<meta data-field="collection-fields" content="">
<meta data-field="collection-layout" content="table">
<meta data-field="collection-group-display" content="headings">
<meta data-field="collection-empty" content="">
<meta data-field="__collection-sentinel" content="true">
<meta data-field="collection-body" content="# Item
{% link href=$item.url %}**{% $item.id %}** — {% $item.data.title %}{% /link %}
# Type
{% humanize($item.type) %}
# Status
{% humanize($item.data.status) %}
# Modified
{% date($item.data.modified) %}
">
<div data-name="items"></div>
</section>| Item | Type | Status | Modified |
|---|---|---|---|
WORK-9101 — Content model validation errors | Work | Ready | Nov 11, 2026 |
WORK-9102 — Token fallback chain for nested tints | Work | Ready | Nov 11, 2026 |
WORK-9103 — Interactive rune playground | Work | Ready | Nov 11, 2026 |
WORK-9104 — Heading level auto-detection for nested runes | Work | In Progress | Nov 11, 2026 |
WORK-9105 — Snapshot tests for identity transform output | Work | In Progress | Nov 11, 2026 |
<section class="rf-collection" data-type="work,bug,spec,decision,milestone" data-layout="table" data-rune="collection" data-density="full">
<div data-name="items" class="rf-collection__items">
<table class="rf-collection__table">
<thead>
<tr>
<th>Item</th>
<th>Type</th>
<th>Status</th>
<th>Modified</th>
</tr>
</thead>
<tbody>
<tr data-entity-id="WORK-9101">
<td>
<p>
<strong marker="**">WORK-9101</strong>
—
Content model validation errors
</p>
</td>
<td>Work</td>
<td>Ready</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9102">
<td>
<p>
<strong marker="**">WORK-9102</strong>
—
Token fallback chain for nested tints
</p>
</td>
<td>Work</td>
<td>Ready</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9103">
<td>
<p>
<strong marker="**">WORK-9103</strong>
—
Interactive rune playground
</p>
</td>
<td>Work</td>
<td>Ready</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9104">
<td>
<p>
<strong marker="**">WORK-9104</strong>
—
Heading level auto-detection for nested runes
</p>
</td>
<td>Work</td>
<td>In Progress</td>
<td>Nov 11, 2026</td>
</tr>
<tr data-entity-id="WORK-9105">
<td>
<p>
<strong marker="**">WORK-9105</strong>
—
Snapshot tests for identity transform output
</p>
</td>
<td>Work</td>
<td>In Progress</td>
<td>Nov 11, 2026</td>
</tr>
</tbody>
</table>
</div>
</section>What it shows
An ordered list, most recently modified first. Each entry shows the date it was last modified, the entity's type (work, bug, spec, decision), its ID, a status badge and its title. Dates come from git history, or the file's modification time when there is none; entities with neither are left out.
Attributes
| Attribute | Type | Required | Description |
|---|---|---|---|
limit | number | — | Maximum number of recent items to show. |
Universal attributes
bg
The background layer: image, video, gradient, flat overlay wash and legibility scrim, in a single injected layer behind the rune's content.
| Attribute | Type | Required | Description |
|---|---|---|---|
bg | string | — | Background preset applied to this block |
bg-from | string | — | Gradient start colour — a semantic token name (→ var(--rf-color-*)) |
bg-gradient | "to-t" | "to-b" | "to-l" | "to-r" | "to-tr" | "to-br" | "to-bl" | "to-tl" | — | Gradient direction (bounded named set) |
bg-gradient-type | "linear" | "radial" | "conic" | — | Gradient type |
bg-to | string | — | Gradient end colour — a semantic token name |
bg-via | string | — | Optional middle gradient stop — a semantic token name |
scrim | "top" | "bottom" | "left" | "right" | "none" | — | Scrim direction (heaviest edge); presence turns the scrim on, "none" opts out of the default cover scrim |
scrim-blur | "none" | "sm" | "md" | "lg" | — | Frost scrim blur amount |
scrim-strength | "sm" | "md" | "lg" | — | Gradient scrim strength |
scrim-tone | "dark" | "light" | — | Whether the scrim darkens (for light text) or lightens (for dark text) |
scrim-type | "gradient" | "frost" | — | Scrim treatment: gradient (default) or frost (backdrop blur) |
elevation
How far the rune sits off the page, from sunken to overlay. The theme decides what each step looks like.
| Attribute | Type | Required | Description |
|---|---|---|---|
elevation | "sunken" | "flush" | "flat" | "raised" | "floating" | "overlay" | "none" | "sm" | "md" | "lg" | — | Surface depth, from sunken to overlay. Deprecated: none, sm, md and lg (read as flat, raised, raised and floating) |
inset
Internal padding override.
| Attribute | Type | Required | Description |
|---|---|---|---|
inset | "flush" | "tight" | "default" | "loose" | "breathe" | — | Inner padding of this block |
motion
Scroll-reveal entrance. You choose its character; the theme decides how it moves.
| Attribute | Type | Required | Description |
|---|---|---|---|
reveal | "none" | "fade" | "slide" | "scale" | "blur" | — | Scroll-reveal entrance character (none|fade|slide|scale|blur); the theme owns the choreography |
stagger | boolean | — | Cascade this block's items in as it reveals (no-op on single-child runes) |
spacing
Block-level rhythm override.
| Attribute | Type | Required | Description |
|---|---|---|---|
spacing | "flush" | "tight" | "default" | "loose" | "breathe" | — | Vertical spacing above and below this block |
substrate
Generated pattern fills behind the content, drawn by the theme.
| Attribute | Type | Required | Description |
|---|---|---|---|
substrate | "dots" | "grid" | "lines" | "cross" | "checker" | "none" | — | Generated surface pattern |
substrate-fill | "inherit" | "inset" | — | Surface fill the pattern sits on (full colour stays with tint) |
substrate-opacity | "sm" | "md" | "lg" | — | Pattern ink strength |
substrate-size | "sm" | "md" | "lg" | — | Pattern cell size |
substrate-target | "self" | "media" | — | Which surface the pattern fills (overrides the rune/theme default) |
tint
Per-rune colour override: a named tint from the theme registry, with inline per-token overrides layered on top.
| Attribute | Type | Required | Description |
|---|---|---|---|
tint | string | — | Color tint preset applied to this block |
tint-mode | "auto" | "dark" | "light" | — | Whether the tint adapts to auto, dark, or light mode |
width
The track a block rune occupies.
| Attribute | Type | Required | Description |
|---|---|---|---|
width | "compact" | "narrow" | "content" | "wide" | "full" | — | Maximum width constraint for this block |
| Not available | Why |
|---|---|
| dropcap, reading | this rune declares no prose body |
| frame | this rune declares neither a `frameTarget` nor a media section |
| prominence | this rune has no page-section header or featured quotation |