feat: add tests (#843)
This commit is contained in:
parent
95a2af2535
commit
9dd9a9898c
35 changed files with 1063 additions and 191 deletions
|
|
@ -211,7 +211,10 @@ function PureMultimodalInput({
|
|||
/>
|
||||
|
||||
{(attachments.length > 0 || uploadQueue.length > 0) && (
|
||||
<div className="flex flex-row gap-2 overflow-x-scroll items-end">
|
||||
<div
|
||||
data-testid="attachments-preview"
|
||||
className="flex flex-row gap-2 overflow-x-scroll items-end"
|
||||
>
|
||||
{attachments.map((attachment) => (
|
||||
<PreviewAttachment key={attachment.url} attachment={attachment} />
|
||||
))}
|
||||
|
|
@ -231,6 +234,7 @@ function PureMultimodalInput({
|
|||
)}
|
||||
|
||||
<Textarea
|
||||
data-testid="multimodal-input"
|
||||
ref={textareaRef}
|
||||
placeholder="Send a message..."
|
||||
value={input}
|
||||
|
|
@ -293,6 +297,7 @@ function PureAttachmentsButton({
|
|||
}) {
|
||||
return (
|
||||
<Button
|
||||
data-testid="attachments-button"
|
||||
className="rounded-md rounded-bl-lg p-[7px] h-fit dark:border-zinc-700 hover:dark:bg-zinc-900 hover:bg-zinc-200"
|
||||
onClick={(event) => {
|
||||
event.preventDefault();
|
||||
|
|
@ -317,6 +322,7 @@ function PureStopButton({
|
|||
}) {
|
||||
return (
|
||||
<Button
|
||||
data-testid="stop-button"
|
||||
className="rounded-full p-1.5 h-fit border dark:border-zinc-600"
|
||||
onClick={(event) => {
|
||||
event.preventDefault();
|
||||
|
|
@ -342,6 +348,7 @@ function PureSendButton({
|
|||
}) {
|
||||
return (
|
||||
<Button
|
||||
data-testid="send-button"
|
||||
className="rounded-full p-1.5 h-fit border dark:border-zinc-600"
|
||||
onClick={(event) => {
|
||||
event.preventDefault();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue