@epam/ai-dial-conversation-input 1.2.0-dev.28 → 1.2.0-dev.282

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/components/AddAttachmentButton/AddAttachmentButton.d.ts +6 -0
  2. package/components/AddAttachmentButton/AddAttachmentButton.d.ts.map +1 -1
  3. package/components/BottomSheetShell/BottomSheetShell.d.ts +2 -2
  4. package/components/BottomSheetShell/BottomSheetShell.d.ts.map +1 -1
  5. package/components/ChatSettingsModal/ChatSettingsModal.d.ts.map +1 -1
  6. package/components/ConversationInput/ConversationInput.d.ts.map +1 -1
  7. package/components/EditMessageInput/EditMessageInput.d.ts.map +1 -1
  8. package/components/Input/Input.d.ts +2 -3
  9. package/components/Input/Input.d.ts.map +1 -1
  10. package/components/Input/ModelSelectorControl.d.ts +3 -1
  11. package/components/Input/ModelSelectorControl.d.ts.map +1 -1
  12. package/components/ModelSelectorBottomSheet/ModelSelectorBottomSheet.d.ts +3 -0
  13. package/components/ModelSelectorBottomSheet/ModelSelectorBottomSheet.d.ts.map +1 -1
  14. package/components/ToolsChips/ToolsChips.d.ts +11 -0
  15. package/components/ToolsChips/ToolsChips.d.ts.map +1 -1
  16. package/components/VoiceBar/VoiceBar.d.ts +1 -3
  17. package/components/VoiceBar/VoiceBar.d.ts.map +1 -1
  18. package/constants/public-class-names.d.ts +41 -0
  19. package/constants/public-class-names.d.ts.map +1 -0
  20. package/hooks/useAttachments.d.ts.map +1 -1
  21. package/hooks/useCommandMenu/useCommandMenu.d.ts +35 -5
  22. package/hooks/useCommandMenu/useCommandMenu.d.ts.map +1 -1
  23. package/hooks/useComposerSeed.d.ts +32 -0
  24. package/hooks/useComposerSeed.d.ts.map +1 -0
  25. package/hooks/useMentionSelectionMirror.d.ts +22 -0
  26. package/hooks/useMentionSelectionMirror.d.ts.map +1 -0
  27. package/hooks/useModelSelector.d.ts +7 -13
  28. package/hooks/useModelSelector.d.ts.map +1 -1
  29. package/hooks/useTextInsertion.d.ts +24 -2
  30. package/hooks/useTextInsertion.d.ts.map +1 -1
  31. package/hooks/useVoiceRecorder.d.ts.map +1 -1
  32. package/index.css +2 -2
  33. package/index.d.ts +5 -2
  34. package/index.d.ts.map +1 -1
  35. package/index.js +1549 -1257
  36. package/models/ConversationInput.d.ts +99 -16
  37. package/models/ConversationInput.d.ts.map +1 -1
  38. package/models/Input.d.ts +207 -32
  39. package/models/Input.d.ts.map +1 -1
  40. package/package.json +4 -5
  41. package/utils/highlight-mirror.d.ts +17 -0
  42. package/utils/highlight-mirror.d.ts.map +1 -0
  43. package/hooks/useBottomSheet.d.ts +0 -9
  44. package/hooks/useBottomSheet.d.ts.map +0 -1
@@ -0,0 +1,17 @@
1
+ import { ReactNode } from 'react';
2
+ import { HighlightedTextRange } from '../models/Input';
3
+ export interface MirrorInsertion {
4
+ offset: number;
5
+ /** A React element carrying its own `key`. */
6
+ node: ReactNode;
7
+ }
8
+ export declare const renderHighlightedText: (text: string, ranges: HighlightedTextRange[], insertions: MirrorInsertion[], mentionHighlightClassName: string, mentionHighlightUnsupportedClassName: string) => ReactNode[];
9
+ /**
10
+ * A DOM `Range` spanning `[start, end)` characters of `message` within the
11
+ * highlight mirror, or `null` when either boundary can't be located (see
12
+ * `locateMirrorOffset`). Used to read the exact, wrap-aware pixel rectangles
13
+ * of the current native text selection via `Range.getClientRects()`, rather
14
+ * than re-deriving line-wrapping by hand.
15
+ */
16
+ export declare const buildMirrorSelectionRange: (root: HTMLElement, start: number, end: number) => Range | null;
17
+ //# sourceMappingURL=highlight-mirror.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"highlight-mirror.d.ts","sourceRoot":"","sources":["../../src/utils/highlight-mirror.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAO5D,MAAM,WAAW,eAAe;IAC9B,MAAM,EAAE,MAAM,CAAC;IACf,8CAA8C;IAC9C,IAAI,EAAE,SAAS,CAAC;CACjB;AA2BD,eAAO,MAAM,qBAAqB,GAChC,MAAM,MAAM,EACZ,QAAQ,oBAAoB,EAAE,EAC9B,YAAY,eAAe,EAAE,EAC7B,2BAA2B,MAAM,EACjC,sCAAsC,MAAM,KAC3C,SAAS,EA6DX,CAAC;AAqCF;;;;;;GAMG;AACH,eAAO,MAAM,yBAAyB,GACpC,MAAM,WAAW,EACjB,OAAO,MAAM,EACb,KAAK,MAAM,KACV,KAAK,GAAG,IASV,CAAC"}
@@ -1,9 +0,0 @@
1
- import { RefObject } from 'react';
2
- /**
3
- * Handles Escape-to-close, body-scroll-locking, and dialog focus management
4
- * (initial focus, Tab trapping, and focus restoration on close) for a
5
- * bottom-sheet overlay. Pass the sheet container ref so focus can be moved
6
- * into the sheet on open and returned to the triggering element on close.
7
- */
8
- export declare const useBottomSheet: (isOpen: boolean, onClose: () => void, sheetRef?: RefObject<HTMLElement | null>) => void;
9
- //# sourceMappingURL=useBottomSheet.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useBottomSheet.d.ts","sourceRoot":"","sources":["../../src/hooks/useBottomSheet.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAWlD;;;;;GAKG;AACH,eAAO,MAAM,cAAc,GACzB,QAAQ,OAAO,EACf,SAAS,MAAM,IAAI,EACnB,WAAW,SAAS,CAAC,WAAW,GAAG,IAAI,CAAC,KACvC,IA4EF,CAAC"}