@starcier/builder-shell

中文文档
1.0.0发布于 2026/11/02MITTypeScriptES Module零依赖

The app frame of a Starcier builder: sign-in, the share and invite pages, the access-aware catalogue and the prototype routes, around the collaboration layer.

原始使用文档
文档目录4 节
  1. Install
  2. Use
  3. Stacking order
  4. License

@starcier/builder-shell

A whole Starcier prototype builder around your prototypes: sign-in, the catalogue, the prototype routes, the password-share and invite pages, and the collaboration layer (comments and guided tours). You supply your palette, your prototypes and your configuration; nothing here knows your design system.

Install

npm install @starcier/collab-core@next @starcier/collab-ui@next @starcier/builder-shell@next react-router @auth0/auth0-react

Until 1.0.0 is released, versions are prereleases (1.0.0-next.N): always install with @next. Without it, npm installs the first prerelease, not the newest. Requires React 18 or 19, react-router 7 or 8, and @auth0/auth0-react 2.

Use

Render it inside your router:

import { BuilderShell } from '@starcier/builder-shell';

<BrowserRouter>
  <BuilderShell
    palette={palette}               // a BuilderPalette resolved from your design tokens
    prototypes={prototypes}         // [{ slug, title, component }, …]
    apiBaseUrl={API_BASE_URL}       // the API origin, without /v1
    tenant={TENANT_SLUG}            // your builder's tenant slug
    auth={{ domain, clientId, audience }}
  />
</BrowserRouter>

Leave out apiBaseUrl and auth to run against localStorage, with no sign-in and no backend — useful for design work. Keep tenant set even then: it keeps this builder's local comments and tours apart from other builders on the same origin, such as localhost. Auth0's code is loaded only when auth is set.

The shell serves /share/:id and /invite/:token, so your host must send unknown paths to index.html, as for any single-page app.

Stacking order

z-indexWhat
200The shell's top bar
9140–10000Comments and tours

Give your own modals and drawers a z-index between the two: above the bar, so a dialog covers it, and below 9140, so comments and tours appear above your dialogs.

The Review toggle lives in the bar, so it is out of reach while a dialog is open. That matches what review mode can do: dialog content cannot be reviewed, and comments go on the page itself.

On a Next.js app, or one with its own router and sign-in, use @starcier/collab-core and @starcier/collab-ui directly instead.

License

MIT

版本与发布记录

@starcier/builder-shell 共发布 7 个版本,首次发布于 2026/10/23;过去 12 个月发布了 7 个版本。

版本发布日期距今
1.0.0latest2026/11/021 天前
1.0.0-next.4next2026/10/303 天前
1.0.0-next.32026/10/294 天前
1.0.0-next.22026/10/2310 天前
1.0.0-next.12026/10/2311 天前
1.0.0-next.02026/10/2311 天前

关于 @starcier/builder-shell 的常见问题

@starcier/builder-shell 是什么?

Starcier构建器的应用框架:围绕协作层的登录、共享和邀请页面、访问感知目录和原型路由。

如何安装 @starcier/builder-shell?

在项目目录运行 npm install @starcier/builder-shell,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:react(^18.0.0 || ^19.0.0)、react-dom(^18.0.0 || ^19.0.0)、react-router(^7.0.0 || ^8.0.0)、@auth0/auth0-react(^2.0.0)、@starcier/collab-ui(^1.0.0)、@starcier/collab-core(^1.0.0)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@starcier/builder-shell 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@starcier/builder-shell 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@starcier/builder-shell 可以商用吗?

@starcier/builder-shell 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@starcier/builder-shell 还在维护吗?

最新版本 1.0.0 发布于 2026/11/02(1 天前);至今共发布 7 个版本,其中过去 12 个月发布了 7 个;首次发布于 2026/10/23。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。