reifyui 0.11.1 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/index.cjs +453 -158
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +17 -2
- package/dist/index.js +454 -159
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/src/components/CascadeMenu.jsx +210 -0
- package/src/components/ChatMessages.jsx +30 -9
- package/src/components/Chip.jsx +37 -10
- package/src/components/Composer.jsx +44 -0
- package/src/index.d.ts +17 -2
- package/src/index.js +2 -0
- package/src/sheet/SheetGrid.jsx +72 -6
- package/styles/chat.css +45 -5
- package/styles/chip.css +36 -0
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
// authored by hand rather than inferred. Components accept the props documented in
|
|
5
5
|
// the README; where a prop set is open-ended (render slots, passthrough) the type is
|
|
6
6
|
// intentionally permissive rather than falsely precise.
|
|
7
|
-
import type { ComponentType, ReactNode } from 'react';
|
|
7
|
+
import type { ComponentType, ForwardRefExoticComponent, ReactNode, RefAttributes } from 'react';
|
|
8
8
|
|
|
9
9
|
// ── streaming ──────────────────────────────────────────────────────────────
|
|
10
10
|
export interface SSEEvent { type: string; [k: string]: unknown; }
|
|
@@ -183,8 +183,14 @@ export interface ComposerProps {
|
|
|
183
183
|
/** The accessible name. Give one whenever the placeholder animates — it is otherwise the only
|
|
184
184
|
* name the field has, and it changes every few seconds. */
|
|
185
185
|
inputAriaLabel?: string;
|
|
186
|
+
/** Single-line layout: accessories, textarea and send share ONE row (the classic chat
|
|
187
|
+
* input); buttons stick to the bottom edge as the textarea grows. */
|
|
188
|
+
inline?: boolean;
|
|
186
189
|
/** Node rendered ABOVE the textarea, e.g. a row of staged attachments. */
|
|
187
190
|
attachments?: ReactNode;
|
|
191
|
+
/** Node rendered INSIDE the card, under the action row — one seamless surface, for the row
|
|
192
|
+
* that belongs to the message being composed (route chips, a template picker). */
|
|
193
|
+
tray?: ReactNode;
|
|
188
194
|
accessoriesLeft?: ReactNode;
|
|
189
195
|
accessoriesRight?: ReactNode;
|
|
190
196
|
/** Replaces the default send button entirely. */
|
|
@@ -348,9 +354,18 @@ export interface ChipProps {
|
|
|
348
354
|
onRemove?: () => void;
|
|
349
355
|
/** Required with onRemove: "✕" alone does not say which of five chips it removes. */
|
|
350
356
|
removeLabel?: string;
|
|
357
|
+
/** The dashed "open slot" look for a choice not yet made. Defaults to clickable-and-unselected;
|
|
358
|
+
* pass slot={false} for a chip that is clickable AND already set. */
|
|
359
|
+
slot?: boolean;
|
|
360
|
+
/** A compact control the chip carries between the label and the ✕ (the caller's control —
|
|
361
|
+
* never wrapped in the chip's own press target). */
|
|
362
|
+
trailing?: ReactNode;
|
|
351
363
|
className?: string;
|
|
364
|
+
/** Everything else lands on the press target (aria-expanded, aria-haspopup, data-*). */
|
|
365
|
+
[k: string]: unknown;
|
|
352
366
|
}
|
|
353
|
-
|
|
367
|
+
/** ref lands on the OUTERMOST element — the box a Popover or CascadeMenu anchors against. */
|
|
368
|
+
export const Chip: ForwardRefExoticComponent<ChipProps & RefAttributes<HTMLElement>>;
|
|
354
369
|
|
|
355
370
|
export interface SearchFieldProps {
|
|
356
371
|
value: string;
|