@oxy.so/bloom 5.1.0 → 5.1.1

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 (430) hide show
  1. package/docs/adoption-matrix.mdx +9 -9
  2. package/docs/button.mdx +2 -0
  3. package/docs/card-form.mdx +2 -0
  4. package/docs/chat-composer.mdx +1 -1
  5. package/docs/earnings.mdx +2 -0
  6. package/docs/field.mdx +2 -0
  7. package/docs/label.mdx +2 -0
  8. package/docs/payment-method.mdx +2 -0
  9. package/docs/place-details.mdx +2 -2
  10. package/docs/proof-of-delivery.mdx +4 -0
  11. package/docs/select.mdx +2 -0
  12. package/lib/commonjs/button/Button.js +36 -3
  13. package/lib/commonjs/button/Button.js.map +1 -1
  14. package/lib/commonjs/button/GlyphButton.js +7 -3
  15. package/lib/commonjs/button/GlyphButton.js.map +1 -1
  16. package/lib/commonjs/card-form/shared.js +3 -2
  17. package/lib/commonjs/card-form/shared.js.map +1 -1
  18. package/lib/commonjs/chat-composer/AttachmentMenu.js +8 -227
  19. package/lib/commonjs/chat-composer/AttachmentMenu.js.map +1 -1
  20. package/lib/commonjs/chat-composer/AttachmentMenu.web.js +16 -0
  21. package/lib/commonjs/chat-composer/AttachmentMenu.web.js.map +1 -0
  22. package/lib/commonjs/chat-composer/ChatComposer.js +9 -388
  23. package/lib/commonjs/chat-composer/ChatComposer.js.map +1 -1
  24. package/lib/commonjs/chat-composer/ChatComposer.web.js +16 -0
  25. package/lib/commonjs/chat-composer/ChatComposer.web.js.map +1 -0
  26. package/lib/commonjs/chat-composer/ComposerAttachmentStrip.js +5 -200
  27. package/lib/commonjs/chat-composer/ComposerAttachmentStrip.js.map +1 -1
  28. package/lib/commonjs/chat-composer/ComposerAttachmentStrip.web.js +12 -0
  29. package/lib/commonjs/chat-composer/ComposerAttachmentStrip.web.js.map +1 -0
  30. package/lib/commonjs/chat-composer/ComposerBanner.js +5 -163
  31. package/lib/commonjs/chat-composer/ComposerBanner.js.map +1 -1
  32. package/lib/commonjs/chat-composer/ComposerBanner.web.js +12 -0
  33. package/lib/commonjs/chat-composer/ComposerBanner.web.js.map +1 -0
  34. package/lib/commonjs/chat-composer/EmojiPicker.js +6 -443
  35. package/lib/commonjs/chat-composer/EmojiPicker.js.map +1 -1
  36. package/lib/commonjs/chat-composer/EmojiPicker.web.js +14 -0
  37. package/lib/commonjs/chat-composer/EmojiPicker.web.js.map +1 -0
  38. package/lib/commonjs/chat-composer/MessageContextMenu.js +12 -102
  39. package/lib/commonjs/chat-composer/MessageContextMenu.js.map +1 -1
  40. package/lib/commonjs/chat-composer/MessageContextMenu.web.js +19 -0
  41. package/lib/commonjs/chat-composer/MessageContextMenu.web.js.map +1 -0
  42. package/lib/commonjs/chat-composer/ReactionPicker.js +6 -107
  43. package/lib/commonjs/chat-composer/ReactionPicker.js.map +1 -1
  44. package/lib/commonjs/chat-composer/ReactionPicker.web.js +14 -0
  45. package/lib/commonjs/chat-composer/ReactionPicker.web.js.map +1 -0
  46. package/lib/commonjs/chat-composer/SuggestionList.js +5 -222
  47. package/lib/commonjs/chat-composer/SuggestionList.js.map +1 -1
  48. package/lib/commonjs/chat-composer/SuggestionList.web.js +12 -0
  49. package/lib/commonjs/chat-composer/SuggestionList.web.js.map +1 -0
  50. package/lib/commonjs/chat-composer/VoiceRecorder.js +7 -263
  51. package/lib/commonjs/chat-composer/VoiceRecorder.js.map +1 -1
  52. package/lib/commonjs/chat-composer/VoiceRecorder.web.js +16 -0
  53. package/lib/commonjs/chat-composer/VoiceRecorder.web.js.map +1 -0
  54. package/lib/commonjs/chat-composer/create-attachment-menu.js +243 -0
  55. package/lib/commonjs/chat-composer/create-attachment-menu.js.map +1 -0
  56. package/lib/commonjs/chat-composer/create-chat-composer.js +400 -0
  57. package/lib/commonjs/chat-composer/create-chat-composer.js.map +1 -0
  58. package/lib/commonjs/chat-composer/create-composer-attachment-strip.js +212 -0
  59. package/lib/commonjs/chat-composer/create-composer-attachment-strip.js.map +1 -0
  60. package/lib/commonjs/chat-composer/create-composer-banner.js +176 -0
  61. package/lib/commonjs/chat-composer/create-composer-banner.js.map +1 -0
  62. package/lib/commonjs/chat-composer/create-emoji-picker.js +456 -0
  63. package/lib/commonjs/chat-composer/create-emoji-picker.js.map +1 -0
  64. package/lib/commonjs/chat-composer/create-message-context-menu.js +119 -0
  65. package/lib/commonjs/chat-composer/create-message-context-menu.js.map +1 -0
  66. package/lib/commonjs/chat-composer/create-reaction-picker.js +120 -0
  67. package/lib/commonjs/chat-composer/create-reaction-picker.js.map +1 -0
  68. package/lib/commonjs/chat-composer/create-suggestion-list.js +234 -0
  69. package/lib/commonjs/chat-composer/create-suggestion-list.js.map +1 -0
  70. package/lib/commonjs/chat-composer/create-voice-recorder.js +277 -0
  71. package/lib/commonjs/chat-composer/create-voice-recorder.js.map +1 -0
  72. package/lib/commonjs/chat-composer/index.js +9 -9
  73. package/lib/commonjs/chat-composer/index.web.js +18 -18
  74. package/lib/commonjs/chat-composer/index.web.js.map +1 -1
  75. package/lib/commonjs/earnings/EarningsSummary.js +12 -2
  76. package/lib/commonjs/earnings/EarningsSummary.js.map +1 -1
  77. package/lib/commonjs/field/Field.js +2 -0
  78. package/lib/commonjs/field/Field.js.map +1 -1
  79. package/lib/commonjs/item/Item.js +16 -8
  80. package/lib/commonjs/item/Item.js.map +1 -1
  81. package/lib/commonjs/job-board/JobCard.js +6 -2
  82. package/lib/commonjs/job-board/JobCard.js.map +1 -1
  83. package/lib/commonjs/label/Label.js +2 -1
  84. package/lib/commonjs/label/Label.js.map +1 -1
  85. package/lib/commonjs/listing-details/AmenityList.js +4 -3
  86. package/lib/commonjs/listing-details/AmenityList.js.map +1 -1
  87. package/lib/commonjs/mail-compose/MailComposeSurface.js +1 -1
  88. package/lib/commonjs/overlay/InteractionBoundary.js +28 -0
  89. package/lib/commonjs/overlay/InteractionBoundary.js.map +1 -0
  90. package/lib/commonjs/payment-method/PaymentMethodList.js +3 -2
  91. package/lib/commonjs/payment-method/PaymentMethodList.js.map +1 -1
  92. package/lib/commonjs/place-details/PlaceAmenities.js +17 -6
  93. package/lib/commonjs/place-details/PlaceAmenities.js.map +1 -1
  94. package/lib/commonjs/place-details/PlacePopularTimes.js +7 -1
  95. package/lib/commonjs/place-details/PlacePopularTimes.js.map +1 -1
  96. package/lib/commonjs/proof-of-delivery/ProofOfDelivery.js +10 -1
  97. package/lib/commonjs/proof-of-delivery/ProofOfDelivery.js.map +1 -1
  98. package/lib/commonjs/proof-of-delivery/shared.js +1 -1
  99. package/lib/commonjs/proof-of-delivery/shared.js.map +1 -1
  100. package/lib/commonjs/select/Select.js +7 -4
  101. package/lib/commonjs/select/Select.js.map +1 -1
  102. package/lib/commonjs/select/Select.web.js +7 -4
  103. package/lib/commonjs/select/Select.web.js.map +1 -1
  104. package/lib/commonjs/select/use-required-description.js +37 -0
  105. package/lib/commonjs/select/use-required-description.js.map +1 -0
  106. package/lib/module/button/Button.js +36 -3
  107. package/lib/module/button/Button.js.map +1 -1
  108. package/lib/module/button/GlyphButton.js +7 -3
  109. package/lib/module/button/GlyphButton.js.map +1 -1
  110. package/lib/module/card-form/shared.js +3 -2
  111. package/lib/module/card-form/shared.js.map +1 -1
  112. package/lib/module/chat-composer/AttachmentMenu.js +7 -226
  113. package/lib/module/chat-composer/AttachmentMenu.js.map +1 -1
  114. package/lib/module/chat-composer/AttachmentMenu.web.js +12 -0
  115. package/lib/module/chat-composer/AttachmentMenu.web.js.map +1 -0
  116. package/lib/module/chat-composer/ChatComposer.js +8 -385
  117. package/lib/module/chat-composer/ChatComposer.js.map +1 -1
  118. package/lib/module/chat-composer/ChatComposer.web.js +12 -0
  119. package/lib/module/chat-composer/ChatComposer.web.js.map +1 -0
  120. package/lib/module/chat-composer/ComposerAttachmentStrip.js +4 -196
  121. package/lib/module/chat-composer/ComposerAttachmentStrip.js.map +1 -1
  122. package/lib/module/chat-composer/ComposerAttachmentStrip.web.js +8 -0
  123. package/lib/module/chat-composer/ComposerAttachmentStrip.web.js.map +1 -0
  124. package/lib/module/chat-composer/ComposerBanner.js +4 -162
  125. package/lib/module/chat-composer/ComposerBanner.js.map +1 -1
  126. package/lib/module/chat-composer/ComposerBanner.web.js +8 -0
  127. package/lib/module/chat-composer/ComposerBanner.web.js.map +1 -0
  128. package/lib/module/chat-composer/EmojiPicker.js +5 -440
  129. package/lib/module/chat-composer/EmojiPicker.js.map +1 -1
  130. package/lib/module/chat-composer/EmojiPicker.web.js +10 -0
  131. package/lib/module/chat-composer/EmojiPicker.web.js.map +1 -0
  132. package/lib/module/chat-composer/MessageContextMenu.js +11 -99
  133. package/lib/module/chat-composer/MessageContextMenu.js.map +1 -1
  134. package/lib/module/chat-composer/MessageContextMenu.web.js +15 -0
  135. package/lib/module/chat-composer/MessageContextMenu.web.js.map +1 -0
  136. package/lib/module/chat-composer/ReactionPicker.js +5 -104
  137. package/lib/module/chat-composer/ReactionPicker.js.map +1 -1
  138. package/lib/module/chat-composer/ReactionPicker.web.js +10 -0
  139. package/lib/module/chat-composer/ReactionPicker.web.js.map +1 -0
  140. package/lib/module/chat-composer/SuggestionList.js +4 -219
  141. package/lib/module/chat-composer/SuggestionList.js.map +1 -1
  142. package/lib/module/chat-composer/SuggestionList.web.js +8 -0
  143. package/lib/module/chat-composer/SuggestionList.web.js.map +1 -0
  144. package/lib/module/chat-composer/VoiceRecorder.js +6 -260
  145. package/lib/module/chat-composer/VoiceRecorder.js.map +1 -1
  146. package/lib/module/chat-composer/VoiceRecorder.web.js +12 -0
  147. package/lib/module/chat-composer/VoiceRecorder.web.js.map +1 -0
  148. package/lib/module/chat-composer/create-attachment-menu.js +238 -0
  149. package/lib/module/chat-composer/create-attachment-menu.js.map +1 -0
  150. package/lib/module/chat-composer/create-chat-composer.js +395 -0
  151. package/lib/module/chat-composer/create-chat-composer.js.map +1 -0
  152. package/lib/module/chat-composer/create-composer-attachment-strip.js +206 -0
  153. package/lib/module/chat-composer/create-composer-attachment-strip.js.map +1 -0
  154. package/lib/module/chat-composer/create-composer-banner.js +171 -0
  155. package/lib/module/chat-composer/create-composer-banner.js.map +1 -0
  156. package/lib/module/chat-composer/create-emoji-picker.js +451 -0
  157. package/lib/module/chat-composer/create-emoji-picker.js.map +1 -0
  158. package/lib/module/chat-composer/create-message-context-menu.js +114 -0
  159. package/lib/module/chat-composer/create-message-context-menu.js.map +1 -0
  160. package/lib/module/chat-composer/create-reaction-picker.js +115 -0
  161. package/lib/module/chat-composer/create-reaction-picker.js.map +1 -0
  162. package/lib/module/chat-composer/create-suggestion-list.js +229 -0
  163. package/lib/module/chat-composer/create-suggestion-list.js.map +1 -0
  164. package/lib/module/chat-composer/create-voice-recorder.js +272 -0
  165. package/lib/module/chat-composer/create-voice-recorder.js.map +1 -0
  166. package/lib/module/chat-composer/index.js +9 -9
  167. package/lib/module/chat-composer/index.js.map +1 -1
  168. package/lib/module/chat-composer/index.web.js +9 -9
  169. package/lib/module/chat-composer/index.web.js.map +1 -1
  170. package/lib/module/earnings/EarningsSummary.js +12 -2
  171. package/lib/module/earnings/EarningsSummary.js.map +1 -1
  172. package/lib/module/field/Field.js +2 -0
  173. package/lib/module/field/Field.js.map +1 -1
  174. package/lib/module/item/Item.js +16 -8
  175. package/lib/module/item/Item.js.map +1 -1
  176. package/lib/module/job-board/JobCard.js +6 -2
  177. package/lib/module/job-board/JobCard.js.map +1 -1
  178. package/lib/module/label/Label.js +2 -1
  179. package/lib/module/label/Label.js.map +1 -1
  180. package/lib/module/listing-details/AmenityList.js +4 -3
  181. package/lib/module/listing-details/AmenityList.js.map +1 -1
  182. package/lib/module/mail-compose/MailComposeSurface.js +1 -1
  183. package/lib/module/mail-compose/MailComposeSurface.js.map +1 -1
  184. package/lib/module/overlay/InteractionBoundary.js +25 -0
  185. package/lib/module/overlay/InteractionBoundary.js.map +1 -0
  186. package/lib/module/payment-method/PaymentMethodList.js +3 -2
  187. package/lib/module/payment-method/PaymentMethodList.js.map +1 -1
  188. package/lib/module/place-details/PlaceAmenities.js +15 -4
  189. package/lib/module/place-details/PlaceAmenities.js.map +1 -1
  190. package/lib/module/place-details/PlacePopularTimes.js +7 -1
  191. package/lib/module/place-details/PlacePopularTimes.js.map +1 -1
  192. package/lib/module/proof-of-delivery/ProofOfDelivery.js +10 -1
  193. package/lib/module/proof-of-delivery/ProofOfDelivery.js.map +1 -1
  194. package/lib/module/proof-of-delivery/shared.js +1 -1
  195. package/lib/module/proof-of-delivery/shared.js.map +1 -1
  196. package/lib/module/select/Select.js +7 -4
  197. package/lib/module/select/Select.js.map +1 -1
  198. package/lib/module/select/Select.web.js +7 -4
  199. package/lib/module/select/Select.web.js.map +1 -1
  200. package/lib/module/select/use-required-description.js +33 -0
  201. package/lib/module/select/use-required-description.js.map +1 -0
  202. package/lib/typescript/commonjs/button/Button.d.ts.map +1 -1
  203. package/lib/typescript/commonjs/card-form/shared.d.ts +2 -1
  204. package/lib/typescript/commonjs/card-form/shared.d.ts.map +1 -1
  205. package/lib/typescript/commonjs/chat-composer/AttachmentMenu.d.ts +1 -2
  206. package/lib/typescript/commonjs/chat-composer/AttachmentMenu.d.ts.map +1 -1
  207. package/lib/typescript/commonjs/chat-composer/AttachmentMenu.web.d.ts +2 -0
  208. package/lib/typescript/commonjs/chat-composer/AttachmentMenu.web.d.ts.map +1 -0
  209. package/lib/typescript/commonjs/chat-composer/ChatComposer.d.ts +1 -2
  210. package/lib/typescript/commonjs/chat-composer/ChatComposer.d.ts.map +1 -1
  211. package/lib/typescript/commonjs/chat-composer/ChatComposer.web.d.ts +2 -0
  212. package/lib/typescript/commonjs/chat-composer/ChatComposer.web.d.ts.map +1 -0
  213. package/lib/typescript/commonjs/chat-composer/ComposerAttachmentStrip.d.ts +1 -2
  214. package/lib/typescript/commonjs/chat-composer/ComposerAttachmentStrip.d.ts.map +1 -1
  215. package/lib/typescript/commonjs/chat-composer/ComposerAttachmentStrip.web.d.ts +2 -0
  216. package/lib/typescript/commonjs/chat-composer/ComposerAttachmentStrip.web.d.ts.map +1 -0
  217. package/lib/typescript/commonjs/chat-composer/ComposerBanner.d.ts +1 -2
  218. package/lib/typescript/commonjs/chat-composer/ComposerBanner.d.ts.map +1 -1
  219. package/lib/typescript/commonjs/chat-composer/ComposerBanner.web.d.ts +2 -0
  220. package/lib/typescript/commonjs/chat-composer/ComposerBanner.web.d.ts.map +1 -0
  221. package/lib/typescript/commonjs/chat-composer/EmojiPicker.d.ts +1 -2
  222. package/lib/typescript/commonjs/chat-composer/EmojiPicker.d.ts.map +1 -1
  223. package/lib/typescript/commonjs/chat-composer/EmojiPicker.web.d.ts +2 -0
  224. package/lib/typescript/commonjs/chat-composer/EmojiPicker.web.d.ts.map +1 -0
  225. package/lib/typescript/commonjs/chat-composer/MessageContextMenu.d.ts +1 -2
  226. package/lib/typescript/commonjs/chat-composer/MessageContextMenu.d.ts.map +1 -1
  227. package/lib/typescript/commonjs/chat-composer/MessageContextMenu.web.d.ts +2 -0
  228. package/lib/typescript/commonjs/chat-composer/MessageContextMenu.web.d.ts.map +1 -0
  229. package/lib/typescript/commonjs/chat-composer/ReactionPicker.d.ts +1 -2
  230. package/lib/typescript/commonjs/chat-composer/ReactionPicker.d.ts.map +1 -1
  231. package/lib/typescript/commonjs/chat-composer/ReactionPicker.web.d.ts +2 -0
  232. package/lib/typescript/commonjs/chat-composer/ReactionPicker.web.d.ts.map +1 -0
  233. package/lib/typescript/commonjs/chat-composer/SuggestionList.d.ts +1 -2
  234. package/lib/typescript/commonjs/chat-composer/SuggestionList.d.ts.map +1 -1
  235. package/lib/typescript/commonjs/chat-composer/SuggestionList.web.d.ts +2 -0
  236. package/lib/typescript/commonjs/chat-composer/SuggestionList.web.d.ts.map +1 -0
  237. package/lib/typescript/commonjs/chat-composer/VoiceRecorder.d.ts +1 -2
  238. package/lib/typescript/commonjs/chat-composer/VoiceRecorder.d.ts.map +1 -1
  239. package/lib/typescript/commonjs/chat-composer/VoiceRecorder.web.d.ts +2 -0
  240. package/lib/typescript/commonjs/chat-composer/VoiceRecorder.web.d.ts.map +1 -0
  241. package/lib/typescript/commonjs/chat-composer/create-attachment-menu.d.ts +11 -0
  242. package/lib/typescript/commonjs/chat-composer/create-attachment-menu.d.ts.map +1 -0
  243. package/lib/typescript/commonjs/chat-composer/create-chat-composer.d.ts +11 -0
  244. package/lib/typescript/commonjs/chat-composer/create-chat-composer.d.ts.map +1 -0
  245. package/lib/typescript/commonjs/chat-composer/create-composer-attachment-strip.d.ts +7 -0
  246. package/lib/typescript/commonjs/chat-composer/create-composer-attachment-strip.d.ts.map +1 -0
  247. package/lib/typescript/commonjs/chat-composer/create-composer-banner.d.ts +7 -0
  248. package/lib/typescript/commonjs/chat-composer/create-composer-banner.d.ts.map +1 -0
  249. package/lib/typescript/commonjs/chat-composer/create-emoji-picker.d.ts +9 -0
  250. package/lib/typescript/commonjs/chat-composer/create-emoji-picker.d.ts.map +1 -0
  251. package/lib/typescript/commonjs/chat-composer/create-message-context-menu.d.ts +14 -0
  252. package/lib/typescript/commonjs/chat-composer/create-message-context-menu.d.ts.map +1 -0
  253. package/lib/typescript/commonjs/chat-composer/create-reaction-picker.d.ts +9 -0
  254. package/lib/typescript/commonjs/chat-composer/create-reaction-picker.d.ts.map +1 -0
  255. package/lib/typescript/commonjs/chat-composer/create-suggestion-list.d.ts +7 -0
  256. package/lib/typescript/commonjs/chat-composer/create-suggestion-list.d.ts.map +1 -0
  257. package/lib/typescript/commonjs/chat-composer/create-voice-recorder.d.ts +11 -0
  258. package/lib/typescript/commonjs/chat-composer/create-voice-recorder.d.ts.map +1 -0
  259. package/lib/typescript/commonjs/chat-composer/index.web.d.ts +9 -9
  260. package/lib/typescript/commonjs/chat-composer/index.web.d.ts.map +1 -1
  261. package/lib/typescript/commonjs/earnings/EarningsSummary.d.ts.map +1 -1
  262. package/lib/typescript/commonjs/field/Field.d.ts +1 -1
  263. package/lib/typescript/commonjs/field/Field.d.ts.map +1 -1
  264. package/lib/typescript/commonjs/field/types.d.ts +2 -0
  265. package/lib/typescript/commonjs/field/types.d.ts.map +1 -1
  266. package/lib/typescript/commonjs/floating/types.d.ts +1 -0
  267. package/lib/typescript/commonjs/floating/types.d.ts.map +1 -1
  268. package/lib/typescript/commonjs/item/Item.d.ts.map +1 -1
  269. package/lib/typescript/commonjs/job-board/JobCard.d.ts.map +1 -1
  270. package/lib/typescript/commonjs/label/Label.d.ts +1 -1
  271. package/lib/typescript/commonjs/label/Label.d.ts.map +1 -1
  272. package/lib/typescript/commonjs/label/types.d.ts +2 -0
  273. package/lib/typescript/commonjs/label/types.d.ts.map +1 -1
  274. package/lib/typescript/commonjs/listing-details/AmenityList.d.ts.map +1 -1
  275. package/lib/typescript/commonjs/overlay/InteractionBoundary.d.ts +7 -0
  276. package/lib/typescript/commonjs/overlay/InteractionBoundary.d.ts.map +1 -0
  277. package/lib/typescript/commonjs/payment-method/PaymentMethodList.d.ts.map +1 -1
  278. package/lib/typescript/commonjs/place-details/PlaceAmenities.d.ts.map +1 -1
  279. package/lib/typescript/commonjs/place-details/PlacePopularTimes.d.ts.map +1 -1
  280. package/lib/typescript/commonjs/proof-of-delivery/ProofOfDelivery.d.ts.map +1 -1
  281. package/lib/typescript/commonjs/select/Select.d.ts.map +1 -1
  282. package/lib/typescript/commonjs/select/Select.web.d.ts.map +1 -1
  283. package/lib/typescript/commonjs/select/use-required-description.d.ts +7 -0
  284. package/lib/typescript/commonjs/select/use-required-description.d.ts.map +1 -0
  285. package/lib/typescript/module/button/Button.d.ts.map +1 -1
  286. package/lib/typescript/module/card-form/shared.d.ts +2 -1
  287. package/lib/typescript/module/card-form/shared.d.ts.map +1 -1
  288. package/lib/typescript/module/chat-composer/AttachmentMenu.d.ts +1 -2
  289. package/lib/typescript/module/chat-composer/AttachmentMenu.d.ts.map +1 -1
  290. package/lib/typescript/module/chat-composer/AttachmentMenu.web.d.ts +2 -0
  291. package/lib/typescript/module/chat-composer/AttachmentMenu.web.d.ts.map +1 -0
  292. package/lib/typescript/module/chat-composer/ChatComposer.d.ts +1 -2
  293. package/lib/typescript/module/chat-composer/ChatComposer.d.ts.map +1 -1
  294. package/lib/typescript/module/chat-composer/ChatComposer.web.d.ts +2 -0
  295. package/lib/typescript/module/chat-composer/ChatComposer.web.d.ts.map +1 -0
  296. package/lib/typescript/module/chat-composer/ComposerAttachmentStrip.d.ts +1 -2
  297. package/lib/typescript/module/chat-composer/ComposerAttachmentStrip.d.ts.map +1 -1
  298. package/lib/typescript/module/chat-composer/ComposerAttachmentStrip.web.d.ts +2 -0
  299. package/lib/typescript/module/chat-composer/ComposerAttachmentStrip.web.d.ts.map +1 -0
  300. package/lib/typescript/module/chat-composer/ComposerBanner.d.ts +1 -2
  301. package/lib/typescript/module/chat-composer/ComposerBanner.d.ts.map +1 -1
  302. package/lib/typescript/module/chat-composer/ComposerBanner.web.d.ts +2 -0
  303. package/lib/typescript/module/chat-composer/ComposerBanner.web.d.ts.map +1 -0
  304. package/lib/typescript/module/chat-composer/EmojiPicker.d.ts +1 -2
  305. package/lib/typescript/module/chat-composer/EmojiPicker.d.ts.map +1 -1
  306. package/lib/typescript/module/chat-composer/EmojiPicker.web.d.ts +2 -0
  307. package/lib/typescript/module/chat-composer/EmojiPicker.web.d.ts.map +1 -0
  308. package/lib/typescript/module/chat-composer/MessageContextMenu.d.ts +1 -2
  309. package/lib/typescript/module/chat-composer/MessageContextMenu.d.ts.map +1 -1
  310. package/lib/typescript/module/chat-composer/MessageContextMenu.web.d.ts +2 -0
  311. package/lib/typescript/module/chat-composer/MessageContextMenu.web.d.ts.map +1 -0
  312. package/lib/typescript/module/chat-composer/ReactionPicker.d.ts +1 -2
  313. package/lib/typescript/module/chat-composer/ReactionPicker.d.ts.map +1 -1
  314. package/lib/typescript/module/chat-composer/ReactionPicker.web.d.ts +2 -0
  315. package/lib/typescript/module/chat-composer/ReactionPicker.web.d.ts.map +1 -0
  316. package/lib/typescript/module/chat-composer/SuggestionList.d.ts +1 -2
  317. package/lib/typescript/module/chat-composer/SuggestionList.d.ts.map +1 -1
  318. package/lib/typescript/module/chat-composer/SuggestionList.web.d.ts +2 -0
  319. package/lib/typescript/module/chat-composer/SuggestionList.web.d.ts.map +1 -0
  320. package/lib/typescript/module/chat-composer/VoiceRecorder.d.ts +1 -2
  321. package/lib/typescript/module/chat-composer/VoiceRecorder.d.ts.map +1 -1
  322. package/lib/typescript/module/chat-composer/VoiceRecorder.web.d.ts +2 -0
  323. package/lib/typescript/module/chat-composer/VoiceRecorder.web.d.ts.map +1 -0
  324. package/lib/typescript/module/chat-composer/create-attachment-menu.d.ts +11 -0
  325. package/lib/typescript/module/chat-composer/create-attachment-menu.d.ts.map +1 -0
  326. package/lib/typescript/module/chat-composer/create-chat-composer.d.ts +11 -0
  327. package/lib/typescript/module/chat-composer/create-chat-composer.d.ts.map +1 -0
  328. package/lib/typescript/module/chat-composer/create-composer-attachment-strip.d.ts +7 -0
  329. package/lib/typescript/module/chat-composer/create-composer-attachment-strip.d.ts.map +1 -0
  330. package/lib/typescript/module/chat-composer/create-composer-banner.d.ts +7 -0
  331. package/lib/typescript/module/chat-composer/create-composer-banner.d.ts.map +1 -0
  332. package/lib/typescript/module/chat-composer/create-emoji-picker.d.ts +9 -0
  333. package/lib/typescript/module/chat-composer/create-emoji-picker.d.ts.map +1 -0
  334. package/lib/typescript/module/chat-composer/create-message-context-menu.d.ts +14 -0
  335. package/lib/typescript/module/chat-composer/create-message-context-menu.d.ts.map +1 -0
  336. package/lib/typescript/module/chat-composer/create-reaction-picker.d.ts +9 -0
  337. package/lib/typescript/module/chat-composer/create-reaction-picker.d.ts.map +1 -0
  338. package/lib/typescript/module/chat-composer/create-suggestion-list.d.ts +7 -0
  339. package/lib/typescript/module/chat-composer/create-suggestion-list.d.ts.map +1 -0
  340. package/lib/typescript/module/chat-composer/create-voice-recorder.d.ts +11 -0
  341. package/lib/typescript/module/chat-composer/create-voice-recorder.d.ts.map +1 -0
  342. package/lib/typescript/module/chat-composer/index.web.d.ts +9 -9
  343. package/lib/typescript/module/chat-composer/index.web.d.ts.map +1 -1
  344. package/lib/typescript/module/earnings/EarningsSummary.d.ts.map +1 -1
  345. package/lib/typescript/module/field/Field.d.ts +1 -1
  346. package/lib/typescript/module/field/Field.d.ts.map +1 -1
  347. package/lib/typescript/module/field/types.d.ts +2 -0
  348. package/lib/typescript/module/field/types.d.ts.map +1 -1
  349. package/lib/typescript/module/floating/types.d.ts +1 -0
  350. package/lib/typescript/module/floating/types.d.ts.map +1 -1
  351. package/lib/typescript/module/item/Item.d.ts.map +1 -1
  352. package/lib/typescript/module/job-board/JobCard.d.ts.map +1 -1
  353. package/lib/typescript/module/label/Label.d.ts +1 -1
  354. package/lib/typescript/module/label/Label.d.ts.map +1 -1
  355. package/lib/typescript/module/label/types.d.ts +2 -0
  356. package/lib/typescript/module/label/types.d.ts.map +1 -1
  357. package/lib/typescript/module/listing-details/AmenityList.d.ts.map +1 -1
  358. package/lib/typescript/module/overlay/InteractionBoundary.d.ts +7 -0
  359. package/lib/typescript/module/overlay/InteractionBoundary.d.ts.map +1 -0
  360. package/lib/typescript/module/payment-method/PaymentMethodList.d.ts.map +1 -1
  361. package/lib/typescript/module/place-details/PlaceAmenities.d.ts.map +1 -1
  362. package/lib/typescript/module/place-details/PlacePopularTimes.d.ts.map +1 -1
  363. package/lib/typescript/module/proof-of-delivery/ProofOfDelivery.d.ts.map +1 -1
  364. package/lib/typescript/module/select/Select.d.ts.map +1 -1
  365. package/lib/typescript/module/select/Select.web.d.ts.map +1 -1
  366. package/lib/typescript/module/select/use-required-description.d.ts +7 -0
  367. package/lib/typescript/module/select/use-required-description.d.ts.map +1 -0
  368. package/package.json +1 -1
  369. package/src/__tests__/support/adoption-matrix.ts +708 -0
  370. package/src/__tests__/support/card-surface.ts +17 -0
  371. package/src/__tests__/support/collision-fixture-barrel.ts +20 -0
  372. package/src/__tests__/support/commerce-harness.tsx +97 -0
  373. package/src/__tests__/support/composite.ts +68 -0
  374. package/src/__tests__/support/constructed-style-sheets.ts +68 -0
  375. package/src/__tests__/support/press-host.ts +30 -0
  376. package/src/__tests__/support/rendered-style.ts +99 -0
  377. package/src/__tests__/support/unread-hook-fixture.ts +33 -0
  378. package/src/__tests__/support/worklet-capture-fixture.tsx +28 -0
  379. package/src/button/Button.tsx +35 -10
  380. package/src/button/GlyphButton.tsx +3 -3
  381. package/src/card-form/shared.ts +3 -2
  382. package/src/chat-composer/AttachmentMenu.tsx +2 -214
  383. package/src/chat-composer/AttachmentMenu.web.tsx +5 -0
  384. package/src/chat-composer/ChatComposer.tsx +2 -459
  385. package/src/chat-composer/ChatComposer.web.tsx +6 -0
  386. package/src/chat-composer/ComposerAttachmentStrip.tsx +2 -202
  387. package/src/chat-composer/ComposerAttachmentStrip.web.tsx +4 -0
  388. package/src/chat-composer/ComposerBanner.tsx +2 -157
  389. package/src/chat-composer/ComposerBanner.web.tsx +4 -0
  390. package/src/chat-composer/EmojiPicker.tsx +2 -402
  391. package/src/chat-composer/EmojiPicker.web.tsx +5 -0
  392. package/src/chat-composer/MessageContextMenu.tsx +2 -88
  393. package/src/chat-composer/MessageContextMenu.web.tsx +12 -0
  394. package/src/chat-composer/ReactionPicker.tsx +2 -100
  395. package/src/chat-composer/ReactionPicker.web.tsx +5 -0
  396. package/src/chat-composer/SuggestionList.tsx +2 -209
  397. package/src/chat-composer/SuggestionList.web.tsx +4 -0
  398. package/src/chat-composer/VoiceRecorder.tsx +2 -287
  399. package/src/chat-composer/VoiceRecorder.web.tsx +6 -0
  400. package/src/chat-composer/create-attachment-menu.tsx +228 -0
  401. package/src/chat-composer/create-chat-composer.tsx +473 -0
  402. package/src/chat-composer/create-composer-attachment-strip.tsx +212 -0
  403. package/src/chat-composer/create-composer-banner.tsx +167 -0
  404. package/src/chat-composer/create-emoji-picker.tsx +414 -0
  405. package/src/chat-composer/create-message-context-menu.tsx +112 -0
  406. package/src/chat-composer/create-reaction-picker.tsx +112 -0
  407. package/src/chat-composer/create-suggestion-list.tsx +219 -0
  408. package/src/chat-composer/create-voice-recorder.tsx +301 -0
  409. package/src/chat-composer/index.web.ts +9 -9
  410. package/src/earnings/EarningsSummary.tsx +9 -2
  411. package/src/field/Field.tsx +2 -1
  412. package/src/field/types.ts +2 -0
  413. package/src/floating/types.ts +1 -0
  414. package/src/item/Item.tsx +16 -11
  415. package/src/job-board/JobCard.tsx +4 -1
  416. package/src/label/Label.tsx +2 -1
  417. package/src/label/types.ts +2 -0
  418. package/src/listing-details/AmenityList.tsx +4 -3
  419. package/src/overlay/InteractionBoundary.tsx +24 -0
  420. package/src/payment-method/PaymentMethodList.tsx +2 -1
  421. package/src/place-details/PlaceAmenities.tsx +9 -0
  422. package/src/place-details/PlacePopularTimes.tsx +7 -1
  423. package/src/proof-of-delivery/ProofOfDelivery.tsx +9 -1
  424. package/src/proof-of-delivery/shared.ts +1 -1
  425. package/src/select/Select.tsx +5 -1
  426. package/src/select/Select.web.tsx +5 -1
  427. package/src/select/use-required-description.tsx +20 -0
  428. package/src/theme/__tests__/__fixtures__/golden-resolved-tokens.json +9346 -0
  429. package/src/theme/__tests__/__fixtures__/tonal-glass-primary-failures.json +69 -0
  430. package/src/theme/__tests__/fixtures/color-engine-golden.json +1 -0
