Vector kit command

transparency.set

Transparency

Sets opacity, blend mode, isolation and knockout of ids or the selection (or of one appearance item), as the Transparency panel does.

Kit
Vector 0.1.0 (.kvector)
Changes the document
yes
Acts on
ids (a list of ids), which a run step’s on fills

Parameters

Parameters of transparency.set
NameTypeRequiredDescription
blendstringno
idintegernoobject ID
idsinteger[]noobject IDs
isolatebooleanno
iteminteger | nullno
knockout"on" | "off" | "neutral" | booleanno
knockoutShapebooleanno
opacityintegerno0 to 100
targetstringno"object" (default) or "contents": the objects themselves, or what their groups and layers hold

Call through vector_run

text
vector_run {
  "path": "<file>.kvector",
  "steps": [{ "command": "transparency.set" }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: blend, id, ids, isolate, item, knockout, knockoutShape, opacity, target. vector_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": {
    "blend": {
      "type": "string"
    },
    "id": {
      "description": "object ID",
      "type": "integer",
      "x-khp-types": [
        "Node"
      ]
    },
    "ids": {
      "description": "object IDs",
      "items": {
        "type": "integer"
      },
      "type": "array",
      "x-khp-types": [
        "Node"
      ]
    },
    "isolate": {
      "type": "boolean"
    },
    "item": {
      "oneOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "knockout": {
      "oneOf": [
        {
          "enum": [
            "on",
            "off",
            "neutral"
          ],
          "type": "string"
        },
        {
          "type": "boolean"
        }
      ]
    },
    "knockoutShape": {
      "type": "boolean"
    },
    "opacity": {
      "description": "0 to 100",
      "type": "integer"
    },
    "target": {
      "description": "\"object\" (default) or \"contents\": the objects themselves, or what their groups and layers hold",
      "type": "string"
    }
  },
  "type": "object"
}

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