@g9tm/lynxcontrols-chat 2.2.1 → 2.4.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.
@@ -0,0 +1,17 @@
1
+ # G9ChatComposer
2
+
3
+ `import { G9ChatComposer } from '@g9tm/lynxcontrols-chat';`
4
+
5
+ The message box: a growing text area (up to 5 lines), attach and emoji at the start, send at the end — send only when there is text; Enter on a hardware keyboard sends, Shift+Enter breaks the line.
6
+
7
+ Props:
8
+ - `onSend`: (text: string) => void
9
+ - `placeholder`: string
10
+ - `value?`: string
11
+ - `onChange?`: (text: string) => void
12
+ - `disabled?`: boolean
13
+ - `onAttach?`: () => void
14
+ - `onEmoji?`: () => void
15
+ - `attachLabel?`: string
16
+
17
+ Example: `<G9ChatComposer onSend={() => {}} placeholder="placeholder" />`
@@ -0,0 +1,17 @@
1
+ # G9ChatThread
2
+
3
+ `import { G9ChatThread } from '@g9tm/lynxcontrols-chat';`
4
+
5
+ A conversation on the recycler: starts at the newest message, day dividers sticky, rows rendered as they come into view (deferred list items), older pages asked for near the top.
6
+
7
+ Props:
8
+ - `me`: string
9
+ - `messages`: object[]
10
+ - `dayLabel?`: (dayStartMs: number) => void
11
+ - `onLoadOlder?`: () => void
12
+ - `onLongPress?`: (message: G9Message) => void
13
+ - `onRetry?`: (message: G9Message) => void
14
+ - `renderAttachment?`: (message) => ReactNode
15
+ - `names?`: object
16
+
17
+ Example: `<G9ChatThread me="me" messages={messages} />`
@@ -0,0 +1,17 @@
1
+ # G9ConversationRow
2
+
3
+ `import { G9ConversationRow } from '@g9tm/lynxcontrols-chat';`
4
+
5
+ A conversation in the inbox: avatar (with presence), name, the last message or «typing…», its time, unread count.
6
+
7
+ Props:
8
+ - `at`: number
9
+ - `name`: string
10
+ - `preview`: string
11
+ - `onPress?`: () => void
12
+ - `typingText?`: string
13
+ - `avatar?`: string
14
+ - `muted?`: boolean
15
+ - `online?`: boolean
16
+
17
+ Example: `<G9ConversationRow at={1} name="name" preview="preview" />`
@@ -0,0 +1,13 @@
1
+ # G9EmojiPicker
2
+
3
+ `import { G9EmojiPicker } from '@g9tm/lynxcontrols-chat';`
4
+
5
+ Emoji by category: tabs over a grid of 44 dp targets.
6
+
7
+ Props:
8
+ - `onPick`: (emoji: string) => void
9
+ - `columns?`: number
10
+ - `labels?`: object
11
+ - `sets?`: object
12
+
13
+ Example: `<G9EmojiPicker onPick={() => {}} />`
@@ -0,0 +1,17 @@
1
+ # G9MessageBubble
2
+
3
+ `import { G9MessageBubble } from '@g9tm/lynxcontrols-chat';`
4
+
5
+ One message: mine on the end side in the primary container colour, theirs on the start side on the surface; the corner toward the sender is tightened inside a run (first/middle/last), the time and the status ticks under
6
+
7
+ Props:
8
+ - `message`: object
9
+ - `mine`: boolean
10
+ - `onLongPress?`: (message: G9Message) => void
11
+ - `onRetry?`: (message: G9Message) => void
12
+ - `attachment?`: ReactNode
13
+ - `position?`: 'single' | 'last' | 'first' | 'middle'
14
+ - `senderName?`: string
15
+ - `showTime?`: boolean
16
+
17
+ Example: `<G9MessageBubble message={message} mine />`
@@ -0,0 +1,10 @@
1
+ # G9TypingDots
2
+
3
+ `import { G9TypingDots } from '@g9tm/lynxcontrols-chat';`
4
+
5
+ Three dots that rise in turn (CSS animation: nothing runs in script).
6
+
7
+ Props:
8
+ - `label?`: string
9
+
10
+ Example: `<G9TypingDots />`