Photo kit command
style.presets.edit
Edit Style Presets
Edits the preset library (`action`: rename, delete, move, newGroup, renameGroup, deleteGroup on `preset`/`group`); app-wide, not the document.
- Kit
- Photo 0.1.0 (PSD, PSB, or .kphoto)
- Changes the document
- yes
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
action | "rename" | "delete" | "move" | "newGroup" | "renameGroup" | "deleteGroup" | no | |
coalesce | string | no | Merges consecutive edits with the same key into one undo step, as a slider drag or a typing session is one. |
group | string | no | narrows the lookup; the group for renameGroup/deleteGroup |
index | integer | no | move |
name | string | no | rename: new name; newGroup/renameGroup: group name |
preset | string | string[] | no | name|[names] (rename/delete/move); rename/delete/move |
to | string | no | group (move); move |
Call through photo_run
text
photo_run {
"path": "<file>.psd",
"steps": [{ "command": "style.presets.edit" }]
}The required parameters, with placeholders for their types: not a tested example. Optional: action, coalesce, group, index, name, preset, to. photo_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": {
"action": {
"enum": [
"rename",
"delete",
"move",
"newGroup",
"renameGroup",
"deleteGroup"
],
"type": "string"
},
"coalesce": {
"description": "Merges consecutive edits with the same key into one undo step, as a slider drag or a typing session is one.",
"type": "string"
},
"group": {
"description": "narrows the lookup; the group for renameGroup/deleteGroup",
"type": "string",
"x-khp-name": "name",
"x-khp-types": []
},
"index": {
"description": "move",
"type": "integer"
},
"name": {
"description": "rename: new name; newGroup/renameGroup: group name",
"type": "string"
},
"preset": {
"description": "name|[names] (rename/delete/move); rename/delete/move",
"oneOf": [
{
"type": "string"
},
{
"items": {
"type": "string"
},
"type": "array"
}
],
"x-khp-name": "name",
"x-khp-types": []
},
"to": {
"description": "group (move); move",
"type": "string",
"x-khp-name": "name",
"x-khp-types": []
}
},
"type": "object"
}Generated from the command list of @kition/[email protected] and the kit itself (photo_commands through @kition/[email protected], built from KitionAI/kition-photo@abe3f30). As data: commands.jsonl.