Slide kit command

chart.options

Chart Elements

Sets which chart elements show (title, legend position, data labels, gridlines), the colour palette (colorful1–4, monochrome1–13; others are refused), series colours, gap width and overlap of the selected or named chart.

Kit
Slide 0.1.0 (.kslide and .pptx)
Changes the document
yes
Acts on
id (one id), which a run step’s on fills

Parameters

Parameters of chart.options
NameTypeRequiredDescription
colorsstring[]noone per series, or per point when coloured by point
dataLabelsbooleanno
gapWidthintegerno0 to 500; %
gridlinesbooleanno
idinteger | stringno
legend"b" | "t" | "l" | "r" | nullnolegend position, null for none
onSlideintegernothe slide the ids are on, from 1
overlapintegerno-100 to 100; %
palettestringnoa palette name
titlestring | nullnochart title, null for none

Call through slide_run

text
slide_run {
  "path": "<file>.pptx",
  "steps": [{ "command": "chart.options" }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: colors, dataLabels, gapWidth, gridlines, id, legend, onSlide, overlap, palette, title. slide_run answers the step’s result in completed[i].result.

Result

The kit gives no result schema for this command.

Parameter schema

json
{
  "additionalProperties": false,
  "properties": {
    "colors": {
      "description": "one per series, or per point when coloured by point",
      "items": {
        "description": "a colour such as #rrggbb",
        "type": "string"
      },
      "type": "array"
    },
    "dataLabels": {
      "type": "boolean"
    },
    "gapWidth": {
      "description": "0 to 500; %",
      "type": "integer"
    },
    "gridlines": {
      "type": "boolean"
    },
    "id": {
      "oneOf": [
        {
          "type": "integer"
        },
        {
          "type": "string"
        }
      ],
      "x-khp-types": [
        "Shape"
      ]
    },
    "legend": {
      "description": "legend position, null for none",
      "oneOf": [
        {
          "enum": [
            "b",
            "t",
            "l",
            "r"
          ],
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "onSlide": {
      "description": "the slide the ids are on, from 1",
      "type": "integer"
    },
    "overlap": {
      "description": "-100 to 100; %",
      "type": "integer"
    },
    "palette": {
      "description": "a palette name",
      "type": "string"
    },
    "title": {
      "description": "chart title, null for none",
      "oneOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    }
  },
  "type": "object",
  "x-khp-position": "independent"
}

Generated from the command list of @kition/[email protected] and the kit itself (slide_commands through @kition/[email protected], built from KitionAI/kition-slide@7ef3d11). As data: commands.jsonl.