feat: 接入新动作 update_canvas
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
"""仅更新画布属性,不修改组件或数据源"""
|
||||
|
||||
from typing import Literal
|
||||
|
||||
from pydantic import Field, JsonValue
|
||||
|
||||
from app.schemas.base import NonBlankString
|
||||
|
||||
from .base import ActionModel
|
||||
|
||||
|
||||
class UpdateCanvasAction(ActionModel):
|
||||
type: Literal["update_canvas"] = "update_canvas"
|
||||
properties: dict[NonBlankString, JsonValue] = Field(
|
||||
min_length=1,
|
||||
description="要替换的 canvas 顶层字段,如 width、height、backgroundColor;未提供的字段保持不变",
|
||||
)
|
||||
Reference in New Issue
Block a user