layout.chart
A chart: a trend over time, a breakdown. Renders <figure>; put the chart's svg or canvas inside with a height, and a text.caption that says what it shows
Read https://www.prongs.dev/docs/intents/layout/chart.md and tell me whether layout.chart fits what I am building.Layout intents
Example
Sign-ups per week, last two months
<Layout intent="layout.chart">
…
</Layout>Connections
Choosing between neighbours
If it is
Use
A chart: a trend over time, a breakdown. Renders <figure>; put the chart's svg or canvas inside with a height, and a text.caption that says what it shows
layout.chartA single number
text.statAn amount shown as blocks, like a battery
layout.blocksA smooth amount where small differences matter
rather thanlayout.blockslayout.chart
For registry authors
Pack intent. prongs add dashboard puts the dashboard pack’s intents in your registry. They are then yours like the starter intents: rename, restyle and add to them, and see them with prongs add gallery.
What this intent is built from and its entry in components/prongs/registry.ts. You only need this to change how it looks or to add an intent like it.
How layout.chart resolves, and its definition
Each layer adds to the one before it; a later class wins over an earlier one that sets the same thing.
arrange.stackChildren in a column, free to shrink inside a row or grid
flex min-w-0 flex-col
layout.chartA chart: a trend over time, a breakdown. Renders <figure>; put the chart's svg or canvas inside with a height, and a text.caption that says what it shows
m-0 min-w-0 gap-2
flex flex-col m-0 min-w-0 gap-2
'layout.chart': {
kind: 'semantic',
description: 'A chart: a trend over time, a breakdown. Renders <figure>; put the chart\'s svg or canvas inside with a height, and a text.caption that says what it shows',
refs: ['arrange.stack'],
binding: { element: 'figure', classes: 'm-0 min-w-0 gap-2' },
notFor: [
{ context: 'a single number', instead: 'text.stat' },
{
context: 'an amount shown as blocks, like a battery',
instead: 'layout.blocks',
},
],
},