reachat 2.1.0-alpha.9 → 2.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.
Files changed (82) hide show
  1. package/README.md +4 -2
  2. package/dist/AppBar/AppBar.d.ts +1 -1
  3. package/dist/{CSVFileRenderer-CkRKGiCl.js → CSVFileRenderer-D2mDdCjs.js} +14 -15
  4. package/dist/CSVFileRenderer-D2mDdCjs.js.map +1 -0
  5. package/dist/Chat.d.ts +9 -3
  6. package/dist/ChatBubble/ChatBubble.d.ts +1 -1
  7. package/dist/ChatContext.d.ts +4 -2
  8. package/dist/ChatInput/ChatInput.d.ts +23 -13
  9. package/dist/ChatInput/FileInput.d.ts +1 -1
  10. package/dist/ChatInput/MentionList.d.ts +32 -0
  11. package/dist/ChatInput/RichTextInput.d.ts +55 -0
  12. package/dist/ChatInput/index.d.ts +3 -0
  13. package/dist/ChatInput/types.d.ts +104 -0
  14. package/dist/ChatSuggestions/ChatSuggestion.d.ts +9 -0
  15. package/dist/ChatSuggestions/ChatSuggestions.d.ts +22 -0
  16. package/dist/ChatSuggestions/index.d.ts +2 -0
  17. package/dist/{DefaultFileRenderer-C1qZ57tG.js → DefaultFileRenderer-BLV8PtJk.js} +2 -2
  18. package/dist/DefaultFileRenderer-BLV8PtJk.js.map +1 -0
  19. package/dist/ImageFileRenderer-C8tVW3I8.js.map +1 -1
  20. package/dist/Markdown/Markdown.d.ts +4 -3
  21. package/dist/Markdown/Table.d.ts +1 -1
  22. package/dist/Markdown/charts/ChartError.d.ts +21 -0
  23. package/dist/Markdown/charts/ChartPre.d.ts +6 -0
  24. package/dist/Markdown/charts/ChartRenderer.d.ts +13 -0
  25. package/dist/Markdown/charts/chartHelpers.d.ts +40 -0
  26. package/dist/Markdown/charts/chartHelpers.spec.d.ts +1 -0
  27. package/dist/Markdown/charts/index.d.ts +7 -0
  28. package/dist/Markdown/index.d.ts +3 -2
  29. package/dist/Markdown/plugins/index.d.ts +1 -0
  30. package/dist/Markdown/plugins/remarkChart.d.ts +59 -0
  31. package/dist/Markdown/plugins/remarkCve.d.ts +1 -1
  32. package/dist/MessageStatus/MessageStatus.d.ts +44 -0
  33. package/dist/MessageStatus/MessageStatusItem.d.ts +9 -0
  34. package/dist/MessageStatus/StatusIcon.d.ts +17 -0
  35. package/dist/MessageStatus/index.d.ts +3 -0
  36. package/dist/PDFFileRenderer-DQdFS2l6.js +9 -0
  37. package/dist/PDFFileRenderer-DQdFS2l6.js.map +1 -0
  38. package/dist/SessionMessages/SessionEmpty.d.ts +4 -1
  39. package/dist/SessionMessages/SessionMessage/MessageFile/renderers/index.d.ts +1 -1
  40. package/dist/SessionMessages/SessionMessage/MessageFiles.d.ts +1 -1
  41. package/dist/SessionMessages/SessionMessage/MessageSources.d.ts +1 -1
  42. package/dist/SessionMessages/SessionMessage/SessionMessage.d.ts +0 -4
  43. package/dist/SessionMessages/SessionMessage/index.d.ts +2 -2
  44. package/dist/SessionMessages/SessionMessages.d.ts +3 -7
  45. package/dist/SessionMessages/index.d.ts +2 -2
  46. package/dist/SessionsList/index.d.ts +2 -2
  47. package/dist/docs.json +1037 -183
  48. package/dist/index-B3dZT-5c.js +4369 -0
  49. package/dist/index-B3dZT-5c.js.map +1 -0
  50. package/dist/index.css +2129 -6532
  51. package/dist/index.d.ts +8 -7
  52. package/dist/index.js +49 -34
  53. package/dist/index.umd.cjs +3414 -1320
  54. package/dist/index.umd.cjs.map +1 -1
  55. package/dist/stories/Changelog.mdx +1 -1
  56. package/dist/stories/ChartError.stories.tsx +85 -0
  57. package/dist/stories/Charts.stories.tsx +371 -0
  58. package/dist/stories/Chat.stories.tsx +5 -5
  59. package/dist/stories/ChatBubble.stories.tsx +3 -3
  60. package/dist/stories/ChatSuggestions.stories.tsx +541 -0
  61. package/dist/stories/Companion.stories.tsx +6 -6
  62. package/dist/stories/Console.stories.tsx +165 -25
  63. package/dist/stories/EnhancedInput.stories.tsx +322 -0
  64. package/dist/stories/Integration.stories.tsx +2 -2
  65. package/dist/stories/Intro.mdx +1 -1
  66. package/dist/stories/MessageStatus.stories.tsx +314 -0
  67. package/dist/stories/RichTextInput.stories.tsx +198 -0
  68. package/dist/stories/assets/logo.svg +19 -38
  69. package/dist/stories/assets/paperclip.svg +1 -4
  70. package/dist/stories/assets/search.svg +1 -5
  71. package/dist/stories/assets/sparkles.svg +7 -0
  72. package/dist/stories/examples.ts +47 -20
  73. package/dist/theme.d.ts +76 -13
  74. package/dist/types.d.ts +10 -0
  75. package/package.json +69 -66
  76. package/dist/CSVFileRenderer-CkRKGiCl.js.map +0 -1
  77. package/dist/DefaultFileRenderer-C1qZ57tG.js.map +0 -1
  78. package/dist/PDFFileRenderer-BBn2EVrV.js +0 -16
  79. package/dist/PDFFileRenderer-BBn2EVrV.js.map +0 -1
  80. package/dist/index-6CsqxEMx.js +0 -2257
  81. package/dist/index-6CsqxEMx.js.map +0 -1
  82. package/dist/utils/index.d.ts +0 -1
