@dust-tt/sparkle 0.2.491 โ†’ 0.2.492

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.
@@ -1,17 +1,36 @@
1
1
  import { Meta, StoryFn } from "@storybook/react";
2
2
  import React, { useRef, useState } from "react";
3
3
 
4
- import { ConfettiBackground, Icon, TypingAnimation } from "@sparkle/components";
4
+ import {
5
+ Avatar,
6
+ ConfettiBackground,
7
+ Tooltip,
8
+ TypingAnimation,
9
+ } from "@sparkle/components";
5
10
  import { Button } from "@sparkle/components/Button";
6
11
  import {
7
- BookOpenIcon,
8
- BrainIcon,
9
- MagnifyingGlassIcon,
12
+ ActionBrainIcon,
13
+ ActionGlobeIcon,
14
+ ActionImageIcon,
15
+ ActionMagnifyingGlassIcon,
16
+ ActionScanIcon,
17
+ ActionTableIcon,
10
18
  PlayIcon,
11
- RobotIcon,
12
- TableIcon,
13
19
  } from "@sparkle/icons";
14
- import { GithubLogo, GoogleLogo, NotionLogo, SlackLogo } from "@sparkle/logo";
20
+ import {
21
+ BigQueryLogo,
22
+ ConfluenceLogo,
23
+ DriveLogo,
24
+ GithubLogo,
25
+ GongLogo,
26
+ IntercomLogo,
27
+ MicrosoftLogo,
28
+ NotionLogo,
29
+ SalesforceLogo,
30
+ SlackLogo,
31
+ SnowflakeLogo,
32
+ ZendeskLogo,
33
+ } from "@sparkle/logo";
15
34
 