@@ -1,389 +1,12 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * The message input bar of a person-to-person chat: a radius-24 pill with a
5
- * left attach button, an autosizing field, an emoji button and a right control
6
- * that swaps between a mic (nothing to send) and an accent send disc (there is).
7
- *
8
- * Presentational. Every piece of state — the draft, the banners, the pending
9
- * attachments, which suggestion is highlighted — arrives as a prop, because the
10
- * app owns drafts per conversation and a composer that kept its own would lose
11
- * them on every navigation.
12
- */
13
- import React, { useCallback, useMemo, useRef, useState } from 'react';
14
- import { TextInput, View } from 'react-native';
15
- import Animated, { Easing, useAnimatedStyle, useReducedMotion, useSharedValue, withTiming } from 'react-native-reanimated';
16
- import { RiAddLine } from "../icons/remix/RiAddLine.js";
17
- import { RiCameraLine } from "../icons/remix/RiCameraLine.js";
18
- import { RiEmotionLine } from "../icons/remix/RiEmotionLine.js";
19
- import { RiForbidLine } from "../icons/remix/RiForbidLine.js";
20
- import { RiMic2Line } from "../icons/remix/RiMic2Line.js";
21
- import { RiSendPlaneLine } from "../icons/remix/RiSendPlaneLine.js";
22
- import { useControllableState } from "../hooks/use-controllable-state.js";
23
- import { useTextareaAutosize } from "../hooks/use-textarea-autosize.js";
24
- import { useTheme } from "../theme/use-theme.js";
25
- import { Text } from "../typography/index.js";
26
- import { TYPE_SCALE } from "../typography/scale.js";
27
- import { ComposerAttachmentStrip } from "./ComposerAttachmentStrip.js";
3
+ import { ComposerAttachmentStrip } from './ComposerAttachmentStrip';
28
4
  import { ComposerIconButton } from './ComposerIconButton';