@@ -1,4 +1,4 @@
1
- import { Meta } from '@storybook/addon-docs/blocks';
1
+ import { Meta } from '@storybook/addon-docs';
2
2
 
3
3
  <Meta title="Docs/Intro" />
4
4
 
@@ -0,0 +1,314 @@
1
+ import type { Meta, StoryObj } from '@storybook/react';
2
+ import { useEffect, useState } from 'react';
3
+ import {
4
+ MessageStatus,
5
+ MessageStatusStep,
6
+ MessageStatusState
7
+ } from 'reachat';
8
+
9
+ export default {
10
+ title: 'Components/MessageStatus',
11
+ component: MessageStatus,
12
+ args: {
13
+ text: 'Analyzing your request...',
14
+ status: 'loading'
15
+ },
16
+ argTypes: {
17
+ status: {
18
+ control: 'select',
19
+ options: ['loading', 'complete', 'error'],
20
+ description: 'Current status state'
21
+ },
22
+ text: {
23
+ control: 'text',
24
+ description: 'Main status text to display'
25
+ },
26
+ steps: {
27
+ description: 'Optional sub-steps to display'
28
+ },
29
+ icon: {
30
+ description: 'Custom icon to display'
31
+ },
32
+ theme: {
33
+ description: 'Custom theme overrides'
34
+ },
35
+ className: {
36
+ description: 'Additional CSS classes'
37
+ }
38
+ }
39
+ } as Meta<typeof MessageStatus>;
40
+
41
+ type Story = StoryObj<typeof MessageStatus>;
42
+
43
+ export const Loading: Story = {
44
+ render: args => (
45
+ <div className="w-[400px]">
46
+ <MessageStatus {...args} />
47
+ </div>
48
+ )
49
+ };
50
+
51
+ export const Complete: Story = {
52
+ args: {
53
+ status: 'complete',
54
+ text: 'Analysis complete'
55
+ },
56
+ render: args => (
57
+ <div className="w-[400px]">
58
+ <MessageStatus {...args} />
59
+ </div>
60
+ )
61
+ };
62
+
63
+ export const Error: Story = {
64
+ args: {
65
+ status: 'error',
66
+ text: 'Failed to analyze request'
67
+ },
68
+ render: args => (
69
+ <div className="w-[400px]">
70
+ <MessageStatus {...args} />
71
+ </div>
72
+ )
73
+ };
74
+
75
+ export const WithSteps: Story = {
76
+ args: {
77
+ text: 'Processing your code...',
78
+ steps: [
79
+ { id: '1', text: 'Reading file contents', status: 'complete' },
80
+ { id: '2', text: 'Analyzing dependencies', status: 'complete' },
81
+ { id: '3', text: 'Running linter checks', status: 'loading' },
82
+ { id: '4', text: 'Generating suggestions', status: 'loading' }
83
+ ]
84
+ },
85
+ render: args => (
86
+ <div className="w-[400px]">
87
+ <MessageStatus {...args} />
88
+ </div>
89
+ )
90
+ };
91
+
92
+ export const WithStepsComplete: Story = {
93
+ args: {
94
+ status: 'complete',
95
+ text: 'Code analysis complete',
96
+ steps: [
97
+ { id: '1', text: 'Reading file contents', status: 'complete' },
98
+ { id: '2', text: 'Analyzing dependencies', status: 'complete' },
99
+ { id: '3', text: 'Running linter checks', status: 'complete' },
100
+ { id: '4', text: 'Generating suggestions', status: 'complete' }
101
+ ]
102
+ },
103
+ render: args => (
104
+ <div className="w-[400px]">
105
+ <MessageStatus {...args} />
106
+ </div>
107
+ )
108
+ };
109
+
110
+ export const WithStepsError: Story = {
111
+ args: {
112
+ status: 'error',
113
+ text: 'Analysis failed',
114
+ steps: [
115
+ { id: '1', text: 'Reading file contents', status: 'complete' },
116
+ { id: '2', text: 'Analyzing dependencies', status: 'complete' },
117
+ { id: '3', text: 'Running linter checks', status: 'error' }
118
+ ]
119
+ },
120
+ render: args => (
121
+ <div className="w-[400px]">
122
+ <MessageStatus {...args} />
123
+ </div>
124
+ )
125
+ };
126
+
127
+ export const AllStates: Story = {
128
+ render: () => (
129
+ <div className="w-[400px] space-y-4">
130
+ <MessageStatus status="loading" text="Searching files..." />
131
+ <MessageStatus status="complete" text="Search complete" />
132
+ <MessageStatus status="error" text="Search failed" />
133
+ </div>
134
+ )
135
+ };
136
+
137
+ export const InteractiveDemo: Story = {
138
+ render: () => {
139
+ const [status, setStatus] = useState<MessageStatusState>('loading');
140
+ const [steps, setSteps] = useState<MessageStatusStep[]>([
141
+ { id: '1', text: 'Searching codebase', status: 'loading' },
142
+ { id: '2', text: 'Analyzing results', status: 'loading' },
143
+ { id: '3', text: 'Generating response', status: 'loading' }
144
+ ]);
145
+ const [currentStep, setCurrentStep] = useState(0);
146
+
147
+ useEffect(() => {
148
+ const interval = setInterval(() => {
149
+ setCurrentStep(prev => {
150
+ const next = prev + 1;
151
+ if (next > steps.length) {
152
+ setStatus('complete');
153
+ clearInterval(interval);
154
+ return prev;
155
+ }
156
+ setSteps(prevSteps =>
157
+ prevSteps.map((step, idx) => ({
158
+ ...step,
159
+ status: idx < next ? 'complete' : 'loading'
160
+ }))
161
+ );
162
+ return next;
163
+ });
164
+ }, 1500);
165
+
166
+ return () => clearInterval(interval);
167
+ }, []);
168
+
169
+ const statusText =
170
+ status === 'complete'
171
+ ? 'Task completed successfully'
172
+ : 'Processing your request...';
173
+
174
+ return (
175
+ <div className="w-[400px]">
176
+ <MessageStatus status={status} text={statusText} steps={steps} />
177
+ </div>
178
+ );
179
+ }
180
+ };
181
+
182
+ export const ToolUsageExample: Story = {
183
+ render: () => {
184
+ const [steps, setSteps] = useState<MessageStatusStep[]>([]);
185
+ const [status, setStatus] = useState<MessageStatusState>('loading');
186
+ const [text, setText] = useState('Starting tool execution...');
187
+
188
+ useEffect(() => {
189
+ const timeline = [
190
+ {
191
+ delay: 500,
192
+ action: () => {
193
+ setText('Using Read tool...');
194
+ setSteps([{ id: '1', text: 'Reading package.json', status: 'loading' as const }]);
195
+ }
196
+ },
197
+ {
198
+ delay: 1500,
199
+ action: () => {
200
+ setSteps(prev =>
201
+ prev.map(s => (s.id === '1' ? { ...s, status: 'complete' as const } : s))
202
+ );
203
+ }
204
+ },
205
+ {
206
+ delay: 2000,
207
+ action: () => {
208
+ setText('Using Grep tool...');
209
+ setSteps(prev => [
210
+ ...prev,
211
+ { id: '2', text: 'Searching for imports', status: 'loading' as const }
212
+ ]);
213
+ }
214
+ },
215
+ {
216
+ delay: 3500,
217
+ action: () => {
218
+ setSteps(prev =>
219
+ prev.map(s => (s.id === '2' ? { ...s, status: 'complete' as const } : s))
220
+ );
221
+ }
222
+ },
223
+ {
224
+ delay: 4000,
225
+ action: () => {
226
+ setText('Using Edit tool...');
227
+ setSteps(prev => [
228
+ ...prev,
229
+ { id: '3', text: 'Modifying source file', status: 'loading' as const }
230
+ ]);
231
+ }
232
+ },
233
+ {
234
+ delay: 5500,
235
+ action: () => {
236
+ setSteps(prev =>
237
+ prev.map(s => (s.id === '3' ? { ...s, status: 'complete' as const } : s))
238
+ );
239
+ setText('Tools completed');
240
+ setStatus('complete');
241
+ }
242
+ }
243
+ ];
244
+
245
+ const timeouts = timeline.map(item =>
246
+ setTimeout(item.action, item.delay)
247
+ );
248
+
249
+ return () => timeouts.forEach(clearTimeout);
250
+ }, []);
251
+
252
+ return (
253
+ <div className="w-[400px]">
254
+ <MessageStatus status={status} text={text} steps={steps} />
255
+ </div>
256
+ );
257
+ }
258
+ };
259
+
260
+ export const MultipleStatuses: Story = {
261
+ render: () => (
262
+ <div className="w-[500px] space-y-3">
263
+ <MessageStatus
264
+ status="complete"
265
+ text="Read src/index.ts"
266
+ steps={[
267
+ { id: '1', text: '156 lines read', status: 'complete' }
268
+ ]}
269
+ />
270
+ <MessageStatus
271
+ status="complete"
272
+ text="Grep for dependencies"
273
+ steps={[
274
+ { id: '1', text: 'Found 12 matches', status: 'complete' }
275
+ ]}
276
+ />
277
+ <MessageStatus
278
+ status="loading"
279
+ text="Analyzing code patterns"
280
+ steps={[
281
+ { id: '1', text: 'Parsing AST', status: 'complete' },
282
+ { id: '2', text: 'Finding patterns', status: 'loading' }
283
+ ]}
284
+ />
285
+ </div>
286
+ )
287
+ };
288
+
289
+ export const CustomStyling: Story = {
290
+ args: {
291
+ text: 'Custom styled status',
292
+ className: 'bg-gradient-to-r from-purple-500/10 to-blue-500/10 border-purple-500/30'
293
+ },
294
+ render: args => (
295
+ <div className="w-[400px]">
296
+ <MessageStatus {...args} />
297
+ </div>
298
+ )
299
+ };
300
+
301
+ export const LongText: Story = {
302
+ args: {
303
+ text: 'Analyzing complex codebase with multiple files and dependencies to generate comprehensive suggestions',
304
+ steps: [
305
+ { id: '1', text: 'Scanning src/components directory for React components', status: 'complete' },
306
+ { id: '2', text: 'Analyzing TypeScript interfaces and type definitions', status: 'loading' }
307
+ ]
308
+ },
309
+ render: args => (
310
+ <div className="w-[400px]">
311
+ <MessageStatus {...args} />
312
+ </div>
313
+ )
314
+ };
@@ -0,0 +1,198 @@
1
+ import type { Meta, StoryObj } from '@storybook/react';
2
+ import { useState } from 'react';
3
+ import { RichTextInput, MentionItem, SlashCommandItem } from 'reachat';
4
+ import { ChatContext } from 'reachat';
5
+ import { chatTheme } from 'reachat';
6
+
7
+ const UserIcon = () => (
8
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" className="w-full h-full">
9
+ <path d="M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2" />
10
+ <circle cx="12" cy="7" r="4" />
11
+ </svg>
12
+ );
13
+
14
+ const HelpIcon = () => (
15
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" className="w-full h-full">
16
+ <circle cx="12" cy="12" r="10" />
17
+ <path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" />
18
+ <line x1="12" y1="17" x2="12.01" y2="17" />
19
+ </svg>
20
+ );
21
+
22
+ const ClearIcon = () => (
23
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" className="w-full h-full">
24
+ <path d="M21 4H8l-7 8 7 8h13a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2z" />
25
+ <line x1="18" y1="9" x2="12" y2="15" />
26
+ <line x1="12" y1="9" x2="18" y2="15" />
27
+ </svg>
28
+ );
29
+
30
+ const ImageIcon = () => (
31
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" className="w-full h-full">
32
+ <rect x="3" y="3" width="18" height="18" rx="2" ry="2" />
33
+ <circle cx="8.5" cy="8.5" r="1.5" />
34
+ <polyline points="21 15 16 10 5 21" />
35
+ </svg>
36
+ );
37
+
38
+ const CodeIcon = () => (
39
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" className="w-full h-full">
40
+ <polyline points="16 18 22 12 16 6" />
41
+ <polyline points="8 6 2 12 8 18" />
42
+ </svg>
43
+ );
44
+
45
+ const sampleMentions: MentionItem[] = [
46
+ { id: '1', label: 'John Doe', description: 'Engineering', icon: <UserIcon /> },
47
+ { id: '2', label: 'Jane Smith', description: 'Design', icon: <UserIcon /> },
48
+ { id: '3', label: 'Bob Wilson', description: 'Product', icon: <UserIcon /> }
49
+ ];
50
+
51
+ const sampleCommands: SlashCommandItem[] = [
52
+ { id: 'help', label: 'help', description: 'Show available commands', icon: <HelpIcon />, shortcut: '?' },
53
+ { id: 'clear', label: 'clear', description: 'Clear the conversation', icon: <ClearIcon /> },
54
+ { id: 'image', label: 'image', description: 'Generate an image', icon: <ImageIcon /> },
55
+ { id: 'code', label: 'code', description: 'Generate code snippet', icon: <CodeIcon /> }
56
+ ];
57
+
58
+ const Wrapper = ({ children }: { children: React.ReactNode }) => (
59
+ <ChatContext.Provider value={{ sessions: [], activeSessionId: null, theme: chatTheme }}>
60
+ {children}
61
+ </ChatContext.Provider>
62
+ );
63
+
64
+ export default {
65
+ title: 'Components/RichTextInput',
66
+ component: RichTextInput,
67
+ decorators: [
68
+ (Story) => (
69
+ <Wrapper>
70
+ <Story />
71
+ </Wrapper>
72
+ )
73
+ ],
74
+ parameters: {
75
+ layout: 'centered'
76
+ }
77
+ } as Meta<typeof RichTextInput>;
78
+
79
+ type Story = StoryObj<typeof RichTextInput>;
80
+
81
+ export const Basic: Story = {
82
+ render: () => {
83
+ const [value, setValue] = useState('');
84
+ const [submitted, setSubmitted] = useState('');
85
+
86
+ return (
87
+ <div className="w-[400px] space-y-4">
88
+ <div className="p-4 bg-white dark:bg-gray-950 rounded-lg border border-gray-200 dark:border-gray-700">
89
+ <RichTextInput
90
+ placeholder="Type a message..."
91
+ value={value}
92
+ onChange={setValue}
93
+ onSubmit={(text) => {
94
+ setSubmitted(text);
95
+ setValue('');
96
+ }}
97
+ />
98
+ </div>
99
+ <div className="text-sm space-y-2">
100
+ <div className="flex gap-2">
101
+ <span className="text-gray-500 w-20">onChange:</span>
102
+ <code className="text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded flex-1 min-h-[24px]">
103
+ {value || '(empty)'}
104
+ </code>
105
+ </div>
106
+ <div className="flex gap-2">
107
+ <span className="text-gray-500 w-20">onSubmit:</span>
108
+ <code className="text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded flex-1 min-h-[24px]">
109
+ {submitted || '(press Enter to submit)'}
110
+ </code>
111
+ </div>
112
+ </div>
113
+ </div>
114
+ );
115
+ }
116
+ };
117
+
118
+ export const WithMentions: Story = {
119
+ render: () => {
120
+ const [value, setValue] = useState('');
121
+ const [submitted, setSubmitted] = useState('');
122
+
123
+ return (
124
+ <div className="w-[400px] space-y-4">
125
+ <div className="p-4 bg-white dark:bg-gray-950 rounded-lg border border-gray-200 dark:border-gray-700">
126
+ <RichTextInput
127
+ placeholder="Type @ to mention someone..."
128
+ value={value}
129
+ onChange={setValue}
130
+ mentions={{
131
+ trigger: '@',
132
+ items: sampleMentions
133
+ }}
134
+ onSubmit={(text) => {
135
+ setSubmitted(text);
136
+ setValue('');
137
+ }}
138
+ />
139
+ </div>
140
+ <div className="text-sm space-y-2">
141
+ <div className="flex gap-2">
142
+ <span className="text-gray-500 w-20">onChange:</span>
143
+ <code className="text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded flex-1 min-h-[24px]">
144
+ {value || '(empty)'}
145
+ </code>
146
+ </div>
147
+ <div className="flex gap-2">
148
+ <span className="text-gray-500 w-20">onSubmit:</span>
149
+ <code className="text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded flex-1 min-h-[24px]">
150
+ {submitted || '(press Enter to submit)'}
151
+ </code>
152
+ </div>
153
+ </div>
154
+ </div>
155
+ );
156
+ }
157
+ };
158
+
159
+ export const WithSlashCommands: Story = {
160
+ render: () => {
161
+ const [value, setValue] = useState('');
162
+ const [submitted, setSubmitted] = useState('');
163
+
164
+ return (
165
+ <div className="w-[400px] space-y-4">
166
+ <div className="p-4 bg-white dark:bg-gray-950 rounded-lg border border-gray-200 dark:border-gray-700">
167
+ <RichTextInput
168
+ placeholder="Type / for commands..."
169
+ value={value}
170
+ onChange={setValue}
171
+ commands={{
172
+ trigger: '/',
173
+ items: sampleCommands
174
+ }}
175
+ onSubmit={(text) => {
176
+ setSubmitted(text);
177
+ setValue('');
178
+ }}
179
+ />
180
+ </div>
181
+ <div className="text-sm space-y-2">
182
+ <div className="flex gap-2">
183
+ <span className="text-gray-500 w-20">onChange:</span>
184
+ <code className="text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded flex-1 min-h-[24px]">
185
+ {value || '(empty)'}
186
+ </code>
187
+ </div>
188
+ <div className="flex gap-2">
189
+ <span className="text-gray-500 w-20">onSubmit:</span>
190
+ <code className="text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded flex-1 min-h-[24px]">
191
+ {submitted || '(press Enter to submit)'}
192
+ </code>
193
+ </div>
194
+ </div>
195
+ </div>
196
+ );
197
+ }
198
+ };
@@ -1,40 +1,21 @@
1
1
  <svg width="795" height="140" viewBox="0 0 795 140" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path