16
35
  import {
17
36
  TourGuide,
@@ -22,7 +41,7 @@ import {
22
41
  } from "../components/TourGuide";
23
42
 
24
43
  export default {
25
- title: "Components/TourGuide",
44
+ title: "Modules/TourGuide",
26
45
  component: TourGuide,
27
46
  parameters: {
28
47
  layout: "fullscreen",
@@ -39,6 +58,28 @@ const Template: StoryFn = () => {
39
58
  setKey((k) => k + 1);
40
59
  };
41
60
  const referentRef = useRef<HTMLDivElement>(null);
61
+ const filteredAgents = [
62
+ {
63
+ name: "Translator",
64
+ emoji: "๐Ÿ’ฌ",
65
+ backgroundColor: "s-bg-green-200",
66
+ },
67
+ {
68
+ name: "TrailblazerGuard",
69
+ emoji: "๐Ÿ‘ฎ",
70
+ backgroundColor: "s-bg-blue-100",
71
+ },
72
+ {
73
+ name: "Transport",
74
+ emoji: "๐ŸšŒ",
75
+ backgroundColor: "s-bg-blue-200",
76
+ },
77
+ {
78
+ name: "TrendTracker",
79
+ emoji: "๐Ÿ˜ป",
80
+ backgroundColor: "s-bg-rose-50",
81
+ },
82
+ ] as const;
42
83
  return (
43
84
  <div className="s-relative s-min-h-screen s-w-full">
44
85
  <div className="s-absolute s-left-3 s-top-3">
@@ -75,28 +116,46 @@ const Template: StoryFn = () => {
75
116
  </TourGuideCardVisual>
76
117
  <TourGuideCardTitle>
77
118
  Welcome to the{" "}
78
- <span className="s-font-semibold s-text-brand-electric-blue">
119
+ <span className="s-font-semibold s-text-brand-hunter-green">
79
120
  Qonto
80
121
  </span>{" "}
81
122
  workspace.
82
123
  </TourGuideCardTitle>
83
124
  <TourGuideCardContent>
84
125
  {" "}
85
- Discover Dustโ€™s basics in 3 steps.
126
+ Discover the basics of Dust in 3 steps.
86
127
  </TourGuideCardContent>
87
128
  </TourGuideCard>
88
129
  <TourGuideCard anchorRef={centerRef}>
89
- <TourGuideCardVisual className="s-flex s-items-center s-justify-center s-bg-brand-support-green s-px-6 s-text-center">
90
- <span className="s-heading-5xl s-text-brand-hunter-green">
91
- <TypingAnimation text="@mentions" />
92
- </span>
130
+ <TourGuideCardVisual className="s-relative s-flex s-overflow-hidden s-bg-brand-support-green s-p-4 s-text-center">
131
+ <div className="s-flex s-gap-1">
132
+ <div className="s-flex s-gap-1">
133
+ <div className="s-heading-2xl s-text-highlight">@tra</div>
134
+ <div className="s-h-[32px] s-w-[3px] s-animate-cursor-blink s-bg-foreground" />
135
+ </div>
136
+ <div className="s-flex s-h-[240px] s-flex-col s-gap-3 s-rounded-xl s-border s-border-border s-bg-background s-p-3 s-pr-5 s-shadow-xl">
137
+ {filteredAgents.map((agent) => {
138
+ return (
139
+ <div
140
+ key={agent.name}
141
+ className="s-heading-base s-flex s-items-center s-gap-2 s-text-foreground"
142
+ >
143
+ <Avatar
144
+ size="sm"
145
+ emoji={agent.emoji}
146
+ backgroundColor={agent.backgroundColor}
147
+ />
148
+ {agent.name}
149
+ </div>
150
+ );
151
+ })}
152
+ </div>
153
+ </div>
93
154
  </TourGuideCardVisual>
94
155
  <TourGuideCardTitle>
95
156
  Use{" "}
96
- <span className="s-font-semibold s-text-brand-hunter-green">
97
- @mentions
98
- </span>{" "}
99
- to call Agents and&nbsp;start a conversation
157
+ <span className="s-font-semibold s-text-highlight">@mentions</span>{" "}
158
+ to call Agents and&nbsp;start a conversation.
100
159
  </TourGuideCardTitle>
101
160
  <TourGuideCardContent className="s-py-2">
102
161
  <Button
@@ -108,23 +167,198 @@ const Template: StoryFn = () => {
108
167
  </TourGuideCard>
109
168
  <TourGuideCard anchorRef={topRightRef}>
110
169
  <TourGuideCardVisual className="s-flex s-flex-col s-items-center s-justify-center s-gap-4 s-bg-brand-support-rose s-px-6 s-text-center">
111
- <div className="s-grid s-grid-cols-4 s-gap-2">
112
- <Icon visual={BookOpenIcon} size="lg" />
113
- <Icon visual={MagnifyingGlassIcon} size="lg" />
114
- <Icon visual={TableIcon} size="lg" />
115
- <Icon visual={BrainIcon} size="lg" />
116
- <Icon visual={NotionLogo} size="lg" />
117
- <Icon visual={GoogleLogo} size="lg" />
118
- <Icon visual={SlackLogo} size="lg" />
119
- <Icon visual={GithubLogo} size="lg" />
170
+ <div className="s-grid s-grid-cols-6 s-gap-2">
171
+ <Tooltip
172
+ label="Google Drive Connection"
173
+ trigger={
174
+ <Avatar
175
+ size="md"
176
+ icon={DriveLogo}
177
+ backgroundColor="s-bg-white"
178
+ />
179
+ }
180
+ />
181
+ <Tooltip
182
+ label="Notion Connection"
183
+ trigger={
184
+ <Avatar
185
+ size="md"
186
+ icon={NotionLogo}
187
+ backgroundColor="s-bg-white"
188
+ />
189
+ }
190
+ />
191
+ <Tooltip
192
+ label="Slack Connection"
193
+ trigger={
194
+ <Avatar
195
+ size="md"
196
+ icon={SlackLogo}
197
+ backgroundColor="s-bg-white"
198
+ />
199
+ }
200
+ />
201
+ <Tooltip
202
+ label="Snowflake Connection"
203
+ trigger={
204
+ <Avatar
205
+ size="md"
206
+ icon={SnowflakeLogo}
207
+ backgroundColor="s-bg-white"
208
+ />
209
+ }
210
+ />
211
+ <Tooltip
212
+ label="BigQuery Connection"
213
+ trigger={
214
+ <Avatar
215
+ size="md"
216
+ icon={BigQueryLogo}
217
+ backgroundColor="s-bg-white"
218
+ />
219
+ }
220
+ />
221
+ <Tooltip
222
+ label="Confluence Connection"
223
+ trigger={
224
+ <Avatar
225
+ size="md"
226
+ icon={ConfluenceLogo}
227
+ backgroundColor="s-bg-white"
228
+ />
229
+ }
230
+ />
231
+ <Tooltip
232
+ label="Intercom Connection"
233
+ trigger={
234
+ <Avatar
235
+ size="md"
236
+ icon={IntercomLogo}
237
+ backgroundColor="s-bg-white"
238
+ />
239
+ }
240
+ />
241
+ <Tooltip
242
+ label="Microsoft Connection"
243
+ trigger={
244
+ <Avatar
245
+ size="md"
246
+ icon={MicrosoftLogo}
247
+ backgroundColor="s-bg-white"
248
+ />
249
+ }
250
+ />
251
+ <Tooltip
252
+ label="Salesforce Connection"
253
+ trigger={
254
+ <Avatar
255
+ size="md"
256
+ icon={SalesforceLogo}
257
+ backgroundColor="s-bg-white"
258
+ />
259
+ }
260
+ />
261
+ <Tooltip
262
+ label="Zendesk Connection"
263
+ trigger={
264
+ <Avatar
265
+ size="md"
266
+ icon={ZendeskLogo}
267
+ backgroundColor="s-bg-white"
268
+ />
269
+ }
270
+ />
271
+ <Tooltip
272
+ label="GitHub Connection"
273
+ trigger={
274
+ <Avatar
275
+ size="md"
276
+ icon={GithubLogo}
277
+ backgroundColor="s-bg-white"
278
+ />
279
+ }
280
+ />
281
+ <Tooltip
282
+ label="Gong Connection"
283
+ trigger={
284
+ <Avatar
285
+ size="md"
286
+ icon={GongLogo}
287
+ backgroundColor="s-bg-white"
288
+ />
289
+ }
290
+ />
291
+ <Tooltip
292
+ label="Search data"
293
+ trigger={
294
+ <Avatar
295
+ size="md"
296
+ icon={ActionMagnifyingGlassIcon}
297
+ backgroundColor="s-bg-gray-700"
298
+ iconColor="s-text-gray-50"
299
+ />
300
+ }
301
+ />
302
+ <Tooltip
303
+ label="Quantitative analysis"
304
+ trigger={
305
+ <Avatar
306
+ size="md"
307
+ icon={ActionTableIcon}
308
+ backgroundColor="s-bg-gray-700"
309
+ iconColor="s-text-gray-50"
310
+ />
311
+ }
312
+ />
313
+ <Tooltip
314
+ label="Data extraction"
315
+ trigger={
316
+ <Avatar
317
+ size="md"
318
+ icon={ActionScanIcon}
319
+ backgroundColor="s-bg-gray-700"
320
+ iconColor="s-text-gray-50"
321
+ />
322
+ }
323
+ />
324
+ <Tooltip
325
+ label="Image generation"
326
+ trigger={
327
+ <Avatar
328
+ size="md"
329
+ icon={ActionImageIcon}
330
+ backgroundColor="s-bg-gray-700"
331
+ iconColor="s-text-gray-50"
332
+ />
333
+ }
334
+ />
335
+ <Tooltip
336
+ label="Web search and browsing"
337
+ trigger={
338
+ <Avatar
339
+ size="md"
340
+ icon={ActionGlobeIcon}
341
+ backgroundColor="s-bg-gray-700"
342
+ iconColor="s-text-gray-50"
343
+ />
344
+ }
345
+ />
346
+ <Tooltip
347
+ label="Reasoning"
348
+ trigger={
349
+ <Avatar
350
+ size="md"
351
+ icon={ActionBrainIcon}
352
+ backgroundColor="s-bg-gray-700"
353
+ iconColor="s-text-gray-50"
354
+ />
355
+ }
356
+ />
120
357
  </div>
121
- <span className="s-heading-2xl">
122
- <TypingAnimation text="Knowledge & Tools" />
123
- </span>
124
358
  </TourGuideCardVisual>
125
359
  <TourGuideCardTitle>
126
360
  Make your agents smarter with&nbsp;
127
- <span className="s-text-brand-red-rose">knowledge and tools</span>
361
+ <span className="s-text-brand-red-rose">knowledge and tools</span>.
128
362
  </TourGuideCardTitle>
129
363
  <TourGuideCardContent className="s-py-2">
130
364
  <Button
@@ -135,21 +369,92 @@ const Template: StoryFn = () => {
135
369
  </TourGuideCardContent>
136
370
  </TourGuideCard>
137
371
  <TourGuideCard anchorRef={bottomLeftRef}>
138
- <TourGuideCardVisual className="s-flex s-flex-col s-items-center s-justify-center s-gap-0 s-px-6 s-text-center">
139
- <Icon
140
- className="s-text-brand-orange-golden"
141
- visual={RobotIcon}
142
- size="xl"
143
- />
144
- <span className="s-heading-mono-2xl s-text-brand-orange-golden">
145
- <TypingAnimation text="Create an Agent" />
146
- </span>
372
+ <TourGuideCardVisual className="s-flex s-flex-col s-items-center s-justify-center s-gap-0 s-bg-brand-support-golden s-px-6 s-text-center">
373
+ <div className="s-grid s-grid-cols-4 s-gap-2">
374
+ <Tooltip
375
+ label="FeedbackHelper"
376
+ trigger={
377
+ <Avatar
378
+ size="lg"
379
+ emoji="โค๏ธ"
380
+ backgroundColor="s-bg-rose-100"
381
+ />
382
+ }
383
+ />
384
+ <Tooltip
385
+ label="RiskAnalyzer"
386
+ trigger={
387
+ <Avatar
388
+ size="lg"
389
+ emoji="๐Ÿ’€"
390
+ backgroundColor="s-bg-lime-800"
391
+ />
392
+ }
393
+ />
394
+ <Tooltip
395
+ label="EngagementPro"
396
+ trigger={
397
+ <Avatar
398
+ size="lg"
399
+ emoji="๐Ÿ˜‚"
400
+ backgroundColor="s-bg-golden-200"
401
+ />
402
+ }
403
+ />
404
+ <Tooltip
405
+ label="RunbookMaster"
406
+ trigger={
407
+ <Avatar
408
+ size="lg"
409
+ emoji="๐Ÿง‘โ€๐Ÿš€"
410
+ backgroundColor="s-bg-violet-800"
411
+ />
412
+ }
413
+ />
414
+ <Tooltip
415
+ label="BrandSpecialist"
416
+ trigger={
417
+ <Avatar
418
+ size="lg"
419
+ emoji="๐Ÿ‘•"
420
+ backgroundColor="s-bg-blue-200"
421
+ />
422
+ }
423
+ />
424
+ <Tooltip
425
+ label="CrisisManager"
426
+ trigger={
427
+ <Avatar size="lg" emoji="๐Ÿš’" backgroundColor="s-bg-red-200" />
428
+ }
429
+ />
430
+ <Tooltip
431
+ label="PerformanceCoach"
432
+ trigger={
433
+ <Avatar
434
+ size="lg"
435
+ emoji="๐Ÿ†"
436
+ backgroundColor="s-bg-yellow-200"
437
+ />
438
+ }
439
+ />
440
+ <Tooltip
441
+ label="StrategyPlanner"
442
+ trigger={
443
+ <Avatar
444
+ size="lg"
445
+ emoji="๐ŸŽฏ"
446
+ backgroundColor="s-bg-pink-100"
447
+ />
448
+ }
449
+ />
450
+ </div>
147
451
  </TourGuideCardVisual>
148
452
  <TourGuideCardTitle>
149
453
  Create new custom agents{" "}
150
454
  <span className="s-text-brand-orange-golden">
151
455
  designed for your needs
152
456
  </span>
457
+ .
153
458
  </TourGuideCardTitle>
154
459
  <TourGuideCardContent className="s-py-2">
155
460
  <Button