@g9tm/lynxcontrols 2.5.9 → 2.5.11
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/catalog/cards/G9Anchor.md +1 -1
- package/catalog/cards/G9AppearancePage.md +2 -2
- package/catalog/cards/G9ContrastPanel.md +1 -0
- package/catalog/cards/G9DesignNode.md +1 -1
- package/catalog/cards/G9Keycap.md +1 -1
- package/catalog/cards/G9PersonalThemeSheet.md +3 -3
- package/catalog/cards/G9ShortcutList.md +1 -1
- package/catalog/cards/G9SwipeView.md +1 -1
- package/catalog/cards/G9ThemePreviewCard.md +1 -0
- package/catalog/cards/G9ThemeTokenEditor.md +17 -0
- package/catalog/cards/G9WallpaperSwatch.md +2 -1
- package/catalog/catalog.json +1172 -224
- package/catalog/index.md +2 -1
- package/dist/.tsbuildinfo +1 -1
- package/dist/appearance/appearance.css +201 -0
- package/dist/appearance/appearance.css.map +1 -1
- package/dist/appearance/appearance.d.ts +75 -9
- package/dist/appearance/appearance.d.ts.map +1 -1
- package/dist/appearance/appearance.jsx +333 -56
- package/dist/appearance/index.d.ts +1 -0
- package/dist/appearance/index.d.ts.map +1 -1
- package/dist/appearance/index.jsx +1 -0
- package/dist/appearance/token-editor.d.ts +52 -0
- package/dist/appearance/token-editor.d.ts.map +1 -0
- package/dist/appearance/token-editor.jsx +205 -0
- package/dist/display/theme-preview.d.ts +2 -0
- package/dist/display/theme-preview.d.ts.map +1 -1
- package/dist/display/theme-preview.jsx +10 -4
- package/dist/provider/provider.d.ts.map +1 -1
- package/dist/provider/provider.jsx +3 -2
- package/dist/swipe/index.d.ts +1 -1
- package/dist/swipe/index.d.ts.map +1 -1
- package/dist/swipe/index.jsx +1 -1
- package/dist/swipe/model.d.ts +7 -0
- package/dist/swipe/model.d.ts.map +1 -1
- package/dist/swipe/model.jsx +8 -1
- package/dist/swipe/swipe-view.d.ts +7 -0
- package/dist/swipe/swipe-view.d.ts.map +1 -1
- package/dist/swipe/swipe-view.jsx +34 -6
- package/package.json +2 -2
- package/skills/g9-lynx-app/SKILL.md +1 -0
- package/skills/g9-lynx-app/references/catalog-index.md +9 -5
- package/skills/g9-lynx-app/references/components/anchor.md +1 -1
- package/skills/g9-lynx-app/references/components/appearance.md +26 -6
- package/skills/g9-lynx-app/references/components/calendar-1.md +21 -37
- package/skills/g9-lynx-app/references/components/calendar-2.md +38 -1
- package/skills/g9-lynx-app/references/components/canvas.md +1 -1
- package/skills/g9-lynx-app/references/components/chat-1.md +58 -61
- package/skills/g9-lynx-app/references/components/chat-2.md +111 -34
- package/skills/g9-lynx-app/references/components/chat-3.md +61 -0
- package/skills/g9-lynx-app/references/components/commands.md +1 -1
- package/skills/g9-lynx-app/references/components/design.md +1 -1
- package/skills/g9-lynx-app/references/components/display-1.md +1 -1
- package/skills/g9-lynx-app/references/components/display-3.md +1 -0
- package/skills/g9-lynx-app/references/components/media-1.md +75 -77
- package/skills/g9-lynx-app/references/components/media-2.md +131 -3
- package/skills/g9-lynx-app/references/components/native-media.md +34 -0
- package/skills/g9-lynx-app/references/components/projects.md +91 -3
- package/skills/g9-lynx-app/references/components/swipe.md +1 -1
- package/skills/g9-lynx-app/references/hosting.md +83 -0
|
@@ -12,9 +12,9 @@ Props:
|
|
|
12
12
|
- `systemScheme`: 'light' | 'dark'
|
|
13
13
|
- `themes`: object[]
|
|
14
14
|
- `onCreateTheme?`: () => void
|
|
15
|
+
- `onDeleteTheme?`: (theme: G9ThemeDefinition) => void
|
|
15
16
|
- `onEditTheme?`: (theme: G9ThemeDefinition) => void
|
|
16
|
-
- `
|
|
17
|
-
- `language?`: string
|
|
17
|
+
- `onExportEach?`: (theme: G9ThemeDefinition) => void
|
|
18
18
|
|
|
19
19
|
Example: `<G9AppearancePage onChange={() => {}} settings={settings} systemScheme="light" themes={themes} />`
|
|
20
20
|
|
|
@@ -27,6 +27,7 @@ A palette's contrast report: a sample, the ratio, AA / AAA and a fix for each fa
|
|
|
27
27
|
Props:
|
|
28
28
|
- `palette`: object
|
|
29
29
|
- `onFix?`: (foreground: string, value: string) => void
|
|
30
|
+
- `appTokens?`: object
|
|
30
31
|
- `onlyFailures?`: boolean
|
|
31
32
|
- `pairs?`: object[]
|
|
32
33
|
- `rules?`: object[]
|
|
@@ -41,16 +42,34 @@ Example: `<G9ContrastPanel palette={palette} />`
|
|
|
41
42
|
The personal theme editor: base, accent, surfaces, mode, wallpaper, a live preview and its contrast.
|
|
42
43
|
|
|
43
44
|
Props:
|
|
44
|
-
- `bases`: object[]
|
|
45
45
|
- `onClose`: () => void
|
|
46
|
-
- `onSave`: (theme: G9ThemeDefinition, draft: G9PersonalThemeDraft) => void
|
|
47
46
|
- `open`: boolean
|
|
48
47
|
- `onDelete?`: (id: string) => void
|
|
49
48
|
- `onExport?`: (theme: G9ThemeDefinition) => void
|
|
49
|
+
- `onSave?`: (theme: G9ThemeDefinition, draft: G9PersonalThemeDraft) => void
|
|
50
50
|
- `accents?`: object[]
|
|
51
|
+
- `bases?`: object[]
|
|
51
52
|
- `draft?`: object
|
|
52
53
|
|
|
53
|
-
Example: `<G9PersonalThemeSheet
|
|
54
|
+
Example: `<G9PersonalThemeSheet onClose={() => {}} open />`
|
|
55
|
+
|
|
56
|
+
# G9ThemeTokenEditor
|
|
57
|
+
|
|
58
|
+
`import { G9ThemeTokenEditor } from '@g9tm/lynxcontrols/appearance';`
|
|
59
|
+
|
|
60
|
+
The organisation theme editor: name, scheme, a row per token, a live preview and its contrast.
|
|
61
|
+
|
|
62
|
+
Props:
|
|
63
|
+
- `onChange`: (theme: G9TokenTheme) => void
|
|
64
|
+
- `value`: object
|
|
65
|
+
- `disabled?`: boolean
|
|
66
|
+
- `listHeight?`: number = 480
|
|
67
|
+
- `fill?`: boolean
|
|
68
|
+
- `inherited?`: object
|
|
69
|
+
- `language?`: string
|
|
70
|
+
- `layout?`: 'auto' | 'side' | 'stack'
|
|
71
|
+
|
|
72
|
+
Example: `<G9ThemeTokenEditor onChange={() => {}} value={value} />`
|
|
54
73
|
|
|
55
74
|
# G9WallpaperSwatch
|
|
56
75
|
|
|
@@ -61,10 +80,11 @@ A wallpaper as a small swatch in the palette's colours, with its name and a ring
|
|
|
61
80
|
Props:
|
|
62
81
|
- `palette`: object
|
|
63
82
|
- `scheme`: 'light' | 'dark'
|
|
64
|
-
- `wallpaper`: object
|
|
83
|
+
- `wallpaper`: object | object
|
|
65
84
|
- `label?`: string
|
|
66
85
|
- `selected?`: boolean
|
|
67
86
|
- `onPress?`: () => void
|
|
68
87
|
- `height?`: number = 56
|
|
88
|
+
- `tokens?`: object
|
|
69
89
|
|
|
70
90
|
Example: `<G9WallpaperSwatch palette={palette} scheme="light" wallpaper={wallpaper} />`
|
|
@@ -33,6 +33,24 @@ Props:
|
|
|
33
33
|
|
|
34
34
|
Example: `<G9BirthdayField labels={labels} onChange={() => {}} value={value} />`
|
|
35
35
|
|
|
36
|
+
# G9DateField
|
|
37
|
+
|
|
38
|
+
`import { G9DateField } from '@g9tm/lynxcontrols-calendar';`
|
|
39
|
+
|
|
40
|
+
A date field: the chosen day in a box (and in the other calendar), G9DateInput in a popover or a sheet on tap.
|
|
41
|
+
|
|
42
|
+
Props:
|
|
43
|
+
- `label`: string
|
|
44
|
+
- `onChange`: (date: G9LocalDate | null) => void
|
|
45
|
+
- `today`: object
|
|
46
|
+
- `value`: object
|
|
47
|
+
- `title?`: string
|
|
48
|
+
- `placeholder?`: string
|
|
49
|
+
- `disabled?`: boolean
|
|
50
|
+
- `clearLabel?`: string
|
|
51
|
+
|
|
52
|
+
Example: `<G9DateField label="Label" onChange={() => {}} today={today} value={value} />`
|
|
53
|
+
|
|
36
54
|
# G9DateInput
|
|
37
55
|
|
|
38
56
|
`import { G9DateInput } from '@g9tm/lynxcontrols-calendar';`
|
|
@@ -65,7 +83,7 @@ Props:
|
|
|
65
83
|
- `busy?`: boolean
|
|
66
84
|
- `guests?`: number
|
|
67
85
|
- `hidden?`: boolean
|
|
68
|
-
- `
|
|
86
|
+
- `online?`: boolean
|
|
69
87
|
|
|
70
88
|
Example: `<G9EventCard event={event} labels={labels} />`
|
|
71
89
|
|
|
@@ -144,10 +162,11 @@ Props:
|
|
|
144
162
|
- `labels`: object
|
|
145
163
|
- `onChange`: (rule: G9Recurrence | null) => void
|
|
146
164
|
- `value`: object
|
|
165
|
+
- `disabled?`: boolean
|
|
166
|
+
- `footer?`: ReactNode
|
|
147
167
|
- `editorLabels?`: object
|
|
148
168
|
- `presets?`: 'none' | 'daily' | 'weekly' | 'workdays' | 'monthlyDate' | 'monthlyWeekday' | 'yearly' | 'custom'[]
|
|
149
169
|
- `start?`: object
|
|
150
|
-
- `words?`: object
|
|
151
170
|
|
|
152
171
|
Example: `<G9RepeatPicker labels={labels} onChange={() => {}} value={value} />`
|
|
153
172
|
|
|
@@ -168,38 +187,3 @@ Props:
|
|
|
168
187
|
- `onMove?`: (event: G9CalendarEvent, draft: G9TimeDraft) => void
|
|
169
188
|
|
|
170
189
|
Example: `<G9TimeGrid events={events} start={start} today={today} />`
|
|
171
|
-
|
|
172
|
-
# G9TimeListPicker
|
|
173
|
-
|
|
174
|
-
`import { G9TimeListPicker } from '@g9tm/lynxcontrols-calendar';`
|
|
175
|
-
|
|
176
|
-
A time picked from a list of steps: a popover on a wide window, a sheet on a phone; it opens at the value.
|
|
177
|
-
|
|
178
|
-
Props:
|
|
179
|
-
- `label`: string
|
|
180
|
-
- `onChange`: (minutes: number) => void
|
|
181
|
-
- `value`: number
|
|
182
|
-
- `title?`: string
|
|
183
|
-
- `placeholder?`: string
|
|
184
|
-
- `disabled?`: boolean
|
|
185
|
-
- `hint?`: string
|
|
186
|
-
- `error?`: string
|
|
187
|
-
|
|
188
|
-
Example: `<G9TimeListPicker label="Label" onChange={() => {}} value={1} />`
|
|
189
|
-
|
|
190
|
-
# G9TodayWidget
|
|
191
|
-
|
|
192
|
-
`import { G9TodayWidget } from '@g9tm/lynxcontrols-calendar';`
|
|
193
|
-
|
|
194
|
-
Today's events on a home screen: the date, all-day first, then timed with the next one marked; «and n more».
|
|
195
|
-
|
|
196
|
-
Props:
|
|
197
|
-
- `events`: object[]
|
|
198
|
-
- `labels`: object
|
|
199
|
-
- `now`: number
|
|
200
|
-
- `today`: object
|
|
201
|
-
- `onOpen?`: () => void
|
|
202
|
-
- `onSelectEvent?`: (event: G9CalendarEvent) => void
|
|
203
|
-
- `max?`: number = 4
|
|
204
|
-
|
|
205
|
-
Example: `<G9TodayWidget events={events} labels={labels} now={1} today={today} />`
|
|
@@ -1,5 +1,41 @@
|
|
|
1
1
|
# `@g9tm/lynxcontrols-calendar` (part 2 of 2) (generated)
|
|
2
2
|
|
|
3
|
+
# G9TimeListPicker
|
|
4
|
+
|
|
5
|
+
`import { G9TimeListPicker } from '@g9tm/lynxcontrols-calendar';`
|
|
6
|
+
|
|
7
|
+
A time picked from a list of steps: a popover on a wide window, a sheet on a phone; it opens at the value.
|
|
8
|
+
|
|
9
|
+
Props:
|
|
10
|
+
- `label`: string
|
|
11
|
+
- `onChange`: (minutes: number) => void
|
|
12
|
+
- `value`: number
|
|
13
|
+
- `title?`: string
|
|
14
|
+
- `placeholder?`: string
|
|
15
|
+
- `disabled?`: boolean
|
|
16
|
+
- `hint?`: string
|
|
17
|
+
- `error?`: string
|
|
18
|
+
|
|
19
|
+
Example: `<G9TimeListPicker label="Label" onChange={() => {}} value={1} />`
|
|
20
|
+
|
|
21
|
+
# G9TodayWidget
|
|
22
|
+
|
|
23
|
+
`import { G9TodayWidget } from '@g9tm/lynxcontrols-calendar';`
|
|
24
|
+
|
|
25
|
+
Today's events on a home screen: the date, all-day first, then timed with the next one marked; «and n more».
|
|
26
|
+
|
|
27
|
+
Props:
|
|
28
|
+
- `events`: object[]
|
|
29
|
+
- `labels`: object
|
|
30
|
+
- `now`: number
|
|
31
|
+
- `today`: object
|
|
32
|
+
- `onNotice?`: () => void
|
|
33
|
+
- `onOpen?`: () => void
|
|
34
|
+
- `onSelectEvent?`: (event: G9CalendarEvent) => void
|
|
35
|
+
- `openText?`: string
|
|
36
|
+
|
|
37
|
+
Example: `<G9TodayWidget events={events} labels={labels} now={1} today={today} />`
|
|
38
|
+
|
|
3
39
|
# G9WorkingHoursEditor
|
|
4
40
|
|
|
5
41
|
`import { G9WorkingHoursEditor } from '@g9tm/lynxcontrols-calendar';`
|
|
@@ -10,10 +46,11 @@ Props:
|
|
|
10
46
|
- `labels`: object
|
|
11
47
|
- `onChange`: (week: Readonly<Partial<Record<number, readonly G9WorkRange[]>>>) => void
|
|
12
48
|
- `value`: object
|
|
49
|
+
- `disabled?`: boolean
|
|
13
50
|
- `onTimeZoneChange?`: (zone: string) => void
|
|
14
51
|
- `defaultRange?`: object = 9
|
|
52
|
+
- `maxRanges?`: number
|
|
15
53
|
- `timeZone?`: string
|
|
16
|
-
- `zones?`: string[]
|
|
17
54
|
|
|
18
55
|
Example: `<G9WorkingHoursEditor labels={labels} onChange={() => {}} value={value} />`
|
|
19
56
|
|
|
@@ -11,7 +11,7 @@ Props:
|
|
|
11
11
|
- `editable`: boolean
|
|
12
12
|
- `port`: object
|
|
13
13
|
- `stroke`: object
|
|
14
|
-
- `tool`: 'text' | 'image' | 'line' | 'selection' | 'arrow' | 'diamond' | 'rectangle' | 'ellipse' | 'frame' | '
|
|
14
|
+
- `tool`: 'text' | 'image' | 'line' | 'selection' | 'hand' | 'arrow' | 'diamond' | 'rectangle' | 'ellipse' | 'frame' | 'freedraw' | 'eraser' | 'laser'
|
|
15
15
|
- `accent?`: string
|
|
16
16
|
- `background?`: color
|
|
17
17
|
- `dark?`: boolean
|
|
@@ -1,4 +1,22 @@
|
|
|
1
|
-
# `@g9tm/lynxcontrols-chat` (part 1 of
|
|
1
|
+
# `@g9tm/lynxcontrols-chat` (part 1 of 3) (generated)
|
|
2
|
+
|
|
3
|
+
# G9AckBar
|
|
4
|
+
|
|
5
|
+
`import { G9AckBar } from '@g9tm/lynxcontrols-chat';`
|
|
6
|
+
|
|
7
|
+
«Read and acknowledge» under a post (a bubble's `after`): one tap to confirm; the sender sees «n of m» and the list.
|
|
8
|
+
|
|
9
|
+
Props:
|
|
10
|
+
- `state`: 'none' | 'done' | 'needed' | 'manage'
|
|
11
|
+
- `words`: object
|
|
12
|
+
- `onAck?`: () => void
|
|
13
|
+
- `onList?`: () => void
|
|
14
|
+
- `acked?`: number
|
|
15
|
+
- `busy?`: boolean
|
|
16
|
+
- `color?`: color
|
|
17
|
+
- `mine?`: boolean
|
|
18
|
+
|
|
19
|
+
Example: `<G9AckBar state="none" words={words} />`
|
|
2
20
|
|
|
3
21
|
# G9ChatComposer
|
|
4
22
|
|
|
@@ -31,8 +49,8 @@ Props:
|
|
|
31
49
|
- `onLoadOlder?`: () => void
|
|
32
50
|
- `onLongPress?`: (message: G9Message) => void
|
|
33
51
|
- `onRetry?`: (message: G9Message) => void
|
|
52
|
+
- `avatarOf?`: (from) => ReactNode
|
|
34
53
|
- `renderAttachment?`: (message) => ReactNode
|
|
35
|
-
- `bubble?`: object
|
|
36
54
|
|
|
37
55
|
Example: `<G9ChatThread me="me" messages={messages} />`
|
|
38
56
|
|
|
@@ -54,6 +72,21 @@ Props:
|
|
|
54
72
|
|
|
55
73
|
Example: `<G9ConversationRow at={1} name="name" preview="preview" />`
|
|
56
74
|
|
|
75
|
+
# G9EditHistorySheet
|
|
76
|
+
|
|
77
|
+
`import { G9EditHistorySheet } from '@g9tm/lynxcontrols-chat';`
|
|
78
|
+
|
|
79
|
+
The edit history of a message: the original, then each edit with what it changed.
|
|
80
|
+
|
|
81
|
+
Props:
|
|
82
|
+
- `onClose`: () => void
|
|
83
|
+
- `open`: boolean
|
|
84
|
+
- `versions`: object[]
|
|
85
|
+
- `title?`: string
|
|
86
|
+
- `originalLabel?`: string
|
|
87
|
+
|
|
88
|
+
Example: `<G9EditHistorySheet onClose={() => {}} open versions={versions} />`
|
|
89
|
+
|
|
57
90
|
# G9EmojiLibrary
|
|
58
91
|
|
|
59
92
|
`import { G9EmojiLibrary } from '@g9tm/lynxcontrols-chat';`
|
|
@@ -94,17 +127,17 @@ Example: `<G9EmojiPicker onPick={() => {}} />`
|
|
|
94
127
|
|
|
95
128
|
`import { G9FileCard } from '@g9tm/lynxcontrols-chat';`
|
|
96
129
|
|
|
97
|
-
A file in a message: its
|
|
130
|
+
A file in a message: its type icon, name and size, an upload's ring, or its download state, and the app's actions.
|
|
98
131
|
|
|
99
132
|
Props:
|
|
100
133
|
- `name`: string
|
|
101
134
|
- `size?`: number
|
|
102
135
|
- `icon?`: icon
|
|
103
136
|
- `onCancel?`: () => void
|
|
137
|
+
- `onDownload?`: () => void
|
|
104
138
|
- `onOpen?`: () => void
|
|
105
139
|
- `cancelLabel?`: string
|
|
106
|
-
- `
|
|
107
|
-
- `progress?`: number
|
|
140
|
+
- `actions?`: ReactNode
|
|
108
141
|
|
|
109
142
|
Example: `<G9FileCard name="name" />`
|
|
110
143
|
|
|
@@ -126,74 +159,38 @@ Props:
|
|
|
126
159
|
|
|
127
160
|
Example: `<G9GifPicker onPick={() => {}} packs={packs} />`
|
|
128
161
|
|
|
162
|
+
# G9KudosDialog
|
|
163
|
+
|
|
164
|
+
`import { G9KudosDialog } from '@g9tm/lynxcontrols-chat';`
|
|
165
|
+
|
|
166
|
+
«👏 Thanks» to a person: their avatar, an emoji and a short note (a sheet's content).
|
|
167
|
+
|
|
168
|
+
Props:
|
|
169
|
+
- `name`: string
|
|
170
|
+
- `onSend`: (emoji: string, note: string) => void
|
|
171
|
+
- `words`: object
|
|
172
|
+
- `onCancel?`: () => void
|
|
173
|
+
- `avatar?`: string
|
|
174
|
+
- `busy?`: boolean
|
|
175
|
+
- `emojis?`: string[]
|
|
176
|
+
- `maxLength?`: number = 280
|
|
177
|
+
|
|
178
|
+
Example: `<G9KudosDialog name="name" onSend={() => {}} words={words} />`
|
|
179
|
+
|
|
129
180
|
# G9LinkPreview
|
|
130
181
|
|
|
131
182
|
`import { G9LinkPreview } from '@g9tm/lynxcontrols-chat';`
|
|
132
183
|
|
|
133
|
-
A link's
|
|
184
|
+
A link's card: the site and its icon, the title, a description, the picture wide on top or as a thumbnail.
|
|
134
185
|
|
|
135
186
|
Props:
|
|
136
187
|
- `url`: string
|
|
137
188
|
- `title?`: string
|
|
138
189
|
- `onDismiss?`: () => void
|
|
190
|
+
- `onImageError?`: (src: string) => void
|
|
139
191
|
- `onOpen?`: (url: string) => void
|
|
140
192
|
- `description?`: string
|
|
141
193
|
- `dismissLabel?`: string
|
|
142
194
|
- `compact?`: boolean
|
|
143
|
-
- `image?`: string
|
|
144
195
|
|
|
145
196
|
Example: `<G9LinkPreview url="url" />`
|
|
146
|
-
|
|
147
|
-
# G9MessageBubble
|
|
148
|
-
|
|
149
|
-
`import { G9MessageBubble } from '@g9tm/lynxcontrols-chat';`
|
|
150
|
-
|
|
151
|
-
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
|
|
152
|
-
|
|
153
|
-
Props:
|
|
154
|
-
- `message`: object
|
|
155
|
-
- `mine`: boolean
|
|
156
|
-
- `customEmoji?`: (shortcode: string) => void
|
|
157
|
-
- `forwardedLabel?`: (from: string) => void
|
|
158
|
-
- `onAddReaction?`: (message: G9Message) => void
|
|
159
|
-
- `onEdited?`: (message: G9Message) => void
|
|
160
|
-
- `onLongPress?`: (message: G9Message) => void
|
|
161
|
-
- `onMention?`: (id: string) => void
|
|
162
|
-
|
|
163
|
-
Example: `<G9MessageBubble message={message} mine />`
|
|
164
|
-
|
|
165
|
-
# G9MessageMenu
|
|
166
|
-
|
|
167
|
-
`import { G9MessageMenu } from '@g9tm/lynxcontrols-chat';`
|
|
168
|
-
|
|
169
|
-
A message's long-press menu: a row of quick reactions (and «+» for the full picker) above the actions.
|
|
170
|
-
|
|
171
|
-
Props:
|
|
172
|
-
- `items`: object[]
|
|
173
|
-
- `onClose`: () => void
|
|
174
|
-
- `onSelect`: (key: string) => void
|
|
175
|
-
- `open`: boolean
|
|
176
|
-
- `title?`: string
|
|
177
|
-
- `onReact?`: (emoji: string) => void
|
|
178
|
-
- `cancelText?`: string
|
|
179
|
-
- `moreLabel?`: string
|
|
180
|
-
|
|
181
|
-
Example: `<G9MessageMenu items={items} onClose={() => {}} onSelect={() => {}} open />`
|
|
182
|
-
|
|
183
|
-
# G9MessageMeta
|
|
184
|
-
|
|
185
|
-
`import { G9MessageMeta } from '@g9tm/lynxcontrols-chat';`
|
|
186
|
-
|
|
187
|
-
A message's meta line: marks (pinned, silent, reminder, waiting), «edited», the time and my ticks.
|
|
188
|
-
|
|
189
|
-
Props:
|
|
190
|
-
- `time`: string | number
|
|
191
|
-
- `onEdited?`: () => void
|
|
192
|
-
- `onRetry?`: () => void
|
|
193
|
-
- `editedLabel?`: string
|
|
194
|
-
- `markIcons?`: icon
|
|
195
|
-
- `edited?`: boolean
|
|
196
|
-
- `marks?`: 'pinned' | 'silent' | 'reminder' | 'waiting'[]
|
|
197
|
-
- `mine?`: boolean
|
|
198
|
-
|
|
199
|
-
Example: `<G9MessageMeta time={time} />`
|
|
@@ -1,4 +1,58 @@
|
|
|
1
|
-
# `@g9tm/lynxcontrols-chat` (part 2 of
|
|
1
|
+
# `@g9tm/lynxcontrols-chat` (part 2 of 3) (generated)
|
|
2
|
+
|
|
3
|
+
# G9MessageBubble
|
|
4
|
+
|
|
5
|
+
`import { G9MessageBubble } from '@g9tm/lynxcontrols-chat';`
|
|
6
|
+
|
|
7
|
+
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
|
|
8
|
+
|
|
9
|
+
Props:
|
|
10
|
+
- `message`: object
|
|
11
|
+
- `mine`: boolean
|
|
12
|
+
- `commentsLabel?`: (count: number) => void
|
|
13
|
+
- `customEmoji?`: (shortcode: string) => void
|
|
14
|
+
- `forwardedLabel?`: (from: string) => void
|
|
15
|
+
- `onAddReaction?`: (message: G9Message) => void
|
|
16
|
+
- `onCallAction?`: (message: G9Message) => void
|
|
17
|
+
- `onContextMenu?`: (message: G9Message, point: { readonly x: number; readonly y: number; }) => void
|
|
18
|
+
|
|
19
|
+
Example: `<G9MessageBubble message={message} mine />`
|
|
20
|
+
|
|
21
|
+
# G9MessageMenu
|
|
22
|
+
|
|
23
|
+
`import { G9MessageMenu } from '@g9tm/lynxcontrols-chat';`
|
|
24
|
+
|
|
25
|
+
A message's long-press menu: a row of quick reactions (and «+» for the full picker) above the actions.
|
|
26
|
+
|
|
27
|
+
Props:
|
|
28
|
+
- `items`: object[]
|
|
29
|
+
- `onClose`: () => void
|
|
30
|
+
- `onSelect`: (key: string) => void
|
|
31
|
+
- `open`: boolean
|
|
32
|
+
- `title?`: string
|
|
33
|
+
- `onReact?`: (emoji: string) => void
|
|
34
|
+
- `cancelText?`: string
|
|
35
|
+
- `moreLabel?`: string
|
|
36
|
+
|
|
37
|
+
Example: `<G9MessageMenu items={items} onClose={() => {}} onSelect={() => {}} open />`
|
|
38
|
+
|
|
39
|
+
# G9MessageMeta
|
|
40
|
+
|
|
41
|
+
`import { G9MessageMeta } from '@g9tm/lynxcontrols-chat';`
|
|
42
|
+
|
|
43
|
+
A message's meta line: marks (pinned, silent, reminder, waiting), «edited», the time and my ticks.
|
|
44
|
+
|
|
45
|
+
Props:
|
|
46
|
+
- `time`: string | number
|
|
47
|
+
- `onEdited?`: () => void
|
|
48
|
+
- `onRetry?`: () => void
|
|
49
|
+
- `editedLabel?`: string
|
|
50
|
+
- `markIcons?`: icon
|
|
51
|
+
- `edited?`: boolean
|
|
52
|
+
- `marks?`: 'pinned' | 'silent' | 'reminder' | 'waiting'[]
|
|
53
|
+
- `mine?`: boolean
|
|
54
|
+
|
|
55
|
+
Example: `<G9MessageMeta time={time} />`
|
|
2
56
|
|
|
3
57
|
# G9MessageText
|
|
4
58
|
|
|
@@ -31,8 +85,8 @@ Props:
|
|
|
31
85
|
- `errorText?`: (error: unknown) => void
|
|
32
86
|
- `onPick?`: (person: G9Person) => void
|
|
33
87
|
- `onSelectedChange?`: (people: G9Person[]) => void
|
|
88
|
+
- `autoFocus?`: boolean
|
|
34
89
|
- `exclude?`: string[]
|
|
35
|
-
- `multiple?`: boolean = false
|
|
36
90
|
|
|
37
91
|
Example: `<G9PersonPicker labels={labels} search={search} />`
|
|
38
92
|
|
|
@@ -52,6 +106,42 @@ Props:
|
|
|
52
106
|
|
|
53
107
|
Example: `<G9PinnedBar items={items} label="Label" onJump={() => {}} />`
|
|
54
108
|
|
|
109
|
+
# G9PollCard
|
|
110
|
+
|
|
111
|
+
`import { G9PollCard } from '@g9tm/lynxcontrols-chat';`
|
|
112
|
+
|
|
113
|
+
A poll in the thread: tap to vote, then live results with bars, my ticks, the leader and the latest voters.
|
|
114
|
+
|
|
115
|
+
Props:
|
|
116
|
+
- `poll`: object
|
|
117
|
+
- `words`: object
|
|
118
|
+
- `onAddOption?`: (text: string) => void
|
|
119
|
+
- `onClose?`: () => void
|
|
120
|
+
- `onRetract?`: () => void
|
|
121
|
+
- `onVote?`: (optionIds: readonly string[]) => void
|
|
122
|
+
- `onVoters?`: () => void
|
|
123
|
+
- `busy?`: boolean
|
|
124
|
+
|
|
125
|
+
Example: `<G9PollCard poll={poll} words={words} />`
|
|
126
|
+
|
|
127
|
+
# G9PollComposer
|
|
128
|
+
|
|
129
|
+
`import { G9PollComposer } from '@g9tm/lynxcontrols-chat';`
|
|
130
|
+
|
|
131
|
+
The poll's composer: a question, 2–12 answers (the action key moves on and adds one), multiple, anonymous, a close.
|
|
132
|
+
|
|
133
|
+
Props:
|
|
134
|
+
- `onSend`: (poll: G9PollDraft) => void
|
|
135
|
+
- `words`: object
|
|
136
|
+
- `busy?`: boolean
|
|
137
|
+
- `closeOptions?`: object[]
|
|
138
|
+
- `initial?`: object
|
|
139
|
+
- `maxOptions?`: number
|
|
140
|
+
- `minOptions?`: number = 2
|
|
141
|
+
- `now?`: number
|
|
142
|
+
|
|
143
|
+
Example: `<G9PollComposer onSend={() => {}} words={words} />`
|
|
144
|
+
|
|
55
145
|
# G9ReactionBar
|
|
56
146
|
|
|
57
147
|
`import { G9ReactionBar } from '@g9tm/lynxcontrols-chat';`
|
|
@@ -65,11 +155,29 @@ Props:
|
|
|
65
155
|
- `onDetails?`: (emoji: string) => void
|
|
66
156
|
- `onToggle?`: (emoji: string) => void
|
|
67
157
|
- `addLabel?`: string
|
|
158
|
+
- `hideSingleCount?`: boolean
|
|
68
159
|
- `mine?`: boolean
|
|
69
|
-
- `selectedWord?`: string
|
|
70
160
|
|
|
71
161
|
Example: `<G9ReactionBar reactions={reactions} />`
|
|
72
162
|
|
|
163
|
+
# G9SchedulePicker
|
|
164
|
+
|
|
165
|
+
`import { G9SchedulePicker } from '@g9tm/lynxcontrols-chat';`
|
|
166
|
+
|
|
167
|
+
Send later (presets, an exact date and time in the culture's calendar, a repeat) or a self-destruct timer.
|
|
168
|
+
|
|
169
|
+
Props:
|
|
170
|
+
- `confirmLabel`: string
|
|
171
|
+
- `onConfirm`: (at: number | null) => void
|
|
172
|
+
- `words`: object
|
|
173
|
+
- `value?`: number
|
|
174
|
+
- `onChange?`: (at: number) => void
|
|
175
|
+
- `repeat?`: ReactNode
|
|
176
|
+
- `destruct?`: object
|
|
177
|
+
- `mode?`: 'send' | 'destruct'
|
|
178
|
+
|
|
179
|
+
Example: `<G9SchedulePicker confirmLabel="confirmLabel" onConfirm={() => {}} words={words} />`
|
|
180
|
+
|
|
73
181
|
# G9SlashSuggestions
|
|
74
182
|
|
|
75
183
|
`import { G9SlashSuggestions } from '@g9tm/lynxcontrols-chat';`
|
|
@@ -86,34 +194,3 @@ Props:
|
|
|
86
194
|
- `keyboard?`: boolean = true
|
|
87
195
|
|
|
88
196
|
Example: `<G9SlashSuggestions commands={commands} onPick={() => {}} text="Label" />`
|
|
89
|
-
|
|
90
|
-
# G9StickerPicker
|
|
91
|
-
|
|
92
|
-
`import { G9StickerPicker } from '@g9tm/lynxcontrols-chat';`
|
|
93
|
-
|
|
94
|
-
Stickers by pack (tabs) or GIFs, in a virtual grid, with an optional search; each cell spoken by its label.
|
|
95
|
-
|
|
96
|
-
Props:
|
|
97
|
-
- `onPick`: (item: G9StickerItem, packId: string | null) => void
|
|
98
|
-
- `packs`: object[]
|
|
99
|
-
- `columns?`: number
|
|
100
|
-
- `variant?`: 'sticker' | 'gif'
|
|
101
|
-
- `onItemLongPress?`: (item: G9StickerItem, packId: string | null) => void
|
|
102
|
-
- `search?`: (query: string, signal: AbortSignal) => void
|
|
103
|
-
- `emptyText?`: string
|
|
104
|
-
- `errorText?`: string
|
|
105
|
-
|
|
106
|
-
Example: `<G9StickerPicker onPick={() => {}} packs={packs} />`
|
|
107
|
-
|
|
108
|
-
# G9TypingDots
|
|
109
|
-
|
|
110
|
-
`import { G9TypingDots } from '@g9tm/lynxcontrols-chat';`
|
|
111
|
-
|
|
112
|
-
Three dots that rise in turn (CSS animation: nothing runs in script).
|
|
113
|
-
|
|
114
|
-
Props:
|
|
115
|
-
- `label?`: string
|
|
116
|
-
- `variant?`: 'bubble' | 'inline'
|
|
117
|
-
- `color?`: color
|
|
118
|
-
|
|
119
|
-
Example: `<G9TypingDots />`
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# `@g9tm/lynxcontrols-chat` (part 3 of 3) (generated)
|
|
2
|
+
|
|
3
|
+
# G9StickerPicker
|
|
4
|
+
|
|
5
|
+
`import { G9StickerPicker } from '@g9tm/lynxcontrols-chat';`
|
|
6
|
+
|
|
7
|
+
Stickers by pack (tabs) or GIFs, in a virtual grid, with an optional search; each cell spoken by its label.
|
|
8
|
+
|
|
9
|
+
Props:
|
|
10
|
+
- `onPick`: (item: G9StickerItem, packId: string | null) => void
|
|
11
|
+
- `packs`: object[]
|
|
12
|
+
- `columns?`: number
|
|
13
|
+
- `variant?`: 'sticker' | 'gif'
|
|
14
|
+
- `onItemLongPress?`: (item: G9StickerItem, packId: string | null) => void
|
|
15
|
+
- `search?`: (query: string, signal: AbortSignal) => void
|
|
16
|
+
- `emptyText?`: string
|
|
17
|
+
- `errorText?`: string
|
|
18
|
+
|
|
19
|
+
Example: `<G9StickerPicker onPick={() => {}} packs={packs} />`
|
|
20
|
+
|
|
21
|
+
# G9SystemPill
|
|
22
|
+
|
|
23
|
+
`import { G9SystemPill } from '@g9tm/lynxcontrols-chat';`
|
|
24
|
+
|
|
25
|
+
A system line in a thread (a member joined, the title changed): a quiet centred pill (2.5.10).
|
|
26
|
+
|
|
27
|
+
Props:
|
|
28
|
+
- `text`: string
|
|
29
|
+
|
|
30
|
+
Example: `<G9SystemPill text="Label" />`
|
|
31
|
+
|
|
32
|
+
# G9ThreadSearch
|
|
33
|
+
|
|
34
|
+
`import { G9ThreadSearch } from '@g9tm/lynxcontrols-chat';`
|
|
35
|
+
|
|
36
|
+
A search bar over a thread: the query, «n of m», ↑ / ↓ through the matches (wrapping), close.
|
|
37
|
+
|
|
38
|
+
Props:
|
|
39
|
+
- `count`: number
|
|
40
|
+
- `index`: number
|
|
41
|
+
- `onClose`: () => void
|
|
42
|
+
- `onIndexChange`: (index: number) => void
|
|
43
|
+
- `onQueryChange`: (query: string) => void
|
|
44
|
+
- `query`: string
|
|
45
|
+
- `autoFocus?`: boolean = true
|
|
46
|
+
- `words?`: object
|
|
47
|
+
|
|
48
|
+
Example: `<G9ThreadSearch count={1} index={1} onClose={() => {}} onIndexChange={() => {}} onQueryChange={() => {}} query="query" />`
|
|
49
|
+
|
|
50
|
+
# G9TypingDots
|
|
51
|
+
|
|
52
|
+
`import { G9TypingDots } from '@g9tm/lynxcontrols-chat';`
|
|
53
|
+
|
|
54
|
+
Three dots that rise in turn (CSS animation: nothing runs in script).
|
|
55
|
+
|
|
56
|
+
Props:
|
|
57
|
+
- `label?`: string
|
|
58
|
+
- `variant?`: 'bubble' | 'inline'
|
|
59
|
+
- `color?`: color
|
|
60
|
+
|
|
61
|
+
Example: `<G9TypingDots />`
|
|
@@ -9,7 +9,7 @@ A layout-neutral box that is an anchor (the probe measures it, hit-tests it, fol
|
|
|
9
9
|
Props:
|
|
10
10
|
- `label?`: string
|
|
11
11
|
- `children?`: ReactNode
|
|
12
|
-
- `kind?`: 'label' | 'image' | 'button' | 'entry' | 'toggle' | 'picker' | '
|
|
12
|
+
- `kind?`: 'label' | 'chips' | 'image' | 'button' | 'entry' | 'toggle' | 'picker' | 'tab' | 'tab-view' | 'list' | 'scroll' | 'item' | 'card' | 'map' | 'view' = "view"
|
|
13
13
|
- `name?`: string
|
|
14
14
|
|
|
15
15
|
Example: `<G9DesignNode />`
|