{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/matsonj/mviz/main/schema/mviz.v1.schema.json", "title": "mviz Chart Specification", "description": "Schema for mviz data visualization specs (v1.x)", "version": "1.0.0", "oneOf": [ { "$ref": "#/$defs/BarChart" }, { "$ref": "#/$defs/LineChart" }, { "$ref": "#/$defs/AreaChart" }, { "$ref": "#/$defs/PieChart" }, { "$ref": "#/$defs/ScatterChart" }, { "$ref": "#/$defs/BubbleChart" }, { "$ref": "#/$defs/BoxplotChart" }, { "$ref": "#/$defs/HistogramChart" }, { "$ref": "#/$defs/WaterfallChart" }, { "$ref": "#/$defs/XmrChart" }, { "$ref": "#/$defs/SankeyChart" }, { "$ref": "#/$defs/FunnelChart" }, { "$ref": "#/$defs/HeatmapChart" }, { "$ref": "#/$defs/CalendarChart" }, { "$ref": "#/$defs/SparklineChart" }, { "$ref": "#/$defs/ComboChart" }, { "$ref": "#/$defs/DumbbellChart" }, { "$ref": "#/$defs/MermaidChart" }, { "$ref": "#/$defs/BigValue" }, { "$ref": "#/$defs/Delta" }, { "$ref": "#/$defs/Alert" }, { "$ref": "#/$defs/Note" }, { "$ref": "#/$defs/Text" }, { "$ref": "#/$defs/Textarea" }, { "$ref": "#/$defs/EmptySpace" }, { "$ref": "#/$defs/Table" } ], "$defs": { "Theme": { "enum": [ "light", "dark" ] }, "FormatOption": { "enum": [ "auto", "currency_auto", "currency", "currency0k", "currency0m", "currency0b", "num0", "num1", "num0k", "num0m", "num0b", "pct", "pct0", "pct1" ] }, "TableColumnFormatOption": { "description": "Format options for table columns. Extends FormatOption with 'date' and 'duration', which only affect table rendering and sort (not chart axes/labels).", "enum": [ "auto", "currency_auto", "currency", "currency0k", "currency0m", "currency0b", "num0", "num1", "num0k", "num0m", "num0b", "pct", "pct0", "pct1", "date", "duration" ] }, "CurrencyCode": { "type": "string", "description": "ISO 4217 currency code (e.g., USD, GBP, EUR)" }, "YField": { "oneOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" }, "minItems": 1 } ] }, "DataArray": { "type": "array", "items": { "type": "object" } }, "ColumnarData": { "type": "object", "description": "Columnar data shape accepted as an alternative to `data` on DataArray-based chart types. The CLI normalizes this to `data` before rendering or linting.", "properties": { "columns": { "type": "array", "items": { "type": "string" } }, "rows": { "type": "array", "items": { "type": "array" } } }, "required": [ "columns", "rows" ] }, "BarChart": { "type": "object", "required": [ "type", "x", "y" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "bar" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "x": { "type": "string" }, "y": { "$ref": "#/$defs/YField" }, "title": { "type": "string" }, "horizontal": { "type": "boolean" }, "stacked": { "type": "boolean" }, "theme": { "$ref": "#/$defs/Theme" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "yMin": { "type": "number" }, "yMax": { "type": "number" }, "xAxisType": { "enum": [ "category", "time", "value" ] } }, "additionalProperties": false }, "LineChart": { "type": "object", "required": [ "type", "x", "y" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "line" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "x": { "type": "string" }, "y": { "$ref": "#/$defs/YField" }, "title": { "type": "string" }, "smooth": { "type": "boolean" }, "theme": { "$ref": "#/$defs/Theme" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "yMin": { "type": "number" }, "yMax": { "type": "number" }, "xAxisType": { "enum": [ "category", "time", "value" ] } }, "additionalProperties": false }, "AreaChart": { "type": "object", "required": [ "type", "x", "y" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "area" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "x": { "type": "string" }, "y": { "$ref": "#/$defs/YField" }, "title": { "type": "string" }, "stacked": { "type": "boolean" }, "smooth": { "type": "boolean" }, "theme": { "$ref": "#/$defs/Theme" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "yMin": { "type": "number" }, "yMax": { "type": "number" }, "xAxisType": { "enum": [ "category", "time", "value" ] } }, "additionalProperties": false }, "PieChart": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "pie" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "name": { "type": "string", "default": "name" }, "value": { "type": "string", "default": "value" }, "title": { "type": "string" }, "donut": { "type": "boolean" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "ScatterChart": { "type": "object", "required": [ "type", "x", "y" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "scatter" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "x": { "type": "string" }, "y": { "type": "string" }, "series": { "type": "string", "description": "Field name to group data points by (creates multiple colored series)" }, "label": { "type": "string", "description": "Field name for point labels shown in tooltips" }, "showLabels": { "type": "boolean", "description": "Show persistent labels next to points (requires label field)" }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" }, "xFormat": { "$ref": "#/$defs/FormatOption" }, "yFormat": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" } }, "additionalProperties": false }, "BubbleChart": { "type": "object", "required": [ "type", "x", "y", "size" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "bubble" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "x": { "type": "string" }, "y": { "type": "string" }, "size": { "type": "string" }, "series": { "type": "string", "description": "Field name to group data points by (creates multiple colored series)" }, "label": { "type": "string", "description": "Field name for point labels shown in tooltips" }, "showLabels": { "type": "boolean", "description": "Show persistent labels next to points (requires label field)" }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" }, "xFormat": { "$ref": "#/$defs/FormatOption" }, "yFormat": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" } }, "additionalProperties": false }, "BoxplotChart": { "type": "object", "required": [ "type", "data", "categories" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "boxplot" }, "data": { "type": "array", "items": { "type": "array", "items": { "type": "number" }, "minItems": 5, "maxItems": 5, "description": "[min, Q1, median, Q3, max]" } }, "categories": { "type": "array", "items": { "type": "string" } }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "HistogramChart": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "histogram" }, "data": { "oneOf": [ { "type": "array", "items": { "type": "number" } }, { "$ref": "#/$defs/DataArray" } ] }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "value": { "type": "string" }, "bins": { "type": "integer", "default": 10 }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "WaterfallChart": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "waterfall" }, "data": { "type": "array", "items": { "type": "object", "properties": { "name": { "type": "string" }, "value": { "type": [ "number", "null" ] }, "type": { "enum": [ "total", "subtotal" ], "description": "Mark bar as total or subtotal (anchored at zero)" }, "isTotal": { "type": "boolean", "description": "Alternative to type: 'total' - marks bar as total (anchored at zero)" } } } }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "name": { "type": "string", "default": "name", "description": "Field name for category labels" }, "value": { "type": "string", "default": "value", "description": "Field name for numeric values" }, "x": { "type": "string", "description": "Alias for 'name' field (consistent with other chart types)" }, "y": { "type": "string", "description": "Alias for 'value' field (consistent with other chart types)" }, "title": { "type": "string" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "XmrChart": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "xmr" }, "data": { "oneOf": [ { "type": "array", "items": { "type": "number" } }, { "$ref": "#/$defs/DataArray" } ] }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "value": { "type": "string", "default": "value" }, "label": { "type": "string", "default": "label" }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" }, "nelson_rules": { "type": "boolean", "default": true }, "yMin": { "type": "number" }, "yMax": { "type": "number" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "SankeyChart": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "sankey" }, "data": { "type": "array", "items": { "type": "object", "required": [ "source", "target", "value" ], "properties": { "source": { "type": "string" }, "target": { "type": "string" }, "value": { "type": "number" } } } }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "nodes": { "type": "array", "items": { "type": "object" } }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "FunnelChart": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "funnel" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "name": { "type": "string" }, "value": { "type": "string" }, "title": { "type": "string" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "HeatmapChart": { "type": "object", "required": [ "type", "xCategories", "yCategories" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "heatmap" }, "data": { "type": "array", "items": { "oneOf": [ { "type": "array", "items": { "type": "number" }, "minItems": 3, "maxItems": 3 }, { "type": "object", "properties": { "x": {}, "y": {}, "value": { "type": "number" } } } ] } }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "xCategories": { "type": "array", "items": { "type": "string" } }, "yCategories": { "type": "array", "items": { "type": "string" } }, "title": { "type": "string" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "CalendarChart": { "type": "object", "required": [ "type", "year" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "calendar" }, "data": { "type": "array", "items": { "type": "object", "required": [ "date", "value" ], "properties": { "date": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "value": { "type": "number" } } } }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "year": { "type": "integer" }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "SparklineChart": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "sparkline" }, "data": { "oneOf": [ { "type": "array", "items": { "type": "number" } }, { "$ref": "#/$defs/DataArray" } ] }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "value": { "oneOf": [ { "type": "number" }, { "type": "string" } ], "description": "Numeric percentage for pct/pct_bar sparkType, or the data field name (string) whose values are plotted for line/bar/area/dumbbell sparkType." }, "sparkType": { "enum": [ "line", "bar", "area", "pct", "pct_bar" ], "default": "line" }, "title": { "type": "string" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "theme": { "$ref": "#/$defs/Theme" }, "showValue": { "type": "boolean", "default": true, "description": "Show the formatted value next to the bar (pct/pct_bar sparkType only)" } }, "additionalProperties": false }, "ComboChart": { "type": "object", "required": [ "type", "x" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "combo" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "x": { "type": "string" }, "bar": { "oneOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ] }, "line": { "oneOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ] }, "dualAxis": { "type": "boolean" }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" }, "format": { "$ref": "#/$defs/FormatOption" }, "secondaryFormat": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "yMin": { "type": "number" }, "yMax": { "type": "number" } }, "additionalProperties": false }, "DumbbellChart": { "type": "object", "required": [ "type", "category", "start", "end" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "dumbbell" }, "data": { "$ref": "#/$defs/DataArray" }, "columns": { "type": "array", "items": { "type": "string" }, "description": "Columnar form: column names. Use together with `rows` as an alternative to `data`." }, "rows": { "type": "array", "items": { "type": "array" }, "description": "Columnar form: row values. Use together with `columns` as an alternative to `data`." }, "category": { "type": "string" }, "start": { "type": "string" }, "end": { "type": "string" }, "startLabel": { "type": "string" }, "endLabel": { "type": "string" }, "higherIsBetter": { "type": "boolean", "default": true }, "showValues": { "type": "boolean", "default": true }, "title": { "type": "string" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "theme": { "$ref": "#/$defs/Theme" }, "xMin": { "type": "number" }, "xMax": { "type": "number" } }, "additionalProperties": false, "anyOf": [ { "required": [ "data" ] }, { "required": [ "columns", "rows" ] } ] }, "MermaidChart": { "type": "object", "required": [ "type", "code" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "mermaid" }, "code": { "oneOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Mermaid diagram syntax as string or array of lines (joined with newlines)" }, "title": { "type": "string" }, "height": { "type": "number", "default": 400 }, "theme": { "$ref": "#/$defs/Theme" }, "ascii": { "type": "boolean", "default": false, "description": "Render as ASCII/Unicode text art instead of SVG" }, "useAscii": { "type": "boolean", "default": false, "description": "When ascii=true, use pure ASCII instead of Unicode box-drawing characters" } }, "additionalProperties": false }, "BigValue": { "type": "object", "required": [ "type", "value" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "big_value" }, "value": { "type": "number" }, "title": { "type": "string", "description": "If only title is provided (no label), used as label below number. If both provided, title becomes H2 header above." }, "label": { "type": "string", "description": "Text displayed below the number" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "comparison": { "type": "object", "properties": { "value": { "type": "number" }, "label": { "type": "string" }, "format": { "$ref": "#/$defs/FormatOption" } } }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "Delta": { "type": "object", "required": [ "type", "value" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "delta" }, "value": { "type": "number" }, "title": { "type": "string", "description": "If only title is provided (no label), used as label below value. If both provided, title becomes header above." }, "label": { "type": "string", "description": "Text displayed below the delta value" }, "format": { "$ref": "#/$defs/FormatOption" }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "positiveIsGood": { "type": "boolean", "default": true }, "neutralIs": { "type": "number", "default": 0, "description": "Value treated as neutral (no change). When value === neutralIs, the indicator uses a right-arrow and muted color instead of green/red." }, "comparison": { "type": "object", "properties": { "value": { "type": "number" }, "label": { "type": "string" }, "format": { "$ref": "#/$defs/FormatOption" } } }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "Alert": { "type": "object", "required": [ "type" ], "anyOf": [ { "required": [ "message" ] }, { "required": [ "content" ] } ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "alert" }, "message": { "type": "string" }, "content": { "type": "string", "description": "Alias for message (deprecated, use message)" }, "alertType": { "enum": [ "info", "success", "warning", "error" ], "default": "info" }, "theme": { "$ref": "#/$defs/Theme" }, "title": { "type": "string" } }, "additionalProperties": false }, "Note": { "type": "object", "required": [ "type", "content" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "note" }, "content": { "type": "string" }, "label": { "type": "string" }, "noteType": { "enum": [ "default", "warning", "tip" ], "default": "default" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "Text": { "type": "object", "required": [ "type", "content" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "text" }, "content": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "Textarea": { "type": "object", "required": [ "type", "content" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "textarea" }, "content": { "type": "string" }, "title": { "type": "string" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "EmptySpace": { "type": "object", "required": [ "type" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "empty_space" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false }, "TableColumnDef": { "type": "object", "required": [ "id" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "id": { "type": "string" }, "title": { "type": "string" }, "align": { "enum": [ "left", "center", "right" ] }, "fmt": { "$ref": "#/$defs/TableColumnFormatOption" }, "bold": { "type": "boolean" }, "italic": { "type": "boolean" }, "type": { "enum": [ "sparkline", "heatmap" ] }, "sparkType": { "enum": [ "line", "bar", "area", "pct_bar", "dumbbell" ] }, "width": { "type": "integer" }, "higherIsBetter": { "type": "boolean" } }, "additionalProperties": false }, "Table": { "type": "object", "required": [ "type", "data" ], "properties": { "$schema": { "type": "string", "format": "uri" }, "type": { "const": "table" }, "data": { "$ref": "#/$defs/DataArray" }, "title": { "type": "string" }, "columns": { "type": "array", "items": { "$ref": "#/$defs/TableColumnDef" } }, "striped": { "type": "boolean", "default": true }, "compact": { "type": "boolean" }, "sortable": { "type": "boolean", "default": true, "description": "Enable click-to-sort on column headers. Cycles asc \u2192 desc \u2192 none. Numeric columns sort by raw value." }, "filter": { "type": "boolean", "default": false, "description": "When true, render a global search input above the table that filters rows by case-insensitive contains match on any cell." }, "currency": { "$ref": "#/$defs/CurrencyCode" }, "theme": { "$ref": "#/$defs/Theme" } }, "additionalProperties": false } } }