vizmatic 0.1.25 → 0.1.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/PROMPT.md CHANGED
@@ -270,7 +270,7 @@ Cards, labels, and compact UI:
270
270
  - `ToneStrip`: `tone`, `width?: number = 34`, `height?: number = 4`.
271
271
  - `StepCard`: `title`, `c`, `subtitle?`, `eyebrow?`, `tone?: ToneName = "blue"`, `width?: number | string = 210`, `minWidth?`, `minHeight?: number | string = 74`, `padding?: number | string = "12px 14px"`, `radius?: number = 8`, `shadow?: boolean = true`, `align?: "left" | "center" = "center"`, `math?: boolean = false`.
272
272
  - `MetricCard`: `label`, `value`, `c`, `tone?: ToneName = "blue"`, `detail?`, `width?`, `minWidth?`, `minHeight?: number | string = 74`, `padding?: number | string = "10px 12px"`, `radius?: number = 8`, `shadow?: boolean = true`, `align?: "left" | "center" = "center"`, `math?: boolean = false`, `valueMono?: boolean = true`, `valueFontSize?: number = 10`, `valueColor?`.
273
- - `CalloutCard`: `c`, `children?`, `title?`, `detail?`, `tone?: ToneName = "blue"`, `width?`, `minHeight?`, `padding?: number | string = 12`, `filled?: boolean = true`, `align?: "left" | "center" = "center"`.
273
+ - `CalloutCard`: `c`, `children?`, `title?`, `detail?`, `tone?: ToneName = "blue"`, `width?`, `minHeight?`, `padding?: number | string = 12`, `titleFontSize?: number`, `detailFontSize?: number`, `filled?: boolean = true`, `align?: "left" | "center" = "center"`.
274
274
  - `ValuePill`: `label`, `value`, `c`, `tone?: ToneName = "blue"`, `detail?`, `width?: number | string = 112`, `math?: boolean = false`.
275
275
  - `BadgePill`: `text`, `c`, `tone?: ToneName = "blue"`, `width?`, `minWidth?: number | string = 34`, `height?: number | string = 20`, `padding?: number | string = "0 8px"`, `radius?: number = 6`, `fontSize?: number = 9`, `mono?: boolean = true`, `filled?: boolean = false`, `math?: boolean = false`.
276
276
  - `Badge`: `label`, `c`, `color?: ColorName = "primary"`.
@@ -306,7 +306,7 @@ Flows and process diagrams:
306
306
  Graphs and networks:
307
307
 
308
308
  - `LayeredNetwork`: `c`, `layers: LayeredNetworkLayer[]`, `activePath?: number[] = []`, `annotations?: string[] = []`, `formula?`, `legend?: string = "highlighted path"`, `width?: number = 900`, `height?: number = 400`, `nodeSize?: number = 56`, `showFormula?: boolean = true`. `LayeredNetworkLayer`: `title`, `nodes: string[]`, `tone?`.
309
- - `GraphDiagram`: `nodes: GraphDiagramNode[]`, `edges: GraphDiagramEdge[]`, `c`, `width?: number = 520`, `height?: number = 420`, `nodeWidth?: number = 150`, `nodeHeight?: number = 66`, `padding?: number = 28`. `GraphDiagramNode`: `id`, `label`, `detail?`, `x`, `y`, `tone?`, `muted?`, `width?`, `height?`. `GraphDiagramEdge`: `from`, `to`, `tone?`, `muted?`, `dashed?`, `label?`.
309
+ - `GraphDiagram`: `nodes: GraphDiagramNode[]`, `edges: GraphDiagramEdge[]`, `c`, `width?: number = 520`, `height?: number = 420`, `nodeWidth?: number = 150`, `nodeHeight?: number = 66`, `labelFontSize?: number = 14`, `detailFontSize?: number = 9`, `arrowSize?: number = 5`, `padding?: number = 28`. `GraphDiagramNode`: `id`, `label`, `detail?`, `x`, `y`, `tone?`, `muted?`, `width?`, `height?`. `GraphDiagramEdge`: `from`, `to`, `tone?`, `muted?`, `dashed?`, `label?`.
310
310
  - `TreeDiagram`: `root: TreeNodeSpec`, `c`, `title?`, `subtitle?`, `width?`, `height?`, `nodeWidth?: number = 156`, `nodeHeight?: number = 64`, `levelGap?: number = 58`, `siblingGap?: number = 24`, `padding?: number = 28`, `math?: boolean = false`. `TreeNodeSpec`: `label`, `id?`, `detail?`, `tone?`, `muted?`, `children?`.
