@exxatdesignux/ui 0.0.6 → 0.0.7
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/bin/init.mjs +29 -0
- package/package.json +7 -2
- package/template/.nvmrc +1 -0
- package/template/.prettierignore +7 -0
- package/template/.prettierrc +11 -0
- package/template/AGENTS.md +485 -0
- package/template/Logo/Exxat_Prism.svg +39 -0
- package/template/Logo/Exxat_one.svg +36 -0
- package/template/README.md +58 -0
- package/template/app/(app)/compliance/page.tsx +10 -0
- package/template/app/(app)/dashboard/loading.tsx +18 -0
- package/template/app/(app)/dashboard/page.tsx +36 -0
- package/template/app/(app)/data-list/[id]/page.tsx +28 -0
- package/template/app/(app)/data-list/new/page.tsx +31 -0
- package/template/app/(app)/data-list/page.tsx +10 -0
- package/template/app/(app)/error.tsx +43 -0
- package/template/app/(app)/help/page.tsx +34 -0
- package/template/app/(app)/layout.tsx +54 -0
- package/template/app/(app)/loading.tsx +18 -0
- package/template/app/(app)/question-bank/page.tsx +10 -0
- package/template/app/(app)/rotations/page.tsx +15 -0
- package/template/app/(app)/settings/page.tsx +17 -0
- package/template/app/(app)/sites/all/page.tsx +13 -0
- package/template/app/(app)/team/page.tsx +10 -0
- package/template/app/favicon.ico +0 -0
- package/template/app/globals.css +1811 -0
- package/template/app/layout.tsx +95 -0
- package/template/app/page.tsx +9 -0
- package/template/components/.gitkeep +0 -0
- package/template/components/app-sidebar-dynamic.tsx +15 -0
- package/template/components/app-sidebar.tsx +901 -0
- package/template/components/ask-leo-composer.tsx +216 -0
- package/template/components/ask-leo-sidebar.tsx +509 -0
- package/template/components/chart-area-interactive.tsx +293 -0
- package/template/components/charts-overview.tsx +2321 -0
- package/template/components/command-menu-01.tsx +133 -0
- package/template/components/command-menu-02.tsx +386 -0
- package/template/components/command-menu.tsx +182 -0
- package/template/components/compliance-board-view.tsx +134 -0
- package/template/components/compliance-client.tsx +92 -0
- package/template/components/compliance-list-view.tsx +59 -0
- package/template/components/compliance-page-header.tsx +89 -0
- package/template/components/compliance-table.tsx +525 -0
- package/template/components/dashboard-onboarding-gallery.tsx +13 -0
- package/template/components/dashboard-onboarding.tsx +21 -0
- package/template/components/dashboard-promo-banner.tsx +67 -0
- package/template/components/dashboard-quota-progress-card.tsx +369 -0
- package/template/components/dashboard-report-charts.tsx +69 -0
- package/template/components/dashboard-section-heading.tsx +68 -0
- package/template/components/dashboard-tabs.tsx +598 -0
- package/template/components/data-list-client.tsx +239 -0
- package/template/components/data-list-table-cells.test.tsx +22 -0
- package/template/components/data-list-table-cells.tsx +173 -0
- package/template/components/data-list-table.tsx +879 -0
- package/template/components/data-table/filter-date-calendar.tsx +38 -0
- package/template/components/data-table/filter-text-value-input.tsx +77 -0
- package/template/components/data-table/index.tsx +1612 -0
- package/template/components/data-table/pagination.tsx +256 -0
- package/template/components/data-table/types.ts +91 -0
- package/template/components/data-table/use-table-state.ts +566 -0
- package/template/components/data-view-dashboard-charts-compliance.tsx +960 -0
- package/template/components/data-view-dashboard-charts-team.tsx +968 -0
- package/template/components/data-view-dashboard-charts.tsx +1668 -0
- package/template/components/data-views/board-card-primitives.tsx +93 -0
- package/template/components/data-views/index.ts +41 -0
- package/template/components/data-views/list-page-board-card.tsx +192 -0
- package/template/components/data-views/list-page-board-template.tsx +122 -0
- package/template/components/data-views/placement-board-card.tsx +262 -0
- package/template/components/export-drawer.tsx +375 -0
- package/template/components/exxat-product-logo.tsx +453 -0
- package/template/components/form-layout-01.tsx +131 -0
- package/template/components/getting-started.tsx +625 -0
- package/template/components/key-metrics.tsx +920 -0
- package/template/components/leo-insight-indicator.tsx +364 -0
- package/template/components/leo-typing-dots.tsx +121 -0
- package/template/components/list-hub-status-badge.tsx +51 -0
- package/template/components/list-page-dashboard-charts.tsx +18 -0
- package/template/components/nav-documents.tsx +89 -0
- package/template/components/nav-main.tsx +58 -0
- package/template/components/nav-secondary.tsx +64 -0
- package/template/components/nav-user.tsx +190 -0
- package/template/components/new-placement-back-btn.tsx +28 -0
- package/template/components/new-placement-form.tsx +1066 -0
- package/template/components/onboarding/index.ts +4 -0
- package/template/components/onboarding/onboarding-01.tsx +7 -0
- package/template/components/onboarding/onboarding-02.tsx +7 -0
- package/template/components/onboarding/onboarding-03.tsx +7 -0
- package/template/components/onboarding/onboarding-04.tsx +7 -0
- package/template/components/page-header.tsx +57 -0
- package/template/components/placement-detail.tsx +438 -0
- package/template/components/placements-board-view.tsx +404 -0
- package/template/components/placements-list-view.tsx +285 -0
- package/template/components/placements-page-header.tsx +160 -0
- package/template/components/placements-table-columns.tsx +639 -0
- package/template/components/product-switcher.tsx +116 -0
- package/template/components/question-bank-board-view.tsx +205 -0
- package/template/components/question-bank-client.tsx +77 -0
- package/template/components/question-bank-list-view.tsx +59 -0
- package/template/components/question-bank-page-header.tsx +89 -0
- package/template/components/question-bank-table.tsx +586 -0
- package/template/components/rotations-empty-state.tsx +47 -0
- package/template/components/rotations-panel-activator.tsx +8 -0
- package/template/components/secondary-nav.tsx +394 -0
- package/template/components/secondary-panel.tsx +239 -0
- package/template/components/section-cards.tsx +106 -0
- package/template/components/settings-appearance-card.tsx +424 -0
- package/template/components/settings-client.tsx +537 -0
- package/template/components/settings-form-row.tsx +42 -0
- package/template/components/sidebar-auto-collapse.tsx +23 -0
- package/template/components/sidebar-auto-open.tsx +18 -0
- package/template/components/sidebar-shell.tsx +37 -0
- package/template/components/site-header.tsx +93 -0
- package/template/components/sites-all-client.tsx +154 -0
- package/template/components/sites-board-view.tsx +67 -0
- package/template/components/sites-list-view.tsx +47 -0
- package/template/components/sites-table.tsx +312 -0
- package/template/components/system-banner-slot.tsx +66 -0
- package/template/components/table-properties/column-row.tsx +90 -0
- package/template/components/table-properties/draggable-list.ts +49 -0
- package/template/components/table-properties/drawer-button.tsx +231 -0
- package/template/components/table-properties/drawer.tsx +1102 -0
- package/template/components/table-properties/filter-card.tsx +251 -0
- package/template/components/table-properties/index.ts +22 -0
- package/template/components/table-properties/sort-card.tsx +59 -0
- package/template/components/table-properties/types.ts +124 -0
- package/template/components/task-list-panel.tsx +98 -0
- package/template/components/task-priority-badge.tsx +28 -0
- package/template/components/team-board-view.tsx +114 -0
- package/template/components/team-client.tsx +93 -0
- package/template/components/team-list-view.tsx +62 -0
- package/template/components/team-page-header.tsx +92 -0
- package/template/components/team-table.tsx +525 -0
- package/template/components/templates/list-page.tsx +576 -0
- package/template/components/templates/primary-page-template.tsx +56 -0
- package/template/components/theme-color-sync.tsx +32 -0
- package/template/components/theme-provider.tsx +71 -0
- package/template/components/tinted-icon-disc.tsx +53 -0
- package/template/components/ui/ai-thinking-surface.tsx +121 -0
- package/template/components/ui/avatar.tsx +1 -0
- package/template/components/ui/badge.tsx +1 -0
- package/template/components/ui/banner.tsx +1 -0
- package/template/components/ui/breadcrumb.tsx +1 -0
- package/template/components/ui/button.tsx +1 -0
- package/template/components/ui/calendar.tsx +1 -0
- package/template/components/ui/card.tsx +1 -0
- package/template/components/ui/chart.tsx +1 -0
- package/template/components/ui/checkbox.tsx +1 -0
- package/template/components/ui/coach-mark.tsx +1 -0
- package/template/components/ui/collapsible.tsx +1 -0
- package/template/components/ui/command.tsx +1 -0
- package/template/components/ui/date-picker-field.tsx +1 -0
- package/template/components/ui/dialog.tsx +1 -0
- package/template/components/ui/dot-pattern.tsx +159 -0
- package/template/components/ui/drag-handle-grip.tsx +1 -0
- package/template/components/ui/drawer.tsx +1 -0
- package/template/components/ui/dropdown-menu.tsx +1 -0
- package/template/components/ui/field.tsx +1 -0
- package/template/components/ui/form.tsx +1 -0
- package/template/components/ui/input-group.tsx +1 -0
- package/template/components/ui/input-mask.tsx +1 -0
- package/template/components/ui/input.tsx +1 -0
- package/template/components/ui/kbd.tsx +1 -0
- package/template/components/ui/label.tsx +1 -0
- package/template/components/ui/leo-icon.tsx +726 -0
- package/template/components/ui/payment-card-fields.tsx +1 -0
- package/template/components/ui/popover.tsx +1 -0
- package/template/components/ui/radio-group.tsx +1 -0
- package/template/components/ui/select.tsx +1 -0
- package/template/components/ui/selection-tile-grid.tsx +1 -0
- package/template/components/ui/separator.tsx +1 -0
- package/template/components/ui/sheet.tsx +1 -0
- package/template/components/ui/sidebar.tsx +1 -0
- package/template/components/ui/skeleton.tsx +1 -0
- package/template/components/ui/sonner.tsx +1 -0
- package/template/components/ui/status-badge.tsx +1 -0
- package/template/components/ui/table.tsx +1 -0
- package/template/components/ui/tabs.tsx +1 -0
- package/template/components/ui/textarea.tsx +1 -0
- package/template/components/ui/tip.tsx +1 -0
- package/template/components/ui/toggle-group.tsx +1 -0
- package/template/components/ui/toggle-switch.tsx +1 -0
- package/template/components/ui/toggle.tsx +1 -0
- package/template/components/ui/tooltip.tsx +1 -0
- package/template/components/ui/view-segmented-control.tsx +1 -0
- package/template/components.json +27 -0
- package/template/contexts/chart-variant-context.tsx +35 -0
- package/template/contexts/command-menu-context.tsx +28 -0
- package/template/contexts/dashboard-view-context.tsx +35 -0
- package/template/contexts/product-context.tsx +38 -0
- package/template/contexts/system-banner-context.tsx +127 -0
- package/template/docs/command-menu-pattern.md +45 -0
- package/template/docs/data-views-pattern.md +160 -0
- package/template/ecosystem.config.cjs +20 -0
- package/template/eslint.config.mjs +18 -0
- package/template/fontawesome-subset.manifest.json +190 -0
- package/template/hooks/.gitkeep +0 -0
- package/template/hooks/use-app-theme.ts +1 -0
- package/template/hooks/use-coach-mark.ts +1 -0
- package/template/hooks/use-mobile.ts +1 -0
- package/template/hooks/use-mod-key-label.ts +1 -0
- package/template/lib/.gitkeep +0 -0
- package/template/lib/ask-leo-route-context.ts +133 -0
- package/template/lib/chart-keyboard-selection.test.ts +20 -0
- package/template/lib/chart-keyboard-selection.ts +17 -0
- package/template/lib/chart-line-dash.ts +16 -0
- package/template/lib/coach-mark-registry.ts +68 -0
- package/template/lib/command-menu-config.ts +127 -0
- package/template/lib/command-menu-search-data.ts +44 -0
- package/template/lib/conditional-rule-match.ts +32 -0
- package/template/lib/dashboard-customize-coach-mark.ts +18 -0
- package/template/lib/dashboard-layout-merge.ts +63 -0
- package/template/lib/data-list-display-options.ts +35 -0
- package/template/lib/data-list-persistence.ts +280 -0
- package/template/lib/data-list-view-surface.ts +58 -0
- package/template/lib/data-list-view.ts +29 -0
- package/template/lib/data-view-dashboard-storage.ts +101 -0
- package/template/lib/date-filter.ts +8 -0
- package/template/lib/dev-log.test.ts +28 -0
- package/template/lib/dev-log.ts +8 -0
- package/template/lib/editable-target.ts +10 -0
- package/template/lib/floating-sheet-panel.ts +72 -0
- package/template/lib/initials-from-name.ts +7 -0
- package/template/lib/list-page-table-properties.ts +52 -0
- package/template/lib/list-status-badges.ts +168 -0
- package/template/lib/logo-dev.ts +12 -0
- package/template/lib/mock/compliance-kpi.ts +61 -0
- package/template/lib/mock/compliance.ts +146 -0
- package/template/lib/mock/dashboard.ts +105 -0
- package/template/lib/mock/navigation.tsx +231 -0
- package/template/lib/mock/placements-kpi.ts +134 -0
- package/template/lib/mock/placements.ts +183 -0
- package/template/lib/mock/question-bank-kpi.ts +61 -0
- package/template/lib/mock/question-bank.ts +142 -0
- package/template/lib/mock/sites-directory.ts +16 -0
- package/template/lib/mock/sites-kpi.ts +25 -0
- package/template/lib/mock/team-kpi.ts +60 -0
- package/template/lib/mock/team.ts +118 -0
- package/template/lib/motion-ui.ts +17 -0
- package/template/lib/placement-board-card-layout.ts +79 -0
- package/template/lib/placement-lifecycle.ts +5 -0
- package/template/lib/row-height.ts +10 -0
- package/template/lib/stock-portrait.ts +11 -0
- package/template/lib/utils.test.ts +13 -0
- package/template/lib/utils.ts +1 -0
- package/template/next.config.mjs +15 -0
- package/template/package.json +83 -0
- package/template/postcss.config.mjs +8 -0
- package/template/public/.gitkeep +0 -0
- package/template/public/Illustration/Rotation.svg +74 -0
- package/template/public/avatars/user.svg +11 -0
- package/template/public/favicon/favicon.ico +0 -0
- package/template/public/favicon.ico +0 -0
- package/template/public/logos/exxat-one.svg +36 -0
- package/template/public/logos/exxat-prism.svg +39 -0
- package/template/public/mock-schools/emory.svg +4 -0
- package/template/public/mock-schools/rush.svg +4 -0
- package/template/scripts/fontawesome-subset-audit.mjs +190 -0
- package/template/scripts/pm2-startup-macos.sh +13 -0
- package/template/skills-lock.json +10 -0
- package/template/stores/app-store.ts +33 -0
- package/template/tests/setup.ts +1 -0
- package/template/tsconfig.json +35 -0
- package/template/types/react-payment-inputs.d.ts +19 -0
- package/template/vitest.config.ts +18 -0
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
"use client"
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* AskLeoComposer — adapted from @blocks-so/ai-01 (AI chat composer).
|
|
5
|
+
* Uses Exxat tokens (bg-card, border-border, etc.) and Font Awesome instead of Tabler.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
import * as React from "react"
|
|
9
|
+
|
|
10
|
+
import { Button } from "@/components/ui/button"
|
|
11
|
+
import {
|
|
12
|
+
DropdownMenu,
|
|
13
|
+
DropdownMenuContent,
|
|
14
|
+
DropdownMenuGroup,
|
|
15
|
+
DropdownMenuItem,
|
|
16
|
+
DropdownMenuTrigger,
|
|
17
|
+
} from "@/components/ui/dropdown-menu"
|
|
18
|
+
import { Textarea } from "@/components/ui/textarea"
|
|
19
|
+
import {
|
|
20
|
+
Tooltip,
|
|
21
|
+
TooltipContent,
|
|
22
|
+
TooltipTrigger,
|
|
23
|
+
} from "@/components/ui/tooltip"
|
|
24
|
+
import { cn } from "@/lib/utils"
|
|
25
|
+
|
|
26
|
+
export interface AskLeoComposerProps {
|
|
27
|
+
value: string
|
|
28
|
+
onChange: (value: string) => void
|
|
29
|
+
/** Called with trimmed message after send (composer clears afterward). */
|
|
30
|
+
onSubmit?: (message: string) => void
|
|
31
|
+
placeholder?: string
|
|
32
|
+
className?: string
|
|
33
|
+
/** Lets the parent swap pill vs card chrome when the field grows (multiline / long text). */
|
|
34
|
+
onExpandedChange?: (expanded: boolean) => void
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export const AskLeoComposer = React.forwardRef<HTMLTextAreaElement, AskLeoComposerProps>(
|
|
38
|
+
function AskLeoComposer(
|
|
39
|
+
{ value, onChange, onSubmit, placeholder = "Ask Leo anything…", className, onExpandedChange },
|
|
40
|
+
forwardedRef,
|
|
41
|
+
) {
|
|
42
|
+
const [isExpanded, setIsExpanded] = React.useState(false)
|
|
43
|
+
const fieldId = React.useId()
|
|
44
|
+
|
|
45
|
+
React.useEffect(() => {
|
|
46
|
+
onExpandedChange?.(isExpanded)
|
|
47
|
+
}, [isExpanded, onExpandedChange])
|
|
48
|
+
const innerRef = React.useRef<HTMLTextAreaElement>(null)
|
|
49
|
+
const fileInputRef = React.useRef<HTMLInputElement>(null)
|
|
50
|
+
|
|
51
|
+
const setTextareaRef = React.useCallback(
|
|
52
|
+
(node: HTMLTextAreaElement | null) => {
|
|
53
|
+
innerRef.current = node
|
|
54
|
+
if (typeof forwardedRef === "function") {
|
|
55
|
+
forwardedRef(node)
|
|
56
|
+
} else if (forwardedRef) {
|
|
57
|
+
;(forwardedRef as React.MutableRefObject<HTMLTextAreaElement | null>).current = node
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
[forwardedRef],
|
|
61
|
+
)
|
|
62
|
+
|
|
63
|
+
function handleSubmit(e: React.FormEvent) {
|
|
64
|
+
e.preventDefault()
|
|
65
|
+
const trimmed = value.trim()
|
|
66
|
+
if (!trimmed) return
|
|
67
|
+
onSubmit?.(trimmed)
|
|
68
|
+
onChange("")
|
|
69
|
+
setIsExpanded(false)
|
|
70
|
+
if (innerRef.current) {
|
|
71
|
+
innerRef.current.style.height = "auto"
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function handleTextareaChange(e: React.ChangeEvent<HTMLTextAreaElement>) {
|
|
76
|
+
onChange(e.target.value)
|
|
77
|
+
if (innerRef.current) {
|
|
78
|
+
innerRef.current.style.height = "auto"
|
|
79
|
+
innerRef.current.style.height = `${innerRef.current.scrollHeight}px`
|
|
80
|
+
}
|
|
81
|
+
setIsExpanded(e.target.value.length > 100 || e.target.value.includes("\n"))
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
function handleKeyDown(e: React.KeyboardEvent<HTMLTextAreaElement>) {
|
|
85
|
+
if (e.key === "Enter" && !e.shiftKey) {
|
|
86
|
+
e.preventDefault()
|
|
87
|
+
handleSubmit(e as unknown as React.FormEvent)
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
return (
|
|
92
|
+
<div className={cn("min-w-0 w-full", className)}>
|
|
93
|
+
<form onSubmit={handleSubmit} className="group/composer min-w-0 w-full" noValidate>
|
|
94
|
+
<label htmlFor={fieldId} className="sr-only">
|
|
95
|
+
Message to Leo
|
|
96
|
+
</label>
|
|
97
|
+
<input ref={fileInputRef} type="file" multiple className="sr-only" onChange={() => {}} />
|
|
98
|
+
|
|
99
|
+
<div
|
|
100
|
+
className={cn(
|
|
101
|
+
"min-w-0 w-full cursor-text overflow-hidden border border-border/80 bg-card transition-[border-radius,padding] duration-200 ease-out",
|
|
102
|
+
isExpanded
|
|
103
|
+
? "rounded-2xl px-2 py-2 shadow-none grid [grid-template-columns:minmax(0,1fr)] [grid-template-rows:auto_1fr_auto] [grid-template-areas:'header'_'primary'_'footer']"
|
|
104
|
+
: "rounded-full px-1 py-0.5 shadow-none grid [grid-template-columns:auto_minmax(0,1fr)_auto] [grid-template-rows:minmax(0,auto)] [grid-template-areas:'header_header_header'_'leading_primary_trailing'_'._footer_.']",
|
|
105
|
+
)}
|
|
106
|
+
>
|
|
107
|
+
<div
|
|
108
|
+
className={cn("flex min-h-0 min-w-0 w-full items-center overflow-x-hidden", {
|
|
109
|
+
"px-0.5 py-1": isExpanded,
|
|
110
|
+
"px-0.5 py-0": !isExpanded,
|
|
111
|
+
})}
|
|
112
|
+
style={{ gridArea: "primary" }}
|
|
113
|
+
>
|
|
114
|
+
<div className="max-h-52 min-h-0 min-w-0 flex-1 overflow-y-auto">
|
|
115
|
+
<Textarea
|
|
116
|
+
id={fieldId}
|
|
117
|
+
ref={setTextareaRef}
|
|
118
|
+
value={value}
|
|
119
|
+
onChange={handleTextareaChange}
|
|
120
|
+
onKeyDown={handleKeyDown}
|
|
121
|
+
placeholder={placeholder}
|
|
122
|
+
autoComplete="off"
|
|
123
|
+
className={cn(
|
|
124
|
+
"min-h-0 min-w-0 w-full max-w-full resize-none rounded-none border-0 bg-transparent p-0 text-sm leading-5 text-foreground shadow-none placeholder:text-foreground/55 focus-visible:border-transparent focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-0 md:text-sm dark:placeholder:text-foreground/50",
|
|
125
|
+
!isExpanded && "min-h-[1.25rem] py-0",
|
|
126
|
+
)}
|
|
127
|
+
rows={1}
|
|
128
|
+
/>
|
|
129
|
+
</div>
|
|
130
|
+
</div>
|
|
131
|
+
|
|
132
|
+
<div className={cn("flex shrink-0 items-center", { hidden: isExpanded })} style={{ gridArea: "leading" }}>
|
|
133
|
+
<DropdownMenu>
|
|
134
|
+
<Tooltip>
|
|
135
|
+
<TooltipTrigger asChild>
|
|
136
|
+
<DropdownMenuTrigger asChild>
|
|
137
|
+
<Button
|
|
138
|
+
type="button"
|
|
139
|
+
variant="ghost"
|
|
140
|
+
size="icon"
|
|
141
|
+
className="size-8 shrink-0 rounded-full hover:bg-accent"
|
|
142
|
+
aria-label="Add attachments"
|
|
143
|
+
>
|
|
144
|
+
<i className="fa-light fa-plus text-base text-muted-foreground" aria-hidden="true" />
|
|
145
|
+
</Button>
|
|
146
|
+
</DropdownMenuTrigger>
|
|
147
|
+
</TooltipTrigger>
|
|
148
|
+
<TooltipContent side="top" sideOffset={6} className="max-w-xs text-xs">
|
|
149
|
+
Add photos, files, and more
|
|
150
|
+
</TooltipContent>
|
|
151
|
+
</Tooltip>
|
|
152
|
+
|
|
153
|
+
<DropdownMenuContent align="start" className="max-w-xs rounded-2xl p-1.5">
|
|
154
|
+
<DropdownMenuGroup className="space-y-1">
|
|
155
|
+
<DropdownMenuItem
|
|
156
|
+
className="flex items-center gap-2 rounded-md"
|
|
157
|
+
onClick={() => fileInputRef.current?.click()}
|
|
158
|
+
>
|
|
159
|
+
<i className="fa-light fa-paperclip w-4 shrink-0 text-center opacity-60" aria-hidden="true" />
|
|
160
|
+
Add photos & files
|
|
161
|
+
</DropdownMenuItem>
|
|
162
|
+
<DropdownMenuItem className="flex items-center gap-2 rounded-md" onClick={() => {}}>
|
|
163
|
+
<i className="fa-light fa-robot w-4 shrink-0 text-center opacity-60" aria-hidden="true" />
|
|
164
|
+
Agent mode
|
|
165
|
+
</DropdownMenuItem>
|
|
166
|
+
<DropdownMenuItem className="flex items-center gap-2 rounded-md" onClick={() => {}}>
|
|
167
|
+
<i className="fa-light fa-magnifying-glass w-4 shrink-0 text-center opacity-60" aria-hidden="true" />
|
|
168
|
+
Deep Research
|
|
169
|
+
</DropdownMenuItem>
|
|
170
|
+
</DropdownMenuGroup>
|
|
171
|
+
</DropdownMenuContent>
|
|
172
|
+
</DropdownMenu>
|
|
173
|
+
</div>
|
|
174
|
+
|
|
175
|
+
<div
|
|
176
|
+
className="flex shrink-0 items-center gap-1"
|
|
177
|
+
style={{ gridArea: isExpanded ? "footer" : "trailing" }}
|
|
178
|
+
>
|
|
179
|
+
<div className="ms-auto flex items-center gap-0.5">
|
|
180
|
+
<Tooltip>
|
|
181
|
+
<TooltipTrigger asChild>
|
|
182
|
+
<Button
|
|
183
|
+
type="button"
|
|
184
|
+
variant="ghost"
|
|
185
|
+
size="icon"
|
|
186
|
+
className="size-8 shrink-0 rounded-full text-muted-foreground hover:bg-accent hover:text-foreground"
|
|
187
|
+
aria-label="Record audio message"
|
|
188
|
+
>
|
|
189
|
+
<i className="fa-light fa-microphone text-base" aria-hidden="true" />
|
|
190
|
+
</Button>
|
|
191
|
+
</TooltipTrigger>
|
|
192
|
+
<TooltipContent side="top" sideOffset={6} className="text-xs">
|
|
193
|
+
Record audio message
|
|
194
|
+
</TooltipContent>
|
|
195
|
+
</Tooltip>
|
|
196
|
+
|
|
197
|
+
{value.trim() ? (
|
|
198
|
+
<Tooltip>
|
|
199
|
+
<TooltipTrigger asChild>
|
|
200
|
+
<Button type="submit" size="icon" className="size-8 shrink-0 rounded-full" aria-label="Send message">
|
|
201
|
+
<i className="fa-light fa-paper-plane-top text-base" aria-hidden="true" />
|
|
202
|
+
</Button>
|
|
203
|
+
</TooltipTrigger>
|
|
204
|
+
<TooltipContent side="top" sideOffset={6} className="text-xs">
|
|
205
|
+
Send message
|
|
206
|
+
</TooltipContent>
|
|
207
|
+
</Tooltip>
|
|
208
|
+
) : null}
|
|
209
|
+
</div>
|
|
210
|
+
</div>
|
|
211
|
+
</div>
|
|
212
|
+
</form>
|
|
213
|
+
</div>
|
|
214
|
+
)
|
|
215
|
+
},
|
|
216
|
+
)
|