@molecule/app-chatbot-tester-solid 0.0.0-stage → 1.1.0

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/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
package/README.md CHANGED
@@ -1,3 +1,232 @@
1
- # Temporary Holding Version
1
+ <!--
2
+ AUTO-GENERATED — DO NOT EDIT THIS FILE.
3
+ Generated by `mlcl sync-docs` from the package's src/index.ts JSDoc + mlcl/registry.json.
4
+ Edits here are overwritten on the next commit (molecule's pre-commit hook regenerates).
5
+ To change this document, edit the module-level JSDoc in src/index.ts.
6
+ Generated: 2026-11-18T23:41:38.115Z
7
+ -->
2
8
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
9
+ # @molecule/app-chatbot-tester-solid
10
+
11
+ `@molecule/app-chatbot-tester-solid` — Solid sandbox UI shell for
12
+ live-testing conversational AI: optional bot picker, message transcript,
13
+ input row, error display.
14
+
15
+ Stateless about transport. The consumer owns the message array, send
16
+ handler, and bot list; the package handles the layout and composition.
17
+
18
+ Extracted from the ai-chatbot-builder TestChat page; usable for any
19
+ "preview your bot live" UI. This is the Solid counterpart of
20
+ `@molecule/app-chatbot-tester-react`: the same props (React names) and the
21
+ same DOM for the same input, so an app swaps framework by changing only the
22
+ package name in its imports.
23
+
24
+ > **Auto-generated, AI-first package reference** for the [molecule.dev](https://molecule.dev) ecosystem.
25
+ > It is written to be read by coding agents as much as by people, and is generated from this
26
+ > package's source — edit `src/index.ts` JSDoc, not this file.
27
+
28
+ ## Quick Start
29
+
30
+ ```tsx
31
+ import { createSignal } from 'solid-js'
32
+ import { ChatbotTester, type TesterMessage } from '@molecule/app-chatbot-tester-solid'
33
+
34
+ const [messages, setMessages] = createSignal<TesterMessage[]>([])
35
+ const [sending, setSending] = createSignal(false)
36
+ const handleSend = async (text: string) => {
37
+ setMessages((prev) => [...prev, { id: Date.now(), role: 'user', content: text }])
38
+ const reply = await http.post(`/api/conversations/${conversationId}/messages`, { content: text })
39
+ setMessages((prev) => [...prev, { id: reply.id, role: 'assistant', content: reply.content }])
40
+ }
41
+
42
+ ;<ChatbotTester
43
+ messages={messages()}
44
+ onSend={handleSend}
45
+ loading={sending()}
46
+ bots={bots}
47
+ botId={botId()}
48
+ onBotChange={setBotId}
49
+ error={error()}
50
+ />
51
+ ```
52
+
53
+ ## Type
54
+
55
+ `feature`
56
+
57
+ ## Installation
58
+
59
+ ```bash
60
+ npm install @molecule/app-chatbot-tester-solid @molecule/app-solid @molecule/app-ui @molecule/app-ui-solid solid-js
61
+ ```
62
+
63
+ ## API
64
+
65
+ ### Interfaces
66
+
67
+ #### `TesterMessage`
68
+
69
+ A single chat message displayed in the chatbot tester sandbox UI.
70
+
71
+ ```typescript
72
+ interface TesterMessage {
73
+ id: string | number
74
+ role: 'user' | 'assistant' | 'system'
75
+ content: string
76
+ timestamp?: string
77
+ }
78
+ ```
79
+
80
+ #### `TesterBotOption`
81
+
82
+ A selectable bot/agent option shown in the chatbot tester sandbox UI.
83
+
84
+ ```typescript
85
+ interface TesterBotOption {
86
+ id: string
87
+ name?: string
88
+ }
89
+ ```
90
+
91
+ #### `ChatbotTesterProps`
92
+
93
+ Props accepted by the {@link ChatbotTester} component.
94
+
95
+ ```typescript
96
+ interface ChatbotTesterProps {
97
+ /** The transcript, in display order. */
98
+ messages: TesterMessage[]
99
+ /** A reply is in flight: the composer and its send action are disabled. */
100
+ loading?: boolean
101
+ /** Called with the trimmed composer text when the user sends. */
102
+ onSend: (text: string) => void | Promise<void>
103
+ /** Optional bot list — when length >= 2, a picker is rendered. */
104
+ bots?: TesterBotOption[]
105
+ /** The selected bot id (controlled). */
106
+ botId?: string
107
+ /** Called with the newly selected bot id. */
108
+ onBotChange?: (id: string) => void
109
+ /** Last error message — rendered in a `role="alert"` paragraph. */
110
+ error?: JSX.Element
111
+ /** Empty-state slot when there are no messages yet. */
112
+ emptyState?: JSX.Element
113
+ /** The bot picker's label — an explicit value overrides `t('chatbotTester.label.testBot')` (`'Test bot'`). */
114
+ botPickerLabel?: JSX.Element
115
+ /** Composer placeholder — an explicit value overrides `t('chatbotTester.placeholder.message')` (`'Type a message…'`). */
116
+ inputPlaceholder?: string
117
+ /** Send button label — an explicit value overrides `t('chatbotTester.label.send')` (`'Send'`). */
118
+ sendLabel?: string
119
+ /** Extra classes on the outer wrapper. */
120
+ className?: string
121
+ }
122
+ ```
123
+
124
+ #### `ChatbotTesterInputProps`
125
+
126
+ Props accepted by the {@link ChatbotTesterInput} component.
127
+
128
+ ```typescript
129
+ interface ChatbotTesterInputProps {
130
+ /** The composer's current text (controlled). */
131
+ value: string
132
+ /** Called with the field's new text on every edit. */
133
+ onChange: (next: string) => void
134
+ /** Called when the user presses Enter (without Shift) or clicks send. */
135
+ onSend: () => void
136
+ /** A reply is in flight: the field and the send button are disabled. */
137
+ loading?: boolean
138
+ /** Placeholder text — an explicit value overrides `t('chatbotTester.placeholder.message')` (`'Type a message…'`). */
139
+ placeholder?: string
140
+ /** Send button label — an explicit value overrides `t('chatbotTester.label.send')` (`'Send'`). */
141
+ sendLabel?: string
142
+ }
143
+ ```
144
+
145
+ #### `ChatbotTesterMessagesProps`
146
+
147
+ Props accepted by the {@link ChatbotTesterMessages} component.
148
+
149
+ ```typescript
150
+ interface ChatbotTesterMessagesProps {
151
+ /** The transcript, in display order. */
152
+ messages: TesterMessage[]
153
+ /** A reply is in flight: the typing indicator is appended. */
154
+ loading?: boolean
155
+ /** Rendered instead of the transcript when there are no messages. */
156
+ emptyState?: JSX.Element
157
+ }
158
+ ```
159
+
160
+ ### Functions
161
+
162
+ #### `ChatbotTester(props)`
163
+
164
+ Full chatbot tester sandbox.
165
+
166
+ ```typescript
167
+ function ChatbotTester(props: ChatbotTesterProps): JSX.Element
168
+ ```
169
+
170
+ - `props` — Component props (see {@link ChatbotTesterProps}).
171
+
172
+ **Returns:** The rendered tester.
173
+
174
+ #### `ChatbotTesterInput(props)`
175
+
176
+ Message composer + send button.
177
+
178
+ ```typescript
179
+ function ChatbotTesterInput(props: ChatbotTesterInputProps): JSX.Element
180
+ ```
181
+
182
+ - `props` — Component props (see {@link ChatbotTesterInputProps}).
183
+
184
+ **Returns:** The rendered composer row.
185
+
186
+ #### `ChatbotTesterMessages(props)`
187
+
188
+ Scrollable transcript pane. Renders the empty-state node instead of the list
189
+ when there are no messages, nothing is loading and an empty state was given
190
+ (React's branch).
191
+
192
+ ```typescript
193
+ function ChatbotTesterMessages(props: ChatbotTesterMessagesProps): JSX.Element
194
+ ```
195
+
196
+ - `props` — Component props (see {@link ChatbotTesterMessagesProps}).
197
+
198
+ **Returns:** The rendered transcript pane.
199
+
200
+ ## Injection Notes
201
+
202
+ ### Requirements
203
+
204
+ Peer dependencies:
205
+
206
+ - `@molecule/app-solid` ^3.5.0
207
+ - `@molecule/app-ui` ^1.3.11
208
+ - `@molecule/app-ui-solid` ^1.1.0
209
+ - `solid-js` ^1.8.0
210
+
211
+ ### Runtime Dependencies
212
+
213
+ - `@molecule/app-solid`
214
+ - `@molecule/app-ui`
215
+ - `@molecule/app-ui-solid`
216
+ - `solid-js`
217
+
218
+ Built-in labels (`botPickerLabel` "Test bot", `inputPlaceholder`
219
+ "Type a message…", `sendLabel` "Send") go through `t()` with the
220
+ `chatbotTester.*` keys of the companion locale bond
221
+ `@molecule/app-locales-chatbot-tester`; an explicit prop still overrides
222
+ them.
223
+ Enter sends; Shift+Enter inserts a newline. The bot picker renders only
224
+ when `bots` has 2+ entries. Styling includes Tailwind classes with
225
+ Material-3 tokens (`bg-surface-container-high`, `border-outline-variant`,
226
+ `text-on-primary`, …) — the app's Tailwind theme must define those tokens
227
+ (the default molecule Tailwind ClassMap bond does); with a non-Tailwind
228
+ ClassMap the bubbles/borders lose their styling.
229
+
230
+ ## Translations
231
+
232
+ Translation strings are provided by `@molecule/app-locales-chatbot-tester`.
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Solid composed chatbot-tester sandbox UI: optional bot picker + messages
3
+ * thread + input row + error region.
4
+ *
5
+ * Stateless about transport: the consumer owns the message array, the send
6
+ * handler and (optionally) the bot list + current bot id. The composer text is
7
+ * this component's own state, exactly as in React.
8
+ *
9
+ * Solid counterpart of `@molecule/app-chatbot-tester-react`'s `ChatbotTester` —
10
+ * the same props (React names) and the same DOM for the same input.
11
+ *
12
+ * @module
13
+ */
14
+ import { type Component } from 'solid-js';
15
+ import type { ChatbotTesterProps } from './types.js';
16
+ /**
17
+ * Full chatbot tester sandbox.
18
+ *
19
+ * @param props - Component props (see {@link ChatbotTesterProps}).
20
+ * @returns The rendered tester.
21
+ */
22
+ export declare const ChatbotTester: Component<ChatbotTesterProps>;
23
+ //# sourceMappingURL=ChatbotTester.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatbotTester.d.ts","sourceRoot":"","sources":["../src/ChatbotTester.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAmD,MAAM,UAAU,CAAA;AAQ1F,OAAO,KAAK,EAAE,kBAAkB,EAAmB,MAAM,YAAY,CAAA;AAErE;;;;;GAKG;AACH,eAAO,MAAM,aAAa,EAAE,SAAS,CAAC,kBAAkB,CAwGvD,CAAA"}
@@ -0,0 +1,93 @@
1
+ /**
2
+ * Solid composed chatbot-tester sandbox UI: optional bot picker + messages
3
+ * thread + input row + error region.
4
+ *
5
+ * Stateless about transport: the consumer owns the message array, the send
6
+ * handler and (optionally) the bot list + current bot id. The composer text is
7
+ * this component's own state, exactly as in React.
8
+ *
9
+ * Solid counterpart of `@molecule/app-chatbot-tester-react`'s `ChatbotTester` —
10
+ * the same props (React names) and the same DOM for the same input.
11
+ *
12
+ * @module
13
+ */
14
+ import { createEffect, createSignal, For, Show } from 'solid-js';
15
+ import { useTranslation } from '@molecule/app-solid';
16
+ import { getClassMap } from '@molecule/app-ui';
17
+ import { ChatbotTesterInput } from './ChatbotTesterInput.jsx';
18
+ import { ChatbotTesterMessages } from './ChatbotTesterMessages.jsx';
19
+ import { applyReactSelectSelection } from './dom.js';
20
+ /**
21
+ * Full chatbot tester sandbox.
22
+ *
23
+ * @param props - Component props (see {@link ChatbotTesterProps}).
24
+ * @returns The rendered tester.
25
+ */
26
+ export const ChatbotTester = (props) => {
27
+ const cm = getClassMap();
28
+ const { t } = useTranslation();
29
+ const [input, setInput] = createSignal('');
30
+ let selectEl;
31
+ /**
32
+ * The bot list React renders (its `bots ?? []`).
33
+ *
34
+ * @returns The bot options.
35
+ */
36
+ const bots = () => props.bots ?? [];
37
+ /** Re-applies react-dom's controlled-select selection. */
38
+ const applySelection = () => {
39
+ applyReactSelectSelection(selectEl, props.botId ?? '');
40
+ };
41
+ // Runs after the picker's options are patched, on mount and on every prop
42
+ // change, as react-dom's controlled `<select>` update does.
43
+ createEffect(() => {
44
+ void props.bots;
45
+ void props.botId;
46
+ applySelection();
47
+ });
48
+ /** Sends the trimmed composer text and clears the field. */
49
+ const handleSend = async () => {
50
+ const text = input().trim();
51
+ if (!text)
52
+ return;
53
+ setInput('');
54
+ await props.onSend(text);
55
+ };
56
+ /**
57
+ * Reports the selected bot, then restores the controlled selection the way
58
+ * react-dom does after a controlled select's change event.
59
+ *
60
+ * @param event - The native change event.
61
+ */
62
+ const handleBotChange = (event) => {
63
+ props.onBotChange?.(event.target.value);
64
+ applySelection();
65
+ };
66
+ const pickerVisible = () => bots().length > 1;
67
+ const labelNode = () => props.botPickerLabel === undefined
68
+ ? t('chatbotTester.label.testBot', undefined, { defaultValue: 'Test bot' })
69
+ : props.botPickerLabel;
70
+ const hasError = () => Boolean(props.error);
71
+ return (<div class={cm.cn(cm.flex({ direction: 'col' }), cm.flex1, cm.minW(0), props.className)}>
72
+ <Show when={pickerVisible()}>
73
+ <div class={cm.cn(cm.flex({ align: 'center' }), cm.sp('px', 6), cm.sp('py', 3), cm.chatbotTesterBotBar)}>
74
+ <label for="chatbot-tester-bot-select" class={cm.cn(cm.textSize('xs'), cm.fontWeight('bold'))}>
75
+ {labelNode()}
76
+ </label>
77
+ <select ref={(el) => {
78
+ selectEl = el;
79
+ }} id="chatbot-tester-bot-select" onChange={handleBotChange} class={cm.cn(cm.textSize('sm'), cm.chatbotTesterBotSelect)}>
80
+ <For each={bots()}>{(bot) => <option value={bot.id}>{bot.name || bot.id}</option>}</For>
81
+ </select>
82
+ </div>
83
+ </Show>
84
+ <ChatbotTesterMessages messages={props.messages} loading={props.loading} emptyState={props.emptyState}/>
85
+ <Show when={hasError()}>
86
+ <p role="alert" class={cm.cn(cm.textSize('sm'), cm.sp('px', 6), cm.sp('py', 2), cm.textError)}>
87
+ {props.error}
88
+ </p>
89
+ </Show>
90
+ <ChatbotTesterInput value={input()} onChange={setInput} onSend={handleSend} loading={props.loading} placeholder={props.inputPlaceholder} sendLabel={props.sendLabel}/>
91
+ </div>);
92
+ };
93
+ //# sourceMappingURL=ChatbotTester.jsx.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatbotTester.jsx","sourceRoot":"","sources":["../src/ChatbotTester.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAkB,YAAY,EAAE,YAAY,EAAE,GAAG,EAAY,IAAI,EAAE,MAAM,UAAU,CAAA;AAE1F,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAE9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAA;AAC7D,OAAO,EAAE,qBAAqB,EAAE,MAAM,6BAA6B,CAAA;AACnE,OAAO,EAAE,yBAAyB,EAAE,MAAM,UAAU,CAAA;AAGpD;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAAkC,CAAC,KAAK,EAAE,EAAE;IACpE,MAAM,EAAE,GAAG,WAAW,EAAE,CAAA;IACxB,MAAM,EAAE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,gBAAgB,CAAC,CACpC,SAAS,CAAC,CAAC,KAAK,CAAC,SAAS,CAAC,EAE/B;IAAA,EAAE,GAAG,CAAC,CACP,CAAA;AACH,CAAC,CAAA"}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Solid composer input row with a send button: Enter sends, Shift+Enter
3
+ * inserts a newline, and the field follows the controlled `value` prop the way
4
+ * react-dom restores it after every edit.
5
+ *
6
+ * Solid counterpart of `@molecule/app-chatbot-tester-react`'s
7
+ * `ChatbotTesterInput` — the same props (React names) and the same DOM for the
8
+ * same input.
9
+ *
10
+ * @module
11
+ */
12
+ import type { Component } from 'solid-js';
13
+ import type { ChatbotTesterInputProps } from './types.js';
14
+ /**
15
+ * Message composer + send button.
16
+ *
17
+ * @param props - Component props (see {@link ChatbotTesterInputProps}).
18
+ * @returns The rendered composer row.
19
+ */
20
+ export declare const ChatbotTesterInput: Component<ChatbotTesterInputProps>;
21
+ //# sourceMappingURL=ChatbotTesterInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatbotTesterInput.d.ts","sourceRoot":"","sources":["../src/ChatbotTesterInput.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,UAAU,CAAA;AAKzC,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAA;AAEzD;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,EAAE,SAAS,CAAC,uBAAuB,CA4EjE,CAAA"}
@@ -0,0 +1,61 @@
1
+ /**
2
+ * Solid composer input row with a send button: Enter sends, Shift+Enter
3
+ * inserts a newline, and the field follows the controlled `value` prop the way
4
+ * react-dom restores it after every edit.
5
+ *
6
+ * Solid counterpart of `@molecule/app-chatbot-tester-react`'s
7
+ * `ChatbotTesterInput` — the same props (React names) and the same DOM for the
8
+ * same input.
9
+ *
10
+ * @module
11
+ */
12
+ import { useTranslation } from '@molecule/app-solid';
13
+ import { getClassMap } from '@molecule/app-ui';
14
+ /**
15
+ * Message composer + send button.
16
+ *
17
+ * @param props - Component props (see {@link ChatbotTesterInputProps}).
18
+ * @returns The rendered composer row.
19
+ */
20
+ export const ChatbotTesterInput = (props) => {
21
+ const cm = getClassMap();
22
+ const { t } = useTranslation();
23
+ /**
24
+ * Reports the edit, then restores the controlled value exactly as
25
+ * react-dom does after a controlled input's change event.
26
+ *
27
+ * @param event - The native input event.
28
+ */
29
+ const handleInput = (event) => {
30
+ const field = event.target;
31
+ props.onChange(field.value);
32
+ if (field.value !== props.value)
33
+ field.value = props.value;
34
+ };
35
+ /**
36
+ * Enter sends; Shift+Enter is left to the browser (a newline).
37
+ *
38
+ * @param event - The native keydown event.
39
+ */
40
+ const handleKeydown = (event) => {
41
+ if (event.key === 'Enter' && !event.shiftKey) {
42
+ event.preventDefault();
43
+ props.onSend();
44
+ }
45
+ };
46
+ return (<div class={cm.cn(cm.flex({ align: 'end', gap: 2 }), cm.sp('px', 6), cm.sp('py', 4), cm.chatbotTesterInputRow)}>
47
+ <textarea rows={1} placeholder={props.placeholder === undefined
48
+ ? t('chatbotTester.placeholder.message', undefined, { defaultValue: 'Type a message…' })
49
+ : props.placeholder} disabled={props.loading} class={cm.cn(cm.flex1, cm.sp('px', 4), cm.sp('py', 2), cm.textSize('sm'), cm.surface, cm.chatbotTesterInputField)} value={props.value} onInput={handleInput} onKeyDown={handleKeydown}/>
50
+ <button type="button" data-mol-id="chatbot-tester-send" onClick={(event) => {
51
+ // React's DOM handler passes the click event, as `onClick={onSend}` does.
52
+ ;
53
+ props.onSend(event);
54
+ }} disabled={Boolean(props.loading) || !props.value.trim()} class={cm.cn(cm.button({ variant: 'solid', color: 'primary', size: 'sm' }), cm.touchTargetCompact)}>
55
+ {props.sendLabel === undefined
56
+ ? t('chatbotTester.label.send', undefined, { defaultValue: 'Send' })
57
+ : props.sendLabel}
58
+ </button>
59
+ </div>);
60
+ };
61
+ //# sourceMappingURL=ChatbotTesterInput.jsx.map
@@ -0,0 +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tB,CAAC,CAEF;QAAA,CAAC,KAAK,CAAC,SAAS,KAAK,SAAS;YAC5B,CAAC,CAAC,CAAC,CAAC,0BAA0B,EAAE,SAAS,EAAE,EAAE,YAAY,EAAE,MAAM,EAAE,CAAC;YACpE,CAAC,CAAC,KAAK,CAAC,SAAS,CACrB;MAAA,EAAE,MAAM,CACV;IAAA,EAAE,GAAG,CAAC,CACP,CAAA;AACH,CAAC,CAAA"}
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Solid scrollable message list for the chatbot sandbox: one left-aligned
3
+ * (assistant) or right-aligned (user) bubble per message, with the typing
4
+ * indicator appended while a reply is in flight.
5
+ *
6
+ * Solid counterpart of `@molecule/app-chatbot-tester-react`'s
7
+ * `ChatbotTesterMessages` — the same props (React names) and the same DOM for
8
+ * the same input.
9
+ *
10
+ * @module
11
+ */
12
+ import { type Component } from 'solid-js';
13
+ import type { ChatbotTesterMessagesProps } from './types.js';
14
+ /**
15
+ * Scrollable transcript pane. Renders the empty-state node instead of the list
16
+ * when there are no messages, nothing is loading and an empty state was given
17
+ * (React's branch).
18
+ *
19
+ * @param props - Component props (see {@link ChatbotTesterMessagesProps}).
20
+ * @returns The rendered transcript pane.
21
+ */
22
+ export declare const ChatbotTesterMessages: Component<ChatbotTesterMessagesProps>;
23
+ //# sourceMappingURL=ChatbotTesterMessages.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatbotTesterMessages.d.ts","sourceRoot":"","sources":["../src/ChatbotTesterMessages.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAa,MAAM,UAAU,CAAA;AAIpD,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,YAAY,CAAA;AAE5D;;;;;;;GAOG;AACH,eAAO,MAAM,qBAAqB,EAAE,SAAS,CAAC,0BAA0B,CAiEvE,CAAA"}
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Solid scrollable message list for the chatbot sandbox: one left-aligned
3
+ * (assistant) or right-aligned (user) bubble per message, with the typing
4
+ * indicator appended while a reply is in flight.
5
+ *
6
+ * Solid counterpart of `@molecule/app-chatbot-tester-react`'s
7
+ * `ChatbotTesterMessages` — the same props (React names) and the same DOM for
8
+ * the same input.
9
+ *
10
+ * @module
11
+ */
12
+ import { For, Show } from 'solid-js';
13
+ import { getClassMap } from '@molecule/app-ui';
14
+ /**
15
+ * Scrollable transcript pane. Renders the empty-state node instead of the list
16
+ * when there are no messages, nothing is loading and an empty state was given
17
+ * (React's branch).
18
+ *
19
+ * @param props - Component props (see {@link ChatbotTesterMessagesProps}).
20
+ * @returns The rendered transcript pane.
21
+ */
22
+ export const ChatbotTesterMessages = (props) => {
23
+ const cm = getClassMap();
24
+ /**
25
+ * Whether React takes the empty-state branch.
26
+ *
27
+ * @returns True when the empty state renders instead of the list.
28
+ */
29
+ const showsEmptyState = () => !props.loading && props.messages.length === 0 && Boolean(props.emptyState);
30
+ return (<Show when={showsEmptyState()} fallback={<div class={cm.cn(cm.flex1, cm.sp('px', 6), cm.sp('py', 4), cm.chatbotTesterMessageList)}>
31
+ <div class={cm.stack(3)}>
32
+ <For each={props.messages}>
33
+ {(msg) => {
34
+ const isUser = () => msg.role === 'user';
35
+ return (<div class={cm.cn(cm.flex({ justify: isUser() ? 'end' : 'start' }))}>
36
+ <div class={cm.cn(cm.sp('px', 4), cm.sp('py', 2), cm.textSize('sm'), cm.chatbotTesterMessageBubble, isUser()
37
+ ? cm.chatbotTesterMessageBubbleUser
38
+ : cm.chatbotTesterMessageBubbleBot)}>
39
+ {msg.content}
40
+ <Show when={msg.timestamp}>
41
+ <div class={cm.cn(cm.textSize('xs'), cm.sp('mt', 1), isUser()
42
+ ? cm.chatbotTesterMessageTimeUser
43
+ : cm.chatbotTesterMessageTimeBot)}>
44
+ {msg.timestamp}
45
+ </div>
46
+ </Show>
47
+ </div>
48
+ </div>);
49
+ }}
50
+ </For>
51
+ <Show when={props.loading}>
52
+ <div class={cm.cn(cm.textSize('xs'), cm.chatbotTesterTypingIndicator)}>...</div>
53
+ </Show>
54
+ <div />
55
+ </div>
56
+ </div>}>
57
+ <div class={cm.cn(cm.flex1, cm.flex({ align: 'center', justify: 'center' }))}>
58
+ {props.emptyState}
59
+ </div>
60
+ </Show>);
61
+ };
62
+ //# sourceMappingURL=ChatbotTesterMessages.jsx.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatbotTesterMessages.jsx","sourceRoot":"","sources":["../src/ChatbotTesterMessages.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAkB,GAAG,EAAE,IAAI,EAAE,MAAM,UAAU,CAAA;AAEpD,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAI9C;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAA0C,CAAC,KAAK,EAAE,EAAE;IACpF,MAAM,EAAE,GAAG,WAAW,EAAE,CAAA;IAExB;;;;OAIG;IACH,MAAM,eAAe,GAAG,GAAY,EAAE,CACpC,CAAC,KAAK,CAAC,OAAO,IAAI,KAAK,CAAC,QAAQ,CAAC,MAAM,KAAK,CAAC,IAAI,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC,CAAA;IAE5E,OAAO,CACL,CAAC,IAAI,CACH,IAAI,CAAC,CAAC,eAAe,EAAE,CAAC,CACxB,QAAQ,CAAC,CACP,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,wBAAwB,CAAC,CAAC,CACvF;UAAA,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CACtB;YAAA,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,KAAK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CAAC,CACH;YAAA,EAAE,GAAG,CACL;YAAA,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CACxB;cAAA,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,4BAA4B,CAAC,CAAC,CAAC,GAAG,EAAE,GAAG,CACjF;YAAA,EAAE,IAAI,CACN;YAAA,CAAC,GAAG,CAAC,AAAD,EACN;UAAA,EAAE,GAAG,CACP;QAAA,EAAE,GAAG,CACP,CAAC,CAED;MAAA,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,CAAC,CAAC,CAC3E;QAAA,CAAC,KAAK,CAAC,UAAU,CACnB;MAAA,EAAE,GAAG,CACP;IAAA,EAAE,IAAI,CAAC,CACR,CAAA;AACH,CAAC,CAAA"}
package/dist/dom.d.ts ADDED
@@ -0,0 +1,16 @@
1
+ /**
2
+ * DOM helpers shared by the Solid chatbot-tester components.
3
+ *
4
+ * @module
5
+ */
6
+ /**
7
+ * Reproduces react-dom's controlled-`<select>` selection: the option whose
8
+ * value matches is selected, and when nothing matches the first non-disabled
9
+ * option is. React never assigns `select.value`, so assigning it here would
10
+ * deselect everything for a value no option carries.
11
+ *
12
+ * @param select - The `<select>` element.
13
+ * @param value - The controlled value (React's `value ?? ''`).
14
+ */
15
+ export declare const applyReactSelectSelection: (select: HTMLSelectElement | null | undefined, value: string) => void;
16
+ //# sourceMappingURL=dom.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dom.d.ts","sourceRoot":"","sources":["../src/dom.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;;;;;GAQG;AACH,eAAO,MAAM,yBAAyB,GACpC,QAAQ,iBAAiB,GAAG,IAAI,GAAG,SAAS,EAC5C,OAAO,MAAM,KACZ,IAWF,CAAA"}
package/dist/dom.js ADDED
@@ -0,0 +1,30 @@
1
+ /**
2
+ * DOM helpers shared by the Solid chatbot-tester components.
3
+ *
4
+ * @module
5
+ */
6
+ /**
7
+ * Reproduces react-dom's controlled-`<select>` selection: the option whose
8
+ * value matches is selected, and when nothing matches the first non-disabled
9
+ * option is. React never assigns `select.value`, so assigning it here would
10
+ * deselect everything for a value no option carries.
11
+ *
12
+ * @param select - The `<select>` element.
13
+ * @param value - The controlled value (React's `value ?? ''`).
14
+ */
15
+ export const applyReactSelectSelection = (select, value) => {
16
+ if (!select)
17
+ return;
18
+ let fallback = null;
19
+ for (const option of Array.from(select.options)) {
20
+ if (option.value === value) {
21
+ option.selected = true;
22
+ return;
23
+ }
24
+ if (fallback === null && !option.disabled)
25
+ fallback = option;
26
+ }
27
+ if (fallback)
28
+ fallback.selected = true;
29
+ };
30
+ //# sourceMappingURL=dom.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dom.js","sourceRoot":"","sources":["../src/dom.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG,CACvC,MAA4C,EAC5C,KAAa,EACP,EAAE;IACR,IAAI,CAAC,MAAM;QAAE,OAAM;IACnB,IAAI,QAAQ,GAA6B,IAAI,CAAA;IAC7C,KAAK,MAAM,MAAM,IAAI,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,EAAE,CAAC;QAChD,IAAI,MAAM,CAAC,KAAK,KAAK,KAAK,EAAE,CAAC;YAC3B,MAAM,CAAC,QAAQ,GAAG,IAAI,CAAA;YACtB,OAAM;QACR,CAAC;QACD,IAAI,QAAQ,KAAK,IAAI,IAAI,CAAC,MAAM,CAAC,QAAQ;YAAE,QAAQ,GAAG,MAAM,CAAA;IAC9D,CAAC;IACD,IAAI,QAAQ;QAAE,QAAQ,CAAC,QAAQ,GAAG,IAAI,CAAA;AACxC,CAAC,CAAA"}
@@ -0,0 +1,58 @@
1
+ /**
2
+ * `@molecule/app-chatbot-tester-solid` — Solid sandbox UI shell for
3
+ * live-testing conversational AI: optional bot picker, message transcript,
4
+ * input row, error display.
5
+ *
6
+ * Stateless about transport. The consumer owns the message array, send
7
+ * handler, and bot list; the package handles the layout and composition.
8
+ *
9
+ * Extracted from the ai-chatbot-builder TestChat page; usable for any
10
+ * "preview your bot live" UI. This is the Solid counterpart of
11
+ * `@molecule/app-chatbot-tester-react`: the same props (React names) and the
12
+ * same DOM for the same input, so an app swaps framework by changing only the
13
+ * package name in its imports.
14
+ *
15
+ * @example
16
+ * ```tsx
17
+ * import { createSignal } from 'solid-js'
18
+ * import { ChatbotTester, type TesterMessage } from '@molecule/app-chatbot-tester-solid'
19
+ *
20
+ * const [messages, setMessages] = createSignal<TesterMessage[]>([])
21
+ * const [sending, setSending] = createSignal(false)
22
+ * const handleSend = async (text: string) => {
23
+ * setMessages((prev) => [...prev, { id: Date.now(), role: 'user', content: text }])
24
+ * const reply = await http.post(`/api/conversations/${conversationId}/messages`, { content: text })
25
+ * setMessages((prev) => [...prev, { id: reply.id, role: 'assistant', content: reply.content }])
26
+ * }
27
+ *
28
+ * <ChatbotTester
29
+ * messages={messages()}
30
+ * onSend={handleSend}
31
+ * loading={sending()}
32
+ * bots={bots}
33
+ * botId={botId()}
34
+ * onBotChange={setBotId}
35
+ * error={error()}
36
+ * />
37
+ * ```
38
+ *
39
+ * @remarks
40
+ * Built-in labels (`botPickerLabel` "Test bot", `inputPlaceholder`
41
+ * "Type a message…", `sendLabel` "Send") go through `t()` with the
42
+ * `chatbotTester.*` keys of the companion locale bond
43
+ * `@molecule/app-locales-chatbot-tester`; an explicit prop still overrides
44
+ * them.
45
+ * Enter sends; Shift+Enter inserts a newline. The bot picker renders only
46
+ * when `bots` has 2+ entries. Styling includes Tailwind classes with
47
+ * Material-3 tokens (`bg-surface-container-high`, `border-outline-variant`,
48
+ * `text-on-primary`, …) — the app's Tailwind theme must define those tokens
49
+ * (the default molecule Tailwind ClassMap bond does); with a non-Tailwind
50
+ * ClassMap the bubbles/borders lose their styling.
51
+ *
52
+ * @module
53
+ */
54
+ export * from './ChatbotTester.jsx';
55
+ export * from './ChatbotTesterInput.jsx';
56
+ export * from './ChatbotTesterMessages.jsx';
57
+ export * from './types.js';
58
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AAEH,cAAc,qBAAqB,CAAA;AACnC,cAAc,0BAA0B,CAAA;AACxC,cAAc,6BAA6B,CAAA;AAC3C,cAAc,YAAY,CAAA"}
package/dist/index.js ADDED
@@ -0,0 +1,58 @@
1
+ /**
2
+ * `@molecule/app-chatbot-tester-solid` — Solid sandbox UI shell for
3
+ * live-testing conversational AI: optional bot picker, message transcript,
4
+ * input row, error display.
5
+ *
6
+ * Stateless about transport. The consumer owns the message array, send
7
+ * handler, and bot list; the package handles the layout and composition.
8
+ *
9
+ * Extracted from the ai-chatbot-builder TestChat page; usable for any
10
+ * "preview your bot live" UI. This is the Solid counterpart of
11
+ * `@molecule/app-chatbot-tester-react`: the same props (React names) and the
12
+ * same DOM for the same input, so an app swaps framework by changing only the
13
+ * package name in its imports.
14
+ *
15
+ * @example
16
+ * ```tsx
17
+ * import { createSignal } from 'solid-js'
18
+ * import { ChatbotTester, type TesterMessage } from '@molecule/app-chatbot-tester-solid'
19
+ *
20
+ * const [messages, setMessages] = createSignal<TesterMessage[]>([])
21
+ * const [sending, setSending] = createSignal(false)
22
+ * const handleSend = async (text: string) => {
23
+ * setMessages((prev) => [...prev, { id: Date.now(), role: 'user', content: text }])
24
+ * const reply = await http.post(`/api/conversations/${conversationId}/messages`, { content: text })
25
+ * setMessages((prev) => [...prev, { id: reply.id, role: 'assistant', content: reply.content }])
26
+ * }
27
+ *
28
+ * <ChatbotTester
29
+ * messages={messages()}
30
+ * onSend={handleSend}
31
+ * loading={sending()}
32
+ * bots={bots}
33
+ * botId={botId()}
34
+ * onBotChange={setBotId}
35
+ * error={error()}
36
+ * />
37
+ * ```
38
+ *
39
+ * @remarks
40
+ * Built-in labels (`botPickerLabel` "Test bot", `inputPlaceholder`
41
+ * "Type a message…", `sendLabel` "Send") go through `t()` with the
42
+ * `chatbotTester.*` keys of the companion locale bond
43
+ * `@molecule/app-locales-chatbot-tester`; an explicit prop still overrides
44
+ * them.
45
+ * Enter sends; Shift+Enter inserts a newline. The bot picker renders only
46
+ * when `bots` has 2+ entries. Styling includes Tailwind classes with
47
+ * Material-3 tokens (`bg-surface-container-high`, `border-outline-variant`,
48
+ * `text-on-primary`, …) — the app's Tailwind theme must define those tokens
49
+ * (the default molecule Tailwind ClassMap bond does); with a non-Tailwind
50
+ * ClassMap the bubbles/borders lose their styling.
51
+ *
52
+ * @module
53
+ */
54
+ export * from './ChatbotTester.jsx';
55
+ export * from './ChatbotTesterInput.jsx';
56
+ export * from './ChatbotTesterMessages.jsx';
57
+ export * from './types.js';
58
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AAEH,cAAc,qBAAqB,CAAA;AACnC,cAAc,0BAA0B,CAAA;AACxC,cAAc,6BAA6B,CAAA;AAC3C,cAAc,YAAY,CAAA"}
@@ -0,0 +1,71 @@
1
+ /**
2
+ * Types for the Solid chatbot-tester sandbox UI — the same props (React names)
3
+ * as `@molecule/app-chatbot-tester-react`.
4
+ *
5
+ * @module
6
+ */
7
+ import type { JSX } from 'solid-js';
8
+ /** A single chat message displayed in the chatbot tester sandbox UI. */
9
+ export interface TesterMessage {
10
+ id: string | number;
11
+ role: 'user' | 'assistant' | 'system';
12
+ content: string;
13
+ timestamp?: string;
14
+ }
15
+ /** A selectable bot/agent option shown in the chatbot tester sandbox UI. */
16
+ export interface TesterBotOption {
17
+ id: string;
18
+ name?: string;
19
+ }
20
+ /** Props accepted by the {@link ChatbotTester} component. */
21
+ export interface ChatbotTesterProps {
22
+ /** The transcript, in display order. */
23
+ messages: TesterMessage[];
24
+ /** A reply is in flight: the composer and its send action are disabled. */
25
+ loading?: boolean;
26
+ /** Called with the trimmed composer text when the user sends. */
27
+ onSend: (text: string) => void | Promise<void>;
28
+ /** Optional bot list — when length >= 2, a picker is rendered. */
29
+ bots?: TesterBotOption[];
30
+ /** The selected bot id (controlled). */
31
+ botId?: string;
32
+ /** Called with the newly selected bot id. */
33
+ onBotChange?: (id: string) => void;
34
+ /** Last error message — rendered in a `role="alert"` paragraph. */
35
+ error?: JSX.Element;
36
+ /** Empty-state slot when there are no messages yet. */
37
+ emptyState?: JSX.Element;
38
+ /** The bot picker's label — an explicit value overrides `t('chatbotTester.label.testBot')` (`'Test bot'`). */
39
+ botPickerLabel?: JSX.Element;
40
+ /** Composer placeholder — an explicit value overrides `t('chatbotTester.placeholder.message')` (`'Type a message…'`). */
41
+ inputPlaceholder?: string;
42
+ /** Send button label — an explicit value overrides `t('chatbotTester.label.send')` (`'Send'`). */
43
+ sendLabel?: string;
44
+ /** Extra classes on the outer wrapper. */
45
+ className?: string;
46
+ }
47
+ /** Props accepted by the {@link ChatbotTesterInput} component. */
48
+ export interface ChatbotTesterInputProps {
49
+ /** The composer's current text (controlled). */
50
+ value: string;
51
+ /** Called with the field's new text on every edit. */
52
+ onChange: (next: string) => void;
53
+ /** Called when the user presses Enter (without Shift) or clicks send. */
54
+ onSend: () => void;
55
+ /** A reply is in flight: the field and the send button are disabled. */
56
+ loading?: boolean;
57
+ /** Placeholder text — an explicit value overrides `t('chatbotTester.placeholder.message')` (`'Type a message…'`). */
58
+ placeholder?: string;
59
+ /** Send button label — an explicit value overrides `t('chatbotTester.label.send')` (`'Send'`). */
60
+ sendLabel?: string;
61
+ }
62
+ /** Props accepted by the {@link ChatbotTesterMessages} component. */
63
+ export interface ChatbotTesterMessagesProps {
64
+ /** The transcript, in display order. */
65
+ messages: TesterMessage[];
66
+ /** A reply is in flight: the typing indicator is appended. */
67
+ loading?: boolean;
68
+ /** Rendered instead of the transcript when there are no messages. */
69
+ emptyState?: JSX.Element;
70
+ }
71
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,UAAU,CAAA;AAEnC,wEAAwE;AACxE,MAAM,WAAW,aAAa;IAC5B,EAAE,EAAE,MAAM,GAAG,MAAM,CAAA;IACnB,IAAI,EAAE,MAAM,GAAG,WAAW,GAAG,QAAQ,CAAA;IACrC,OAAO,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,4EAA4E;AAC5E,MAAM,WAAW,eAAe;IAC9B,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,CAAC,EAAE,MAAM,CAAA;CACd;AAED,6DAA6D;AAC7D,MAAM,WAAW,kBAAkB;IACjC,wCAAwC;IACxC,QAAQ,EAAE,aAAa,EAAE,CAAA;IACzB,2EAA2E;IAC3E,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,iEAAiE;IACjE,MAAM,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IAC9C,kEAAkE;IAClE,IAAI,CAAC,EAAE,eAAe,EAAE,CAAA;IACxB,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,6CAA6C;IAC7C,WAAW,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;IAClC,mEAAmE;IACnE,KAAK,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;IACnB,uDAAuD;IACvD,UAAU,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;IACxB,8GAA8G;IAC9G,cAAc,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;IAC5B,yHAAyH;IACzH,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,kGAAkG;IAClG,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,kEAAkE;AAClE,MAAM,WAAW,uBAAuB;IACtC,gDAAgD;IAChD,KAAK,EAAE,MAAM,CAAA;IACb,sDAAsD;IACtD,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;IAChC,yEAAyE;IACzE,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,wEAAwE;IACxE,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,qHAAqH;IACrH,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,kGAAkG;IAClG,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,qEAAqE;AACrE,MAAM,WAAW,0BAA0B;IACzC,wCAAwC;IACxC,QAAQ,EAAE,aAAa,EAAE,CAAA;IACzB,8DAA8D;IAC9D,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,qEAAqE;IACrE,UAAU,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;CACzB"}
package/dist/types.js ADDED
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Types for the Solid chatbot-tester sandbox UI — the same props (React names)
3
+ * as `@molecule/app-chatbot-tester-react`.
4
+ *
5
+ * @module
6
+ */
7
+ export {};
8
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG"}
package/package.json CHANGED
@@ -1,6 +1,67 @@
1
1
  {
2
2
  "name": "@molecule/app-chatbot-tester-solid",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "1.1.0",
4
+ "description": "Bot-picker + transcript + composer sandbox UI",
5
+ "homepage": "https://www.molecule.dev/packages/app-chatbot-tester-solid",
6
+ "type": "module",
7
+ "main": "dist/index.js",
8
+ "types": "dist/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "types": "./dist/index.d.ts",
12
+ "import": "./dist/index.js"
13
+ }
14
+ },
15
+ "files": [
16
+ "dist",
17
+ "README.md"
18
+ ],
19
+ "scripts": {
20
+ "build": "tsc",
21
+ "dev": "tsc --watch",
22
+ "test": "vitest run",
23
+ "test:watch": "vitest"
24
+ },
25
+ "keywords": [
26
+ "molecule",
27
+ "chatbot",
28
+ "playground",
29
+ "tester",
30
+ "ai",
31
+ "solid"
32
+ ],
33
+ "author": "Molecule Dev, Inc. (https://molecule.dev)",
34
+ "license": "Apache-2.0",
35
+ "repository": {
36
+ "type": "git",
37
+ "url": "https://github.com/molecule-dev/molecule.git",
38
+ "directory": "packages/app/features/chatbot-tester-solid"
39
+ },
40
+ "engines": {
41
+ "node": ">=20"
42
+ },
43
+ "bugs": "https://github.com/molecule-dev/molecule/issues",
44
+ "publishConfig": {
45
+ "access": "public"
46
+ },
47
+ "peerDependencies": {
48
+ "@molecule/app-solid": "^3.5.0",
49
+ "@molecule/app-ui": "^1.3.11",
50
+ "@molecule/app-ui-solid": "^1.1.0",
51
+ "solid-js": "^1.8.0"
52
+ },
53
+ "devDependencies": {
54
+ "@molecule/app-framework-conformance": "0.0.0",
55
+ "@molecule/app-i18n": "1.2.2",
56
+ "@molecule/app-icons": "1.0.4",
57
+ "@molecule/app-solid": "3.7.2",
58
+ "@molecule/app-ui": "1.4.0",
59
+ "@molecule/app-ui-solid": "1.1.5",
60
+ "@types/node": "26.6.5",
61
+ "jsdom": "30.1.3",
62
+ "solid-js": "1.9.17",
63
+ "typescript": "6.0.3",
64
+ "vite-plugin-solid": "2.11.15",
65
+ "vitest": "4.1.12"
66
+ }
67
+ }