mirror of
https://github.com/lobehub/lobehub.git
synced 2026-09-20 04:56:13 +08:00
5097c0e8b8
* ✨ feat: add artifact deployment business extension slots * ✨ feat: add BusinessResourceRoutes slot and ResourceCategories hook Open extension points so a cloud-only `/resource/artifacts` page can mount inside the shared `/resource` layout and surface in the CategoryMenu next to All / Documents / Images / Audios / Videos. OSS defaults to no-op (empty array, empty hook), so self-hosted users see the unchanged CategoryMenu and a 404 if they navigate to /resource/artifacts. * 🐛 fix(spa-routes): nest BusinessResourceRoutes under (home) layout Business-injected /resource child routes were spread at the outer resource layout level, so they rendered without the home Sidebar (which hosts CategoryMenu). Move the spread into the (home) group's children so injected pages inherit ResourceHomeLayout's Sidebar. Both desktopRouter.config.tsx and desktopRouter.config.desktop.tsx updated to keep them in sync (sync test still passes). * ✨ feat(resource): artifact revision history i18n + category menu key cast * ✨ feat(artifact-history): add per-release public URL i18n + tweak artifact render spacing Adds locale keys for the revoked tag, revision URL copy/open actions, and updates restoreSuccess copy to reflect alias-switch semantics. Render: nbsp around the identifier separator so the title row doesn't wrap awkwardly when actions appear. * ♻️ refactor(artifact): extract React renderer template into builtin-skills Move React artifact sandbox setup (dependencies, files, external resources) into a reusable buildReactArtifactProject in @lobechat/builtin-skills so non-renderer call sites (cloud artifact host, future renderers) can share the same project shape. * ✨ feat(artifact-history): i18n for compare modal layout Add restoreTo / dayLabel.today / dayLabel.yesterday keys to support the new ArtifactReleaseHistoryModal compare layout (cmpbar Restore button, sidebar day-group headers). * ✨ feat(builtin-skills): React artifact template with vite base='./' Set base: './' in the default vite config so the same dist works at both the live subdomain root and at /v<N>/ per-release immutable URLs. Absolute paths broke the per-release case: the browser resolves <script src='/assets/...'> against the subdomain root, bypassing the /v<N>/ prefix and pulling assets from the LIVE manifest instead of the requested release's manifest. Also expose REACT_ARTIFACT_BOOTSTRAP_PATH so callers can address the JS bootstrap module separately from the HTML entry, and pin react/react-dom to 18.3.1 (avoids React 18 vs 19 ABI mismatch through esm.sh *-prefix mode). * ✨ feat(chat): add `building` status label for v2.2 async deployments The market DTO now returns status='building' between the publish call and the builder callback finalizing the release. Cloud UI surfaces this state via the deployments sidebar tag — add the en-US source + zh-CN translation + default locale TS source. * ✨ feat(chat): buildFailedFallback i18n for building artifact deployments When a deployment is still 'active' (the previous release serves) but the last build attempt failed/timed out, the sidebar surfaces a warning icon with this message in a tooltip. en-US + zh-CN both added. * ✨ feat: centralize artifact template package * ✨ feat(artifact): pin lucide-react 0.x + add deployment failed/retry i18n - Pin lucide-react to ^0.544.0 in artifact-template. AI training data still emits the 0.x icon names (Github, Twitter); lucide-react 1.x renamed/dropped both, causing every generated React artifact to fail vite build with [MISSING_EXPORT] errors. Sync regenerates the builder's preinstall set. - Add workingPanel.deployments.status.failed for the new 'failed' DTO state (deployment active but no release shipped + last build terminal-failed), and workingPanel.deployments.retry.{title,success, failed,noSource} for the sidebar retry button on failed deployments. * ✅ test(agent): stub chat store and business sidebar tabs in WorkingSidebar test * ✨ feat(labs): add enableArtifactDeployment lab flag
12 lines
201 B
JSON
12 lines
201 B
JSON
{
|
|
"name": "@lobechat/artifact-template",
|
|
"version": "1.0.0",
|
|
"private": true,
|
|
"type": "module",
|
|
"exports": {
|
|
".": "./src/index.ts"
|
|
},
|
|
"main": "./src/index.ts",
|
|
"dependencies": {}
|
|
}
|