3
- d="M18.3191 17.5C10.2662 17.5 3.73579 24.0304 3.73579 32.0833V102.083L30.2775 84.5833H82.4858C90.5387 84.5833 97.0691 78.0529 97.0691 70V17.5H18.3191Z"
4
- fill="url(#paint0_linear_182_647)" />
5
- <path
6
- d="M137.902 61.2501V134.167L111.361 116.667H59.1525C51.0995 116.667 44.5691 110.136 44.5691 102.083V84.5834H82.4858C90.5387 84.5834 97.0691 78.053 97.0691 70.0001V46.6667H123.319C131.372 46.6667 137.902 53.1972 137.902 61.2501Z"
7
- fill="url(#paint1_linear_182_647)" />
8
- <path
9
- d="M251.987 103.6H237.683L224.147 80.2719H214.067V103.6H200.819V36.3999H227.699C233.939 36.3999 239.219 38.6079 243.539 42.9279C247.859 47.2479 250.067 52.5279 250.067 58.6719C250.067 67.0239 244.883 74.7039 237.107 78.2559L251.987 103.6ZM227.699 48.7839H200.819V68.6559H227.699C232.691 68.6559 236.819 64.1439 236.819 58.6719C236.819 53.1999 232.691 48.7839 227.699 48.7839Z"
10
- fill="currentColor" />
11
- <path
12
- d="M290.508 75.8559V90.9279H332.076V103.6H290.508V36.3999H331.596V49.0719H290.508V63.3759H329.196V75.8559H290.508Z"
13
- fill="currentColor" />
14
- <path
15
- d="M430.765 103.6H416.365L412.333 91.5039H385.549L381.517 103.6H367.213L390.733 36.3999H407.149L430.765 103.6ZM398.989 51.6639L385.549 91.5039H412.333L398.989 51.6639Z"
16
- fill="currentColor" />
17
- <path
18
- d="M497.445 104.944C487.365 104.944 479.013 101.584 472.389 94.8639C465.765 88.1439 462.501 79.8879 462.501 69.9999C462.501 60.1119 465.765 51.7599 472.389 45.1359C479.013 38.4159 487.365 35.0559 497.445 35.0559C509.637 35.0559 520.581 41.1999 526.341 50.8959L514.917 57.5199C511.557 51.4719 505.125 47.9199 497.445 47.9199C490.917 47.9199 485.637 49.9359 481.605 54.0639C477.669 58.1919 475.653 63.4719 475.653 69.9999C475.653 76.4319 477.669 81.7119 481.605 85.8399C485.637 89.9679 490.917 91.9839 497.445 91.9839C505.125 91.9839 511.749 88.3359 514.917 82.4799L526.341 89.1039C520.581 98.7999 509.733 104.944 497.445 104.944Z"
19
- fill="currentColor" />
20
- <path
21
- d="M603.407 63.0879V36.3999H616.559V103.6H603.407V75.7599H578.447V103.6H565.199V36.3999H578.447V63.0879H603.407Z"
22
- fill="currentColor" />
23
- <path
24
- d="M717.363 103.6H702.963L698.931 91.5039H672.147L668.115 103.6H653.811L677.331 36.3999H693.747L717.363 103.6ZM685.587 51.6639L672.147 91.5039H698.931L685.587 51.6639Z"
25
- fill="currentColor" />
26
- <path d="M744.741 36.3999H794.181V49.0719H776.037V103.6H762.789V49.0719H744.741V36.3999Z"
27
- fill="currentColor" />
28
- <defs>
29
- <linearGradient id="paint0_linear_182_647" x1="50.4025" y1="17.5" x2="50.4025" y2="102.083"
30
- gradientUnits="userSpaceOnUse">
31
- <stop stop-color="#105EFF" />
32
- <stop offset="1" stop-color="#2E2E77" />
33
- </linearGradient>
34
- <linearGradient id="paint1_linear_182_647" x1="141.706" y1="169.085" x2="61.445" y2="30.0709"
35
- gradientUnits="userSpaceOnUse">
36
- <stop stop-color="#105EFF" />
37
- <stop offset="1" stop-color="#105EFF" stop-opacity="0.71" />
38
- </linearGradient>
39
- </defs>
2
+ <path d="M18.3191 17.5C10.2662 17.5 3.73579 24.0304 3.73579 32.0833V102.083L30.2775 84.5833H82.4858C90.5387 84.5833 97.0691 78.0529 97.0691 70V17.5H18.3191Z" fill="url(#paint0_linear_182_647)"/>
3
+ <path d="M137.902 61.2501V134.167L111.361 116.667H59.1525C51.0995 116.667 44.5691 110.136 44.5691 102.083V84.5834H82.4858C90.5387 84.5834 97.0691 78.053 97.0691 70.0001V46.6667H123.319C131.372 46.6667 137.902 53.1972 137.902 61.2501Z" fill="url(#paint1_linear_182_647)"/>
4
+ <path d="M251.987 103.6H237.683L224.147 80.2719H214.067V103.6H200.819V36.3999H227.699C233.939 36.3999 239.219 38.6079 243.539 42.9279C247.859 47.2479 250.067 52.5279 250.067 58.6719C250.067 67.0239 244.883 74.7039 237.107 78.2559L251.987 103.6ZM227.699 48.7839H200.819V68.6559H227.699C232.691 68.6559 236.819 64.1439 236.819 58.6719C236.819 53.1999 232.691 48.7839 227.699 48.7839Z" fill="white"/>
5
+ <path d="M290.508 75.8559V90.9279H332.076V103.6H290.508V36.3999H331.596V49.0719H290.508V63.3759H329.196V75.8559H290.508Z" fill="white"/>
6
+ <path d="M430.765 103.6H416.365L412.333 91.5039H385.549L381.517 103.6H367.213L390.733 36.3999H407.149L430.765 103.6ZM398.989 51.6639L385.549 91.5039H412.333L398.989 51.6639Z" fill="white"/>
7
+ <path d="M497.445 104.944C487.365 104.944 479.013 101.584 472.389 94.8639C465.765 88.1439 462.501 79.8879 462.501 69.9999C462.501 60.1119 465.765 51.7599 472.389 45.1359C479.013 38.4159 487.365 35.0559 497.445 35.0559C509.637 35.0559 520.581 41.1999 526.341 50.8959L514.917 57.5199C511.557 51.4719 505.125 47.9199 497.445 47.9199C490.917 47.9199 485.637 49.9359 481.605 54.0639C477.669 58.1919 475.653 63.4719 475.653 69.9999C475.653 76.4319 477.669 81.7119 481.605 85.8399C485.637 89.9679 490.917 91.9839 497.445 91.9839C505.125 91.9839 511.749 88.3359 514.917 82.4799L526.341 89.1039C520.581 98.7999 509.733 104.944 497.445 104.944Z" fill="white"/>
8
+ <path d="M603.407 63.0879V36.3999H616.559V103.6H603.407V75.7599H578.447V103.6H565.199V36.3999H578.447V63.0879H603.407Z" fill="white"/>
9
+ <path d="M717.363 103.6H702.963L698.931 91.5039H672.147L668.115 103.6H653.811L677.331 36.3999H693.747L717.363 103.6ZM685.587 51.6639L672.147 91.5039H698.931L685.587 51.6639Z" fill="white"/>
10
+ <path d="M744.741 36.3999H794.181V49.0719H776.037V103.6H762.789V49.0719H744.741V36.3999Z" fill="white"/>
11
+ <defs>
12
+ <linearGradient id="paint0_linear_182_647" x1="50.4025" y1="17.5" x2="50.4025" y2="102.083" gradientUnits="userSpaceOnUse">
13
+ <stop stop-color="#105EFF"/>
14
+ <stop offset="1" stop-color="#2E2E77"/>
15
+ </linearGradient>
16
+ <linearGradient id="paint1_linear_182_647" x1="141.706" y1="169.085" x2="61.445" y2="30.0709" gradientUnits="userSpaceOnUse">
17
+ <stop stop-color="#105EFF"/>
18
+ <stop offset="1" stop-color="#105EFF" stop-opacity="0.71"/>
19
+ </linearGradient>
20
+ </defs>
40
21
  </svg>
