-
Notifications
You must be signed in to change notification settings - Fork 6.5k
Expand file tree
/
Copy pathindex.tsx
More file actions
40 lines (36 loc) · 1.44 KB
/
index.tsx
File metadata and controls
40 lines (36 loc) · 1.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
'use client';
import { PaperAirplaneIcon } from '@heroicons/react/20/solid';
import { PauseCircleIcon } from '@heroicons/react/24/solid';
import { PromptTextArea } from '@orama/ui/components';
import { useTranslations } from 'next-intl';
import type { FC } from 'react';
import styles from './index.module.css';
export const ChatInput: FC = () => {
const t = useTranslations();
return (
<div className="pb-2 pt-6">
<PromptTextArea.Wrapper
className={`${styles.promptWrapperCustom} mx-8 flex items-center gap-2 rounded-2xl border border-[rgb(64,64,64)] bg-[rgb(38,38,38)] px-4 py-3 text-base text-white`}
>
<PromptTextArea.Field
placeholder={t('components.search.chatPlaceholder')}
rows={1}
maxLength={500}
autoFocus
className={`${styles.promptFieldCustom} m-0 w-full resize-none border-none bg-transparent p-0 font-normal leading-relaxed text-white outline-none`}
/>
<PromptTextArea.Button
abortContent={<PauseCircleIcon />}
className={`${styles.promptButtonCustom} orama-custom-button`}
>
<PaperAirplaneIcon className="h-4 w-4" />
</PromptTextArea.Button>
</PromptTextArea.Wrapper>
<div
className={`${styles.slidingPanelFooter} flex flex-row items-center justify-center pt-1 text-xs text-neutral-400`}
>
<small>{t('components.search.disclaimer')}</small>
</div>
</div>
);
};