@fungi.computer/parakeet 0.16.2 → 0.16.4
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/dist/components/ChatComposer.js +1 -2
- package/dist/parakeet.d.ts +6 -1
- package/dist/parakeet.js +4 -4
- package/docs/api/index.md +1 -0
- package/package.json +3 -3
|
@@ -205,8 +205,7 @@ function HostComposerTextarea({ placeholder, onChange, onSend, onAbort, slash, s
|
|
|
205
205
|
})), className: "font-sans text-base-content", id: textareaId, onChange: (event) => {
|
|
206
206
|
onChange(event.target.value);
|
|
207
207
|
setHistoryIndex(-1);
|
|
208
|
-
}, onKeyDown: onKeyDown, placeholder: placeholder ??
|
|
209
|
-
(slash === undefined ? "Ask agent..." : "Ask agent… (/ for commands)"), ref: textareaRef, rows: 1, value: value }), queuedRecall === undefined ? null : (_jsx("span", { id: `${textareaId}-recall-guidance`, className: "sr-only", children: "Press Up on an empty composer to recall your newest queued message." }))] }));
|
|
208
|
+
}, onKeyDown: onKeyDown, placeholder: placeholder ?? "Message agent…", ref: textareaRef, rows: 1, value: value }), queuedRecall === undefined ? null : (_jsx("span", { id: `${textareaId}-recall-guidance`, className: "sr-only", children: "Press Up on an empty composer to recall your newest queued message." }))] }));
|
|
210
209
|
}
|
|
211
210
|
/** Full Session readout for announcements; the footer only draws attention states. */
|
|
212
211
|
export function sessionReadout(status, view) {
|
package/dist/parakeet.d.ts
CHANGED
|
@@ -64,6 +64,11 @@ export type ParakeetViewProps = Readonly<{
|
|
|
64
64
|
visitor?: ParakeetVisitor | undefined;
|
|
65
65
|
/** Optional Caps action style for a host-specific quieter composer. */
|
|
66
66
|
composerActionVariant?: "primary" | "outline" | undefined;
|
|
67
|
+
/**
|
|
68
|
+
* What the empty composer says, such as "Message Moss…". Absent, the composer
|
|
69
|
+
* says "Message agent…"; a visitor conversation always names its Agent.
|
|
70
|
+
*/
|
|
71
|
+
placeholder?: string | undefined;
|
|
67
72
|
/** Optional caller-owned actions for a completed tool result. */
|
|
68
73
|
renderToolActions?: ((item: ToolItem) => ReactNode) | undefined;
|
|
69
74
|
/** Optional host claim: true hides this item's image parts from the tool body because the host shows them. */
|
|
@@ -90,6 +95,6 @@ export type ParakeetViewProps = Readonly<{
|
|
|
90
95
|
commands?: ParakeetCommandRuntime | undefined;
|
|
91
96
|
}>;
|
|
92
97
|
/** Render the retained conversation surface within one Parakeet provider. */
|
|
93
|
-
export declare function ParakeetView({ hideSoleAuthor, disambiguateAuthors, visitor, composerActionVariant, empty, hostFacts, autoFocus, commands, renderToolActions, claimsToolMedia, renderAssistantAttachment, formatAssistantText, onLink, onOpen, }: ParakeetViewProps): ReactElement;
|
|
98
|
+
export declare function ParakeetView({ hideSoleAuthor, disambiguateAuthors, visitor, composerActionVariant, placeholder, empty, hostFacts, autoFocus, commands, renderToolActions, claimsToolMedia, renderAssistantAttachment, formatAssistantText, onLink, onOpen, }: ParakeetViewProps): ReactElement;
|
|
94
99
|
/** Standalone typed composer and exact-message timeline. */
|
|
95
100
|
export declare function Parakeet({ authorOf, hideSoleAuthor, disambiguateAuthors, visitor, markdownPolicy, composerActionVariant, empty, hostFacts, session, clients, renderToolActions, claimsToolMedia, renderAssistantAttachment, formatAssistantText, commands, onLink, onOpen, }: ParakeetProps): ReactElement;
|
package/dist/parakeet.js
CHANGED
|
@@ -24,7 +24,7 @@ import { useSlashCommands, } from "./commands/use-slash-commands.js";
|
|
|
24
24
|
import { TimelineItem } from "./components/TimelineItem.js";
|
|
25
25
|
import { MarkdownPolicyContext } from "./components/MarkdownRenderer.js";
|
|
26
26
|
/** Render the retained conversation surface within one Parakeet provider. */
|
|
27
|
-
export function ParakeetView({ hideSoleAuthor, disambiguateAuthors, visitor, composerActionVariant, empty, hostFacts, autoFocus, commands, renderToolActions, claimsToolMedia, renderAssistantAttachment, formatAssistantText, onLink, onOpen, }) {
|
|
27
|
+
export function ParakeetView({ hideSoleAuthor, disambiguateAuthors, visitor, composerActionVariant, placeholder, empty, hostFacts, autoFocus, commands, renderToolActions, claimsToolMedia, renderAssistantAttachment, formatAssistantText, onLink, onOpen, }) {
|
|
28
28
|
const textareaRef = useRef(null);
|
|
29
29
|
// Opening a conversation puts the caret in the composer; a click elsewhere keeps it.
|
|
30
30
|
useEffect(() => {
|
|
@@ -88,7 +88,7 @@ export function ParakeetView({ hideSoleAuthor, disambiguateAuthors, visitor, com
|
|
|
88
88
|
]),
|
|
89
89
|
...unanchoredHere,
|
|
90
90
|
], actions: clientActions, onOpen: onOpen }, entryId));
|
|
91
|
-
}) })) : null, _jsx(ConversationWaiting, { clientActions: clientActions }), _jsx(ConversationComposer, { visitor: visitor, textareaRef: textareaRef, composerActionVariant: composerActionVariant, slash: slash })] }), visitor === undefined ? (_jsx(ConversationInteraction, { slash: slash })) : null] }) }));
|
|
91
|
+
}) })) : null, _jsx(ConversationWaiting, { clientActions: clientActions }), _jsx(ConversationComposer, { visitor: visitor, textareaRef: textareaRef, composerActionVariant: composerActionVariant, placeholder: placeholder, slash: slash })] }), visitor === undefined ? (_jsx(ConversationInteraction, { slash: slash })) : null] }) }));
|
|
92
92
|
}
|
|
93
93
|
const noHostFacts = {};
|
|
94
94
|
const busyStatuses = new Set([
|
|
@@ -367,7 +367,7 @@ function ConversationWaiting({ clientActions, }) {
|
|
|
367
367
|
void clientActions.execute(extensionWaiting.entryId, extensionWaiting.value.waiting.cancel, true);
|
|
368
368
|
}, children: extensionWaiting.value.waiting.cancel.label })] })) }));
|
|
369
369
|
}
|
|
370
|
-
function ConversationComposer({ visitor, textareaRef, composerActionVariant, slash, }) {
|
|
370
|
+
function ConversationComposer({ visitor, textareaRef, composerActionVariant, placeholder, slash, }) {
|
|
371
371
|
const hostFacts = useContext(ParakeetHostFactsContext);
|
|
372
372
|
const composer = useComposer();
|
|
373
373
|
const sessionStatus = useStatus();
|
|
@@ -402,7 +402,7 @@ function ConversationComposer({ visitor, textareaRef, composerActionVariant, sla
|
|
|
402
402
|
onChange: composer.setDraft,
|
|
403
403
|
onSend: slash.submit,
|
|
404
404
|
slash: visitor === undefined ? slash : undefined,
|
|
405
|
-
placeholder: visitor === undefined ?
|
|
405
|
+
placeholder: visitor === undefined ? placeholder : `Ask ${visitor.agentName}…`,
|
|
406
406
|
showFooter: visitor === undefined,
|
|
407
407
|
status: sessionStatus.status,
|
|
408
408
|
viewState: sessionStatus.viewState,
|
package/docs/api/index.md
CHANGED
|
@@ -614,6 +614,7 @@ type ParakeetViewProps = Readonly<{
|
|
|
614
614
|
disambiguateAuthors?: boolean;
|
|
615
615
|
visitor?: ParakeetVisitor;
|
|
616
616
|
composerActionVariant?: "primary" | "outline";
|
|
617
|
+
placeholder?: string;
|
|
617
618
|
renderToolActions?: (item) => ReactNode;
|
|
618
619
|
claimsToolMedia?: (item) => boolean;
|
|
619
620
|
renderAssistantAttachment?: (text) => ReactNode;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fungi.computer/parakeet",
|
|
3
|
-
"version": "0.16.
|
|
3
|
+
"version": "0.16.4",
|
|
4
4
|
"author": "Levi <levi@technomancy.dev>",
|
|
5
5
|
"private": false,
|
|
6
6
|
"description": "Standalone React composer for a typed Shiitake Session",
|
|
@@ -71,11 +71,11 @@
|
|
|
71
71
|
"@fungi.computer/agar": "0.24.0",
|
|
72
72
|
"@fungi.computer/bird-dog": "0.3.7",
|
|
73
73
|
"@fungi.computer/cairn": "0.1.0",
|
|
74
|
-
"@fungi.computer/caps": "0.12.
|
|
74
|
+
"@fungi.computer/caps": "0.12.3",
|
|
75
75
|
"@fungi.computer/gills": "0.4.0",
|
|
76
76
|
"@fungi.computer/knapsack": "0.4.21",
|
|
77
77
|
"@fungi.computer/mule": "0.3.0",
|
|
78
|
-
"@fungi.computer/shiitake": "0.21.
|
|
78
|
+
"@fungi.computer/shiitake": "0.21.12",
|
|
79
79
|
"@fungi.computer/sigils": "0.3.2",
|
|
80
80
|
"@fungi.computer/sprite": "0.2.2",
|
|
81
81
|
"@fungi.computer/sprite-zdog": "0.3.2",
|