@arbidocs/react 0.4.5 → 0.4.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/README.md +12 -0
- package/dist/artifacts/index.cjs +59 -23
- package/dist/artifacts/index.cjs.map +1 -1
- package/dist/artifacts/index.d.cts +18 -2
- package/dist/artifacts/index.d.ts +18 -2
- package/dist/artifacts/index.js +56 -21
- package/dist/artifacts/index.js.map +1 -1
- package/dist/{chunk-DVRJFLE7.js → chunk-2ACHNDO6.js} +5 -5
- package/dist/chunk-2ACHNDO6.js.map +1 -0
- package/dist/{chunk-2DXS7L7M.cjs → chunk-CBJ3WOGD.cjs} +18 -3
- package/dist/chunk-CBJ3WOGD.cjs.map +1 -0
- package/dist/{chunk-ZY53R6I4.js → chunk-KWCHIAQ5.js} +18 -4
- package/dist/chunk-KWCHIAQ5.js.map +1 -0
- package/dist/{chunk-7V7B7OEM.cjs → chunk-OI55JRKT.cjs} +44 -28
- package/dist/chunk-OI55JRKT.cjs.map +1 -0
- package/dist/{chunk-H7ZZQ4ZV.js → chunk-RIHMIEXM.js} +44 -29
- package/dist/chunk-RIHMIEXM.js.map +1 -0
- package/dist/{chunk-7BDGLRQX.cjs → chunk-Z5YCRJY3.cjs} +6 -6
- package/dist/chunk-Z5YCRJY3.cjs.map +1 -0
- package/dist/index-CC6CvXEs.d.cts +1366 -0
- package/dist/index-CC6CvXEs.d.ts +1366 -0
- package/dist/index.cjs +952 -322
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +588 -28
- package/dist/index.d.ts +588 -28
- package/dist/index.js +642 -42
- package/dist/index.js.map +1 -1
- package/dist/ui/index.cjs +131 -127
- package/dist/ui/index.d.cts +24 -1324
- package/dist/ui/index.d.ts +24 -1324
- package/dist/ui/index.js +2 -2
- package/package.json +3 -3
- package/dist/chunk-2DXS7L7M.cjs.map +0 -1
- package/dist/chunk-7BDGLRQX.cjs.map +0 -1
- package/dist/chunk-7V7B7OEM.cjs.map +0 -1
- package/dist/chunk-DVRJFLE7.js.map +0 -1
- package/dist/chunk-H7ZZQ4ZV.js.map +0 -1
- package/dist/chunk-ZY53R6I4.js.map +0 -1
package/dist/ui/index.d.cts
CHANGED
|
@@ -1,1324 +1,24 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';
|
|
26
|
-
import { Components } from 'react-markdown';
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* Minimal, dependency-free tooltip — a drop-in API replacement for a Radix
|
|
30
|
-
* wrapper (same exports/props: Tooltip, TooltipTrigger, TooltipContent,
|
|
31
|
-
* TooltipProvider). Promoted verbatim from the ARBI app.
|
|
32
|
-
*
|
|
33
|
-
* It attaches the trigger via a STABLE `useCallback` ref (never setStates,
|
|
34
|
-
* identity never changes), so React 19 never detach/attach-thrashes.
|
|
35
|
-
*/
|
|
36
|
-
type Side = 'top' | 'bottom' | 'left' | 'right';
|
|
37
|
-
interface TooltipProviderProps {
|
|
38
|
-
children?: React$1.ReactNode;
|
|
39
|
-
/** Hover delay, in ms, inherited by every Tooltip below. Default 300. */
|
|
40
|
-
delayDuration?: number;
|
|
41
|
-
skipDelayDuration?: number;
|
|
42
|
-
disableHoverableContent?: boolean;
|
|
43
|
-
}
|
|
44
|
-
/**
|
|
45
|
-
* Sets tooltip defaults for the whole tree. Mount it once, at the app root —
|
|
46
|
-
* `AppShell` in @arbidocs/blocks does this so every app gets it for free.
|
|
47
|
-
* Tooltips still render without it, at the default delay.
|
|
48
|
-
*/
|
|
49
|
-
declare const TooltipProvider: ({ children, delayDuration }: TooltipProviderProps) => React$1.JSX.Element;
|
|
50
|
-
interface TooltipProps {
|
|
51
|
-
children: React$1.ReactNode;
|
|
52
|
-
/** Overrides the provider's delay for this one tooltip. */
|
|
53
|
-
delayDuration?: number;
|
|
54
|
-
}
|
|
55
|
-
declare function Tooltip({ children, delayDuration }: TooltipProps): React$1.JSX.Element;
|
|
56
|
-
interface TooltipTriggerProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
57
|
-
asChild?: boolean;
|
|
58
|
-
}
|
|
59
|
-
declare function TooltipTrigger({ asChild, children, ...props }: TooltipTriggerProps): React$1.JSX.Element;
|
|
60
|
-
interface TooltipContentProps extends React$1.HTMLAttributes<HTMLDivElement> {
|
|
61
|
-
side?: Side;
|
|
62
|
-
sideOffset?: number;
|
|
63
|
-
/** Minimum gap, in px, kept between the tip and the viewport edges. Default 8. */
|
|
64
|
-
collisionPadding?: number;
|
|
65
|
-
}
|
|
66
|
-
declare const TooltipContent: React$1.ForwardRefExoticComponent<TooltipContentProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
67
|
-
|
|
68
|
-
interface ColorClasses {
|
|
69
|
-
text: string;
|
|
70
|
-
bg: string;
|
|
71
|
-
}
|
|
72
|
-
interface IconToggleProps {
|
|
73
|
-
icon: LucideIcon;
|
|
74
|
-
isActive: boolean;
|
|
75
|
-
onToggle: (isActive: boolean) => void;
|
|
76
|
-
colors: ColorClasses;
|
|
77
|
-
fillWhenActive?: boolean;
|
|
78
|
-
disabled?: boolean;
|
|
79
|
-
/** Tooltip to show when disabled (e.g., "You cannot unshare this resource") */
|
|
80
|
-
disabledTooltip?: string;
|
|
81
|
-
showLabel?: boolean;
|
|
82
|
-
label?: string;
|
|
83
|
-
tooltipActive?: string;
|
|
84
|
-
tooltipInactive?: string;
|
|
85
|
-
tooltipMixed?: string;
|
|
86
|
-
isMixed?: boolean;
|
|
87
|
-
/** Set to false to disable tooltip (useful when nested inside another tooltip) */
|
|
88
|
-
showTooltip?: boolean;
|
|
89
|
-
'data-testid'?: string;
|
|
90
|
-
}
|
|
91
|
-
declare function IconToggle({ icon: Icon, isActive, onToggle, colors, fillWhenActive, disabled, disabledTooltip, showLabel, label, tooltipActive, tooltipInactive, tooltipMixed, isMixed, showTooltip, 'data-testid': dataTestId, }: IconToggleProps): React$1.JSX.Element;
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* DictateContext
|
|
95
|
-
*
|
|
96
|
-
* Lets `Input`/`Textarea`'s `dictate` prop work with a one-line `dictate` prop
|
|
97
|
-
* anywhere in the app, instead of threading a `transcribe` function through
|
|
98
|
-
* every field individually. A host app wraps its tree once with
|
|
99
|
-
* `<DictateProvider transcribe={...} onError={...}>`; every `dictate`-enabled
|
|
100
|
-
* field downstream then just works. Fields rendered outside a provider
|
|
101
|
-
* silently render without a mic button — dictation is a progressive
|
|
102
|
-
* enhancement, never a hard requirement.
|
|
103
|
-
*/
|
|
104
|
-
interface DictateContextValue {
|
|
105
|
-
transcribe: (blob: Blob) => Promise<string>;
|
|
106
|
-
onError?: (message: string) => void;
|
|
107
|
-
}
|
|
108
|
-
declare function DictateProvider({ transcribe, onError, children, }: DictateContextValue & {
|
|
109
|
-
children: React.ReactNode;
|
|
110
|
-
}): React$1.JSX.Element;
|
|
111
|
-
|
|
112
|
-
declare const Avatar: React$1.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarProps & React$1.RefAttributes<HTMLSpanElement>, "ref"> & React$1.RefAttributes<HTMLSpanElement>>;
|
|
113
|
-
declare const AvatarImage: React$1.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarImageProps & React$1.RefAttributes<HTMLImageElement>, "ref"> & React$1.RefAttributes<HTMLImageElement>>;
|
|
114
|
-
declare const AvatarFallback: React$1.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarFallbackProps & React$1.RefAttributes<HTMLSpanElement>, "ref"> & React$1.RefAttributes<HTMLSpanElement>>;
|
|
115
|
-
|
|
116
|
-
declare const badgeVariants: (props?: ({
|
|
117
|
-
variant?: "default" | "outline" | "accent" | "secondary" | "destructive" | null | undefined;
|
|
118
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
119
|
-
interface BadgeProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
|
|
120
|
-
}
|
|
121
|
-
declare function Badge({ className, variant, ...props }: BadgeProps): React$1.JSX.Element;
|
|
122
|
-
|
|
123
|
-
declare const buttonVariants: (props?: ({
|
|
124
|
-
variant?: "link" | "default" | "outline" | "accent" | "secondary" | "destructive" | "ghost" | null | undefined;
|
|
125
|
-
size?: "default" | "icon" | "sm" | "lg" | null | undefined;
|
|
126
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
127
|
-
interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
|
|
128
|
-
asChild?: boolean;
|
|
129
|
-
}
|
|
130
|
-
declare const Button: React$1.ForwardRefExoticComponent<ButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
131
|
-
|
|
132
|
-
declare const HoverCard: React$1.FC<HoverCardPrimitive.HoverCardProps>;
|
|
133
|
-
declare const HoverCardTrigger: React$1.ForwardRefExoticComponent<HoverCardPrimitive.HoverCardTriggerProps & React$1.RefAttributes<HTMLAnchorElement>>;
|
|
134
|
-
declare const HoverCardContent: React$1.ForwardRefExoticComponent<Omit<HoverCardPrimitive.HoverCardContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
135
|
-
|
|
136
|
-
/**
|
|
137
|
-
* Clean-ARBI design contract rule 3: borderless by default; shadows
|
|
138
|
-
* only when an element needs to read as elevated/floating.
|
|
139
|
-
*
|
|
140
|
-
* - `flat` (default): just a rounded surface, no border, no shadow.
|
|
141
|
-
* Separation comes from background + spacing.
|
|
142
|
-
* - `outline`: adds a single border for surfaces that need a visible
|
|
143
|
-
* edge (e.g. selectable list cards, embedded panels).
|
|
144
|
-
* - `elevated`: border + a subtle shadow for cards that should lift.
|
|
145
|
-
*
|
|
146
|
-
* Self-styled consumers that pass their own border/shadow classes keep
|
|
147
|
-
* working unchanged on the default `flat` base.
|
|
148
|
-
*/
|
|
149
|
-
declare const cardVariants: (props?: ({
|
|
150
|
-
variant?: "flat" | "outline" | "elevated" | null | undefined;
|
|
151
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
152
|
-
interface CardProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof cardVariants> {
|
|
153
|
-
}
|
|
154
|
-
declare const Card: React$1.ForwardRefExoticComponent<CardProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
155
|
-
declare const CardHeader: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
156
|
-
declare const CardTitle: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
157
|
-
declare const CardDescription: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
158
|
-
declare const CardContent: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
159
|
-
declare const CardFooter: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>>;
|
|
160
|
-
|
|
161
|
-
interface InputProps extends React$1.ComponentProps<'input'> {
|
|
162
|
-
/** Adds a small dictate-instead-of-type button inside the field's right
|
|
163
|
-
* edge (visible only while focused, or mid-recording) that appends
|
|
164
|
-
* transcribed speech to the field's value. Requires a `DictateProvider`
|
|
165
|
-
* ancestor supplying the host's transcribe endpoint — with none, this is
|
|
166
|
-
* a no-op (no button renders). Not meant for password/search/numeric/code
|
|
167
|
-
* fields — opt in per field, not on by default. */
|
|
168
|
-
dictate?: boolean;
|
|
169
|
-
}
|
|
170
|
-
declare const Input: React$1.ForwardRefExoticComponent<Omit<InputProps, "ref"> & React$1.RefAttributes<HTMLInputElement>>;
|
|
171
|
-
|
|
172
|
-
interface LabelProps extends React$1.LabelHTMLAttributes<HTMLLabelElement> {
|
|
173
|
-
className?: string;
|
|
174
|
-
}
|
|
175
|
-
declare const Label: React$1.ForwardRefExoticComponent<LabelProps & React$1.RefAttributes<HTMLLabelElement>>;
|
|
176
|
-
|
|
177
|
-
declare const Separator: React$1.ForwardRefExoticComponent<Omit<SeparatorPrimitive.SeparatorProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
178
|
-
|
|
179
|
-
interface TextareaProps extends React$1.ComponentProps<'textarea'> {
|
|
180
|
-
/** Adds a small dictate-instead-of-type button inside the field's top-right
|
|
181
|
-
* corner (visible only while focused, or mid-recording) that appends
|
|
182
|
-
* transcribed speech to the field's value. Requires a `DictateProvider`
|
|
183
|
-
* ancestor supplying the host's transcribe endpoint — with none, this is
|
|
184
|
-
* a no-op (no button renders). */
|
|
185
|
-
dictate?: boolean;
|
|
186
|
-
}
|
|
187
|
-
declare const Textarea: React$1.ForwardRefExoticComponent<Omit<TextareaProps, "ref"> & React$1.RefAttributes<HTMLTextAreaElement>>;
|
|
188
|
-
|
|
189
|
-
declare const Collapsible: React$1.ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
190
|
-
declare const CollapsibleTrigger: React$1.ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
191
|
-
declare const CollapsibleContent: React$1.ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleContentProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
192
|
-
|
|
193
|
-
declare const Progress: React$1.ForwardRefExoticComponent<Omit<ProgressPrimitive.ProgressProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
194
|
-
|
|
195
|
-
declare const ScrollArea: React$1.ForwardRefExoticComponent<Omit<ScrollAreaPrimitive.ScrollAreaProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
196
|
-
declare const ScrollBar: React$1.ForwardRefExoticComponent<Omit<ScrollAreaPrimitive.ScrollAreaScrollbarProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
197
|
-
|
|
198
|
-
declare const RadioGroup: React$1.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
199
|
-
declare const RadioGroupItem: React$1.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupItemProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
200
|
-
|
|
201
|
-
declare const Checkbox: React$1.ForwardRefExoticComponent<Omit<CheckboxPrimitive.CheckboxProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
202
|
-
|
|
203
|
-
declare const Switch: React$1.ForwardRefExoticComponent<Omit<SwitchPrimitives.SwitchProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
204
|
-
|
|
205
|
-
declare const Tabs: React$1.ForwardRefExoticComponent<TabsPrimitive.TabsProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
206
|
-
declare const TabsList: React$1.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsListProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
207
|
-
declare const TabsTrigger: React$1.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsTriggerProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
208
|
-
declare const TabsContent: React$1.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
209
|
-
|
|
210
|
-
declare const Table: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLTableElement> & React$1.RefAttributes<HTMLTableElement>>;
|
|
211
|
-
declare const TableHeader: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLTableSectionElement> & React$1.RefAttributes<HTMLTableSectionElement>>;
|
|
212
|
-
declare const TableBody: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLTableSectionElement> & React$1.RefAttributes<HTMLTableSectionElement>>;
|
|
213
|
-
declare const TableFooter: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLTableSectionElement> & React$1.RefAttributes<HTMLTableSectionElement>>;
|
|
214
|
-
declare const TableRow: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLTableRowElement> & React$1.RefAttributes<HTMLTableRowElement>>;
|
|
215
|
-
interface TableHeadProps extends React$1.ThHTMLAttributes<HTMLTableCellElement> {
|
|
216
|
-
className?: string;
|
|
217
|
-
}
|
|
218
|
-
declare const TableHead: React$1.ForwardRefExoticComponent<TableHeadProps & React$1.RefAttributes<HTMLTableCellElement>>;
|
|
219
|
-
interface TableCellProps extends React$1.TdHTMLAttributes<HTMLTableCellElement> {
|
|
220
|
-
className?: string;
|
|
221
|
-
}
|
|
222
|
-
declare const TableCell: React$1.ForwardRefExoticComponent<TableCellProps & React$1.RefAttributes<HTMLTableCellElement>>;
|
|
223
|
-
declare const TableCaption: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLTableCaptionElement> & React$1.RefAttributes<HTMLTableCaptionElement>>;
|
|
224
|
-
|
|
225
|
-
interface SliderProps extends React$1.ComponentPropsWithoutRef<typeof SliderPrimitive.Root> {
|
|
226
|
-
rangeClassName?: string;
|
|
227
|
-
}
|
|
228
|
-
declare const Slider: React$1.ForwardRefExoticComponent<SliderProps & React$1.RefAttributes<HTMLSpanElement>>;
|
|
229
|
-
|
|
230
|
-
declare const toggleVariants: (props?: ({
|
|
231
|
-
variant?: "default" | "outline" | null | undefined;
|
|
232
|
-
size?: "default" | "sm" | "lg" | null | undefined;
|
|
233
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
234
|
-
declare const Toggle: React$1.ForwardRefExoticComponent<Omit<TogglePrimitive.ToggleProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & VariantProps<(props?: ({
|
|
235
|
-
variant?: "default" | "outline" | null | undefined;
|
|
236
|
-
size?: "default" | "sm" | "lg" | null | undefined;
|
|
237
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
238
|
-
|
|
239
|
-
declare const ToggleGroup: React$1.ForwardRefExoticComponent<((Omit<ToggleGroupPrimitive.ToggleGroupSingleProps & React$1.RefAttributes<HTMLDivElement>, "ref"> | Omit<ToggleGroupPrimitive.ToggleGroupMultipleProps & React$1.RefAttributes<HTMLDivElement>, "ref">) & VariantProps<(props?: ({
|
|
240
|
-
variant?: "default" | "outline" | null | undefined;
|
|
241
|
-
size?: "default" | "sm" | "lg" | null | undefined;
|
|
242
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string>) & React$1.RefAttributes<HTMLDivElement>>;
|
|
243
|
-
declare const ToggleGroupItem: React$1.ForwardRefExoticComponent<Omit<ToggleGroupPrimitive.ToggleGroupItemProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & VariantProps<(props?: ({
|
|
244
|
-
variant?: "default" | "outline" | null | undefined;
|
|
245
|
-
size?: "default" | "sm" | "lg" | null | undefined;
|
|
246
|
-
} & class_variance_authority_types.ClassProp) | undefined) => string> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
247
|
-
|
|
248
|
-
declare const Dialog: React$1.FC<DialogPrimitive.DialogProps>;
|
|
249
|
-
declare const DialogTrigger: React$1.ForwardRefExoticComponent<DialogPrimitive.DialogTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
250
|
-
declare const DialogPortal: React$1.FC<DialogPrimitive.DialogPortalProps>;
|
|
251
|
-
declare const DialogClose: React$1.ForwardRefExoticComponent<DialogPrimitive.DialogCloseProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
252
|
-
declare const DialogOverlay: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
253
|
-
/**
|
|
254
|
-
* Where the dialog sits on a PHONE (< 640px). Wider screens always get a centred dialog.
|
|
255
|
-
* - `center`: centred box with a 1rem margin (small prompts and confirmations).
|
|
256
|
-
* - `sheet`: bottom sheet, full width, rounded top corners (forms and pickers).
|
|
257
|
-
* - `full`: full-height sheet that stops below the status bar (large editors, wizards).
|
|
258
|
-
*/
|
|
259
|
-
type DialogPresentation = 'center' | 'sheet' | 'full';
|
|
260
|
-
declare const DialogContent: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
261
|
-
hideCloseButton?: boolean;
|
|
262
|
-
/** Phone presentation (see {@link DialogPresentation}). Defaults to `center`. */
|
|
263
|
-
presentation?: DialogPresentation;
|
|
264
|
-
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
265
|
-
declare const DialogHeader: {
|
|
266
|
-
({ className, ...props }: React$1.HTMLAttributes<HTMLDivElement>): React$1.JSX.Element;
|
|
267
|
-
displayName: string;
|
|
268
|
-
};
|
|
269
|
-
declare const DialogFooter: {
|
|
270
|
-
({ className, ...props }: React$1.HTMLAttributes<HTMLDivElement>): React$1.JSX.Element;
|
|
271
|
-
displayName: string;
|
|
272
|
-
};
|
|
273
|
-
declare const DialogTitle: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogTitleProps & React$1.RefAttributes<HTMLHeadingElement>, "ref"> & React$1.RefAttributes<HTMLHeadingElement>>;
|
|
274
|
-
declare const DialogDescription: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogDescriptionProps & React$1.RefAttributes<HTMLParagraphElement>, "ref"> & React$1.RefAttributes<HTMLParagraphElement>>;
|
|
275
|
-
|
|
276
|
-
declare const Popover: React$1.FC<PopoverPrimitive.PopoverProps>;
|
|
277
|
-
declare const PopoverTrigger: React$1.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
278
|
-
declare const PopoverAnchor: React$1.ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
279
|
-
declare const PopoverContent: React$1.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
280
|
-
container?: HTMLElement | null;
|
|
281
|
-
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
282
|
-
|
|
283
|
-
/** One row of a mark's menu. Give it `onSelect`, or an `href` for a real link row. */
|
|
284
|
-
interface MarkMenuItem {
|
|
285
|
-
id: string;
|
|
286
|
-
label: string;
|
|
287
|
-
/** Runs when the row is chosen; the menu closes afterwards. */
|
|
288
|
-
onSelect?: () => void;
|
|
289
|
-
/** Renders the row as a link (no `onSelect` needed). */
|
|
290
|
-
href?: string;
|
|
291
|
-
/** The headline action: listed first, set a little larger, and run by a plain mouse click. */
|
|
292
|
-
primary?: boolean;
|
|
293
|
-
destructive?: boolean;
|
|
294
|
-
testId?: string;
|
|
295
|
-
}
|
|
296
|
-
interface MarkMenuProps extends Omit<HTMLAttributes<HTMLElement>, 'children' | 'onClick'> {
|
|
297
|
-
/** The element the mark itself is: a real link or an inline span. */
|
|
298
|
-
as?: 'a' | 'span';
|
|
299
|
-
href?: string;
|
|
300
|
-
/** Rows of the menu. The `primary` one (else the first) is the mark's default action. */
|
|
301
|
-
items: MarkMenuItem[];
|
|
302
|
-
/** Optional read-only content above the rows (a quoted passage, a note, a label name). */
|
|
303
|
-
preview?: ReactNode;
|
|
304
|
-
/** Accessible name of the menu. */
|
|
305
|
-
menuLabel: string;
|
|
306
|
-
/** A plain mouse click runs the primary row (default). Touch and keyboard always open the menu. */
|
|
307
|
-
shouldClickRunPrimary?: boolean;
|
|
308
|
-
/** Hover delay before the menu opens (ms). */
|
|
309
|
-
openDelay?: number;
|
|
310
|
-
closeDelay?: number;
|
|
311
|
-
testId?: string;
|
|
312
|
-
menuTestId?: string;
|
|
313
|
-
/** The mark element, for hosts that move focus back to it. */
|
|
314
|
-
triggerRef?: Ref<HTMLElement>;
|
|
315
|
-
children: ReactNode;
|
|
316
|
-
}
|
|
317
|
-
/**
|
|
318
|
-
* The ONE contextual menu of every inline mark (link, bookmark, citation, label, note).
|
|
319
|
-
*
|
|
320
|
-
* The mark stays quiet text. A compact popover opens on hover (short delay) and on keyboard focus;
|
|
321
|
-
* on touch a tap opens it instead of acting, so the primary row is one deliberate tap away. A
|
|
322
|
-
* plain mouse click runs the primary action, so existing click behaviour is unchanged.
|
|
323
|
-
* Keyboard: Enter/Space/ArrowDown open it and move into it, arrows move, Escape closes and
|
|
324
|
-
* returns focus to the mark. Rows are 44px high on coarse pointers.
|
|
325
|
-
*/
|
|
326
|
-
declare function MarkMenu({ as, href, items, preview, menuLabel, shouldClickRunPrimary, openDelay, closeDelay, testId, menuTestId, triggerRef: externalRef, className, children, onPointerDown, onPointerEnter, onPointerLeave, onFocus, onBlur, onKeyDown, ...rest }: MarkMenuProps): React$1.JSX.Element;
|
|
327
|
-
|
|
328
|
-
declare const DropdownMenu: React$1.FC<DropdownMenuPrimitive.DropdownMenuProps>;
|
|
329
|
-
declare const DropdownMenuTrigger: React$1.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
330
|
-
declare const DropdownMenuGroup: React$1.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuGroupProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
331
|
-
declare const DropdownMenuPortal: React$1.FC<DropdownMenuPrimitive.DropdownMenuPortalProps>;
|
|
332
|
-
declare const DropdownMenuSub: React$1.FC<DropdownMenuPrimitive.DropdownMenuSubProps>;
|
|
333
|
-
declare const DropdownMenuRadioGroup: React$1.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuRadioGroupProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
334
|
-
declare const DropdownMenuSubTrigger: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubTriggerProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
335
|
-
inset?: boolean;
|
|
336
|
-
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
337
|
-
declare const DropdownMenuSubContent: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
338
|
-
declare const DropdownMenuContent: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
339
|
-
declare const DropdownMenuItem: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
340
|
-
inset?: boolean;
|
|
341
|
-
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
342
|
-
declare const DropdownMenuCheckboxItem: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuCheckboxItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
343
|
-
declare const DropdownMenuRadioItem: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuRadioItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
344
|
-
declare const DropdownMenuLabel: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuLabelProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
345
|
-
inset?: boolean;
|
|
346
|
-
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
347
|
-
declare const DropdownMenuSeparator: React$1.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSeparatorProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
348
|
-
declare const DropdownMenuShortcut: {
|
|
349
|
-
({ className, ...props }: React$1.HTMLAttributes<HTMLSpanElement>): React$1.JSX.Element;
|
|
350
|
-
displayName: string;
|
|
351
|
-
};
|
|
352
|
-
|
|
353
|
-
declare const Select: React$1.FC<SelectPrimitive.SelectProps>;
|
|
354
|
-
declare const SelectGroup: React$1.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
355
|
-
declare const SelectValue: React$1.ForwardRefExoticComponent<SelectPrimitive.SelectValueProps & React$1.RefAttributes<HTMLSpanElement>>;
|
|
356
|
-
declare const SelectTrigger: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
357
|
-
declare const SelectScrollUpButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
358
|
-
declare const SelectScrollDownButton: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
359
|
-
declare const SelectContent: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
360
|
-
declare const SelectLabel: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
361
|
-
declare const SelectItem: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
362
|
-
declare const SelectSeparator: React$1.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
363
|
-
|
|
364
|
-
declare const Command: React$1.ForwardRefExoticComponent<Omit<{
|
|
365
|
-
children?: React$1.ReactNode;
|
|
366
|
-
} & Pick<Pick<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
367
|
-
ref?: React$1.Ref<HTMLDivElement>;
|
|
368
|
-
} & {
|
|
369
|
-
asChild?: boolean;
|
|
370
|
-
}, "key" | "asChild" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
371
|
-
label?: string;
|
|
372
|
-
shouldFilter?: boolean;
|
|
373
|
-
filter?: (value: string, search: string, keywords?: string[]) => number;
|
|
374
|
-
defaultValue?: string;
|
|
375
|
-
value?: string;
|
|
376
|
-
onValueChange?: (value: string) => void;
|
|
377
|
-
loop?: boolean;
|
|
378
|
-
disablePointerSelection?: boolean;
|
|
379
|
-
vimBindings?: boolean;
|
|
380
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
381
|
-
declare const CommandDialog: ({ children, ...props }: DialogProps) => React$1.JSX.Element;
|
|
382
|
-
declare const CommandInput: React$1.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<React$1.DetailedHTMLProps<React$1.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof React$1.InputHTMLAttributes<HTMLInputElement>> & {
|
|
383
|
-
ref?: React$1.Ref<HTMLInputElement>;
|
|
384
|
-
} & {
|
|
385
|
-
asChild?: boolean;
|
|
386
|
-
}, "key" | "asChild" | keyof React$1.InputHTMLAttributes<HTMLInputElement>>, "value" | "type" | "onChange"> & {
|
|
387
|
-
value?: string;
|
|
388
|
-
onValueChange?: (search: string) => void;
|
|
389
|
-
} & React$1.RefAttributes<HTMLInputElement>, "ref"> & React$1.RefAttributes<HTMLInputElement>>;
|
|
390
|
-
declare const CommandList: React$1.ForwardRefExoticComponent<Omit<{
|
|
391
|
-
children?: React$1.ReactNode;
|
|
392
|
-
} & Pick<Pick<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
393
|
-
ref?: React$1.Ref<HTMLDivElement>;
|
|
394
|
-
} & {
|
|
395
|
-
asChild?: boolean;
|
|
396
|
-
}, "key" | "asChild" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
397
|
-
label?: string;
|
|
398
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
399
|
-
declare const CommandEmpty: React$1.ForwardRefExoticComponent<Omit<{
|
|
400
|
-
children?: React$1.ReactNode;
|
|
401
|
-
} & Pick<Pick<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
402
|
-
ref?: React$1.Ref<HTMLDivElement>;
|
|
403
|
-
} & {
|
|
404
|
-
asChild?: boolean;
|
|
405
|
-
}, "key" | "asChild" | keyof React$1.HTMLAttributes<HTMLDivElement>> & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
406
|
-
declare const CommandGroup: React$1.ForwardRefExoticComponent<Omit<{
|
|
407
|
-
children?: React$1.ReactNode;
|
|
408
|
-
} & Omit<Pick<Pick<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
409
|
-
ref?: React$1.Ref<HTMLDivElement>;
|
|
410
|
-
} & {
|
|
411
|
-
asChild?: boolean;
|
|
412
|
-
}, "key" | "asChild" | keyof React$1.HTMLAttributes<HTMLDivElement>>, "value" | "heading"> & {
|
|
413
|
-
heading?: React$1.ReactNode;
|
|
414
|
-
value?: string;
|
|
415
|
-
forceMount?: boolean;
|
|
416
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
417
|
-
declare const CommandSeparator: React$1.ForwardRefExoticComponent<Omit<Pick<Pick<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
418
|
-
ref?: React$1.Ref<HTMLDivElement>;
|
|
419
|
-
} & {
|
|
420
|
-
asChild?: boolean;
|
|
421
|
-
}, "key" | "asChild" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
422
|
-
alwaysRender?: boolean;
|
|
423
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
424
|
-
declare const CommandItem: React$1.ForwardRefExoticComponent<Omit<{
|
|
425
|
-
children?: React$1.ReactNode;
|
|
426
|
-
} & Omit<Pick<Pick<React$1.DetailedHTMLProps<React$1.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React$1.HTMLAttributes<HTMLDivElement>> & {
|
|
427
|
-
ref?: React$1.Ref<HTMLDivElement>;
|
|
428
|
-
} & {
|
|
429
|
-
asChild?: boolean;
|
|
430
|
-
}, "key" | "asChild" | keyof React$1.HTMLAttributes<HTMLDivElement>>, "value" | "onSelect" | "disabled"> & {
|
|
431
|
-
disabled?: boolean;
|
|
432
|
-
onSelect?: (value: string) => void;
|
|
433
|
-
value?: string;
|
|
434
|
-
keywords?: string[];
|
|
435
|
-
forceMount?: boolean;
|
|
436
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
437
|
-
declare const CommandShortcut: {
|
|
438
|
-
({ className, ...props }: React$1.HTMLAttributes<HTMLSpanElement>): React$1.JSX.Element;
|
|
439
|
-
displayName: string;
|
|
440
|
-
};
|
|
441
|
-
|
|
442
|
-
interface MarkdownRendererProps {
|
|
443
|
-
/** Markdown content to render. */
|
|
444
|
-
children: string;
|
|
445
|
-
/** Custom component overrides merged on top of the defaults. */
|
|
446
|
-
components?: Partial<Components>;
|
|
447
|
-
/**
|
|
448
|
-
* When true, signals heavy custom components (via `MarkdownStreamingContext`)
|
|
449
|
-
* to defer their work while tokens are still arriving. Defaults to false.
|
|
450
|
-
*/
|
|
451
|
-
isStreaming?: boolean;
|
|
452
|
-
/** Extra classes on the wrapper (font-size, prose width, etc.). */
|
|
453
|
-
className?: string;
|
|
454
|
-
/** Overrides the `data-testid` on the wrapper (default `markdown-renderer`). */
|
|
455
|
-
testId?: string;
|
|
456
|
-
}
|
|
457
|
-
declare function MarkdownRendererComponent({ children, components: customComponents, isStreaming, className, testId, }: MarkdownRendererProps): React__default.JSX.Element;
|
|
458
|
-
/**
|
|
459
|
-
* Memoised so a stable message in a long thread doesn't re-parse when unrelated
|
|
460
|
-
* tokens arrive elsewhere; a streaming message gets a fresh `children` each flush
|
|
461
|
-
* and re-renders (only its trailing block re-parses, thanks to `MemoizedBlock`).
|
|
462
|
-
*/
|
|
463
|
-
declare const MarkdownRenderer: React__default.MemoExoticComponent<typeof MarkdownRendererComponent>;
|
|
464
|
-
|
|
465
|
-
/**
|
|
466
|
-
* Signals to `MarkdownRenderer`'s component overrides that the surrounding
|
|
467
|
-
* message is still streaming tokens. Heavy renderers can defer their work while
|
|
468
|
-
* this is true to avoid burning CPU on partially complete fences and to keep the
|
|
469
|
-
* UI responsive during long generations.
|
|
470
|
-
*
|
|
471
|
-
* Default `false` means non-streaming usages (parsed documents, static answers,
|
|
472
|
-
* DM bubbles) get the full rendering with no behaviour change.
|
|
473
|
-
*/
|
|
474
|
-
declare const MarkdownStreamingContext: React$1.Context<boolean>;
|
|
475
|
-
|
|
476
|
-
declare function splitMarkdownBlocks(content: string): string[];
|
|
477
|
-
|
|
478
|
-
declare function AiMarkdown({ children, className, isStreaming, }: {
|
|
479
|
-
children: string;
|
|
480
|
-
className?: string;
|
|
481
|
-
isStreaming?: boolean;
|
|
482
|
-
}): React$1.JSX.Element;
|
|
483
|
-
|
|
484
|
-
/**
|
|
485
|
-
* Brand-neutral presentational component overrides for react-markdown, shared by
|
|
486
|
-
* every markdown surface in the workspace (the monolith's `MarkdownRenderer` and
|
|
487
|
-
* the AI kit's `AiMarkdown`). One house style for headings, lists, tables and the
|
|
488
|
-
* inline text elements — token-based, so it themes per app.
|
|
489
|
-
*
|
|
490
|
-
* Deliberately excluded (kept per-consumer): `a` (external-link confirm vs
|
|
491
|
-
* plain), `code`/`pre` (rich CodeBlock + Mermaid vs inline), `span` (doc-entity
|
|
492
|
-
* pills), and `del`/`ins`/`mark` (general emphasis vs redline tracked-changes) —
|
|
493
|
-
* these differ by intent or carry heavy/coupled behaviour, so each renderer owns
|
|
494
|
-
* them and spreads this base underneath.
|
|
495
|
-
*/
|
|
496
|
-
declare const markdownBaseComponents: Partial<Components>;
|
|
497
|
-
|
|
498
|
-
/**
|
|
499
|
-
* PassageCard — the card ("bubble") a single retrieved passage is rendered as.
|
|
500
|
-
*
|
|
501
|
-
* One presentation shared by every surface that lists retrieval hits: the
|
|
502
|
-
* <SemanticSearch> block here and the ARBI-frontend monolith's SmartSearch
|
|
503
|
-
* results. Those had drifted into two different looks for the same object; this
|
|
504
|
-
* is the single one.
|
|
505
|
-
*
|
|
506
|
-
* The card owns the chrome only — the rounded border, the AI-accent hover /
|
|
507
|
-
* focus / selected states, the header row and the relevance dot. What goes in
|
|
508
|
-
* the header and how the snippet itself is rendered stays with the caller,
|
|
509
|
-
* because those genuinely differ: the block shows a plain-text excerpt in a
|
|
510
|
-
* narrow sidebar, the monolith renders markdown with a show-more toggle.
|
|
511
|
-
*
|
|
512
|
-
* Theming is semantic tokens only (shadcn + the AI-accent contract).
|
|
513
|
-
*/
|
|
514
|
-
|
|
515
|
-
/**
|
|
516
|
-
* A dot conveying relevance — green (high) / amber (mid) / muted (low).
|
|
517
|
-
*
|
|
518
|
-
* The band is shown, the raw number is not: scores are not on a normalized 0-1
|
|
519
|
-
* scale across search modes (BM25 keyword scores can exceed 1), so a printed
|
|
520
|
-
* figure invites a comparison it cannot support. The value is kept in the
|
|
521
|
-
* tooltip for anyone debugging a ranking.
|
|
522
|
-
*/
|
|
523
|
-
declare function RelevanceDot({ score }: {
|
|
524
|
-
score?: number | null;
|
|
525
|
-
}): React__default.JSX.Element | null;
|
|
526
|
-
interface PassageCardProps {
|
|
527
|
-
/** Left of the header row — the source affordance (document pill, page label). */
|
|
528
|
-
header: React__default.ReactNode;
|
|
529
|
-
/** Relevance score for the dot. Omit to hide it. */
|
|
530
|
-
score?: number | null;
|
|
531
|
-
/** Extra affordance pinned right of the dot (e.g. a hover-revealed open icon). */
|
|
532
|
-
headerRight?: React__default.ReactNode;
|
|
533
|
-
/** Marks the card as the currently open passage. */
|
|
534
|
-
active?: boolean;
|
|
535
|
-
onClick?: (e: React__default.MouseEvent) => void;
|
|
536
|
-
/** Rendered under the snippet, outside the click target's typography. */
|
|
537
|
-
footer?: React__default.ReactNode;
|
|
538
|
-
className?: string;
|
|
539
|
-
children: React__default.ReactNode;
|
|
540
|
-
'data-testid'?: string;
|
|
541
|
-
}
|
|
542
|
-
declare function PassageCard({ header, score, headerRight, active, onClick, footer, className, children, 'data-testid': testId, }: PassageCardProps): React__default.JSX.Element;
|
|
543
|
-
|
|
544
|
-
/**
|
|
545
|
-
* EntityPill Component
|
|
546
|
-
*
|
|
547
|
-
* Base component for pill-style entity displays. Provides consistent styling and
|
|
548
|
-
* interaction patterns. Promoted verbatim from the ARBI app (import paths only
|
|
549
|
-
* changed to resolve within the SDK).
|
|
550
|
-
*
|
|
551
|
-
* Pattern: [Icon] [Label] [Optional: secondary text] [MoreVertical when interactive]
|
|
552
|
-
*/
|
|
553
|
-
|
|
554
|
-
interface EntityPillProps {
|
|
555
|
-
/** The icon element (Avatar, ShieldIcon, FileIcon, etc.) */
|
|
556
|
-
icon: React__default.ReactNode;
|
|
557
|
-
/** Primary label text */
|
|
558
|
-
label: string;
|
|
559
|
-
/** Optional secondary text (e.g., page notation "p.1") */
|
|
560
|
-
secondaryText?: React__default.ReactNode;
|
|
561
|
-
/** Size variant: 'sm' for compact, 'base' for tab headers */
|
|
562
|
-
size?: 'sm' | 'base';
|
|
563
|
-
/** Shape variant: 'pill' for rounded-full, 'rounded' for rounded-md */
|
|
564
|
-
shape?: 'pill' | 'rounded';
|
|
565
|
-
/** Additional CSS classes */
|
|
566
|
-
className?: string;
|
|
567
|
-
/** Max width for label truncation */
|
|
568
|
-
labelMaxWidth?: string;
|
|
569
|
-
/** Extra classes on the label text (e.g. a heavier weight on a card face). */
|
|
570
|
-
labelClassName?: string;
|
|
571
|
-
/** When true, the pill fills its container width (`flex w-full`) and the main
|
|
572
|
-
* area flexes + truncates so the trailing control (⋯ menu) pins to the right
|
|
573
|
-
* edge — used by the documents table's Document column. Default: shrink-to-fit. */
|
|
574
|
-
fullWidth?: boolean;
|
|
575
|
-
/** When true, render the pill with the active/"viewing" highlight — a solid
|
|
576
|
-
* dark-navy background with light text, applied LAST so it wins over both the
|
|
577
|
-
* default background and the interactive hover. */
|
|
578
|
-
highlight?: boolean;
|
|
579
|
-
/** Click handler for main area (icon + label) - primary action */
|
|
580
|
-
onClick?: (e: React__default.MouseEvent) => void;
|
|
581
|
-
/** Click handler for icon only — when set, only the icon is clickable (not the label) */
|
|
582
|
-
onIconClick?: (e: React__default.MouseEvent) => void;
|
|
583
|
-
/** Click handler for MoreVertical - opens popover/menu. When provided, shows MoreVertical icon */
|
|
584
|
-
onMoreClick?: (e: React__default.MouseEvent) => void;
|
|
585
|
-
/** Custom trailing element (e.g. a ⋯ dropdown menu). Rendered in the same
|
|
586
|
-
* trailing zone as MoreVertical, but as-is — so it stays outside the pill's
|
|
587
|
-
* primary click area. Takes precedence over `onMoreClick`. */
|
|
588
|
-
moreContent?: React__default.ReactNode;
|
|
589
|
-
/** Link URL - makes the main area an anchor tag */
|
|
590
|
-
href?: string;
|
|
591
|
-
/** Whether the pill is disabled */
|
|
592
|
-
disabled?: boolean;
|
|
593
|
-
/** Tooltip for main area (describes primary action, e.g., "View document") */
|
|
594
|
-
tooltipContent?: React__default.ReactNode;
|
|
595
|
-
/** Tooltip side placement */
|
|
596
|
-
tooltipSide?: 'top' | 'bottom' | 'left' | 'right';
|
|
597
|
-
/** Test ID for testing */
|
|
598
|
-
'data-testid'?: string;
|
|
599
|
-
}
|
|
600
|
-
declare const EntityPill: React__default.ForwardRefExoticComponent<EntityPillProps & React__default.RefAttributes<HTMLElement>>;
|
|
601
|
-
|
|
602
|
-
/**
|
|
603
|
-
* DocumentEntity Component
|
|
604
|
-
*
|
|
605
|
-
* Displays a document as a compact entity pill with file-type icon and name.
|
|
606
|
-
* Promoted from the ARBI app and DECOUPLED from the app store/API: it renders
|
|
607
|
-
* purely from the `doc` prop and optional `onClick`/`onIconClick` callbacks.
|
|
608
|
-
*/
|
|
609
|
-
|
|
610
|
-
/** Minimal, decoupled document shape the pill needs. Structurally compatible
|
|
611
|
-
* with the SDK's `DocResponse` (from `useDocuments`), but no dependency on it —
|
|
612
|
-
* a consumer can pass any object with these fields. */
|
|
613
|
-
interface DocumentLike {
|
|
614
|
-
file_name?: string | null;
|
|
615
|
-
folder?: string | null;
|
|
616
|
-
doc_metadata?: {
|
|
617
|
-
title?: string | null;
|
|
618
|
-
} | null;
|
|
619
|
-
}
|
|
620
|
-
/**
|
|
621
|
-
* The file-type glyph for a document, by extension.
|
|
622
|
-
*
|
|
623
|
-
* Exported because a document is recognisable by its icon before its name — any
|
|
624
|
-
* surface that lists documents (the entity pill here, the workspace home's
|
|
625
|
-
* Documents card) has to draw the same PDF/image/audio/video/email glyph, or
|
|
626
|
-
* the same file looks like two different things in two places.
|
|
627
|
-
*/
|
|
628
|
-
declare function getDocIcon(fileName?: string | null, iconSize?: number): React__default.ReactNode;
|
|
629
|
-
interface DocumentEntityProps {
|
|
630
|
-
doc: DocumentLike;
|
|
631
|
-
/** Override the default file-type icon */
|
|
632
|
-
icon?: React__default.ReactNode;
|
|
633
|
-
/** Size variant — 'sm' (default) for inline/compact contexts, 'base' for a
|
|
634
|
-
* larger pill (e.g. the documents grid's primary name column). */
|
|
635
|
-
size?: 'sm' | 'base';
|
|
636
|
-
/** Override default label max width */
|
|
637
|
-
labelMaxWidth?: string;
|
|
638
|
-
/** Extra classes on the label text (e.g. a heavier weight on a card face). */
|
|
639
|
-
labelClassName?: string;
|
|
640
|
-
/** Click handler for the whole pill */
|
|
641
|
-
onClick?: (e: React__default.MouseEvent) => void;
|
|
642
|
-
/** Click handler for the icon only */
|
|
643
|
-
onIconClick?: (e: React__default.MouseEvent) => void;
|
|
644
|
-
/** When true, the file-type icon is replaced by a pinned Eye — marks the
|
|
645
|
-
* document that is currently open/being viewed. */
|
|
646
|
-
viewing?: boolean;
|
|
647
|
-
/** Small overlay pinned to the icon's corner (e.g. an "available offline" pip). */
|
|
648
|
-
iconBadge?: React__default.ReactNode;
|
|
649
|
-
/** Trailing control rendered outside the click area (e.g. a ⋯ actions menu). */
|
|
650
|
-
actions?: React__default.ReactNode;
|
|
651
|
-
/** When true, the pill fills the available width and the name truncates via
|
|
652
|
-
* CSS so the trailing ⋯ menu pins to the right edge. */
|
|
653
|
-
fullWidth?: boolean;
|
|
654
|
-
/** Render the WHOLE title (skip the 30-char `clampLabel` string cut) while
|
|
655
|
-
* keeping the normal content-width layout — for callers that want the full
|
|
656
|
-
* name to show/wrap (via a `labelClassName`) without `fullWidth`'s w-full.
|
|
657
|
-
* `fullWidth` already implies this. */
|
|
658
|
-
noClamp?: boolean;
|
|
659
|
-
/** Override the default folder/title hover tooltip. */
|
|
660
|
-
tooltipContent?: React__default.ReactNode;
|
|
661
|
-
className?: string;
|
|
662
|
-
/** Forwarded to the pill so a surface can address this document's chip. */
|
|
663
|
-
'data-testid'?: string;
|
|
664
|
-
}
|
|
665
|
-
declare function DocumentEntity({ doc, icon, size, labelMaxWidth, labelClassName, onClick, onIconClick, viewing, iconBadge, actions, tooltipContent, className, fullWidth, noClamp, 'data-testid': testId, }: DocumentEntityProps): React__default.JSX.Element;
|
|
666
|
-
|
|
667
|
-
/**
|
|
668
|
-
* TagEntity Component
|
|
669
|
-
*
|
|
670
|
-
* Single source of truth for tag visual appearance, promoted from the ARBI app
|
|
671
|
-
* and DECOUPLED from the app store/API. It renders purely from the `tag` prop —
|
|
672
|
-
* the app-only bits (creator/updater lookup, visibility toggle, live doctag
|
|
673
|
-
* count from the query cache) are dropped; pass `doctagCount`/`shared` if you
|
|
674
|
-
* want them shown in the built-in tooltip, or inject a fully custom `tooltipContent`.
|
|
675
|
-
*/
|
|
676
|
-
|
|
677
|
-
/** Minimal, decoupled tag shape the pill needs. */
|
|
678
|
-
interface TagLike {
|
|
679
|
-
external_id: string;
|
|
680
|
-
name: string;
|
|
681
|
-
/** Tag type discriminator — drives the icon and the tooltip's "Type" line. */
|
|
682
|
-
tag_type?: {
|
|
683
|
-
type: string;
|
|
684
|
-
} | null;
|
|
685
|
-
/** Optional explicit color; when omitted it's derived from `external_id`. */
|
|
686
|
-
color?: string;
|
|
687
|
-
/** Optional document count shown in the tooltip. */
|
|
688
|
-
doctag_count?: number | null;
|
|
689
|
-
/** Optional shared/private flag shown in the tooltip. */
|
|
690
|
-
shared?: boolean | null;
|
|
691
|
-
}
|
|
692
|
-
interface TagEntityProps {
|
|
693
|
-
tag: TagLike;
|
|
694
|
-
size?: 'sm' | 'md' | 'lg';
|
|
695
|
-
className?: string;
|
|
696
|
-
onClick?: (e: React__default.MouseEvent) => void;
|
|
697
|
-
/** Whether to show a tooltip (default: true) */
|
|
698
|
-
showTooltip?: boolean;
|
|
699
|
-
/** Injected tooltip override. When provided (and `showTooltip` is not false) it
|
|
700
|
-
* replaces the built-in tooltip — used by the monolith to render its rich,
|
|
701
|
-
* store-coupled tooltip (fresh count, creator/updater, visibility toggle). */
|
|
702
|
-
tooltipContent?: React__default.ReactNode;
|
|
703
|
-
}
|
|
704
|
-
declare function TagEntity({ tag, size, className, onClick, showTooltip, tooltipContent, }: TagEntityProps): React__default.JSX.Element;
|
|
705
|
-
|
|
706
|
-
/**
|
|
707
|
-
* Tag-type presentation primitives — the brand-neutral icon and label maps that
|
|
708
|
-
* back the shared `TagEntity` pill. Kept in their own module (not the component
|
|
709
|
-
* file) so app-side wrappers can import them to build their own store-coupled
|
|
710
|
-
* tooltip content without pulling in a component, and so the component file stays
|
|
711
|
-
* fast-refresh friendly.
|
|
712
|
-
*/
|
|
713
|
-
|
|
714
|
-
/** Human-readable tag type names. */
|
|
715
|
-
declare const TAG_TYPE_LABELS: Record<string, string>;
|
|
716
|
-
/** Icon mapping for tag types. */
|
|
717
|
-
declare const TAG_TYPE_ICONS: Record<string, typeof StickyNote>;
|
|
718
|
-
/** Resolve the icon component for a tag type, with the `text` (NotebookPen) fallback.
|
|
719
|
-
* Annotations share the NotebookPen mark used by the AI Annotate bulk action, so
|
|
720
|
-
* the table column and the batch bar name the same thing the same way. */
|
|
721
|
-
declare function getTagTypeIcon(type?: string | null): typeof StickyNote;
|
|
722
|
-
/** Resolve the human-readable label for a tag type, falling back to the raw type. */
|
|
723
|
-
declare function getTagTypeLabel(type?: string | null): string;
|
|
724
|
-
|
|
725
|
-
/**
|
|
726
|
-
* ProjectEntity Component
|
|
727
|
-
*
|
|
728
|
-
* Fully-rounded pill for a "project" (a.k.a. a "matter" in some consumer apps).
|
|
729
|
-
* The viewer's relationship to the project drives a TINTED (soft-fill) colour
|
|
730
|
-
* so the kinds read at a glance without shouting:
|
|
731
|
-
* - your paid project → primary tint
|
|
732
|
-
* - someone else's → secondary tint
|
|
733
|
-
* - your free project → grey tint
|
|
734
|
-
* "Common" keeps the neutral muted pill.
|
|
735
|
-
*
|
|
736
|
-
* Promoted from the ARBI app and DECOUPLED: no store/stripe deps. The icon
|
|
737
|
-
* defaults to the `CreditCard` glyph and can be overridden via `icon`, and
|
|
738
|
-
* the display text via `label` (falls back to `name`) so consumers can relabel
|
|
739
|
-
* a "project" as a "matter", "case", etc.
|
|
740
|
-
*/
|
|
741
|
-
|
|
742
|
-
type ProjectRelation = 'mine' | 'other' | 'common';
|
|
743
|
-
interface ProjectEntityProps {
|
|
744
|
-
name: string;
|
|
745
|
-
/** Display text override (defaults to `name`) — lets a consumer relabel. */
|
|
746
|
-
label?: string;
|
|
747
|
-
/** Icon override (defaults to the CreditCard glyph). */
|
|
748
|
-
icon?: React__default.ReactNode;
|
|
749
|
-
subscription?: string;
|
|
750
|
-
hasCollaborators?: boolean;
|
|
751
|
-
size?: 'sm' | 'base';
|
|
752
|
-
className?: string;
|
|
753
|
-
onClick?: (e: React__default.MouseEvent) => void;
|
|
754
|
-
/** Viewer's relationship to the project — drives the inverted pill colour. */
|
|
755
|
-
relation?: ProjectRelation;
|
|
756
|
-
/** Whether the given `subscription` should be treated as paid. When omitted,
|
|
757
|
-
* it's inferred from the `subscription` value ('active' | 'past_due' | 'dev'). */
|
|
758
|
-
isPaid?: boolean;
|
|
759
|
-
/** Hover tooltip. */
|
|
760
|
-
tooltipContent?: React__default.ReactNode;
|
|
761
|
-
}
|
|
762
|
-
declare function ProjectEntity({ name, label, icon, subscription, hasCollaborators, size, className, onClick, relation, isPaid, tooltipContent, }: ProjectEntityProps): React__default.JSX.Element;
|
|
763
|
-
|
|
764
|
-
/**
|
|
765
|
-
* UserEntity Component
|
|
766
|
-
*
|
|
767
|
-
* Single source of truth for the user pill/avatar visual, promoted from the ARBI
|
|
768
|
-
* app and DECOUPLED from the app store/API. It renders purely from injected,
|
|
769
|
-
* already-resolved props — the app-coupled bits (current user, WebSocket presence
|
|
770
|
-
* status, shared-workspace / agent-owner lookups) are resolved by the app adapter
|
|
771
|
-
* and passed in as `isMe` / `displayStatus` / `tooltipContent` / `onClick`.
|
|
772
|
-
*
|
|
773
|
-
* Variants:
|
|
774
|
-
* - pill: Avatar + name in a rounded container (default)
|
|
775
|
-
* - icon: Avatar circle with hover tooltip
|
|
776
|
-
*
|
|
777
|
-
* Status-dot colours use the semantic `--color-status-*` token contract (see the
|
|
778
|
-
* consuming app's @theme); they are seeded to the app's prior palette so the dots
|
|
779
|
-
* stay pixel-identical.
|
|
780
|
-
*/
|
|
781
|
-
|
|
782
|
-
/** Presence display status - WebSocket states plus 'hidden' for when status is intentionally not shown */
|
|
783
|
-
type PresenceDisplayStatus = 'connected' | 'connecting' | 'disconnected' | 'error' | 'hidden';
|
|
784
|
-
interface UserEntityProps {
|
|
785
|
-
size?: 'xs' | 'sm' | 'md' | 'lg';
|
|
786
|
-
variant?: 'icon' | 'pill';
|
|
787
|
-
className?: string;
|
|
788
|
-
/** When true (default), shows tooltip on hover */
|
|
789
|
-
showTooltip?: boolean;
|
|
790
|
-
/** When true (default), clicking triggers the injected action. Set false to disable interaction. */
|
|
791
|
-
interactive?: boolean;
|
|
792
|
-
/** When true, shows a blue unread indicator on the chat icon */
|
|
793
|
-
hasUnreadMessages?: boolean;
|
|
794
|
-
/** Two-letter initials shown in the avatar fallback (resolved by the app). */
|
|
795
|
-
initials?: string;
|
|
796
|
-
/** Display label — "You" for the current user, else the real name. */
|
|
797
|
-
displayName?: string;
|
|
798
|
-
/** Avatar image URL, if any. */
|
|
799
|
-
picture?: string | null;
|
|
800
|
-
/** Avatar background colour class for non-agents (e.g. 'bg-blue-500'). */
|
|
801
|
-
colorClass?: string;
|
|
802
|
-
/** Whether this user is an agent — drives the dashed ring + bot badge. */
|
|
803
|
-
isAgent?: boolean;
|
|
804
|
-
/** Inline border/text colour for agent avatars (from the app's agentAvatarColors). */
|
|
805
|
-
agentStyle?: React__default.CSSProperties;
|
|
806
|
-
/**
|
|
807
|
-
* Inline avatar colours for ANY user, not only agents — e.g. the deterministic
|
|
808
|
-
* tint the DM rows derive from the user id. Takes precedence over
|
|
809
|
-
* `agentStyle`, which predates it and is the same mechanism under a narrower
|
|
810
|
-
* name.
|
|
811
|
-
*/
|
|
812
|
-
avatarStyle?: React__default.CSSProperties;
|
|
813
|
-
/** Whether this pill represents the current user — hides the chat icon and drives
|
|
814
|
-
* which action `onClick` performs. */
|
|
815
|
-
isMe?: boolean;
|
|
816
|
-
/** Resolved presence dot state; undefined hides the dot. */
|
|
817
|
-
displayStatus?: PresenceDisplayStatus;
|
|
818
|
-
/** Resolved click handler (open settings for me, DM for others). */
|
|
819
|
-
onClick?: (e: React__default.MouseEvent) => void;
|
|
820
|
-
/** Injected rich tooltip content (built by the app adapter). */
|
|
821
|
-
tooltipContent?: React__default.ReactNode;
|
|
822
|
-
/** Render the empty "no user" avatar. */
|
|
823
|
-
empty?: boolean;
|
|
824
|
-
}
|
|
825
|
-
declare const UserEntity: React__default.NamedExoticComponent<UserEntityProps>;
|
|
826
|
-
|
|
827
|
-
/**
|
|
828
|
-
* "AGENT" stamp for an `agt-` peer.
|
|
829
|
-
*
|
|
830
|
-
* `UserEntity` already marks agents with a dashed ring and a bot icon, but that
|
|
831
|
-
* is a detail you have to know to read. An agent is a different KIND of
|
|
832
|
-
* correspondent — it acts on someone's behalf, and what you send it may be
|
|
833
|
-
* acted on rather than read — so it also gets a label you cannot miss.
|
|
834
|
-
*/
|
|
835
|
-
declare function AgentBadge({ className }: {
|
|
836
|
-
className?: string;
|
|
837
|
-
}): React$1.JSX.Element;
|
|
838
|
-
/**
|
|
839
|
-
* Presence in words rather than a coloured dot alone.
|
|
840
|
-
*
|
|
841
|
-
* `status` is *resolved* by the app, exactly as {@link UserEntity} expects it,
|
|
842
|
-
* and `undefined` renders nothing at all. That default matters: a consumer that
|
|
843
|
-
* has not wired a WebSocket provider has no presence information, and labelling
|
|
844
|
-
* every one of its contacts "Offline" would be stating something we do not
|
|
845
|
-
* know. Whether absence of a signal means offline is a claim only the app can
|
|
846
|
-
* make, so the app makes it by resolving to `disconnected`.
|
|
847
|
-
*/
|
|
848
|
-
declare function PresenceLabel({ status, className, }: {
|
|
849
|
-
status?: PresenceDisplayStatus;
|
|
850
|
-
className?: string;
|
|
851
|
-
}): React$1.JSX.Element | null;
|
|
852
|
-
|
|
853
|
-
/** A status variant is an opaque string — its valid values are defined by the
|
|
854
|
-
* injected Badge (or the default Badge's variants). */
|
|
855
|
-
type StatusVariant = string;
|
|
856
|
-
/** The shape a consumer's Badge must satisfy to be injected as the pill skin. */
|
|
857
|
-
interface StatusBadgeProps {
|
|
858
|
-
variant?: StatusVariant;
|
|
859
|
-
className?: string;
|
|
860
|
-
children?: ReactNode;
|
|
861
|
-
'data-testid'?: string;
|
|
862
|
-
}
|
|
863
|
-
type StatusBadgeComponent = ComponentType<StatusBadgeProps>;
|
|
864
|
-
/** Register a firm's status→variant vocabulary (merged in place), and optionally
|
|
865
|
-
* its fallback variant + its own Badge skin. Mirrors `configureEntityRegistry`. */
|
|
866
|
-
declare function configureStatusRegistry(map: Record<string, StatusVariant>, opts?: {
|
|
867
|
-
fallback?: StatusVariant;
|
|
868
|
-
Badge?: StatusBadgeComponent;
|
|
869
|
-
}): void;
|
|
870
|
-
/** Resolve a status string to its variant (falls back to the registered default). */
|
|
871
|
-
declare function getStatusVariant(status: string): StatusVariant;
|
|
872
|
-
interface StatusPillProps {
|
|
873
|
-
status: string;
|
|
874
|
-
label?: string;
|
|
875
|
-
/** Escape hatch: force a variant, skipping the registry. */
|
|
876
|
-
variant?: StatusVariant;
|
|
877
|
-
className?: string;
|
|
878
|
-
testId?: string;
|
|
879
|
-
}
|
|
880
|
-
/** A status chip whose look comes from the injected Badge + registered vocabulary. */
|
|
881
|
-
declare function StatusPill({ status, label, variant, className, testId }: StatusPillProps): React$1.JSX.Element;
|
|
882
|
-
type Rag = 'red' | 'amber' | 'green';
|
|
883
|
-
/** Override the RAG label copy (defaults are seeded so consumers stay identical). */
|
|
884
|
-
declare function configureRagLabels(labels: Partial<Record<Rag, string>>): void;
|
|
885
|
-
/** A small RAG dot + optional label for dense tables. Semantic tokens only. */
|
|
886
|
-
declare function RagDot({ rag, withLabel, className, }: {
|
|
887
|
-
rag: Rag;
|
|
888
|
-
withLabel?: boolean;
|
|
889
|
-
className?: string;
|
|
890
|
-
}): React$1.JSX.Element;
|
|
891
|
-
|
|
892
|
-
/** An icon component usable in the registry (lucide icons + custom SVG wrappers). */
|
|
893
|
-
type EntityIconComponent = React__default.ComponentType<React__default.SVGAttributes<SVGElement> & {
|
|
894
|
-
size?: number | string;
|
|
895
|
-
className?: string;
|
|
896
|
-
}>;
|
|
897
|
-
/**
|
|
898
|
-
* Entity Mappings — naming conventions + icons for every entity in the app.
|
|
899
|
-
*
|
|
900
|
-
* `WORKSPACE.ICONS.DEFAULT` is the generic `SquareM` here; the monolith injects a
|
|
901
|
-
* rotated variant via {@link configureEntityRegistry}. The object is mutated in
|
|
902
|
-
* place by that helper, so existing `ENTITY_MAPPINGS` references stay live.
|
|
903
|
-
*/
|
|
904
|
-
declare const ENTITY_MAPPINGS: {
|
|
905
|
-
PRODUCT: {
|
|
906
|
-
NAMES: {
|
|
907
|
-
SINGULAR: string;
|
|
908
|
-
};
|
|
909
|
-
ICONS: {
|
|
910
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
911
|
-
};
|
|
912
|
-
};
|
|
913
|
-
SECTION: {
|
|
914
|
-
NAMES: {
|
|
915
|
-
SINGULAR: string;
|
|
916
|
-
};
|
|
917
|
-
ICONS: {
|
|
918
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
919
|
-
};
|
|
920
|
-
};
|
|
921
|
-
WORKSPACE: {
|
|
922
|
-
NAMES: {
|
|
923
|
-
SINGULAR: string;
|
|
924
|
-
PLURAL: string;
|
|
925
|
-
};
|
|
926
|
-
ICONS: {
|
|
927
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
928
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
929
|
-
LIST: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
930
|
-
SETTINGS: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
931
|
-
};
|
|
932
|
-
};
|
|
933
|
-
CONVERSATION: {
|
|
934
|
-
NAMES: {
|
|
935
|
-
SINGULAR: string;
|
|
936
|
-
PLURAL: string;
|
|
937
|
-
NEW: string;
|
|
938
|
-
};
|
|
939
|
-
ICONS: {
|
|
940
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
941
|
-
OFF: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
942
|
-
ACTIVE: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
943
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
944
|
-
LIST: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
945
|
-
};
|
|
946
|
-
};
|
|
947
|
-
DOCUMENT: {
|
|
948
|
-
NAMES: {
|
|
949
|
-
SINGULAR: string;
|
|
950
|
-
PLURAL: string;
|
|
951
|
-
};
|
|
952
|
-
ICONS: {
|
|
953
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
954
|
-
OFF: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
955
|
-
};
|
|
956
|
-
};
|
|
957
|
-
VIEWER: {
|
|
958
|
-
NAMES: {
|
|
959
|
-
SINGULAR: string;
|
|
960
|
-
PLURAL: string;
|
|
961
|
-
};
|
|
962
|
-
ICONS: {
|
|
963
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
964
|
-
OFF: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
965
|
-
};
|
|
966
|
-
};
|
|
967
|
-
TAG: {
|
|
968
|
-
NAMES: {
|
|
969
|
-
SINGULAR: string;
|
|
970
|
-
PLURAL: string;
|
|
971
|
-
};
|
|
972
|
-
ICONS: {
|
|
973
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
974
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
975
|
-
};
|
|
976
|
-
};
|
|
977
|
-
ANNOTATION: {
|
|
978
|
-
NAMES: {
|
|
979
|
-
SINGULAR: string;
|
|
980
|
-
PLURAL: string;
|
|
981
|
-
};
|
|
982
|
-
ICONS: {
|
|
983
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
984
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
985
|
-
};
|
|
986
|
-
};
|
|
987
|
-
NOTE: {
|
|
988
|
-
NAMES: {
|
|
989
|
-
SINGULAR: string;
|
|
990
|
-
PLURAL: string;
|
|
991
|
-
};
|
|
992
|
-
ICONS: {
|
|
993
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
994
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
995
|
-
};
|
|
996
|
-
};
|
|
997
|
-
USER: {
|
|
998
|
-
NAMES: {
|
|
999
|
-
SINGULAR: string;
|
|
1000
|
-
PLURAL: string;
|
|
1001
|
-
};
|
|
1002
|
-
ICONS: {
|
|
1003
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1004
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1005
|
-
SETTINGS: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1006
|
-
};
|
|
1007
|
-
};
|
|
1008
|
-
WORKSPACEUSER: {
|
|
1009
|
-
NAMES: {
|
|
1010
|
-
SINGULAR: string;
|
|
1011
|
-
PLURAL: string;
|
|
1012
|
-
};
|
|
1013
|
-
ICONS: {
|
|
1014
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1015
|
-
PLURAL: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1016
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1017
|
-
SETTINGS: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1018
|
-
};
|
|
1019
|
-
};
|
|
1020
|
-
CONTACT: {
|
|
1021
|
-
NAMES: {
|
|
1022
|
-
SINGULAR: string;
|
|
1023
|
-
PLURAL: string;
|
|
1024
|
-
};
|
|
1025
|
-
ICONS: {
|
|
1026
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1027
|
-
NEW: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1028
|
-
};
|
|
1029
|
-
};
|
|
1030
|
-
TASK: {
|
|
1031
|
-
NAMES: {
|
|
1032
|
-
SINGULAR: string;
|
|
1033
|
-
PLURAL: string;
|
|
1034
|
-
};
|
|
1035
|
-
ICONS: {
|
|
1036
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1037
|
-
};
|
|
1038
|
-
};
|
|
1039
|
-
PROJECT: {
|
|
1040
|
-
NAMES: {
|
|
1041
|
-
SINGULAR: string;
|
|
1042
|
-
PLURAL: string;
|
|
1043
|
-
};
|
|
1044
|
-
ICONS: {
|
|
1045
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1046
|
-
};
|
|
1047
|
-
};
|
|
1048
|
-
SKILL: {
|
|
1049
|
-
NAMES: {
|
|
1050
|
-
SINGULAR: string;
|
|
1051
|
-
PLURAL: string;
|
|
1052
|
-
};
|
|
1053
|
-
ICONS: {
|
|
1054
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1055
|
-
};
|
|
1056
|
-
};
|
|
1057
|
-
ACCOUNT: {
|
|
1058
|
-
NAMES: {
|
|
1059
|
-
SINGULAR: string;
|
|
1060
|
-
};
|
|
1061
|
-
ICONS: {
|
|
1062
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1063
|
-
};
|
|
1064
|
-
};
|
|
1065
|
-
NOTIFICATIONS: {
|
|
1066
|
-
NAMES: {
|
|
1067
|
-
SINGULAR: string;
|
|
1068
|
-
PLURAL: string;
|
|
1069
|
-
};
|
|
1070
|
-
ICONS: {
|
|
1071
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1072
|
-
};
|
|
1073
|
-
};
|
|
1074
|
-
MESSAGE: {
|
|
1075
|
-
NAMES: {
|
|
1076
|
-
SINGULAR: string;
|
|
1077
|
-
PLURAL: string;
|
|
1078
|
-
};
|
|
1079
|
-
ICONS: {
|
|
1080
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1081
|
-
};
|
|
1082
|
-
};
|
|
1083
|
-
NOTIFICATION: {
|
|
1084
|
-
NAMES: {
|
|
1085
|
-
SINGULAR: string;
|
|
1086
|
-
PLURAL: string;
|
|
1087
|
-
};
|
|
1088
|
-
ICONS: {
|
|
1089
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1090
|
-
};
|
|
1091
|
-
};
|
|
1092
|
-
APP: {
|
|
1093
|
-
NAMES: {
|
|
1094
|
-
SINGULAR: string;
|
|
1095
|
-
PLURAL: string;
|
|
1096
|
-
};
|
|
1097
|
-
ICONS: {
|
|
1098
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1099
|
-
HOME: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1100
|
-
LOGOUT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1101
|
-
UPLOAD: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1102
|
-
};
|
|
1103
|
-
};
|
|
1104
|
-
HELP: {
|
|
1105
|
-
NAMES: {
|
|
1106
|
-
SINGULAR: string;
|
|
1107
|
-
PLURAL: string;
|
|
1108
|
-
};
|
|
1109
|
-
ICONS: {
|
|
1110
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1111
|
-
DOCS: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1112
|
-
FAQ: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1113
|
-
ABOUT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1114
|
-
};
|
|
1115
|
-
};
|
|
1116
|
-
USERSHIELD: {
|
|
1117
|
-
NAMES: {
|
|
1118
|
-
SINGULAR: string;
|
|
1119
|
-
PLURAL: string;
|
|
1120
|
-
};
|
|
1121
|
-
ICONS: {
|
|
1122
|
-
DEFAULT: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1123
|
-
};
|
|
1124
|
-
};
|
|
1125
|
-
};
|
|
1126
|
-
/** The set of registered entity types. */
|
|
1127
|
-
type EntityType = keyof typeof ENTITY_MAPPINGS;
|
|
1128
|
-
/** Deployment override for a single entity: extra/replacement names and icons. */
|
|
1129
|
-
interface EntityRegistryOverride {
|
|
1130
|
-
NAMES?: Record<string, string>;
|
|
1131
|
-
ICONS?: Record<string, EntityIconComponent>;
|
|
1132
|
-
}
|
|
1133
|
-
/**
|
|
1134
|
-
* Layer deployment-specific names/icons onto the canonical registry — call once
|
|
1135
|
-
* at app startup. Merges in place (so live `ENTITY_MAPPINGS` refs pick it up) and
|
|
1136
|
-
* only touches the keys you pass, e.g.:
|
|
1137
|
-
*
|
|
1138
|
-
* ```ts
|
|
1139
|
-
* configureEntityRegistry({
|
|
1140
|
-
* WORKSPACE: { NAMES: { SINGULAR: 'MatterSpace' }, ICONS: { DEFAULT: RotatedSquareM } },
|
|
1141
|
-
* })
|
|
1142
|
-
* ```
|
|
1143
|
-
*/
|
|
1144
|
-
declare function configureEntityRegistry(overrides: Partial<Record<EntityType, EntityRegistryOverride>>): void;
|
|
1145
|
-
/**
|
|
1146
|
-
* Resolve the icon component for an entity type + variant, falling back to the
|
|
1147
|
-
* type's DEFAULT icon for unknown variants.
|
|
1148
|
-
*/
|
|
1149
|
-
declare const getEntityIcon: (entityType: EntityType, variant?: string) => EntityIconComponent | undefined;
|
|
1150
|
-
/**
|
|
1151
|
-
* Display label for an entity type. `SINGULAR` (default); `PLURAL`/`SHORT`/`NEW`
|
|
1152
|
-
* fall back to derivations of the singular when not explicitly configured.
|
|
1153
|
-
*/
|
|
1154
|
-
declare const getEntityLabel: (entityType: EntityType, form?: "SINGULAR" | "PLURAL" | "SHORT" | "NEW") => string;
|
|
1155
|
-
type EntityIconProps = {
|
|
1156
|
-
entityType: EntityType;
|
|
1157
|
-
variant?: string;
|
|
1158
|
-
className?: string;
|
|
1159
|
-
size?: number;
|
|
1160
|
-
color?: string;
|
|
1161
|
-
'data-testid'?: string;
|
|
1162
|
-
onClick?: () => void;
|
|
1163
|
-
} & React__default.SVGAttributes<SVGElement>;
|
|
1164
|
-
/**
|
|
1165
|
-
* Render an entity's icon — the recommended way to show entity glyphs so all
|
|
1166
|
-
* icon choices stay centralised.
|
|
1167
|
-
*/
|
|
1168
|
-
declare const EntityIcon: ({ entityType, variant, ...props }: EntityIconProps) => React__default.ReactElement<React__default.SVGAttributes<SVGElement> & {
|
|
1169
|
-
size?: number | string;
|
|
1170
|
-
className?: string;
|
|
1171
|
-
}, string | React__default.JSXElementConstructor<any>> | null;
|
|
1172
|
-
/** Centralised icons for private/shared visibility states. */
|
|
1173
|
-
declare const VISIBILITY_ICONS: {
|
|
1174
|
-
PRIVATE: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1175
|
-
SHARED: React__default.ForwardRefExoticComponent<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1176
|
-
};
|
|
1177
|
-
/** Render the private/shared visibility glyph. */
|
|
1178
|
-
declare const VisibilityIcon: ({ isShared, ...props }: {
|
|
1179
|
-
isShared: boolean;
|
|
1180
|
-
className?: string;
|
|
1181
|
-
size?: number;
|
|
1182
|
-
color?: string;
|
|
1183
|
-
"data-testid"?: string;
|
|
1184
|
-
onClick?: () => void;
|
|
1185
|
-
} & React__default.SVGAttributes<SVGElement>) => React__default.FunctionComponentElement<Omit<lucide_react.LucideProps, "ref"> & React__default.RefAttributes<SVGSVGElement>>;
|
|
1186
|
-
|
|
1187
|
-
/**
|
|
1188
|
-
* Entity colour system — the single source of truth for deriving a stable colour
|
|
1189
|
-
* from an entity id (workspace/tag/doc badges) shared across every app.
|
|
1190
|
-
*
|
|
1191
|
-
* ONE base palette (16 colours, indexed by the hex char at position 5 of an
|
|
1192
|
-
* entity id) + three opacity constants that shift every variant globally. Pure,
|
|
1193
|
-
* framework-free: no React, no store, no app `@/` imports.
|
|
1194
|
-
*/
|
|
1195
|
-
/** Semantic placeholder colour for empty/pending states (gray-400). */
|
|
1196
|
-
declare const PLACEHOLDER_COLOR = "#9ca3af";
|
|
1197
|
-
/** Neutral gray for generic/unknown file types (slate-500). */
|
|
1198
|
-
declare const NEUTRAL_GRAY = "#64748b";
|
|
1199
|
-
/** Base palette — source of truth for all entity colours (hex char 0–f). */
|
|
1200
|
-
declare const BASE_COLORS: Record<string, string>;
|
|
1201
|
-
/**
|
|
1202
|
-
* Deterministic colour for an entity id. The 5th char (index 4) of the id selects
|
|
1203
|
-
* a base colour; the variant picks the opacity treatment.
|
|
1204
|
-
*/
|
|
1205
|
-
declare function getEntityColor(entityId: string, variant?: 'light' | 'medium' | 'text'): string;
|
|
1206
|
-
/** Full badge colour set for an entity id: light background + solid text + border. */
|
|
1207
|
-
declare function getEntityColorStyles(entityId: string): {
|
|
1208
|
-
backgroundColor: string;
|
|
1209
|
-
color: string;
|
|
1210
|
-
borderColor: string;
|
|
1211
|
-
};
|
|
1212
|
-
/**
|
|
1213
|
-
* Colour for a workspace id — the MEDIUM (solid) variant, for white text on top.
|
|
1214
|
-
* Returns the `--primary` token when colours are disabled or the id is invalid,
|
|
1215
|
-
* so callers always get a paintable value.
|
|
1216
|
-
*/
|
|
1217
|
-
declare const getWorkspaceColor: (workspaceId: string | undefined | null, useWorkspaceColors?: boolean) => string;
|
|
1218
|
-
|
|
1219
|
-
interface UserMenuItem {
|
|
1220
|
-
label: string;
|
|
1221
|
-
icon?: ComponentType<{
|
|
1222
|
-
className?: string;
|
|
1223
|
-
}>;
|
|
1224
|
-
onSelect: () => void;
|
|
1225
|
-
testId?: string;
|
|
1226
|
-
/** A count or short state on the right (e.g. the number of files processing). */
|
|
1227
|
-
badge?: string | number;
|
|
1228
|
-
/** A small unread dot on the icon (e.g. new messages). */
|
|
1229
|
-
dot?: boolean;
|
|
1230
|
-
/** Makes the row a labelled on/off switch (role menuitemcheckbox); selecting it flips the state. */
|
|
1231
|
-
checked?: boolean;
|
|
1232
|
-
/** Draw a divider above this row to start a new group. */
|
|
1233
|
-
separatorBefore?: boolean;
|
|
1234
|
-
}
|
|
1235
|
-
/** Connection/presence state shown as a dot on the avatar and a line under the
|
|
1236
|
-
* email — the account menu is where "am I connected" belongs. */
|
|
1237
|
-
interface UserMenuStatus {
|
|
1238
|
-
/** Short state word — "Connected", "Working offline". */
|
|
1239
|
-
label: string;
|
|
1240
|
-
tone: 'online' | 'busy' | 'offline';
|
|
1241
|
-
/** Fine print under the label (e.g. the server domain). */
|
|
1242
|
-
detail?: string;
|
|
1243
|
-
testId?: string;
|
|
1244
|
-
}
|
|
1245
|
-
interface UserMenuProps {
|
|
1246
|
-
user: {
|
|
1247
|
-
name: string;
|
|
1248
|
-
email?: string | null;
|
|
1249
|
-
picture?: string | null;
|
|
1250
|
-
};
|
|
1251
|
-
/** Optional connection status: avatar dot + a line in the dropdown header. */
|
|
1252
|
-
status?: UserMenuStatus;
|
|
1253
|
-
/** Account actions above the sign-out divider (e.g. Settings). */
|
|
1254
|
-
items?: UserMenuItem[];
|
|
1255
|
-
onLogout: () => void;
|
|
1256
|
-
logoutLabel?: string;
|
|
1257
|
-
align?: 'start' | 'center' | 'end';
|
|
1258
|
-
/** Which side of the trigger the menu opens on (a footer trigger opens upward or sideways). */
|
|
1259
|
-
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
1260
|
-
/**
|
|
1261
|
-
* `avatar` (default): avatar + chevron. `account`: a full-width account bar, avatar + display
|
|
1262
|
-
* name + chevron, for a sidebar footer.
|
|
1263
|
-
*/
|
|
1264
|
-
variant?: 'avatar' | 'account';
|
|
1265
|
-
/** `avatar` only: draw the chevron (the icon-only rail hides it). */
|
|
1266
|
-
showChevron?: boolean;
|
|
1267
|
-
classNames?: {
|
|
1268
|
-
trigger?: string;
|
|
1269
|
-
fallback?: string;
|
|
1270
|
-
};
|
|
1271
|
-
testId?: string;
|
|
1272
|
-
logoutTestId?: string;
|
|
1273
|
-
}
|
|
1274
|
-
declare function UserMenu({ user, status, items, onLogout, logoutLabel, align, side, variant, showChevron, classNames, testId, logoutTestId, }: UserMenuProps): React$1.JSX.Element;
|
|
1275
|
-
|
|
1276
|
-
/**
|
|
1277
|
-
* DocumentCard — the canonical document thumbnail tile.
|
|
1278
|
-
*
|
|
1279
|
-
* One tile, shared by every app: a full-bleed first-page thumbnail (falling back
|
|
1280
|
-
* to the file-type icon) with the selection checkbox, the actions menu, the
|
|
1281
|
-
* processing state and the document's name pill layered on top of it, rather
|
|
1282
|
-
* than a thumbnail box with a separate meta strip beneath.
|
|
1283
|
-
*
|
|
1284
|
-
* Presentational only — it takes a thumbnail, a status and callbacks, and knows
|
|
1285
|
-
* nothing about how documents are fetched. `DocumentGallery` binds it to data.
|
|
1286
|
-
*/
|
|
1287
|
-
|
|
1288
|
-
interface DocumentCardProps {
|
|
1289
|
-
/** The document — anything with a file name and optional metadata title. */
|
|
1290
|
-
doc: DocumentLike;
|
|
1291
|
-
/** First-page thumbnail (data URI or URL). Falls back to the file-type icon. */
|
|
1292
|
-
thumbnailUrl?: string | null;
|
|
1293
|
-
/** Processing status, e.g. `parsing` (overlay) or `completed` (corner marker). */
|
|
1294
|
-
status?: string | null;
|
|
1295
|
-
/** Renders the selection checkbox. Omit `onToggleSelect` to hide it entirely. */
|
|
1296
|
-
selected?: boolean;
|
|
1297
|
-
onToggleSelect?: () => void;
|
|
1298
|
-
/** Pins the "eye" on the name pill — this is the document open in the viewer. */
|
|
1299
|
-
viewing?: boolean;
|
|
1300
|
-
onOpen?: () => void;
|
|
1301
|
-
/** Actions menu, pinned to the tile's top-right corner. */
|
|
1302
|
-
actions?: React__default.ReactNode;
|
|
1303
|
-
/** Swaps the name pill for an inline rename field. */
|
|
1304
|
-
renaming?: boolean;
|
|
1305
|
-
onCommitRename?: (name: string) => void;
|
|
1306
|
-
onCancelRename?: () => void;
|
|
1307
|
-
/** Replaces the pill's default hover tooltip (e.g. an AI summary + labels). */
|
|
1308
|
-
tooltipContent?: React__default.ReactNode;
|
|
1309
|
-
/** Bottom-left marker slot (e.g. an "available offline" glyph). */
|
|
1310
|
-
marker?: React__default.ReactNode;
|
|
1311
|
-
testId?: string;
|
|
1312
|
-
className?: string;
|
|
1313
|
-
}
|
|
1314
|
-
declare function DocumentCard({ doc, thumbnailUrl, status, selected, onToggleSelect, viewing, onOpen, actions, renaming, onCommitRename, onCancelRename, tooltipContent, marker, testId, className, }: DocumentCardProps): React__default.JSX.Element;
|
|
1315
|
-
|
|
1316
|
-
/**
|
|
1317
|
-
* Core utility: `cn()` — merge class names with Tailwind-aware conflict
|
|
1318
|
-
* resolution (clsx + tailwind-merge). Copied faithfully from the ARBI app so the
|
|
1319
|
-
* promoted "lego" components style identically in a consumer app.
|
|
1320
|
-
*/
|
|
1321
|
-
|
|
1322
|
-
declare function cn(...inputs: ClassValue[]): string;
|
|
1323
|
-
|
|
1324
|
-
export { AgentBadge, AiMarkdown, Avatar, AvatarFallback, AvatarImage, BASE_COLORS, Badge, type BadgeProps, Button, type ButtonProps, Card, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, type DialogPresentation, DialogTitle, DialogTrigger, type DictateContextValue, DictateProvider, DocumentCard, type DocumentCardProps, DocumentEntity, type DocumentEntityProps, type DocumentLike, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, ENTITY_MAPPINGS, EntityIcon, type EntityIconComponent, EntityPill, type EntityRegistryOverride, type EntityType, HoverCard, HoverCardContent, HoverCardTrigger, IconToggle, type IconToggleProps, Input, type InputProps, Label, MarkMenu, type MarkMenuItem, type MarkMenuProps, MarkdownRenderer, type MarkdownRendererProps, MarkdownStreamingContext, NEUTRAL_GRAY, PLACEHOLDER_COLOR, PassageCard, type PassageCardProps, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, type PresenceDisplayStatus, PresenceLabel, Progress, ProjectEntity, type ProjectEntityProps, type ProjectRelation, RadioGroup, RadioGroupItem, type Rag, RagDot, RelevanceDot, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Slider, type StatusBadgeComponent, type StatusBadgeProps, StatusPill, type StatusPillProps, type StatusVariant, Switch, TAG_TYPE_ICONS, TAG_TYPE_LABELS, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, TagEntity, type TagEntityProps, type TagLike, Textarea, type TextareaProps, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, UserEntity, type UserEntityProps, UserMenu, type UserMenuItem, type UserMenuProps, type UserMenuStatus, VISIBILITY_ICONS, VisibilityIcon, badgeVariants, buttonVariants, cardVariants, cn, configureEntityRegistry, configureRagLabels, configureStatusRegistry, getDocIcon, getEntityColor, getEntityColorStyles, getEntityIcon, getEntityLabel, getStatusVariant, getTagTypeIcon, getTagTypeLabel, getWorkspaceColor, markdownBaseComponents, splitMarkdownBlocks, toggleVariants };
|
|
1
|
+
export { A as AgentBadge, a as AiMarkdown, b as Avatar, c as AvatarFallback, d as AvatarImage, B as BASE_COLORS, e as Badge, f as BadgeProps, g as Button, h as ButtonProps, C as Card, i as CardContent, j as CardDescription, k as CardFooter, l as CardHeader, m as CardProps, n as CardTitle, o as Checkbox, p as Collapsible, q as CollapsibleContent, r as CollapsibleTrigger, s as Command, t as CommandDialog, u as CommandEmpty, v as CommandGroup, w as CommandInput, x as CommandItem, y as CommandList, z as CommandSeparator, D as CommandShortcut, E as Dialog, F as DialogClose, G as DialogContent, H as DialogDescription, I as DialogFooter, J as DialogHeader, K as DialogOverlay, L as DialogPortal, M as DialogPresentation, N as DialogTitle, O as DialogTrigger, P as DictateContextValue, Q as DictateProvider, R as DocumentCard, S as DocumentCardProps, T as DocumentEntity, U as DocumentEntityProps, V as DocumentLike, W as DropdownMenu, X as DropdownMenuCheckboxItem, Y as DropdownMenuContent, Z as DropdownMenuGroup, _ as DropdownMenuItem, $ as DropdownMenuLabel, a0 as DropdownMenuPortal, a1 as DropdownMenuRadioGroup, a2 as DropdownMenuRadioItem, a3 as DropdownMenuSeparator, a4 as DropdownMenuShortcut, a5 as DropdownMenuSub, a6 as DropdownMenuSubContent, a7 as DropdownMenuSubTrigger, a8 as DropdownMenuTrigger, a9 as ENTITY_MAPPINGS, aa as EntityIcon, ab as EntityIconComponent, ac as EntityPill, ad as EntityRegistryOverride, ae as EntityType, af as HoverCard, ag as HoverCardContent, ah as HoverCardTrigger, ai as IconToggle, aj as IconToggleProps, ak as Input, al as InputProps, am as Label, an as MarkMenu, ao as MarkMenuItem, ap as MarkMenuProps, aq as MarkdownRenderer, ar as MarkdownRendererProps, as as MarkdownStreamingContext, at as NEUTRAL_GRAY, au as PLACEHOLDER_COLOR, av as PassageCard, aw as PassageCardProps, ax as Popover, ay as PopoverAnchor, az as PopoverContent, aA as PopoverTrigger, aB as PresenceDisplayStatus, aC as PresenceLabel, aD as Progress, aE as ProjectEntity, aF as ProjectEntityProps, aG as ProjectRelation, aH as RadioGroup, aI as RadioGroupItem, aJ as Rag, aK as RagDot, aL as RelevanceDot, aM as ScrollArea, aN as ScrollBar, aO as Select, aP as SelectContent, aQ as SelectGroup, aR as SelectItem, aS as SelectLabel, aT as SelectScrollDownButton, aU as SelectScrollUpButton, aV as SelectSeparator, aW as SelectTrigger, aX as SelectValue, aY as Separator, aZ as Slider, a_ as StatusBadgeComponent, a$ as StatusBadgeProps, b0 as StatusPill, b1 as StatusPillProps, b2 as StatusVariant, b3 as Switch, b4 as TAG_TYPE_ICONS, b5 as TAG_TYPE_LABELS, b6 as Table, b7 as TableBody, b8 as TableCaption, b9 as TableCell, ba as TableFooter, bb as TableHead, bc as TableHeader, bd as TableRow, be as Tabs, bf as TabsContent, bg as TabsList, bh as TabsTrigger, bi as TagEntity, bj as TagEntityProps, bk as TagLike, bl as Textarea, bm as TextareaProps, bn as Toggle, bo as ToggleGroup, bp as ToggleGroupItem, bq as Tooltip, br as TooltipContent, bs as TooltipProvider, bt as TooltipTrigger, bu as UserEntity, bv as UserEntityProps, bw as UserMenu, bx as UserMenuItem, by as UserMenuProps, bz as UserMenuStatus, bA as VISIBILITY_ICONS, bB as VisibilityIcon, bC as badgeVariants, bD as buttonVariants, bE as cardVariants, bF as cn, bG as configureEntityRegistry, bH as configureRagLabels, bI as configureStatusRegistry, bJ as getDocIcon, bK as getEntityColor, bL as getEntityColorStyles, bM as getEntityIcon, bN as getEntityLabel, bO as getStatusVariant, bP as getTagTypeIcon, bQ as getTagTypeLabel, bR as getWorkspaceColor, bS as markdownBaseComponents, bU as splitMarkdownBlocks, bV as toggleVariants, bW as trimOpenCitation } from '../index-CC6CvXEs.cjs';
|
|
2
|
+
import 'clsx';
|
|
3
|
+
import 'react';
|
|
4
|
+
import '@radix-ui/react-avatar';
|
|
5
|
+
import 'class-variance-authority/types';
|
|
6
|
+
import 'class-variance-authority';
|
|
7
|
+
import '@radix-ui/react-checkbox';
|
|
8
|
+
import 'lucide-react';
|
|
9
|
+
import '@radix-ui/react-collapsible';
|
|
10
|
+
import '@radix-ui/react-dialog';
|
|
11
|
+
import '@radix-ui/react-dropdown-menu';
|
|
12
|
+
import '@radix-ui/react-hover-card';
|
|
13
|
+
import '@radix-ui/react-popover';
|
|
14
|
+
import '@radix-ui/react-progress';
|
|
15
|
+
import '@radix-ui/react-radio-group';
|
|
16
|
+
import '@radix-ui/react-scroll-area';
|
|
17
|
+
import '@radix-ui/react-select';
|
|
18
|
+
import '@radix-ui/react-separator';
|
|
19
|
+
import '@radix-ui/react-slider';
|
|
20
|
+
import '@radix-ui/react-switch';
|
|
21
|
+
import '@radix-ui/react-tabs';
|
|
22
|
+
import '@radix-ui/react-toggle';
|
|
23
|
+
import '@radix-ui/react-toggle-group';
|
|
24
|
+
import 'react-markdown';
|