311
311
 
312
312
  Matrices and heatmaps:
package/dist/cli.js CHANGED
@@ -3212,6 +3212,9 @@ function GraphDiagram({
3212
3212
  height = 420,
3213
3213
  nodeWidth = 150,
3214
3214
  nodeHeight = 66,
3215
+ labelFontSize = 14,
3216
+ detailFontSize = 9,
3217
+ arrowSize = 5,
3215
3218
  padding = 28
3216
3219
  }) {
3217
3220
  const layout = new Map(nodes.map((node) => {
@@ -3281,7 +3284,7 @@ function GraphDiagram({
3281
3284
  ...edgeLayouts.map((edge) => ArrowMarkerDef({
3282
3285
  id: edge.markerId,
3283
3286
  color: edge.color,
3284
- size: 5
3287
+ size: arrowSize
3285
3288
  }))
3286
3289
  ),
3287
3290
  ...edgeLayouts.map((edge) => React6.createElement("line", {
@@ -3350,7 +3353,7 @@ function GraphDiagram({
3350
3353
  React6.createElement("div", {
3351
3354
  style: {
3352
3355
  fontFamily: "Inter",
3353
- fontSize: 14,
3356
+ fontSize: labelFontSize,
3354
3357
  fontWeight: 900,
3355
3358
  lineHeight: 1.15
3356
3359
  }
@@ -3359,7 +3362,7 @@ function GraphDiagram({
3359
3362
  style: {
3360
3363
  color: c.textMuted,
3361
3364
  fontFamily: "JetBrains Mono",
3362
- fontSize: 9,
3365
+ fontSize: detailFontSize,
3363
3366
  fontWeight: 650,
3364
3367
  lineHeight: 1.2
3365
3368
  }
@@ -3580,6 +3583,8 @@ function CalloutCard({
3580
3583
  width,
3581
3584
  minHeight,
3582
3585
  padding = 12,
3586
+ titleFontSize,
3587
+ detailFontSize,
3583
3588
  filled = true,
3584
3589
  align = "center"
3585
3590
  }) {
@@ -3608,6 +3613,7 @@ function CalloutCard({
3608
3613
  title && React6.createElement("div", {
3609
3614
  style: {
3610
3615
  ...typography.small,
3616
+ ...titleFontSize != null ? { fontSize: titleFontSize } : {},
3611
3617
  color: filled ? c.textOnColor : accent,
3612
3618
  fontWeight: 900,
3613
3619
  lineHeight: 1.2,
@@ -3617,6 +3623,7 @@ function CalloutCard({
3617
3623
  detail && React6.createElement("div", {
3618
3624
  style: {
3619
3625
  ...typography.tiny,
3626
+ ...detailFontSize != null ? { fontSize: detailFontSize } : {},
3620
3627
  color: filled ? "rgba(255,255,255,0.84)" : c.textSecondary,
3621
3628
  lineHeight: 1.3,
3622
3629
  textAlign
package/dist/index.cjs CHANGED
@@ -3226,6 +3226,9 @@ function GraphDiagram({
3226
3226
  height = 420,
3227
3227
  nodeWidth = 150,
3228
3228
  nodeHeight = 66,
3229
+ labelFontSize = 14,
3230
+ detailFontSize = 9,
3231
+ arrowSize = 5,
3229
3232
  padding = 28
3230
3233
  }) {
3231
3234
  const layout = new Map(nodes.map((node) => {
@@ -3295,7 +3298,7 @@ function GraphDiagram({
3295
3298
  ...edgeLayouts.map((edge) => ArrowMarkerDef({
3296
3299
  id: edge.markerId,
3297
3300
  color: edge.color,
3298
- size: 5
3301
+ size: arrowSize
3299
3302
  }))
3300
3303
  ),
3301
3304
  ...edgeLayouts.map((edge) => import_react6.default.createElement("line", {
@@ -3364,7 +3367,7 @@ function GraphDiagram({
3364
3367
  import_react6.default.createElement("div", {
3365
3368
  style: {
3366
3369
  fontFamily: "Inter",
3367
- fontSize: 14,
3370
+ fontSize: labelFontSize,
3368
3371
  fontWeight: 900,
3369
3372
  lineHeight: 1.15
3370
3373
  }
@@ -3373,7 +3376,7 @@ function GraphDiagram({
3373
3376
  style: {
3374
3377
  color: c.textMuted,
3375
3378
  fontFamily: "JetBrains Mono",
3376
- fontSize: 9,
3379
+ fontSize: detailFontSize,
3377
3380
  fontWeight: 650,
3378
3381
  lineHeight: 1.2
3379
3382
  }
@@ -3594,6 +3597,8 @@ function CalloutCard({
3594
3597
  width,
3595
3598
  minHeight,
3596
3599
  padding = 12,
3600
+ titleFontSize,
3601
+ detailFontSize,
3597
3602
  filled = true,
3598
3603
  align = "center"
3599
3604
  }) {
@@ -3622,6 +3627,7 @@ function CalloutCard({
3622
3627
  title && import_react6.default.createElement("div", {
3623
3628
  style: {
3624
3629
  ...typography.small,
3630
+ ...titleFontSize != null ? { fontSize: titleFontSize } : {},
3625
3631
  color: filled ? c.textOnColor : accent,
3626
3632
  fontWeight: 900,
3627
3633
  lineHeight: 1.2,
@@ -3631,6 +3637,7 @@ function CalloutCard({
3631
3637
  detail && import_react6.default.createElement("div", {
3632
3638
  style: {
3633
3639
  ...typography.tiny,
3640
+ ...detailFontSize != null ? { fontSize: detailFontSize } : {},
3634
3641
  color: filled ? "rgba(255,255,255,0.84)" : c.textSecondary,
3635
3642
  lineHeight: 1.3,
3636
3643
  textAlign
package/dist/index.d.cts CHANGED
@@ -889,9 +889,12 @@ interface GraphDiagramProps {
889
889
  height?: number;
890
890
  nodeWidth?: number;
891
891
  nodeHeight?: number;
892
+ labelFontSize?: number;
893
+ detailFontSize?: number;
894
+ arrowSize?: number;
892
895
  padding?: number;
893
896
  }
894
- declare function GraphDiagram({ nodes, edges, c, width, height, nodeWidth, nodeHeight, padding, }: GraphDiagramProps): React.ReactElement;
897
+ declare function GraphDiagram({ nodes, edges, c, width, height, nodeWidth, nodeHeight, labelFontSize, detailFontSize, arrowSize, padding, }: GraphDiagramProps): React.ReactElement;
895
898
  interface TreeNodeSpec {
896
899
  label: React.ReactNode;
897
900
  id?: string;
@@ -924,10 +927,12 @@ interface CalloutCardProps {
924
927
  width?: number | string;
925
928
  minHeight?: number | string;
926
929
  padding?: number | string;
930
+ titleFontSize?: number;
931
+ detailFontSize?: number;
927
932
  filled?: boolean;
928
933
  align?: 'left' | 'center';
929
934
  }
930
- declare function CalloutCard({ c, children, title, detail, tone, width, minHeight, padding, filled, align, }: CalloutCardProps): React.ReactElement;
935
+ declare function CalloutCard({ c, children, title, detail, tone, width, minHeight, padding, titleFontSize, detailFontSize, filled, align, }: CalloutCardProps): React.ReactElement;
931
936
  interface PipelineStage {
932
937
  label: string;
933
938
  sublabel?: string;
package/dist/index.d.ts CHANGED
@@ -889,9 +889,12 @@ interface GraphDiagramProps {
889
889
  height?: number;
890
890
  nodeWidth?: number;
891
891
  nodeHeight?: number;
892
+ labelFontSize?: number;
893
+ detailFontSize?: number;
894
+ arrowSize?: number;
892
895
  padding?: number;
893
896
  }
894
- declare function GraphDiagram({ nodes, edges, c, width, height, nodeWidth, nodeHeight, padding, }: GraphDiagramProps): React.ReactElement;
897
+ declare function GraphDiagram({ nodes, edges, c, width, height, nodeWidth, nodeHeight, labelFontSize, detailFontSize, arrowSize, padding, }: GraphDiagramProps): React.ReactElement;
895
898
  interface TreeNodeSpec {
896
899
  label: React.ReactNode;
897
900
  id?: string;
@@ -924,10 +927,12 @@ interface CalloutCardProps {
924
927
  width?: number | string;
925
928
  minHeight?: number | string;
926
929
  padding?: number | string;
930
+ titleFontSize?: number;
931
+ detailFontSize?: number;
927
932
  filled?: boolean;
928
933
  align?: 'left' | 'center';
929
934
  }
930
- declare function CalloutCard({ c, children, title, detail, tone, width, minHeight, padding, filled, align, }: CalloutCardProps): React.ReactElement;
935
+ declare function CalloutCard({ c, children, title, detail, tone, width, minHeight, padding, titleFontSize, detailFontSize, filled, align, }: CalloutCardProps): React.ReactElement;
931
936
  interface PipelineStage {
932
937
  label: string;
933
938
  sublabel?: string;
package/dist/index.js CHANGED
@@ -3095,6 +3095,9 @@ function GraphDiagram({
3095
3095
  height = 420,
3096
3096
  nodeWidth = 150,
3097
3097
  nodeHeight = 66,
3098
+ labelFontSize = 14,
3099
+ detailFontSize = 9,
3100
+ arrowSize = 5,
3098
3101
  padding = 28
3099
3102
  }) {
3100
3103
  const layout = new Map(nodes.map((node) => {
@@ -3164,7 +3167,7 @@ function GraphDiagram({
3164
3167
  ...edgeLayouts.map((edge) => ArrowMarkerDef({
3165
3168
  id: edge.markerId,
3166
3169
  color: edge.color,
3167
- size: 5
3170
+ size: arrowSize
3168
3171
  }))
3169
3172
  ),
3170
3173
  ...edgeLayouts.map((edge) => React6.createElement("line", {
@@ -3233,7 +3236,7 @@ function GraphDiagram({
3233
3236
  React6.createElement("div", {
3234
3237
  style: {
3235
3238
  fontFamily: "Inter",
3236
- fontSize: 14,
3239
+ fontSize: labelFontSize,
3237
3240
  fontWeight: 900,
3238
3241
  lineHeight: 1.15
3239
3242
  }
@@ -3242,7 +3245,7 @@ function GraphDiagram({
3242
3245
  style: {
3243
3246
  color: c.textMuted,
3244
3247
  fontFamily: "JetBrains Mono",
3245
- fontSize: 9,
3248
+ fontSize: detailFontSize,
3246
3249
  fontWeight: 650,
3247
3250
  lineHeight: 1.2
3248
3251
  }
@@ -3463,6 +3466,8 @@ function CalloutCard({
3463
3466
  width,
3464
3467
  minHeight,
3465
3468
  padding = 12,
3469
+ titleFontSize,
3470
+ detailFontSize,
3466
3471
  filled = true,
3467
3472
  align = "center"
3468
3473
  }) {
@@ -3491,6 +3496,7 @@ function CalloutCard({
3491
3496
  title && React6.createElement("div", {
3492
3497
  style: {
3493
3498
  ...typography.small,
3499
+ ...titleFontSize != null ? { fontSize: titleFontSize } : {},
3494
3500
  color: filled ? c.textOnColor : accent,
3495
3501
  fontWeight: 900,
3496
3502
  lineHeight: 1.2,
@@ -3500,6 +3506,7 @@ function CalloutCard({
3500
3506
  detail && React6.createElement("div", {
3501
3507
  style: {
3502
3508
  ...typography.tiny,
3509
+ ...detailFontSize != null ? { fontSize: detailFontSize } : {},
3503
3510
  color: filled ? "rgba(255,255,255,0.84)" : c.textSecondary,
3504
3511
  lineHeight: 1.3,
3505
3512
  textAlign
@@ -22,3 +22,4 @@ Rendered assets live on the [Vizmatic gallery](https://bvolpato.github.io/vizmat
22
22
  | [Theme System](theme-system.tsx) | <img src="https://bvolpato.github.io/vizmatic/assets/examples/theme-system_dark.png" alt="Theme System dark render" width="360" /> | <img src="https://bvolpato.github.io/vizmatic/assets/examples/theme-system_light.png" alt="Theme System light render" width="360" /> |
23
23
  | [Token Matrix](token-matrix.tsx) | <img src="https://bvolpato.github.io/vizmatic/assets/examples/token-matrix_dark.png" alt="Token Matrix dark render" width="360" /> | <img src="https://bvolpato.github.io/vizmatic/assets/examples/token-matrix_light.png" alt="Token Matrix light render" width="360" /> |
24
24
  | [Transparent Badge](transparent-badge.tsx) | <img src="https://bvolpato.github.io/vizmatic/assets/examples/transparent-badge_dark.png" alt="Transparent Badge dark render" width="360" /> | <img src="https://bvolpato.github.io/vizmatic/assets/examples/transparent-badge_light.png" alt="Transparent Badge light render" width="360" /> |
25
+ | [Vizmatic Hero](vizmatic-hero.tsx) | <img src="https://bvolpato.github.io/vizmatic/assets/examples/vizmatic-hero_dark.png" alt="Vizmatic Hero dark render" width="360" /> | <img src="https://bvolpato.github.io/vizmatic/assets/examples/vizmatic-hero_light.png" alt="Vizmatic Hero light render" width="360" /> |
@@ -0,0 +1,48 @@
1
+ width = 1040;
2
+ height = 640;
3
+
4
+ <Scene
5
+ title="From prompt to polished visual"
6
+ gap={24}
7
+ >
8
+ <GraphDiagram
9
+ width={900}
10
+ height={340}
11
+ nodeWidth={170}
12
+ nodeHeight={76}
13
+ labelFontSize={19}
14
+ arrowSize={7}
15
+ nodes={[
16
+ { id: 'brief', label: 'Agent prompt', x: 0.10, y: 0.50, tone: 'blue' },
17
+ { id: 'primitives', label: 'Visual primitives', x: 0.36, y: 0.25, tone: 'purple' },
18
+ { id: 'theme', label: 'Theme tokens', x: 0.36, y: 0.75, tone: 'cyan' },
19
+ { id: 'render', label: 'Headless render', x: 0.65, y: 0.50, tone: 'warm' },
20
+ { id: 'asset', label: 'PNG / SVG / GIF', x: 0.90, y: 0.50, tone: 'green' },
21
+ ]}
22
+ edges={[
23
+ { from: 'brief', to: 'primitives', tone: 'blue' },
24
+ { from: 'brief', to: 'theme', tone: 'cyan' },
25
+ { from: 'primitives', to: 'render', tone: 'purple' },
26
+ { from: 'theme', to: 'render', tone: 'cyan' },
27
+ { from: 'render', to: 'asset', tone: 'green' },
28
+ ]}
29
+ />
30
+ <Row width="100%" gap={14}>
31
+ <CalloutCard
32
+ title="Editable TSX source"
33
+ tone="purple"
34
+ width={430}
35
+ minHeight={64}
36
+ padding={18}
37
+ titleFontSize={18}
38
+ />
39
+ <CalloutCard
40
+ title="Offline, deterministic output"
41
+ tone="green"
42
+ width={430}
43
+ minHeight={64}
44
+ padding={18}
45
+ titleFontSize={18}
46
+ />
47
+ </Row>
48
+ </Scene>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vizmatic",
3
- "version": "0.1.25",
3
+ "version": "0.1.26",
4
4
  "description": "Theme-aware visual primitives and render pipeline for AI-generated diagrams, figures, and presentation frames.",
5
5
  "type": "module",
6
6
  "license": "MIT",