@molecule/app-ide-react 1.3.0 → 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -4
- package/dist/components/ChatPanel.d.ts +3 -1
- package/dist/components/ChatPanel.d.ts.map +1 -1
- package/dist/components/ChatPanel.js +15 -4
- package/dist/components/ChatPanel.js.map +1 -1
- package/dist/components/PreviewPanel.d.ts.map +1 -1
- package/dist/components/PreviewPanel.js +69 -37
- package/dist/components/PreviewPanel.js.map +1 -1
- package/dist/types.d.ts +8 -3
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js.map +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@ AUTO-GENERATED — DO NOT EDIT THIS FILE.
|
|
|
3
3
|
Generated by `mlcl sync-docs` from the package's src/index.ts JSDoc + mlcl/registry.json.
|
|
4
4
|
Edits here are overwritten on the next commit (molecule's pre-commit hook regenerates).
|
|
5
5
|
To change this document, edit the module-level JSDoc in src/index.ts.
|
|
6
|
-
Generated: 2026-08-
|
|
6
|
+
Generated: 2026-08-18T16:06:01.076Z
|
|
7
7
|
-->
|
|
8
8
|
|
|
9
9
|
# @molecule/app-ide-react
|
|
@@ -388,9 +388,14 @@ interface ChatPanelProps {
|
|
|
388
388
|
* Whether the current user is anonymous. The shared IDE no longer renders any
|
|
389
389
|
* built-in sign-up/guest card itself — guest reminders now arrive as a `custom`
|
|
390
390
|
* stream event the host registers via {@link registerCustomEventCard}, and upgrade
|
|
391
|
-
* call-to-actions come from {@link ChatPanelProps.buildUpgradeCta}
|
|
392
|
-
*
|
|
393
|
-
*
|
|
391
|
+
* call-to-actions come from {@link ChatPanelProps.buildUpgradeCta}, and the host's own
|
|
392
|
+
* `buildUpgradeCta` closure decides whether an anonymous user should sign up vs. upgrade.
|
|
393
|
+
*
|
|
394
|
+
* It IS read for one thing: a limit error the backend raised for an anonymous caller
|
|
395
|
+
* (`requiresSignup`) is dropped once this is explicitly `false` — the viewer signed in
|
|
396
|
+
* mid-session (the in-IDE auth modal never navigates, so the panel keeps running), and a
|
|
397
|
+
* "create a free account for more" banner with dead-end Sign up / Log in buttons is stale
|
|
398
|
+
* the moment they have an account. Leave it `undefined` and nothing is suppressed.
|
|
394
399
|
*/
|
|
395
400
|
isAnonymous?: boolean
|
|
396
401
|
/** When true, user has a paid plan and can use all models (drives locked-model display). */
|
|
@@ -1665,6 +1670,7 @@ function ChatPanel({
|
|
|
1665
1670
|
userEditedFile,
|
|
1666
1671
|
userEditedFileKey,
|
|
1667
1672
|
isPro,
|
|
1673
|
+
isAnonymous,
|
|
1668
1674
|
buildUpgradeCta,
|
|
1669
1675
|
buildHelpUpgradeSection,
|
|
1670
1676
|
userAvatar,
|
|
@@ -99,6 +99,8 @@ export interface ChatInnerProps {
|
|
|
99
99
|
initialMessage?: string;
|
|
100
100
|
onInitialMessageSent?: () => void;
|
|
101
101
|
isPro?: boolean;
|
|
102
|
+
/** Whether the viewer is anonymous — see {@link ChatPanelProps.isAnonymous}. */
|
|
103
|
+
isAnonymous?: boolean;
|
|
102
104
|
/** Host-supplied upgrade/sign-in CTA builder — see {@link ChatPanelProps.buildUpgradeCta}. */
|
|
103
105
|
buildUpgradeCta?: ChatPanelProps['buildUpgradeCta'];
|
|
104
106
|
/** Host-supplied `/help` upgrade section builder — see {@link ChatPanelProps.buildHelpUpgradeSection}. */
|
|
@@ -178,7 +180,7 @@ export interface ChatInnerProps {
|
|
|
178
180
|
* @param props - Component props (see {@link MessageItemProps}).
|
|
179
181
|
* @returns The rendered chat panel element.
|
|
180
182
|
*/
|
|
181
|
-
export declare function ChatPanel({ projectId, endpoint, initialMessage, onInitialMessageSent, activeFile, openTabs, onFileOpen, onFileDoubleClick, onFileDiff, onFileRevert, onFileChange, onFileDeleted, onCommit, onActivityClick, onRenderError, onProfileClick, onReadyToBuild, awaitingSandboxBoot, onClientAction, onTurnComplete, onLoadingChange, onNavigatePreview, onRegisterPushHandler, autoSubmitSignal, initialInputValue, hideConversationMenu, renderConversationHeader, conversationId: controlledConversationId, chatKey: controlledChatKey, onConversationId: controlledOnConversationId, openShareSignal: controlledShareSignal, openReportSignal: controlledReportSignal, openSettingsSignal: controlledSettingsSignal, onManageCustomModels, gitStatusTick, pendingMessage, pendingMessageKey, pendingMessageSuppressUser, pendingMessageUserInitiated, userEditedFile, userEditedFileKey, isPro, buildUpgradeCta, buildHelpUpgradeSection, userAvatar, agentName, productName, version, feedbackUrl, className, }: ChatPanelProps): JSX.Element;
|
|
183
|
+
export declare function ChatPanel({ projectId, endpoint, initialMessage, onInitialMessageSent, activeFile, openTabs, onFileOpen, onFileDoubleClick, onFileDiff, onFileRevert, onFileChange, onFileDeleted, onCommit, onActivityClick, onRenderError, onProfileClick, onReadyToBuild, awaitingSandboxBoot, onClientAction, onTurnComplete, onLoadingChange, onNavigatePreview, onRegisterPushHandler, autoSubmitSignal, initialInputValue, hideConversationMenu, renderConversationHeader, conversationId: controlledConversationId, chatKey: controlledChatKey, onConversationId: controlledOnConversationId, openShareSignal: controlledShareSignal, openReportSignal: controlledReportSignal, openSettingsSignal: controlledSettingsSignal, onManageCustomModels, gitStatusTick, pendingMessage, pendingMessageKey, pendingMessageSuppressUser, pendingMessageUserInitiated, userEditedFile, userEditedFileKey, isPro, isAnonymous, buildUpgradeCta, buildHelpUpgradeSection, userAvatar, agentName, productName, version, feedbackUrl, className, }: ChatPanelProps): JSX.Element;
|
|
182
184
|
export declare namespace ChatPanel {
|
|
183
185
|
var displayName: string;
|
|
184
186
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChatPanel.d.ts","sourceRoot":"","sources":["../../src/components/ChatPanel.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAa,MAAM,OAAO,CAAA;AAY3C,OAAO,KAAK,EAAa,WAAW,EAAmB,MAAM,uBAAuB,CAAA;AAuCpF,OAAO,KAA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BAAgB,SAAS,CAAC,EACxB,SAAS,EACT,QAAQ,EACR,cAAc,EACd,oBAAoB,EACpB,UAAU,EACV,QAAQ,EACR,UAAU,EACV,iBAAiB,EACjB,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,aAAa,EACb,QAAQ,EACR,eAAe,EACf,aAAa,EACb,cAAc,EACd,cAAc,EACd,mBAAmB,EACnB,cAAc,EACd,cAAc,EACd,eAAe,EACf,iBAAiB,EACjB,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,EACjB,oBAAoB,EACpB,wBAA+B,EAC/B,cAAc,EAAE,wBAAwB,EACxC,OAAO,EAAE,iBAAiB,EAC1B,gBAAgB,EAAE,0BAA0B,EAC5C,eAAe,EAAE,qBAAqB,EACtC,gBAAgB,EAAE,sBAAsB,EACxC,kBAAkB,EAAE,wBAAwB,EAC5C,oBAAoB,EACpB,aAAa,EACb,cAAc,EACd,iBAAiB,EACjB,0BAA0B,EAC1B,2BAA2B,EAC3B,cAAc,EACd,iBAAiB,EACjB,KAAK,EACL,WAAW,EACX,eAAe,EACf,uBAAuB,EACvB,UAAU,EACV,SAAS,EACT,WAAW,EACX,OAAO,EACP,WAAW,EACX,SAAS,GACV,EAAE,cAAc,GAAG,GAAG,CAAC,OAAO,CA6b9B;yBAjfe,SAAS"}
|
|
@@ -1246,7 +1246,7 @@ const MessageItem = memo(function MessageItem(props) {
|
|
|
1246
1246
|
* @param props - Component props (see {@link MessageItemProps}).
|
|
1247
1247
|
* @returns The rendered chat inner component.
|
|
1248
1248
|
*/
|
|
1249
|
-
function ChatInner({ projectId, endpoint, initialMessage, onInitialMessageSent, isPro, buildUpgradeCta, buildHelpUpgradeSection, activeFile, openTabs, onFileOpen, onFileDoubleClick, onFileDiff, onFileRevert, onFileChange, onFileDeleted, onCommit, onConversationId, onActivityClick, onRenderError, onProfileClick, onReadyToBuild, awaitingSandboxBoot, onClientAction, onTurnComplete, onLoadingChange, onNavigatePreview, onRegisterPushHandler, autoSubmitSignal, openSettingsSignal, onManageCustomModels, openReportSignal, openShareSignal, initialInputValue, pendingMessage, pendingMessageKey, pendingMessageSuppressUser, pendingMessageUserInitiated, userEditedFile, userEditedFileKey, gitStatusTick: externalGitStatusTick, discovery, userAvatar, agentName = DEFAULT_AGENT_NAME, productName = DEFAULT_PRODUCT_NAME, version,
|
|
1249
|
+
function ChatInner({ projectId, endpoint, initialMessage, onInitialMessageSent, isPro, isAnonymous, buildUpgradeCta, buildHelpUpgradeSection, activeFile, openTabs, onFileOpen, onFileDoubleClick, onFileDiff, onFileRevert, onFileChange, onFileDeleted, onCommit, onConversationId, onActivityClick, onRenderError, onProfileClick, onReadyToBuild, awaitingSandboxBoot, onClientAction, onTurnComplete, onLoadingChange, onNavigatePreview, onRegisterPushHandler, autoSubmitSignal, openSettingsSignal, onManageCustomModels, openReportSignal, openShareSignal, initialInputValue, pendingMessage, pendingMessageKey, pendingMessageSuppressUser, pendingMessageUserInitiated, userEditedFile, userEditedFileKey, gitStatusTick: externalGitStatusTick, discovery, userAvatar, agentName = DEFAULT_AGENT_NAME, productName = DEFAULT_PRODUCT_NAME, version,
|
|
1250
1250
|
// feedbackUrl: prop kept for back-compat (callers still pass it), but no longer
|
|
1251
1251
|
// consumed here — its only use was the command-menu footer link removed in P3-21.
|
|
1252
1252
|
}) {
|
|
@@ -4725,6 +4725,15 @@ function ChatInner({ projectId, endpoint, initialMessage, onInitialMessageSent,
|
|
|
4725
4725
|
return null;
|
|
4726
4726
|
}
|
|
4727
4727
|
}, [t, AVAILABLE_MODELS, effectiveModelRegion]);
|
|
4728
|
+
// A limit the backend raised for an ANONYMOUS caller — `requiresSignup`, whose
|
|
4729
|
+
// whole message is "…for guests … or create a free account for more" and whose
|
|
4730
|
+
// CTAs are Sign up / Log in — is STALE the moment the viewer signs in: they now
|
|
4731
|
+
// have an account, a different allowance, and two dead-end buttons. The error
|
|
4732
|
+
// state survives the in-place auth modal (nothing navigates, and useChat only
|
|
4733
|
+
// clears it on the next send), so without this the freshly-signed-up user keeps
|
|
4734
|
+
// reading the guest limit they just escaped. Same reasoning the host's
|
|
4735
|
+
// `upgrade_prompt` card factory already applies to the recorded guest card.
|
|
4736
|
+
const isStaleAnonymousLimit = errorMeta?.requiresSignup === true && isAnonymous === false;
|
|
4728
4737
|
const timeline = useMemo(() => {
|
|
4729
4738
|
const items = [];
|
|
4730
4739
|
// A card-message (role:'system' carrying a cardEvent) renders as a SYSTEM CARD, not a chat
|
|
@@ -4738,7 +4747,7 @@ function ChatInner({ projectId, endpoint, initialMessage, onInitialMessageSent,
|
|
|
4738
4747
|
// clears). The banner stays: it is the refused send's only feedback, and its message
|
|
4739
4748
|
// can be the more specific one (platform capacity vs the user's own budget, same
|
|
4740
4749
|
// `limitType`). See {@link ChatEventCard.coversLimitType}.
|
|
4741
|
-
const liveLimitType = error ? errorMeta?.limitType : undefined;
|
|
4750
|
+
const liveLimitType = error && !isStaleAnonymousLimit ? errorMeta?.limitType : undefined;
|
|
4742
4751
|
for (const msg of visibleMessages) {
|
|
4743
4752
|
if (msg.cardEvent) {
|
|
4744
4753
|
const card = cardEventToSystemCard(msg.cardEvent, msg.id, msg.timestamp);
|
|
@@ -4769,6 +4778,7 @@ function ChatInner({ projectId, endpoint, initialMessage, onInitialMessageSent,
|
|
|
4769
4778
|
tipCards,
|
|
4770
4779
|
error,
|
|
4771
4780
|
errorMeta,
|
|
4781
|
+
isStaleAnonymousLimit,
|
|
4772
4782
|
]);
|
|
4773
4783
|
// The live settings list for the /settings card. Shared by the closeable
|
|
4774
4784
|
// overlay and the legacy inline 'settings' branch (back-compat for any already
|
|
@@ -4997,6 +5007,7 @@ function ChatInner({ projectId, endpoint, initialMessage, onInitialMessageSent,
|
|
|
4997
5007
|
}
|
|
4998
5008
|
return (_jsx(MessageItem, { msg: msg, editingQueuedId: editingQueuedId, editingQueuedText: editingQueuedText, setEditingQueuedId: setEditingQueuedId, setEditingQueuedText: setEditingQueuedText, editQueuedMessage: editQueuedMessage, deleteQueuedMessage: deleteQueuedMessage, sendMessage: sendMessage, handleAskUserResponse: handleAskUserResponse, isLoading: isLoading, streamingStatus: streamingStatus, onNavigatePreview: onNavigatePreview, undoneTcIds: undoneTcIds, handleUndoToggle: handleUndoToggle, onFileOpen: onFileOpen, onFileDoubleClick: onFileDoubleClick, onFileDiff: onFileDiff, handleFileRevert: handleFileRevert, setInputAndCursorEnd: setInputAndCursorEnd, setModelPicker: setModelPicker, userAvatar: userAvatar, onAvatarClick: onUserAvatarClick, discovery: discovery, buildUpgradeCta: buildUpgradeCta }, msg.id));
|
|
4999
5009
|
} }, item.kind === 'message' ? item.msg.id : item.card.id))), error &&
|
|
5010
|
+
!isStaleAnonymousLimit &&
|
|
5000
5011
|
(errorMeta?.limitType ? (_jsx(ResourceLimitBanner, { message: error, action: buildUpgradeCta?.({ requiresSignup: errorMeta.requiresSignup }) })) : (_jsx("div", { className: cm.cn(cm.textSize('sm'), cm.sp('p', 2), cm.sp('mb', 2), cm.bgErrorSubtle, cm.textError), style: { borderRadius: '6px' }, children: error }))), (() => {
|
|
5001
5012
|
const showActivity = isLoading || awaitingSandboxBoot;
|
|
5002
5013
|
const streamingMsg = isLoading
|
|
@@ -6599,7 +6610,7 @@ function ChatInner({ projectId, endpoint, initialMessage, onInitialMessageSent,
|
|
|
6599
6610
|
* @param props - Component props (see {@link MessageItemProps}).
|
|
6600
6611
|
* @returns The rendered chat panel element.
|
|
6601
6612
|
*/
|
|
6602
|
-
export function ChatPanel({ projectId, endpoint, initialMessage, onInitialMessageSent, activeFile, openTabs, onFileOpen, onFileDoubleClick, onFileDiff, onFileRevert, onFileChange, onFileDeleted, onCommit, onActivityClick, onRenderError, onProfileClick, onReadyToBuild, awaitingSandboxBoot, onClientAction, onTurnComplete, onLoadingChange, onNavigatePreview, onRegisterPushHandler, autoSubmitSignal, initialInputValue, hideConversationMenu, renderConversationHeader = true, conversationId: controlledConversationId, chatKey: controlledChatKey, onConversationId: controlledOnConversationId, openShareSignal: controlledShareSignal, openReportSignal: controlledReportSignal, openSettingsSignal: controlledSettingsSignal, onManageCustomModels, gitStatusTick, pendingMessage, pendingMessageKey, pendingMessageSuppressUser, pendingMessageUserInitiated, userEditedFile, userEditedFileKey, isPro, buildUpgradeCta, buildHelpUpgradeSection, userAvatar, agentName, productName, version, feedbackUrl, className, }) {
|
|
6613
|
+
export function ChatPanel({ projectId, endpoint, initialMessage, onInitialMessageSent, activeFile, openTabs, onFileOpen, onFileDoubleClick, onFileDiff, onFileRevert, onFileChange, onFileDeleted, onCommit, onActivityClick, onRenderError, onProfileClick, onReadyToBuild, awaitingSandboxBoot, onClientAction, onTurnComplete, onLoadingChange, onNavigatePreview, onRegisterPushHandler, autoSubmitSignal, initialInputValue, hideConversationMenu, renderConversationHeader = true, conversationId: controlledConversationId, chatKey: controlledChatKey, onConversationId: controlledOnConversationId, openShareSignal: controlledShareSignal, openReportSignal: controlledReportSignal, openSettingsSignal: controlledSettingsSignal, onManageCustomModels, gitStatusTick, pendingMessage, pendingMessageKey, pendingMessageSuppressUser, pendingMessageUserInitiated, userEditedFile, userEditedFileKey, isPro, isAnonymous, buildUpgradeCta, buildHelpUpgradeSection, userAvatar, agentName, productName, version, feedbackUrl, className, }) {
|
|
6603
6614
|
const cm = getClassMap();
|
|
6604
6615
|
const isNarrow = useNarrowViewport();
|
|
6605
6616
|
const isCoarse = useCoarsePointer();
|
|
@@ -6808,7 +6819,7 @@ export function ChatPanel({ projectId, endpoint, initialMessage, onInitialMessag
|
|
|
6808
6819
|
textOverflow: 'ellipsis',
|
|
6809
6820
|
whiteSpace: 'nowrap',
|
|
6810
6821
|
width: '100%',
|
|
6811
|
-
}, children: conv.preview ?? 'New conversation' }), _jsx("span", { className: cm.cn(cm.textMuted, cm.textSize('xs')), style: { opacity: 0.55 }, children: relativeTime(conv.updatedAt) })] }, conv.id)))] }))] })), _jsx(ChatInner, { projectId: projectId, endpoint: chatEndpoint, initialMessage: initialMessage, onInitialMessageSent: onInitialMessageSent, isPro: isPro, buildUpgradeCta: buildUpgradeCta, buildHelpUpgradeSection: buildHelpUpgradeSection, activeFile: activeFile, openTabs: openTabs, onFileOpen: onFileOpen, onFileDoubleClick: onFileDoubleClick, onFileDiff: onFileDiff, onFileRevert: onFileRevert, onFileChange: onFileChange, onFileDeleted: onFileDeleted, onCommit: onCommit, onConversationId: reportConversationId, onActivityClick: onActivityClick, onRenderError: onRenderError, onProfileClick: onProfileClick, onReadyToBuild: onReadyToBuild, awaitingSandboxBoot: awaitingSandboxBoot, onClientAction: onClientAction, onTurnComplete: onTurnComplete, onLoadingChange: onLoadingChange, onNavigatePreview: onNavigatePreview, onRegisterPushHandler: onRegisterPushHandler, autoSubmitSignal: autoSubmitSignal, openSettingsSignal: effectiveSettingsSignal, onManageCustomModels: onManageCustomModels, openReportSignal: effectiveReportSignal, openShareSignal: effectiveShareSignal, initialInputValue: initialInputValue, pendingMessage: pendingMessage, pendingMessageKey: pendingMessageKey, pendingMessageSuppressUser: pendingMessageSuppressUser, pendingMessageUserInitiated: pendingMessageUserInitiated, userEditedFile: userEditedFile, userEditedFileKey: userEditedFileKey, gitStatusTick: gitStatusTick, discovery: hideConversationMenu, userAvatar: userAvatar, agentName: agentName, productName: productName, version: version, feedbackUrl: feedbackUrl }, chatKey)] }));
|
|
6822
|
+
}, children: conv.preview ?? 'New conversation' }), _jsx("span", { className: cm.cn(cm.textMuted, cm.textSize('xs')), style: { opacity: 0.55 }, children: relativeTime(conv.updatedAt) })] }, conv.id)))] }))] })), _jsx(ChatInner, { projectId: projectId, endpoint: chatEndpoint, initialMessage: initialMessage, onInitialMessageSent: onInitialMessageSent, isPro: isPro, isAnonymous: isAnonymous, buildUpgradeCta: buildUpgradeCta, buildHelpUpgradeSection: buildHelpUpgradeSection, activeFile: activeFile, openTabs: openTabs, onFileOpen: onFileOpen, onFileDoubleClick: onFileDoubleClick, onFileDiff: onFileDiff, onFileRevert: onFileRevert, onFileChange: onFileChange, onFileDeleted: onFileDeleted, onCommit: onCommit, onConversationId: reportConversationId, onActivityClick: onActivityClick, onRenderError: onRenderError, onProfileClick: onProfileClick, onReadyToBuild: onReadyToBuild, awaitingSandboxBoot: awaitingSandboxBoot, onClientAction: onClientAction, onTurnComplete: onTurnComplete, onLoadingChange: onLoadingChange, onNavigatePreview: onNavigatePreview, onRegisterPushHandler: onRegisterPushHandler, autoSubmitSignal: autoSubmitSignal, openSettingsSignal: effectiveSettingsSignal, onManageCustomModels: onManageCustomModels, openReportSignal: effectiveReportSignal, openShareSignal: effectiveShareSignal, initialInputValue: initialInputValue, pendingMessage: pendingMessage, pendingMessageKey: pendingMessageKey, pendingMessageSuppressUser: pendingMessageSuppressUser, pendingMessageUserInitiated: pendingMessageUserInitiated, userEditedFile: userEditedFile, userEditedFileKey: userEditedFileKey, gitStatusTick: gitStatusTick, discovery: hideConversationMenu, userAvatar: userAvatar, agentName: agentName, productName: productName, version: version, feedbackUrl: feedbackUrl }, chatKey)] }));
|
|
6812
6823
|
}
|
|
6813
6824
|
ChatPanel.displayName = 'ChatPanel';
|
|
6814
6825
|
//# sourceMappingURL=ChatPanel.js.map
|