Slide kit command

media.options

Playback

Sets audio/video playback options (autoplay, loop, rewind, volume, trim, fade). Applies to the shapes in `ids` (on slide `onSlide`, from 1) or else the selection.

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

Parameters

Parameters of media.options
NameTypeRequiredDescription
acrossSlidesbooleanno
autoplaybooleanno
fadeInnumbernomilliseconds
fadeOutnumbernomilliseconds
fullScreenbooleanno
hidebooleannohide while not playing
ids(integer | string)[]no
loopbooleanno
onSlideintegernothe slide the ids are on, from 1
rewindbooleannorewind after playing
trimEndnumbernomilliseconds
trimStartnumbernomilliseconds
volumenumber (≥ 0, ≤ 1)no0 to 1

Call through slide_run

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

The required parameters, with placeholders for their types: not a tested example. Optional: acrossSlides, autoplay, fadeIn, fadeOut, fullScreen, hide, ids, loop, onSlide, rewind, trimEnd, trimStart, volume. 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": {
    "acrossSlides": {
      "type": "boolean"
    },
    "autoplay": {
      "type": "boolean"
    },
    "fadeIn": {
      "description": "milliseconds",
      "type": "number"
    },
    "fadeOut": {
      "description": "milliseconds",
      "type": "number"
    },
    "fullScreen": {
      "type": "boolean"
    },
    "hide": {
      "description": "hide while not playing",
      "type": "boolean"
    },
    "ids": {
      "items": {
        "description": "an id",
        "oneOf": [
          {
            "type": "integer"
          },
          {
            "type": "string"
          }
        ]
      },
      "type": "array",
      "x-khp-types": [
        "Shape"
      ]
    },
    "loop": {
      "type": "boolean"
    },
    "onSlide": {
      "description": "the slide the ids are on, from 1",
      "type": "integer"
    },
    "rewind": {
      "description": "rewind after playing",
      "type": "boolean"
    },
    "trimEnd": {
      "description": "milliseconds",
      "type": "number"
    },
    "trimStart": {
      "description": "milliseconds",
      "type": "number"
    },
    "volume": {
      "description": "0 to 1",
      "maximum": 1,
      "minimum": 0,
      "type": "number"
    }
  },
  "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.