29
- import { BAR_PADDING, BAR_RADIUS, chatComposerLabels, CONTROL_SIZE, DEFAULT_MAX_LINES, LINE_HEIGHT, SWAP_MS, resolveChatComposerPalette } from "./shared.js";
30
- import { SuggestionList } from "./SuggestionList.js";
31
- import { dataHook, IS_WEB, useChatComposerWebCss } from "./web-hooks.js";
32
- import { useMessages } from "../locale/messages.js";
33
- import { CHAT_COMPOSER_MESSAGES } from "./messages.js";
34
- import { useCommonMessages } from "../locale/common-messages.js";
35
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
36
- const EASE_OUT = Easing.bezier(0, 0, 0.2, 1);
37
-
38
- /**
39
- * One half of the mic ↔ send crossfade.
40
- *
41
- * Two things the fade must not break, neither of which the animation expresses:
42
- *
43
- * `pointerEvents` is a PROP, not a style entry — react-native-web drops it from
44
- * a style object silently, and a hidden layer that still takes the press is a
45
- * send button that fires when the field is empty.
46
- *
47
- * The hidden half leaves the ACCESSIBILITY TREE too. Both halves stay mounted so
48
- * they can cross-fade, so without this every composer announces "Send" and
49
- * "Record a voice message" side by side and only one of them does anything.
50
- * `aria-hidden` is what react-native-web reads and
51
- * `importantForAccessibility` is what React Native reads; a surface that sets
52
- * one of the two is hidden on one platform only.
53
- */
54
- function SwapLayer({
55
- shown,
56
- children
57
- }) {
58
- const reducedMotion = useReducedMotion();
59
- const progress = useSharedValue(shown ? 1 : 0);
60
- React.useEffect(() => {
61
- progress.value = reducedMotion ? shown ? 1 : 0 : withTiming(shown ? 1 : 0, {
62
- duration: SWAP_MS,
63
- easing: EASE_OUT
64
- });
65
- }, [shown, reducedMotion, progress]);
66
- const animated = useAnimatedStyle(() => ({
67
- opacity: progress.value
68
- }), [progress]);
69
- return /*#__PURE__*/_jsx(Animated.View, {
70
- pointerEvents: shown ? 'auto' : 'none',
71
- "aria-hidden": !shown,
72
- accessibilityElementsHidden: !shown,
73
- importantForAccessibility: shown ? 'auto' : 'no-hide-descendants',
74
- style: [{
75
- position: 'absolute',
76
- top: 0,
77
- left: 0
78
- }, animated],
79
- children: children
80
- });
81
- }
82
-
83
- /** A DOM keyboard event as react-native-web hands it to `onKeyPress`. */
84
-
85
- export function ChatComposer({
86
- value,
87
- defaultValue = '',
88
- onValueChange,
89
- placeholder: placeholderProp,
90
- onSend,
91
- sendOn = 'enter',
92
- maxLines = DEFAULT_MAX_LINES,
93
- minLines = 1,
94
- disabled = false,
95
- notice,
96
- noticeIcon,
97
- banner,
98
- attachments,
99
- onRemoveAttachment,
100
- leading,
101
- onAttachPress,
102
- emojiSlot,
103
- onEmojiPress,
104
- onCameraPress,
105
- onMicPress,
106
- onMicPressIn,
107
- onMicPressOut,
108
- canSend,
109
- recorder,
110
- suggestions,
111
- suggestionKind = 'mention',
112
- activeIndex = -1,
113
- onActiveIndexChange,
114
- onSelectSuggestion,
115
- onEscape,
116
- onEditLast,
117
- showKeyboardHint = false,
118
- inputRef,
119
- onFocus,
120
- onBlur,
121
- labels: labelOverrides,
122
- style,
123
- testID,
124
- accessibilityLabel
125
- }) {
126
- const theme = useTheme();
127
- const {
128
- messages
129
- } = useMessages(CHAT_COMPOSER_MESSAGES);
130
- const common = useCommonMessages();
131
- const palette = resolveChatComposerPalette(theme);
132
- useChatComposerWebCss();
133
- const labels = useMemo(() => ({
134
- ...chatComposerLabels(messages, common.send),
135
- ...labelOverrides
136
- }), [common.send, labelOverrides, messages]);
137
- const placeholder = placeholderProp ?? messages.message;
138
- const [text, setText] = useControllableState({
139
- value,
140
- defaultValue,
141
- onChange: onValueChange
142
- });
143
- const localRef = useRef(null);
144
- const setFieldRef = useCallback(node => {
145
- localRef.current = node;
146
- if (inputRef) inputRef.current = node;
147
- }, [inputRef]);
148
- const minHeight = Math.max(1, minLines) * LINE_HEIGHT;
149
- const maxHeight = Math.max(minLines, maxLines) * LINE_HEIGHT;
150
- const [contentHeight, setContentHeight] = useState(minHeight);
151
- const height = Math.min(maxHeight, Math.max(minHeight, contentHeight));
152
-
153
- /**
154
- * Web autosize measures the node, native reads `onContentSizeChange`.
155
- *
156
- * They are not interchangeable: react-native-web reports `scrollHeight`,
157
- * which never falls below the height already applied, so a field grown to six
158
- * lines and then emptied would stay six lines tall. `useTextareaAutosize`
159
- * collapses the node to measure it only when the draft may have got SHORTER —
160
- * collapsing on every keystroke re-laid-out the whole page three times a key.
161
- */
162
- useTextareaAutosize(localRef, text, {
163
- enabled: IS_WEB,
164
- height,
165
- minHeight,
166
- onMeasure: setContentHeight
167
- });
168
- const onContentSizeChange = useCallback(event => {
169
- if (IS_WEB) return;
170
- setContentHeight(event.nativeEvent.contentSize.height);
171
- }, []);
172
- const trimmed = text.trim();
173
- const hasAttachments = !!attachments && attachments.length > 0;
174
- const showSend = canSend ?? (trimmed.length > 0 || hasAttachments);
175
- const submit = useCallback(() => {
176
- if (disabled || !showSend) return;
177
- onSend?.(text);
178
- if (value === undefined) setText('');
179
- }, [disabled, showSend, onSend, text, value, setText]);
180
- const openSuggestions = !!suggestions && suggestions.length > 0;
181
- const onKeyPress = useCallback(event => {
182
- if (!IS_WEB) return;
183
- const native = event.nativeEvent;
184
- // An IME candidate window is using the same keys; committing a
185
- // composition must never send the half-written word behind it.
186
- if (native.isComposing) return;
187
- const mod = native.metaKey === true || native.ctrlKey === true;
188
- if (openSuggestions && (native.key === 'ArrowDown' || native.key === 'ArrowUp')) {
189
- event.preventDefault();
190
- const count = suggestions?.length ?? 0;
191
- const step = native.key === 'ArrowDown' ? 1 : -1;
192
- const from = activeIndex < 0 ? step > 0 ? -1 : 0 : activeIndex;
193
- onActiveIndexChange?.((from + step + count) % count);
194
- return;
195
- }
196
- if (native.key === 'Escape') {
197
- event.preventDefault();
198
- onEscape?.();
199
- return;
200
- }
201
- if (native.key === 'ArrowUp' && text.length === 0) {
202
- event.preventDefault();
203
- onEditLast?.();
204
- return;
205
- }
206
- if (native.key !== 'Enter') return;
207
- if (openSuggestions && activeIndex >= 0) {
208
- const picked = suggestions?.[activeIndex];
209
- if (picked && !picked.disabled) {
210
- event.preventDefault();
211
- onSelectSuggestion?.(picked, activeIndex);
212
- return;
213
- }
214
- }
215
- if (sendOn === 'enter' ? native.shiftKey !== true && !mod : mod) {
216
- event.preventDefault();
217
- submit();
218
- }
219
- }, [activeIndex, onActiveIndexChange, onEditLast, onEscape, onSelectSuggestion, openSuggestions, sendOn, submit, suggestions, text.length]);
220
- const bar = {
221
- flexDirection: 'row',
222
- alignItems: 'flex-end',
223
- gap: 2,
224
- minHeight: CONTROL_SIZE + BAR_PADDING * 2,
225
- borderRadius: BAR_RADIUS,
226
- borderWidth: 1,
227
- borderColor: palette.border,
228
- // A disabled bar changes its FILL rather than its opacity. Dimming the
229
- // container compounds with each control's own disabled opacity — 0.55 × 0.4
230
- // put the send disc at 0.22, which reads as a rendering fault rather than a
231
- // state.
232
- backgroundColor: disabled ? palette.inset : palette.surface,
233
- paddingLeft: BAR_PADDING,
234
- paddingRight: BAR_PADDING,
235
- paddingTop: BAR_PADDING,
236
- paddingBottom: BAR_PADDING,
237
- '--bloom-chat-composer-ring': palette.focusRing
238
- };
239
- const NoticeIcon = noticeIcon ?? RiForbidLine;
240
- return /*#__PURE__*/_jsxs(View, {
241
- accessibilityLabel: accessibilityLabel,
242
- style: [{
243
- width: '100%',
244
- flexDirection: 'column',
245
- gap: 6
246
- }, style],
247
- testID: testID,
248
- children: [openSuggestions ? /*#__PURE__*/_jsx(SuggestionList, {
249
- kind: suggestionKind,
250
- suggestions: suggestions ?? [],
251
- activeIndex: activeIndex,
252
- onActiveIndexChange: onActiveIndexChange,
253
- onSelectSuggestion: onSelectSuggestion,
254
- testID: testID ? `${testID}-suggestions` : undefined
255
- }) : null, banner, hasAttachments ? /*#__PURE__*/_jsx(ComposerAttachmentStrip, {
256
- attachments: attachments ?? [],
257
- onRemove: onRemoveAttachment,
258
- testID: testID ? `${testID}-attachments` : undefined
259
- }) : null, recorder ?? /*#__PURE__*/_jsx(View, {
260
- style: bar,
261
- testID: testID ? `${testID}-bar` : undefined,
262
- children: notice !== undefined ? /*#__PURE__*/_jsx(View, {
263
- style: {
264
- flexDirection: 'row',
265
- alignItems: 'center',
266
- justifyContent: 'center',
267
- gap: 8,
268
- flexGrow: 1,
269
- minHeight: CONTROL_SIZE,
270
- paddingLeft: 12,
271
- paddingRight: 12
272
- },
273
- testID: testID ? `${testID}-notice` : undefined,
274
- children: typeof notice === 'string' ? /*#__PURE__*/_jsxs(_Fragment, {
275
- children: [/*#__PURE__*/_jsx(NoticeIcon, {
276
- width: 16,
277
- height: 16,
278
- fill: palette.iconSecondary
279
- }), /*#__PURE__*/_jsx(Text, {
280
- variant: "body-2-regular",
281
- numberOfLines: 2,
282
- style: {
283
- color: palette.textSecondary,
284
- textAlign: 'center'
285
- },
286
- children: notice
287
- })]
288
- }) : notice
289
- }) : /*#__PURE__*/_jsxs(_Fragment, {
290
- children: [leading ?? (onAttachPress ? /*#__PURE__*/_jsx(ComposerIconButton, {
291
- icon: RiAddLine,
292
- accessibilityLabel: labels.attach,
293
- onPress: onAttachPress,
294
- disabled: disabled,
295
- iconSize: 22,
296
- testID: testID ? `${testID}-attach` : undefined
297
- }) : null), /*#__PURE__*/_jsx(View, {
298
- style: {
299
- flexGrow: 1,
300
- flexShrink: 1,
301
- justifyContent: 'center',
302
- minHeight: CONTROL_SIZE,
303
- paddingLeft: 6,
304
- paddingRight: 6
305
- },
306
- children: /*#__PURE__*/_jsx(TextInput, {
307
- ref: setFieldRef,
308
- ...dataHook('bloomChatComposerInput'),
309
- accessibilityLabel: labels.input,
310
- multiline: true,
311
- editable: !disabled,
312
- value: text,
313
- onChangeText: setText,
314
- onKeyPress: onKeyPress,
315
- onContentSizeChange: onContentSizeChange,
316
- onFocus: onFocus,
317
- onBlur: onBlur,
318
- placeholder: placeholder,
319
- placeholderTextColor: palette.textPlaceholder,
320
- selectionColor: palette.accent,
321
- cursorColor: palette.accent,
322
- scrollEnabled: height >= maxHeight,
323
- style: {
324
- width: '100%',
325
- height,
326
- maxHeight,
327
- padding: 0,
328
- margin: 0,
329
- ...TYPE_SCALE['body-regular'],
330
- fontFamily: IS_WEB ? 'var(--bloom-font-sans)' : 'Inter',
331
- color: disabled ? palette.textSecondary : palette.text,
332
- backgroundColor: 'transparent'
333
- },
334
- testID: testID ? `${testID}-input` : undefined
335
- })
336
- }), onCameraPress ? /*#__PURE__*/_jsx(ComposerIconButton, {
337
- icon: RiCameraLine,
338
- accessibilityLabel: labels.camera,
339
- onPress: onCameraPress,
340
- disabled: disabled,
341
- testID: testID ? `${testID}-camera` : undefined
342
- }) : null, emojiSlot ?? (onEmojiPress ? /*#__PURE__*/_jsx(ComposerIconButton, {
343
- icon: RiEmotionLine,
344
- accessibilityLabel: labels.emoji,
345
- onPress: onEmojiPress,
346
- disabled: disabled,
347
- testID: testID ? `${testID}-emoji` : undefined
348
- }) : null), /*#__PURE__*/_jsxs(View, {
349
- style: {
350
- width: CONTROL_SIZE,
351
- height: CONTROL_SIZE,
352
- marginLeft: 2
353
- },
354
- children: [/*#__PURE__*/_jsx(SwapLayer, {
355
- shown: showSend,
356
- children: /*#__PURE__*/_jsx(ComposerIconButton, {
357
- icon: RiSendPlaneLine,
358
- tone: "accent",
359
- accessibilityLabel: labels.send,
360
- onPress: submit,
361
- disabled: disabled,
362
- iconSize: 18,
363
- testID: testID ? `${testID}-send` : undefined
364
- })
365
- }), /*#__PURE__*/_jsx(SwapLayer, {
366
- shown: !showSend,
367
- children: /*#__PURE__*/_jsx(ComposerIconButton, {
368
- icon: RiMic2Line,
369
- accessibilityLabel: labels.mic,
370
- onPress: onMicPress,
371
- onPressIn: onMicPressIn,
372
- onPressOut: onMicPressOut,
373
- disabled: disabled,
374
- testID: testID ? `${testID}-mic` : undefined
375
- })
376
- })]
377
- })]
378
- })
379
- }), showKeyboardHint && IS_WEB && notice === undefined ? /*#__PURE__*/_jsx(Text, {
380
- variant: "caption-2-regular",
381
- style: {
382
- color: palette.textPlaceholder,
383
- paddingLeft: 14
384
- },
385
- children: sendOn === 'enter' ? labels.enterHint : labels.modEnterHint
386
- }) : null]
387
- });
388
- }
5
+ import { SuggestionList } from './SuggestionList';
6
+ import { createChatComposer } from "./create-chat-composer.js";
7
+ export const ChatComposer = createChatComposer({
8
+ ComposerAttachmentStrip,
9
+ ComposerIconButton,
10
+ SuggestionList
11
+ });
389
12
  //# sourceMappingURL=ChatComposer.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","useCallback","useMemo","useRef","useState","TextInput","View","Animated","Easing","useAnimatedStyle","useReducedMotion","useSharedValue","withTiming","RiAddLine","RiCameraLine","RiEmotionLine","RiForbidLine","RiMic2Line","RiSendPlaneLine","useControllableState","useTextareaAutosize","useTheme","Text","TYPE_SCALE","ComposerAttachmentStrip","ComposerIconButton","BAR_PADDING","BAR_RADIUS","chatComposerLabels","CONTROL_SIZE","DEFAULT_MAX_LINES","LINE_HEIGHT","SWAP_MS","resolveChatComposerPalette","SuggestionList","dataHook","IS_WEB","useChatComposerWebCss","useMessages","CHAT_COMPOSER_MESSAGES","useCommonMessages","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","EASE_OUT","bezier","SwapLayer","shown","children","reducedMotion","progress","useEffect","value","duration","easing","animated","opacity","pointerEvents","accessibilityElementsHidden","importantForAccessibility","style","position","top","left","ChatComposer","defaultValue","onValueChange","placeholder","placeholderProp","onSend","sendOn","maxLines","minLines","disabled","notice","noticeIcon","banner","attachments","onRemoveAttachment","leading","onAttachPress","emojiSlot","onEmojiPress","onCameraPress","onMicPress","onMicPressIn","onMicPressOut","canSend","recorder","suggestions","suggestionKind","activeIndex","onActiveIndexChange","onSelectSuggestion","onEscape","onEditLast","showKeyboardHint","inputRef","onFocus","onBlur","labels","labelOverrides","testID","accessibilityLabel","theme","messages","common","palette","send","message","text","setText","onChange","localRef","setFieldRef","node","current","minHeight","Math","max","maxHeight","contentHeight","setContentHeight","height","min","enabled","onMeasure","onContentSizeChange","event","nativeEvent","contentSize","trimmed","trim","hasAttachments","length","showSend","submit","undefined","openSuggestions","onKeyPress","native","isComposing","mod","metaKey","ctrlKey","key","preventDefault","count","step","from","picked","shiftKey","bar","flexDirection","alignItems","gap","borderRadius","borderWidth","borderColor","border","backgroundColor","inset","surface","paddingLeft","paddingRight","paddingTop","paddingBottom","focusRing","NoticeIcon","width","kind","onRemove","justifyContent","flexGrow","fill","iconSecondary","variant","numberOfLines","color","textSecondary","textAlign","icon","attach","onPress","iconSize","flexShrink","ref","input","multiline","editable","onChangeText","placeholderTextColor","textPlaceholder","selectionColor","accent","cursorColor","scrollEnabled","padding","margin","fontFamily","camera","emoji","marginLeft","tone","mic","onPressIn","onPressOut","enterHint","modEnterHint"],"sourceRoot":"../../../src","sources":["chat-composer/ChatComposer.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAOA,KAAK,IAAIC,WAAW,EAAEC,OAAO,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AACrE,SACEC,SAAS,EACTC,IAAI,QAIC,cAAc;AACrB,OAAOC,QAAQ,IACbC,MAAM,EACNC,gBAAgB,EAChBC,gBAAgB,EAChBC,cAAc,EACdC,UAAU,QACL,yBAAyB;AAEhC,SAASC,SAAS,QAAQ,6BAA0B;AACpD,SAASC,YAAY,QAAQ,gCAA6B;AAC1D,SAASC,aAAa,QAAQ,iCAA8B;AAC5D,SAASC,YAAY,QAAQ,gCAA6B;AAC1D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CAAC4G;IAAY,CACxD,CAAC,GACL,IAAI;EAAA,CACJ,CAAC;AAEX","ignoreList":[]}
