skills/modelscope.cn/gallery-editor-child-sdk

gallery-editor-child-sdk

Installation
SKILL.md

Gallery Editor Child SDK

概述

本 Skill 描述了 Gallery 静态网页(子页面)如何通过 Penpal 接收 ModelScope 主站 Gallery Editor(父页面)注入的编辑能力。

子页面被嵌入 /tools/gallery-editor?galleryId=xx/xx 的 iframe 中时,父页面通过 Penpal 向其注入三个方法:

  • getConfig() — 获取 config.json 的完整内容
  • saveConfig(json) — 整体覆盖写入 config.json
  • uploadAsset(fileBase64, filename) — 上传文件到 assets 目录,返回相对路径

前提条件

  • 子页面需引入 Penpal v6.x
  • 子页面需被 g-{gid}.ms.show 域名托管(即存储在 Gallery 中的静态 HTML)

接口协议

Installs
2
First Seen
Jun 17, 2026
gallery-editor-child-sdk from modelscope.cn