@@ -1,4 +1 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" width="24px" height="24px">
2
- <path
3
- d="M25.3,56.007c-3.409,0-6.818-1.297-9.414-3.893c-2.595-2.596-3.893-6.005-3.893-9.415c0-3.409,1.298-6.819,3.893-9.414 l20.4-20.4c1.847-1.847,4.302-2.864,6.914-2.864c2.611,0,5.067,1.017,6.914,2.864c3.812,3.813,3.812,10.016,0,13.829l-20.4,20.4 c-2.438,2.439-6.385,2.441-8.828,0c-2.434-2.435-2.434-6.395,0-8.829l13.7-13.7c0.781-0.781,2.047-0.781,2.828,0 c0.781,0.781,0.781,2.047,0,2.828l-13.7,13.7c-0.874,0.875-0.874,2.297,0.001,3.172c0.847,0.846,2.324,0.846,3.171,0l20.4-20.4 c2.252-2.253,2.252-5.919,0-8.172c-1.092-1.091-2.543-1.692-4.086-1.692c-1.544,0-2.994,0.601-4.086,1.692l-20.4,20.4 c-1.815,1.816-2.723,4.201-2.723,6.586c0,2.385,0.908,4.77,2.723,6.586c1.816,1.815,4.201,2.723,6.586,2.723 c2.385,0,4.771-0.907,6.586-2.723l12.7-12.7c0.781-0.781,2.047-0.781,2.828,0c0.781,0.781,0.781,2.047,0,2.828l-12.7,12.7 C32.119,54.709,28.71,56.007,25.3,56.007z" fill="currentColor" />
4
- </svg>
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-paperclip"><path d="m21.44 11.05-9.19 9.19a6 6 0 0 1-8.49-8.49l8.57-8.57A4 4 0 1 1 18 8.84l-8.59 8.57a2 2 0 0 1-2.83-2.83l8.49-8.48"/></svg>
@@ -1,5 +1 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 18 18" fill="none">
2
- <path
3
- d="M7.75 2C10.92 2 13.5 4.58 13.5 7.75C13.5 9.06476 13.0552 10.2773 12.3096 11.2471L15.7812 14.7188C16.0743 15.0118 16.0743 15.4873 15.7812 15.7803C15.6353 15.9263 15.443 16 15.251 16H15.25C15.058 16 14.8657 15.9273 14.7197 15.7803L11.248 12.3086C10.2781 13.0547 9.06525 13.5 7.75 13.5C4.58 13.5 2 10.92 2 7.75C2 4.58 4.58 2 7.75 2ZM7.75 3.5C5.407 3.5 3.5 5.407 3.5 7.75C3.5 10.093 5.407 12 7.75 12C10.093 12 12 10.093 12 7.75C12 5.407 10.093 3.5 7.75 3.5Z"
4
- fill="currentColor" />
5
- </svg>
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-search"><circle cx="11" cy="11" r="8"/><path d="m21 21-4.3-4.3"/></svg>
@@ -0,0 +1,7 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
2
+ <path d="M12 3l1.912 5.813a2 2 0 0 0 1.275 1.275L21 12l-5.813 1.912a2 2 0 0 0-1.275 1.275L12 21l-1.912-5.813a2 2 0 0 0-1.275-1.275L3 12l5.813-1.912a2 2 0 0 0 1.275-1.275L12 3z"/>
3
+ <path d="M5 3v4"/>
4
+ <path d="M3 5h4"/>
5
+ <path d="M19 17v4"/>
6
+ <path d="M17 19h4"/>
7
+ </svg>