1
+ {"version":3,"names":["ComposerAttachmentStrip","ComposerIconButton","SuggestionList","createChatComposer","ChatComposer"],"sourceRoot":"../../../src","sources":["chat-composer/ChatComposer.tsx"],"mappings":";;AAAA,SAASA,uBAAuB,QAAQ,2BAA2B;AACnE,SAASC,kBAAkB,QAAQ,sBAAsB;AACzD,SAASC,cAAc,QAAQ,kBAAkB;AACjD,SAASC,kBAAkB,QAAQ,2BAAwB;AAE3D,OAAO,MAAMC,YAAY,GAAGD,kBAAkB,CAAC;EAAEH,uBAAuB;EAAEC,kBAAkB;EAAEC;AAAe,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+
3
+ import { ComposerAttachmentStrip } from "./ComposerAttachmentStrip.web.js";
4
+ import { ComposerIconButton } from "./ComposerIconButton.web.js";
5
+ import { SuggestionList } from "./SuggestionList.web.js";
6
+ import { createChatComposer } from "./create-chat-composer.js";
7
+ export const ChatComposer = createChatComposer({
8
+ ComposerAttachmentStrip,
9
+ ComposerIconButton,
10
+ SuggestionList
11
+ });
12
+ //# sourceMappingURL=ChatComposer.web.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["ComposerAttachmentStrip","ComposerIconButton","SuggestionList","createChatComposer","ChatComposer"],"sourceRoot":"../../../src","sources":["chat-composer/ChatComposer.web.tsx"],"mappings":";;AAAA,SAASA,uBAAuB,QAAQ,kCAA+B;AACvE,SAASC,kBAAkB,QAAQ,6BAA0B;AAC7D,SAASC,cAAc,QAAQ,yBAAsB;AACrD,SAASC,kBAAkB,QAAQ,2BAAwB;AAE3D,OAAO,MAAMC,YAAY,GAAGD,kBAAkB,CAAC;EAAEH,uBAAuB;EAAEC,kBAAkB;EAAEC;AAAe,CAAC,CAAC","ignoreList":[]}
@@ -1,200 +1,8 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * The pending-attachment strip between the banner stack and the bar.
5
- *
6
- * The tile geometry and the rounded-rect progress path are `composer-panel`'s —
7
- * imported rather than retyped, because a second ring drawn from a second path
8
- * helper is how two composers end up with rings that close at different angles.
9
- */
10
- import React from 'react';
11
- import { Image, Pressable, ScrollView, View } from 'react-native';
12
- import Svg, { Path } from 'react-native-svg';
13
- import { ringPath } from "../composer-panel/shared.js";
14
- import { RiCloseLine } from "../icons/remix/RiCloseLine.js";
15
- import { RiFileTextLine } from "../icons/remix/RiFileTextLine.js";
16
- import { useImageResolver } from "../image-resolver/context.js";
17
- import { useTheme } from "../theme/use-theme.js";
18
- import { Text } from "../typography/index.js";
19
3
  import { ComposerIconButton } from './ComposerIconButton';
20
- import { TILE, TILE_RADIUS, resolveChatComposerPalette } from "./shared.js";
21
- import { dataHook } from "./web-hooks.js";
22
- import { useMessages } from "../locale/messages.js";
23
- import { CHAT_COMPOSER_MESSAGES } from "./messages.js";
24
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
25
- function isUrl(value) {
26
- return /^(https?:)?\/\//.test(value) || value.startsWith('data:') || value.startsWith('file:');
27
- }
28
- function Tile({
29
- attachment,
30
- size,
31
- onRemove,
32
- removeLabel,
33
- onOpen,
34
- openLabel,
35
- testID
36
- }) {
37
- const theme = useTheme();
38
- const palette = resolveChatComposerPalette(theme);
39
- const resolveImage = useImageResolver();
40
- const Glyph = attachment.icon ?? RiFileTextLine;
41
- const uploading = attachment.progress !== undefined;
42
- const progress = Math.min(100, Math.max(0, attachment.progress ?? 0));
43
- const radius = TILE_RADIUS - 1;
44
- const path = ringPath(size, size, 1, radius);
45
- // No `pathLength` on native, so the dash arithmetic needs the real length:
46
- // four straight runs plus one full circle of the corner radius.
47
- const length = 4 * (size - 2 - 2 * radius) + 2 * Math.PI * radius;
48
- const uri = attachment.source === undefined ? undefined : isUrl(attachment.source) ? attachment.source : resolveImage?.(attachment.source, 'thumb');
49
-
50
- // The box is a button only where the caller gave it something to do. A tile
51
- // that is `role="button"` with no handler announces an action that is not
52
- // there, and one that opens on press without a role is unreachable.
53
- const Box = onOpen === undefined ? View : Pressable;
54
- const boxProps = onOpen === undefined ? {} : {
55
- role: 'button',
56
- accessibilityLabel: (openLabel ?? (a => a.name))(attachment),
57
- onPress: () => onOpen(attachment.id)
58
- };
59
- return /*#__PURE__*/_jsxs(View, {
60
- style: {
61
- width: size,
62
- gap: 4
63
- },
64
- testID: testID,
65
- children: [/*#__PURE__*/_jsxs(View, {
66
- style: {
67
- position: 'relative',
68
- width: size,
69
- height: size
70
- },
71
- children: [/*#__PURE__*/_jsx(Box, {
72
- ...boxProps,
73
- style: {
74
- width: size,
75
- height: size,
76
- borderRadius: TILE_RADIUS,
77
- borderWidth: 1,
78
- borderColor: palette.border,
79
- backgroundColor: palette.inset,
80
- alignItems: 'center',
81
- justifyContent: 'center',
82
- overflow: 'hidden'
83
- },
84
- children: uri ? /*#__PURE__*/_jsx(Image, {
85
- source: {
86
- uri
87
- },
88
- accessibilityIgnoresInvertColors: true,
89
- style: {
90
- width: size,
91
- height: size,
92
- opacity: uploading ? 0.6 : 1
93
- }
94
- }) : /*#__PURE__*/_jsx(Glyph, {
95
- width: 22,
96
- height: 22,
97
- fill: palette.iconSecondary
98
- })
99
- }), uploading ? /*#__PURE__*/_jsx(View, {
100
- ...dataHook('bloomChatComposerRing'),
101
- pointerEvents: "none",
102
- style: {
103
- position: 'absolute',
104
- top: 0,
105
- left: 0,
106
- width: size,
107
- height: size
108
- },
109
- testID: testID ? `${testID}-ring` : undefined,
110
- children: /*#__PURE__*/_jsx(Svg, {
111
- width: size,
112
- height: size,
113
- children: /*#__PURE__*/_jsx(Path, {
114
- d: path,
115
- fill: "none",
116
- stroke: palette.accent,
117
- strokeWidth: 2,
118
- strokeLinecap: "round",
119
- strokeDasharray: `${length * progress / 100} ${length}`
120
- })
121
- })
122
- }) : null]
123
- }), onRemove && !uploading ? /*#__PURE__*/_jsx(View, {
124
- style: {
125
- position: 'absolute',
126
- top: -6,
127
- right: -6
128
- },
129
- children: /*#__PURE__*/_jsx(ComposerIconButton, {
130
- icon: RiCloseLine,
131
- accessibilityLabel: removeLabel(attachment),
132
- onPress: () => onRemove(attachment.id),
133
- size: 20,
134
- iconSize: 12,
135
- style: {
136
- backgroundColor: palette.surface,
137
- borderWidth: 1,
138
- borderColor: palette.border
139
- },
140
- testID: testID ? `${testID}-remove` : undefined
141
- })
142
- }) : null, /*#__PURE__*/_jsx(Text, {
143
- variant: "caption-2-regular",
144
- numberOfLines: 1,
145
- style: {
146
- color: uploading ? palette.accent : palette.textSecondary
147
- },
148
- children: uploading ? `${Math.round(progress)}%` : attachment.caption ?? attachment.name
149
- })]
150
- });
151
- }
152
- export function ComposerAttachmentStrip({
153
- attachments,
154
- onRemove,
155
- onOpen,
156
- size = TILE,
157
- removeLabel: removeLabelProp,
158
- openLabel,
159
- style,
160
- testID,
161
- accessibilityLabel: accessibilityLabelProp
162
- }) {
163
- const {
164
- messages
165
- } = useMessages(CHAT_COMPOSER_MESSAGES);
166
- const removeLabel = removeLabelProp ?? (attachment => messages.removeAttachment(attachment.name));
167
- const accessibilityLabel = accessibilityLabelProp ?? messages.attachments;
168
- if (attachments.length === 0) return null;
169
- return /*#__PURE__*/_jsx(ScrollView, {
170
- ...dataHook('bloomChatComposerScroll'),
171
- horizontal: true,
172
- showsHorizontalScrollIndicator: false,
173
- accessibilityLabel: accessibilityLabel,
174
- contentContainerStyle: {
175
- flexDirection: 'row',
176
- gap: 10,
177
- // The remove disc hangs 6px past the tile on both axes and a horizontal
178
- // ScrollView clips its cross axis (`overflow-y: hidden` on web), so the
179
- // top pad is the disc's overhang plus its border — not a rhythm value.
180
- paddingLeft: 8,
181
- paddingRight: 8,
182
- paddingTop: 10,
183
- paddingBottom: 2
184
- },
185
- style: [{
186
- flexGrow: 0
187
- }, style],
188
- testID: testID,
189
- children: attachments.map(attachment => /*#__PURE__*/_jsx(Tile, {
190
- attachment: attachment,
191
- size: size,
192
- onRemove: onRemove,
193
- removeLabel: removeLabel,
194
- onOpen: onOpen,
195
- openLabel: openLabel,
196
- testID: testID ? `${testID}-${attachment.id}` : undefined
197
- }, attachment.id))
198
- });
199
- }
4
+ import { createComposerAttachmentStrip } from "./create-composer-attachment-strip.js";
5
+ export const ComposerAttachmentStrip = createComposerAttachmentStrip({
6
+ ComposerIconButton
7
+ });
200
8
  //# sourceMappingURL=ComposerAttachmentStrip.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","Image","Pressable","ScrollView","View","Svg","Path","ringPath","RiCloseLine","RiFileTextLine","useImageResolver","useTheme","Text","ComposerIconButton","TILE","TILE_RADIUS","resolveChatComposerPalette","dataHook","useMessages","CHAT_COMPOSER_MESSAGES","jsx","_jsx","jsxs","_jsxs","isUrl","value","test","startsWith","Tile","attachment","size","onRemove","removeLabel","onOpen","openLabel","testID","theme","palette","resolveImage","Glyph","icon","uploading","progress","undefined","Math","min","max","radius","path","length","PI","uri","source","Box","boxProps","role","accessibilityLabel","a","name","onPress","id","style","width","gap","children","position","height","borderRadius","borderWidth","borderColor","border","backgroundColor","inset","alignItems","justifyContent","overflow","accessibilityIgnoresInvertColors","opacity","fill","iconSecondary","pointerEvents","top","left","d","stroke","accent","strokeWidth","strokeLinecap","strokeDasharray","right","iconSize","surface","variant","numberOfLines","color","textSecondary","round","caption","ComposerAttachmentStrip","attachments","removeLabelProp","accessibilityLabelProp","messages","removeAttachment","horizontal","showsHorizontalScrollIndicator","contentContainerStyle","flexDirection","paddingLeft","paddingRight","paddingTop","paddingBottom","flexGrow","map"],"sourceRoot":"../../../src","sources":["chat-composer/ComposerAttachmentStrip.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,KAAK,EAAEC,SAAS,EAAEC,UAAU,EAAEC,IAAI,QAAQ,cAAc;AACjE,OAAOC,GAAG,IAAIC,IAAI,QAAQ,kBAAkB;AAE5C,SAASC,QAAQ,QAAQ,6BAA0B;AACnD,SAASC,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AAU,CAAC+B,EAQjB,CACF;EAAC,CACQ,CAAC;AAEjB","ignoreList":[]}
1
+ {"version":3,"names":["ComposerIconButton","createComposerAttachmentStrip","ComposerAttachmentStrip"],"sourceRoot":"../../../src","sources":["chat-composer/ComposerAttachmentStrip.tsx"],"mappings":";;AAAA,SAASA,kBAAkB,QAAQ,sBAAsB;AACzD,SAASC,6BAA6B,QAAQ,uCAAoC;AAElF,OAAO,MAAMC,uBAAuB,GAAGD,6BAA6B,CAAC;EAAED;AAAmB,CAAC,CAAC","ignoreList":[]}