marketplace-add-extension
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAdd an Extension Point Route
添加扩展点路由
You are helping the user add a new extension point to their Sitecore Marketplace app.
你正在协助用户为其Sitecore Marketplace应用添加新的扩展点。
Step 1: Determine Extension Type
步骤1:确定扩展类型
Ask the user which type (or infer from $ARGUMENTS):
| Type | Slug | Description | Typical Size |
|---|---|---|---|
| Custom Field | | Inline field in content editor | ~300px wide |
| Dashboard Widget | | Widget on the dashboard | ~400x300px |
| Pages Context Panel | | Side panel in Pages editor | ~350px wide, full height |
| Fullscreen | | Full-page within Sitecore shell | Full viewport |
| Standalone | | Independent page | Full viewport |
询问用户所需的扩展类型(或从$ARGUMENTS中推断):
| 类型 | Slug | 描述 | 典型尺寸 |
|---|---|---|---|
| 自定义字段 | | 内容编辑器中的内嵌字段 | 宽约300px |
| 仪表盘Widget | | 仪表盘上的组件 | 约400x300px |
| 页面上下文面板 | | 页面编辑器中的侧边面板 | 宽约350px,全屏高 |
| 全屏 | | Sitecore shell内的全页面 | 完整视口 |
| 独立页面 | | 独立的页面 | 完整视口 |
Step 2: Generate the Route
步骤2:生成路由
Create the route at (or a custom path the user prefers).
app/<extension-type>/page.tsxSee extension-types.md for complete boilerplate templates for each extension type.
在路径下创建路由(或用户偏好的自定义路径)。
app/<extension-type>/page.tsx查看extension-types.md获取每种扩展类型的完整样板模板。
Step 3: Register in Developer Portal
步骤3:在开发者门户注册
Remind the user to register the extension point in the Sitecore Developer Portal:
- Go to Developer Portal → Your App → Extension Points
- Click "Add Extension Point"
- Select the type and set the route path (e.g., )
/custom-field
提醒用户在Sitecore Developer Portal中注册该扩展点:
- 进入开发者门户 → 你的应用 → 扩展点
- 点击「添加扩展点」
- 选择类型并设置路由路径(例如)
/custom-field
Step 4: Suggest Next Steps
步骤4:后续操作建议
- Use to build out the UI
/marketplace-build-component - Use to look up available queries/mutations for this extension type
/marketplace-sdk-reference - Use if the extension needs XM Cloud data
/marketplace-add-xmc
- 使用构建UI
/marketplace-build-component - 使用查询该扩展类型可用的queries/mutations
/marketplace-sdk-reference - 如果扩展需要XM Cloud数据,使用
/marketplace-add-xmc
Reference Files
参考文件
- Extension Types — Boilerplate templates for each extension type
- 扩展类型 — 各类扩展类型的样板模板