@celljs/ta-web 4.9.0 → 4.10.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.
Files changed (376) hide show
  1. package/README.en.md +4 -3
  2. package/README.md +4 -3
  3. package/esm/browser/assistant/assistant-chat-list.js +8 -2
  4. package/esm/browser/assistant/assistant-extension.d.ts +8 -1
  5. package/esm/browser/assistant/assistant-extension.js +33 -5
  6. package/esm/browser/assistant/assistant-protocol.d.ts +3 -1
  7. package/esm/browser/assistant/assistant-task-source.d.ts +2 -0
  8. package/esm/browser/assistant/assistant-task-source.js +2 -0
  9. package/esm/browser/assistant/assistant-task-util.d.ts +8 -0
  10. package/esm/browser/assistant/assistant-task-util.js +13 -3
  11. package/esm/browser/assistant/assistant-tasks.js +3 -2
  12. package/esm/browser/assistant/assistant-view.js +81 -56
  13. package/esm/browser/assistant/assistant.d.ts +30 -1
  14. package/esm/browser/assistant/assistant.js +89 -6
  15. package/esm/browser/assistant/task-views.d.ts +40 -6
  16. package/esm/browser/assistant/task-views.js +73 -21
  17. package/esm/browser/avatar/dino-avatar.d.ts +3 -4
  18. package/esm/browser/avatar/dino-avatar.js +4 -178
  19. package/esm/browser/avatar/dino-face.d.ts +19 -0
  20. package/esm/browser/avatar/dino-face.js +142 -0
  21. package/esm/browser/avatar/dino-geometry.d.ts +11 -0
  22. package/esm/browser/avatar/dino-geometry.js +38 -0
  23. package/esm/browser/avatar/dino-kinds.d.ts +15 -0
  24. package/esm/browser/avatar/dino-kinds.js +544 -0
  25. package/esm/browser/avatar/dino-motion.js +1 -1
  26. package/esm/browser/avatar/dino-shape.d.ts +80 -0
  27. package/esm/browser/avatar/dino-shape.js +113 -0
  28. package/esm/browser/avatar/dino-species.d.ts +1 -61
  29. package/esm/browser/avatar/dino-species.js +2 -653
  30. package/esm/browser/chat/chat-packages.d.ts +39 -0
  31. package/esm/browser/chat/chat-packages.js +70 -0
  32. package/esm/browser/chat/chat-protocol.d.ts +23 -1
  33. package/esm/browser/chat/chat-stores.d.ts +59 -0
  34. package/esm/browser/chat/chat-stores.js +121 -0
  35. package/esm/browser/chat/chat-util.d.ts +17 -0
  36. package/esm/browser/chat/chat-util.js +61 -0
  37. package/esm/browser/chat/chat-view.js +33 -12
  38. package/esm/browser/chat/chat.d.ts +31 -39
  39. package/esm/browser/chat/chat.js +226 -175
  40. package/esm/browser/components/access-view.js +1 -1
  41. package/esm/browser/components/account-menu.js +1 -1
  42. package/esm/browser/components/app-nav.d.ts +6 -3
  43. package/esm/browser/components/app-nav.js +19 -10
  44. package/esm/browser/components/app-shell-hooks.d.ts +47 -0
  45. package/esm/browser/components/app-shell-hooks.js +169 -0
  46. package/esm/browser/components/app-view.js +81 -172
  47. package/esm/browser/components/auth-view.js +1 -1
  48. package/esm/browser/components/chat-list.d.ts +20 -2
  49. package/esm/browser/components/chat-list.js +138 -22
  50. package/esm/browser/components/composer-box.d.ts +5 -5
  51. package/esm/browser/components/composer-box.js +111 -4
  52. package/esm/browser/components/composer.d.ts +7 -0
  53. package/esm/browser/components/composer.js +22 -14
  54. package/esm/browser/components/connection-bar.js +50 -17
  55. package/esm/browser/components/context-menu.d.ts +30 -4
  56. package/esm/browser/components/context-menu.js +199 -37
  57. package/esm/browser/components/conversation-scroll.d.ts +129 -6
  58. package/esm/browser/components/conversation-scroll.js +429 -109
  59. package/esm/browser/components/dino.js +1 -1
  60. package/esm/browser/components/earlier-messages.d.ts +2 -1
  61. package/esm/browser/components/earlier-messages.js +2 -17
  62. package/esm/browser/components/editor-area.d.ts +3 -1
  63. package/esm/browser/components/editor-area.js +6 -5
  64. package/esm/browser/components/empty-pictures.d.ts +0 -2
  65. package/esm/browser/components/empty-pictures.js +0 -16
  66. package/esm/browser/components/folder-picker.d.ts +5 -2
  67. package/esm/browser/components/folder-picker.js +30 -9
  68. package/esm/browser/components/held-talk.d.ts +28 -0
  69. package/esm/browser/components/held-talk.js +76 -0
  70. package/esm/browser/components/host-view.d.ts +1 -1
  71. package/esm/browser/components/host-view.js +1 -1
  72. package/esm/browser/components/icon.d.ts +2 -2
  73. package/esm/browser/components/icon.js +5 -6
  74. package/esm/browser/components/image-viewer.d.ts +124 -0
  75. package/esm/browser/components/image-viewer.js +397 -0
  76. package/esm/browser/components/lightbox.d.ts +11 -0
  77. package/esm/browser/components/lightbox.js +24 -0
  78. package/esm/browser/components/markdown.d.ts +6 -2
  79. package/esm/browser/components/markdown.js +24 -10
  80. package/esm/browser/components/media.js +1 -10
  81. package/esm/browser/components/message-footer.d.ts +16 -2
  82. package/esm/browser/components/message-footer.js +29 -12
  83. package/esm/browser/components/message-list.d.ts +24 -3
  84. package/esm/browser/components/message-list.js +149 -20
  85. package/esm/browser/components/message-menu.d.ts +3 -1
  86. package/esm/browser/components/message-menu.js +18 -3
  87. package/esm/browser/components/nav-places.d.ts +16 -1
  88. package/esm/browser/components/nav-places.js +12 -3
  89. package/esm/browser/components/phone-shell.d.ts +4 -1
  90. package/esm/browser/components/phone-shell.js +3 -1
  91. package/esm/browser/components/run-status.js +3 -3
  92. package/esm/browser/components/select-bar.d.ts +9 -0
  93. package/esm/browser/components/select-bar.js +24 -0
  94. package/esm/browser/components/session-settings.d.ts +6 -0
  95. package/esm/browser/components/session-settings.js +14 -1
  96. package/esm/browser/components/session-view.js +8 -4
  97. package/esm/browser/components/settings-choices.d.ts +35 -0
  98. package/esm/browser/components/settings-choices.js +117 -0
  99. package/esm/browser/components/settings-parts.d.ts +21 -0
  100. package/esm/browser/components/settings-parts.js +323 -0
  101. package/esm/browser/components/settings-view.d.ts +0 -6
  102. package/esm/browser/components/settings-view.js +4 -406
  103. package/esm/browser/components/swipe-row.d.ts +2 -2
  104. package/esm/browser/components/swipe-row.js +7 -3
  105. package/esm/browser/components/tool-view.js +14 -12
  106. package/esm/browser/components/voice-button.d.ts +1 -1
  107. package/esm/browser/components/voice-button.js +1 -1
  108. package/esm/browser/components/voice-talk.d.ts +43 -0
  109. package/esm/browser/components/voice-talk.js +222 -0
  110. package/esm/browser/components/workbench-view.js +1 -1
  111. package/esm/browser/device/device.d.ts +3 -0
  112. package/esm/browser/device/device.js +11 -1
  113. package/esm/browser/device/hold.d.ts +42 -0
  114. package/esm/browser/device/hold.js +136 -0
  115. package/esm/browser/device/launch-screen.d.ts +1 -1
  116. package/esm/browser/device/launch-screen.js +1 -1
  117. package/esm/browser/device/long-press.d.ts +2 -0
  118. package/esm/browser/device/long-press.js +16 -1
  119. package/esm/browser/device/pull-down.d.ts +4 -2
  120. package/esm/browser/device/pull-down.js +64 -76
  121. package/esm/browser/device/row-swipe.d.ts +35 -10
  122. package/esm/browser/device/row-swipe.js +149 -71
  123. package/esm/browser/device/shake-undo.d.ts +16 -0
  124. package/esm/browser/device/shake-undo.js +59 -0
  125. package/esm/browser/device/sheet-swipe.d.ts +118 -18
  126. package/esm/browser/device/sheet-swipe.js +406 -107
  127. package/esm/browser/extension/icons.js +2 -1
  128. package/esm/browser/extension/web-extension-api.d.ts +135 -2
  129. package/esm/browser/extension/web-extension-code.d.ts +6 -0
  130. package/esm/browser/extension/web-extension-code.js +24 -0
  131. package/esm/browser/extension/web-extension-protocol.d.ts +23 -1
  132. package/esm/browser/extension/web-extension-protocol.js +8 -0
  133. package/esm/browser/extension/web-extensions.d.ts +14 -1
  134. package/esm/browser/extension/web-extensions.js +128 -24
  135. package/esm/browser/extension/web-tasks.d.ts +9 -1
  136. package/esm/browser/extension/web-tasks.js +24 -0
  137. package/esm/browser/files/files-protocol.d.ts +25 -0
  138. package/esm/browser/files/files-protocol.js +2 -0
  139. package/esm/browser/files/files.d.ts +35 -0
  140. package/esm/browser/files/files.js +119 -0
  141. package/esm/browser/hooks.d.ts +3 -1
  142. package/esm/browser/hooks.js +8 -0
  143. package/esm/browser/i18n/locales.d.ts +29 -2
  144. package/esm/browser/i18n/messages.d.ts +28 -1
  145. package/esm/browser/i18n/messages.js +58 -4
  146. package/esm/browser/index.d.ts +6 -0
  147. package/esm/browser/index.js +6 -0
  148. package/esm/browser/notices/notices-protocol.d.ts +9 -1
  149. package/esm/browser/notices/notices.d.ts +2 -0
  150. package/esm/browser/notices/notices.js +20 -10
  151. package/esm/browser/offline/device-values.d.ts +55 -0
  152. package/esm/browser/offline/device-values.js +142 -0
  153. package/esm/browser/offline/kept-chats-protocol.d.ts +17 -0
  154. package/esm/browser/offline/kept-chats-protocol.js +2 -0
  155. package/esm/browser/offline/kept-chats.d.ts +47 -0
  156. package/esm/browser/offline/kept-chats.js +146 -0
  157. package/esm/browser/offline/offline-reads.d.ts +44 -0
  158. package/esm/browser/offline/offline-reads.js +107 -0
  159. package/esm/browser/settings/settings-protocol.d.ts +2 -0
  160. package/esm/browser/settings/settings-protocol.js +2 -0
  161. package/esm/browser/style/conversation.d.ts +1 -1
  162. package/esm/browser/style/conversation.js +57 -17
  163. package/esm/browser/style/device.js +43 -4
  164. package/esm/browser/style/layout.d.ts +1 -1
  165. package/esm/browser/style/layout.js +67 -15
  166. package/esm/browser/style/pages.d.ts +1 -1
  167. package/esm/browser/style/pages.js +2 -1
  168. package/esm/browser/style/shell.d.ts +1 -1
  169. package/esm/browser/style/shell.js +47 -3
  170. package/esm/browser/style/tasks.d.ts +1 -1
  171. package/esm/browser/style/tasks.js +2 -0
  172. package/esm/browser/util/frame.d.ts +5 -4
  173. package/esm/browser/util/frame.js +5 -4
  174. package/esm/browser/util/markdown.d.ts +18 -1
  175. package/esm/browser/util/markdown.js +119 -5
  176. package/esm/browser/util/process.d.ts +21 -0
  177. package/esm/browser/util/process.js +45 -1
  178. package/esm/browser/util/voice.d.ts +5 -2
  179. package/esm/browser/util/voice.js +6 -3
  180. package/esm/browser/util/zoom.d.ts +46 -0
  181. package/esm/browser/util/zoom.js +96 -0
  182. package/esm/browser/workbench-calls.d.ts +59 -0
  183. package/esm/browser/workbench-calls.js +141 -0
  184. package/esm/browser/workbench-protocol.d.ts +5 -1
  185. package/esm/browser/workbench-util.d.ts +68 -0
  186. package/esm/browser/workbench-util.js +145 -0
  187. package/esm/browser/workbench.d.ts +15 -42
  188. package/esm/browser/workbench.js +53 -167
  189. package/lib/browser/assistant/assistant-chat-list.js +8 -2
  190. package/lib/browser/assistant/assistant-extension.d.ts +8 -1
  191. package/lib/browser/assistant/assistant-extension.js +33 -5
  192. package/lib/browser/assistant/assistant-protocol.d.ts +3 -1
  193. package/lib/browser/assistant/assistant-task-source.d.ts +2 -0
  194. package/lib/browser/assistant/assistant-task-source.js +2 -0
  195. package/lib/browser/assistant/assistant-task-util.d.ts +8 -0
  196. package/lib/browser/assistant/assistant-task-util.js +13 -3
  197. package/lib/browser/assistant/assistant-tasks.js +2 -1
  198. package/lib/browser/assistant/assistant-view.js +78 -53
  199. package/lib/browser/assistant/assistant.d.ts +30 -1
  200. package/lib/browser/assistant/assistant.js +89 -6
  201. package/lib/browser/assistant/task-views.d.ts +40 -6
  202. package/lib/browser/assistant/task-views.js +74 -21
  203. package/lib/browser/avatar/dino-avatar.d.ts +3 -4
  204. package/lib/browser/avatar/dino-avatar.js +27 -202
  205. package/lib/browser/avatar/dino-face.d.ts +20 -0
  206. package/lib/browser/avatar/dino-face.js +148 -0
  207. package/lib/browser/avatar/dino-geometry.d.ts +12 -0
  208. package/lib/browser/avatar/dino-geometry.js +47 -0
  209. package/lib/browser/avatar/dino-kinds.d.ts +16 -0
  210. package/lib/browser/avatar/dino-kinds.js +547 -0
  211. package/lib/browser/avatar/dino-motion.js +2 -2
  212. package/lib/browser/avatar/dino-shape.d.ts +81 -0
  213. package/lib/browser/avatar/dino-shape.js +126 -0
  214. package/lib/browser/avatar/dino-species.d.ts +1 -61
  215. package/lib/browser/avatar/dino-species.js +34 -687
  216. package/lib/browser/chat/chat-packages.d.ts +40 -0
  217. package/lib/browser/chat/chat-packages.js +74 -0
  218. package/lib/browser/chat/chat-protocol.d.ts +23 -1
  219. package/lib/browser/chat/chat-stores.d.ts +60 -0
  220. package/lib/browser/chat/chat-stores.js +125 -0
  221. package/lib/browser/chat/chat-util.d.ts +18 -0
  222. package/lib/browser/chat/chat-util.js +64 -0
  223. package/lib/browser/chat/chat-view.js +33 -12
  224. package/lib/browser/chat/chat.d.ts +31 -39
  225. package/lib/browser/chat/chat.js +227 -176
  226. package/lib/browser/components/access-view.js +2 -2
  227. package/lib/browser/components/account-menu.js +2 -2
  228. package/lib/browser/components/app-nav.d.ts +6 -3
  229. package/lib/browser/components/app-nav.js +17 -8
  230. package/lib/browser/components/app-shell-hooks.d.ts +48 -0
  231. package/lib/browser/components/app-shell-hooks.js +211 -0
  232. package/lib/browser/components/app-view.js +89 -180
  233. package/lib/browser/components/auth-view.js +3 -3
  234. package/lib/browser/components/chat-list.d.ts +20 -2
  235. package/lib/browser/components/chat-list.js +137 -21
  236. package/lib/browser/components/composer-box.d.ts +5 -5
  237. package/lib/browser/components/composer-box.js +111 -4
  238. package/lib/browser/components/composer.d.ts +7 -0
  239. package/lib/browser/components/composer.js +22 -14
  240. package/lib/browser/components/connection-bar.js +48 -15
  241. package/lib/browser/components/context-menu.d.ts +30 -4
  242. package/lib/browser/components/context-menu.js +198 -36
  243. package/lib/browser/components/conversation-scroll.d.ts +129 -6
  244. package/lib/browser/components/conversation-scroll.js +431 -110
  245. package/lib/browser/components/dino.js +3 -3
  246. package/lib/browser/components/earlier-messages.d.ts +2 -1
  247. package/lib/browser/components/earlier-messages.js +2 -17
  248. package/lib/browser/components/editor-area.d.ts +3 -1
  249. package/lib/browser/components/editor-area.js +5 -4
  250. package/lib/browser/components/empty-pictures.d.ts +0 -2
  251. package/lib/browser/components/empty-pictures.js +0 -17
  252. package/lib/browser/components/folder-picker.d.ts +5 -2
  253. package/lib/browser/components/folder-picker.js +30 -9
  254. package/lib/browser/components/held-talk.d.ts +29 -0
  255. package/lib/browser/components/held-talk.js +79 -0
  256. package/lib/browser/components/host-view.d.ts +1 -1
  257. package/lib/browser/components/host-view.js +5 -5
  258. package/lib/browser/components/icon.d.ts +2 -2
  259. package/lib/browser/components/icon.js +7 -6
  260. package/lib/browser/components/image-viewer.d.ts +125 -0
  261. package/lib/browser/components/image-viewer.js +435 -0
  262. package/lib/browser/components/lightbox.d.ts +12 -0
  263. package/lib/browser/components/lightbox.js +60 -0
  264. package/lib/browser/components/markdown.d.ts +6 -2
  265. package/lib/browser/components/markdown.js +24 -10
  266. package/lib/browser/components/media.js +2 -11
  267. package/lib/browser/components/message-footer.d.ts +16 -2
  268. package/lib/browser/components/message-footer.js +31 -12
  269. package/lib/browser/components/message-list.d.ts +24 -3
  270. package/lib/browser/components/message-list.js +146 -16
  271. package/lib/browser/components/message-menu.d.ts +3 -1
  272. package/lib/browser/components/message-menu.js +17 -2
  273. package/lib/browser/components/nav-places.d.ts +16 -1
  274. package/lib/browser/components/nav-places.js +13 -3
  275. package/lib/browser/components/phone-shell.d.ts +4 -1
  276. package/lib/browser/components/phone-shell.js +3 -1
  277. package/lib/browser/components/run-status.js +3 -3
  278. package/lib/browser/components/select-bar.d.ts +10 -0
  279. package/lib/browser/components/select-bar.js +61 -0
  280. package/lib/browser/components/session-settings.d.ts +6 -0
  281. package/lib/browser/components/session-settings.js +14 -1
  282. package/lib/browser/components/session-view.js +7 -3
  283. package/lib/browser/components/settings-choices.d.ts +36 -0
  284. package/lib/browser/components/settings-choices.js +156 -0
  285. package/lib/browser/components/settings-parts.d.ts +22 -0
  286. package/lib/browser/components/settings-parts.js +359 -0
  287. package/lib/browser/components/settings-view.d.ts +0 -6
  288. package/lib/browser/components/settings-view.js +2 -405
  289. package/lib/browser/components/swipe-row.d.ts +2 -2
  290. package/lib/browser/components/swipe-row.js +7 -3
  291. package/lib/browser/components/tool-view.js +14 -12
  292. package/lib/browser/components/voice-button.d.ts +1 -1
  293. package/lib/browser/components/voice-button.js +1 -1
  294. package/lib/browser/components/voice-talk.d.ts +44 -0
  295. package/lib/browser/components/voice-talk.js +260 -0
  296. package/lib/browser/components/workbench-view.js +3 -3
  297. package/lib/browser/device/device.d.ts +3 -0
  298. package/lib/browser/device/device.js +11 -1
  299. package/lib/browser/device/hold.d.ts +43 -0
  300. package/lib/browser/device/hold.js +173 -0
  301. package/lib/browser/device/launch-screen.d.ts +1 -1
  302. package/lib/browser/device/launch-screen.js +1 -1
  303. package/lib/browser/device/long-press.d.ts +2 -0
  304. package/lib/browser/device/long-press.js +16 -1
  305. package/lib/browser/device/pull-down.d.ts +4 -2
  306. package/lib/browser/device/pull-down.js +63 -75
  307. package/lib/browser/device/row-swipe.d.ts +35 -10
  308. package/lib/browser/device/row-swipe.js +148 -70
  309. package/lib/browser/device/shake-undo.d.ts +17 -0
  310. package/lib/browser/device/shake-undo.js +63 -0
  311. package/lib/browser/device/sheet-swipe.d.ts +118 -18
  312. package/lib/browser/device/sheet-swipe.js +410 -108
  313. package/lib/browser/extension/icons.js +1 -0
  314. package/lib/browser/extension/web-extension-api.d.ts +135 -2
  315. package/lib/browser/extension/web-extension-code.d.ts +6 -0
  316. package/lib/browser/extension/web-extension-code.js +24 -0
  317. package/lib/browser/extension/web-extension-protocol.d.ts +23 -1
  318. package/lib/browser/extension/web-extension-protocol.js +9 -1
  319. package/lib/browser/extension/web-extensions.d.ts +14 -1
  320. package/lib/browser/extension/web-extensions.js +125 -21
  321. package/lib/browser/extension/web-tasks.d.ts +9 -1
  322. package/lib/browser/extension/web-tasks.js +24 -0
  323. package/lib/browser/files/files-protocol.d.ts +26 -0
  324. package/lib/browser/files/files-protocol.js +5 -0
  325. package/lib/browser/files/files.d.ts +36 -0
  326. package/lib/browser/files/files.js +122 -0
  327. package/lib/browser/hooks.d.ts +3 -1
  328. package/lib/browser/hooks.js +9 -0
  329. package/lib/browser/i18n/locales.d.ts +29 -2
  330. package/lib/browser/i18n/messages.d.ts +28 -1
  331. package/lib/browser/i18n/messages.js +58 -4
  332. package/lib/browser/index.d.ts +6 -0
  333. package/lib/browser/index.js +6 -0
  334. package/lib/browser/notices/notices-protocol.d.ts +9 -1
  335. package/lib/browser/notices/notices.d.ts +2 -0
  336. package/lib/browser/notices/notices.js +20 -10
  337. package/lib/browser/offline/device-values.d.ts +56 -0
  338. package/lib/browser/offline/device-values.js +148 -0
  339. package/lib/browser/offline/kept-chats-protocol.d.ts +18 -0
  340. package/lib/browser/offline/kept-chats-protocol.js +5 -0
  341. package/lib/browser/offline/kept-chats.d.ts +48 -0
  342. package/lib/browser/offline/kept-chats.js +149 -0
  343. package/lib/browser/offline/offline-reads.d.ts +45 -0
  344. package/lib/browser/offline/offline-reads.js +111 -0
  345. package/lib/browser/settings/settings-protocol.d.ts +2 -0
  346. package/lib/browser/settings/settings-protocol.js +2 -0
  347. package/lib/browser/style/conversation.d.ts +1 -1
  348. package/lib/browser/style/conversation.js +57 -17
  349. package/lib/browser/style/device.js +43 -4
  350. package/lib/browser/style/layout.d.ts +1 -1
  351. package/lib/browser/style/layout.js +67 -15
  352. package/lib/browser/style/pages.d.ts +1 -1
  353. package/lib/browser/style/pages.js +2 -1
  354. package/lib/browser/style/shell.d.ts +1 -1
  355. package/lib/browser/style/shell.js +47 -3
  356. package/lib/browser/style/tasks.d.ts +1 -1
  357. package/lib/browser/style/tasks.js +2 -0
  358. package/lib/browser/util/frame.d.ts +5 -4
  359. package/lib/browser/util/frame.js +5 -4
  360. package/lib/browser/util/markdown.d.ts +18 -1
  361. package/lib/browser/util/markdown.js +119 -5
  362. package/lib/browser/util/process.d.ts +21 -0
  363. package/lib/browser/util/process.js +46 -2
  364. package/lib/browser/util/voice.d.ts +5 -2
  365. package/lib/browser/util/voice.js +6 -3
  366. package/lib/browser/util/zoom.d.ts +47 -0
  367. package/lib/browser/util/zoom.js +99 -0
  368. package/lib/browser/workbench-calls.d.ts +60 -0
  369. package/lib/browser/workbench-calls.js +145 -0
  370. package/lib/browser/workbench-protocol.d.ts +5 -1
  371. package/lib/browser/workbench-util.d.ts +69 -0
  372. package/lib/browser/workbench-util.js +151 -0
  373. package/lib/browser/workbench.d.ts +15 -42
  374. package/lib/browser/workbench.js +74 -189
  375. package/package.json +10 -10
  376. package/public/launch.svg +46 -42
@@ -0,0 +1,10 @@
1
+ import * as React from 'react';
2
+ import type { WebSelectBarProps, WebSelectCheckProps } from '../extension/web-extension-api';
3
+ /** The round mark at the start of a row while its list is selecting, as WeChat's: filled once chosen. */
4
+ export declare function SelectCheck({ checked, disabled }: WebSelectCheckProps): React.JSX.Element;
5
+ /**
6
+ * Under a list that is selecting: Select all (or none, once all are), how many are chosen, what can be done
7
+ * with them and Done. Every list of the page and of web extensions (`ui.SelectBar`) takes it.
8
+ */
9
+ export declare function SelectBar({ count, total, onSelectAll, onDone, actions }: WebSelectBarProps): React.JSX.Element;
10
+ //# sourceMappingURL=select-bar.d.ts.map
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.SelectCheck = SelectCheck;
37
+ exports.SelectBar = SelectBar;
38
+ const lucide_react_1 = require("lucide-react");
39
+ const React = __importStar(require("react"));
40
+ const use_t_1 = require("../i18n/use-t");
41
+ const icon_1 = require("./icon");
42
+ /** The round mark at the start of a row while its list is selecting, as WeChat's: filled once chosen. */
43
+ function SelectCheck({ checked, disabled }) {
44
+ return (React.createElement("span", { className: "ta-select-check", "data-checked": checked ? '' : undefined, "data-disabled": disabled ? '' : undefined, "aria-hidden": "true" }, checked && React.createElement(icon_1.Icon, { icon: lucide_react_1.Check, size: 12 })));
45
+ }
46
+ /**
47
+ * Under a list that is selecting: Select all (or none, once all are), how many are chosen, what can be done
48
+ * with them and Done. Every list of the page and of web extensions (`ui.SelectBar`) takes it.
49
+ */
50
+ function SelectBar({ count, total, onSelectAll, onDone, actions }) {
51
+ const t = (0, use_t_1.useT)();
52
+ const all = total > 0 && count >= total;
53
+ return (React.createElement("div", { className: "ta-select-bar", role: "toolbar", "aria-label": t('ta.select.count', { count }) },
54
+ React.createElement("button", { type: "button", className: "ta-select-bar-all", disabled: total === 0, onClick: () => onSelectAll(!all) },
55
+ React.createElement(SelectCheck, { checked: all }),
56
+ t('ta.select.all')),
57
+ React.createElement("span", { className: "ta-select-bar-count", "aria-live": "polite" }, t('ta.select.count', { count })),
58
+ actions.map(action => (React.createElement("button", { key: action.key, type: "button", className: `ta-button ta-select-bar-action${action.danger ? ' ta-danger' : ''}`, disabled: count === 0, onClick: action.run }, action.label))),
59
+ React.createElement("button", { type: "button", className: "ta-button ta-select-bar-done", onClick: onDone }, t('ta.select.done'))));
60
+ }
61
+ //# sourceMappingURL=select-bar.js.map
@@ -22,6 +22,12 @@ export interface SessionSettingsHandlers {
22
22
  }
23
23
  export declare namespace SessionSettingsUtil {
24
24
  const EMPTY: SessionSettings;
25
+ /**
26
+ * Whether the settings are loaded again: at once, a run going or not, so that a conversation opened
27
+ * while it works (a new one, the first message just sent) lists its models from the start, and after
28
+ * each run, which an extension or another client may have changed them in.
29
+ */
30
+ function reloads(wasWorking: boolean | undefined, working: boolean): boolean;
25
31
  function modelRef(model?: {
26
32
  provider: string;
27
33
  id: string;
@@ -42,6 +42,15 @@ const model_picker_1 = require("./model-picker");
42
42
  var SessionSettingsUtil;
43
43
  (function (SessionSettingsUtil) {
44
44
  SessionSettingsUtil.EMPTY = { models: [], levels: [], commands: [] };
45
+ /**
46
+ * Whether the settings are loaded again: at once, a run going or not, so that a conversation opened
47
+ * while it works (a new one, the first message just sent) lists its models from the start, and after
48
+ * each run, which an extension or another client may have changed them in.
49
+ */
50
+ function reloads(wasWorking, working) {
51
+ return wasWorking === undefined || (wasWorking && !working);
52
+ }
53
+ SessionSettingsUtil.reloads = reloads;
45
54
  function modelRef(model) {
46
55
  return model ? `${model.provider}/${model.id}` : '';
47
56
  }
@@ -110,10 +119,14 @@ function useSessionSettings(server, settingsServer, store, working, t, onError)
110
119
  .then(([state, { models }, { levels }, { commands }]) => setSettings({ models, model: SessionSettingsUtil.modelRef(state.model), thinkingLevel: state.thinkingLevel, levels, commands }))
111
120
  .catch(() => undefined);
112
121
  }, [server, sessionId]);
122
+ // Whether the session worked when it was last looked at; none for a session not looked at yet.
123
+ const last = React.useRef(undefined);
113
124
  React.useEffect(() => {
114
- if (!working) {
125
+ var _a;
126
+ if (SessionSettingsUtil.reloads(((_a = last.current) === null || _a === void 0 ? void 0 : _a.load) === load ? last.current.working : undefined, working)) {
115
127
  load();
116
128
  }
129
+ last.current = { load, working };
117
130
  }, [load, working]);
118
131
  React.useEffect(() => store.onEvent(event => {
119
132
  if (event.type === 'session_reloaded') {
@@ -34,9 +34,11 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.SessionView = SessionView;
37
+ const react_1 = require("@celljs/react");
37
38
  const lucide_react_1 = require("lucide-react");
38
39
  const React = __importStar(require("react"));
39
40
  const device_1 = require("../device/device");
41
+ const files_protocol_1 = require("../files/files-protocol");
40
42
  const hooks_1 = require("../hooks");
41
43
  const use_t_1 = require("../i18n/use-t");
42
44
  const message_1 = require("../util/message");
@@ -130,7 +132,8 @@ function SessionView({ store, server, workspace, info, onClosed, onActivity, lea
130
132
  (_a = composer.current) === null || _a === void 0 ? void 0 : _a.setText(draftText);
131
133
  }
132
134
  }, [draftText]);
133
- const fileUrl = React.useCallback((path) => workspace.fileUrl(path, cwd), [workspace, cwd]);
135
+ const files = (0, react_1.useInject)(files_protocol_1.TaFiles);
136
+ const fileUrl = React.useCallback(async (path) => files.loadable(await workspace.fileUrl(path, cwd)), [workspace, cwd, files]);
134
137
  const openLink = (0, hooks_1.useOpenLink)(cwd);
135
138
  // biome-ignore lint/correctness/useExhaustiveDependencies: runs when a run starts or settles
136
139
  React.useEffect(() => onActivity(), [state.working, onActivity]);
@@ -146,6 +149,7 @@ function SessionView({ store, server, workspace, info, onClosed, onActivity, lea
146
149
  const title = (info === null || info === void 0 ? void 0 : info.sessionName) || (info ? message_1.MessageUtil.basename(info.cwd) : t('ta.session.title'));
147
150
  const conversation = React.useMemo(() => ({ sessionId: store.sessionId, sessionFile: info === null || info === void 0 ? void 0 : info.sessionFile, cwd: info === null || info === void 0 ? void 0 : info.cwd, kind: 'chat', group: info === null || info === void 0 ? void 0 : info.group, title }), [store.sessionId, info === null || info === void 0 ? void 0 : info.sessionFile, info === null || info === void 0 ? void 0 : info.cwd, info === null || info === void 0 ? void 0 : info.group, title]);
148
151
  const addons = (0, composer_addons_1.useComposerAddons)(conversation);
152
+ const outbox = React.useMemo(() => ({ resend: id => void store.resend(id), discard: id => store.discard(id) }), [store]);
149
153
  return (React.createElement("section", { className: `ta-session ${compact ? 'ta-session-compact' : ''}` },
150
154
  !compact && (React.createElement("header", { className: "ta-session-header" },
151
155
  leading,
@@ -155,14 +159,14 @@ function SessionView({ store, server, workspace, info, onClosed, onActivity, lea
155
159
  trailing)),
156
160
  React.createElement("div", { className: "ta-scroll ta-conversation", ref: scroller },
157
161
  React.createElement("div", { className: "ta-thread" },
158
- state.start > 0 && (React.createElement("div", { className: "ta-earlier", role: "status", "aria-label": t('ta.session.earlier') },
162
+ state.start > 0 && (React.createElement("div", { className: "ta-earlier", role: "status", "aria-label": t('ta.session.earlier'), ...conversation_scroll_1.SCROLL_SKIP },
159
163
  React.createElement("span", { className: "ta-spinner" }))),
160
164
  state.messages.length === 0 && (empty !== null && empty !== void 0 ? empty : React.createElement("div", { className: "ta-empty" }, t('ta.session.empty', { cwd: (_a = info === null || info === void 0 ? void 0 : info.cwd) !== null && _a !== void 0 ? _a : '.' }))),
161
165
  React.createElement(message_list_1.ConversationSession.Provider, { value: info },
162
166
  React.createElement(message_footer_1.MessageActions.Provider, { value: messageActions },
163
167
  React.createElement(media_1.FileUrls.Provider, { value: fileUrl },
164
168
  React.createElement(link_1.OpenLink.Provider, { value: openLink },
165
- React.createElement(message_list_1.MessageList, { state: state }))))))),
169
+ React.createElement(message_list_1.MessageList, { state: state, outbox: outbox }))))))),
166
170
  React.createElement("div", { className: "ta-bottom" },
167
171
  away && (React.createElement("button", { type: "button", className: "ta-to-bottom", "aria-label": t('ta.session.toBottom'), title: t('ta.session.toBottom'), onClick: toBottom },
168
172
  React.createElement(lucide_react_1.ArrowDown, { size: 18 }))),
@@ -0,0 +1,36 @@
1
+ import { type TaPackageInfo } from '@celljs/ta-protocol';
2
+ import { type LucideIcon } from 'lucide-react';
3
+ import type { MessageId } from '../i18n/messages';
4
+ import type { useT } from '../i18n/use-t';
5
+ import type { FontSize, LanguageSetting, ThemeSetting } from '../settings/settings-protocol';
6
+ import type { Navigation } from './nav-places';
7
+ import { type Choice, type RowEntry } from './settings-controls';
8
+ export declare const THEMES: Choice<ThemeSetting>[];
9
+ export declare const FONT_SIZES: Choice<FontSize>[];
10
+ export declare const LANGUAGES: Choice<LanguageSetting>[];
11
+ export declare const GROUP_ICONS: Record<string, LucideIcon>;
12
+ /** The keys of the page and of the message box; `Mod` is ⌘ on a Mac, Ctrl elsewhere. */
13
+ export declare const SHORTCUTS: {
14
+ keys: string;
15
+ label: MessageId;
16
+ }[];
17
+ /**
18
+ * The packages pi loads, as the server lists them, those turned off too: the built-in ones turn off and
19
+ * stay; the others turn off and on, and go.
20
+ */
21
+ export declare function usePackages(): {
22
+ packages: TaPackageInfo[];
23
+ toggle: (pkg: TaPackageInfo, on: boolean) => Promise<void>;
24
+ remove: (pkg: TaPackageInfo) => Promise<void>;
25
+ read: () => Promise<void>;
26
+ };
27
+ export declare const SLOTS: Choice<string>[];
28
+ /** The rows of the navigation: how many pages it shows, and where each page is. */
29
+ export declare function navigationRows(navigation: Navigation, t: ReturnType<typeof useT>): RowEntry[];
30
+ /** How a package shows in a row: what it calls itself for people, else its name and the description of its package.json. */
31
+ export declare function packageLabel(pkg: TaPackageInfo, language: string): {
32
+ title: string;
33
+ summary: string | undefined;
34
+ icon: import("..").WebIcon;
35
+ };
36
+ //# sourceMappingURL=settings-choices.d.ts.map
@@ -0,0 +1,156 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.SLOTS = exports.SHORTCUTS = exports.GROUP_ICONS = exports.LANGUAGES = exports.FONT_SIZES = exports.THEMES = void 0;
37
+ exports.usePackages = usePackages;
38
+ exports.navigationRows = navigationRows;
39
+ exports.packageLabel = packageLabel;
40
+ const ta_protocol_1 = require("@celljs/ta-protocol");
41
+ const lucide_react_1 = require("lucide-react");
42
+ const React = __importStar(require("react"));
43
+ const icons_1 = require("../extension/icons");
44
+ const web_extension_protocol_1 = require("../extension/web-extension-protocol");
45
+ const hooks_1 = require("../hooks");
46
+ const navigation_1 = require("../settings/navigation");
47
+ const icon_1 = require("./icon");
48
+ const settings_controls_1 = require("./settings-controls");
49
+ exports.THEMES = [
50
+ { value: 'system', icon: lucide_react_1.Monitor, label: 'ta.settings.theme.system' },
51
+ { value: 'light', icon: lucide_react_1.Sun, label: 'ta.settings.theme.light' },
52
+ { value: 'dark', icon: lucide_react_1.Moon, label: 'ta.settings.theme.dark' },
53
+ ];
54
+ exports.FONT_SIZES = [
55
+ { value: 'small', label: 'ta.settings.fontSize.small' },
56
+ { value: 'standard', label: 'ta.settings.fontSize.standard' },
57
+ { value: 'large', label: 'ta.settings.fontSize.large' },
58
+ { value: 'xlarge', label: 'ta.settings.fontSize.xlarge' },
59
+ ];
60
+ exports.LANGUAGES = [
61
+ { value: 'system', icon: lucide_react_1.Globe, label: 'ta.settings.language.system' },
62
+ { value: 'zh-CN', label: '简体中文' },
63
+ { value: 'en-US', label: 'English' },
64
+ ];
65
+ exports.GROUP_ICONS = { model: lucide_react_1.Sparkles, conversation: lucide_react_1.MessagesSquare, context: lucide_react_1.Layers, tools: lucide_react_1.Wrench };
66
+ /** The keys of the page and of the message box; `Mod` is ⌘ on a Mac, Ctrl elsewhere. */
67
+ exports.SHORTCUTS = [
68
+ { keys: 'Mod+,', label: 'ta.shortcut.settings' },
69
+ { keys: 'Mod+B', label: 'ta.shortcut.sidebar' },
70
+ { keys: 'Enter', label: 'ta.shortcut.send' },
71
+ { keys: 'Shift+Enter', label: 'ta.shortcut.newline' },
72
+ { keys: 'Alt+Enter', label: 'ta.shortcut.followUp' },
73
+ { keys: 'Esc', label: 'ta.shortcut.stop' },
74
+ { keys: '/', label: 'ta.shortcut.commands' },
75
+ { keys: '@', label: 'ta.shortcut.files' },
76
+ { keys: 'Mod+S', label: 'ta.shortcut.save' },
77
+ ];
78
+ /**
79
+ * The packages pi loads, as the server lists them, those turned off too: the built-in ones turn off and
80
+ * stay; the others turn off and on, and go.
81
+ */
82
+ function usePackages() {
83
+ const [workbench, bench] = (0, hooks_1.useWorkbench)();
84
+ const [, host] = (0, hooks_1.useWebExtensions)();
85
+ const [packages, setPackages] = React.useState([]);
86
+ const read = React.useCallback(() => bench.packages.listPackages().then(setPackages), [bench]);
87
+ React.useEffect(() => {
88
+ if (workbench.status === 'online') {
89
+ read().catch(() => undefined);
90
+ }
91
+ }, [workbench.status, read]);
92
+ const changed = async () => {
93
+ await host.reloadPackages();
94
+ await read();
95
+ };
96
+ /** By the name of a built-in package, by the id of another. */
97
+ const toggle = async (pkg, on) => {
98
+ setPackages(current => current.map(other => (other.id === pkg.id ? { ...other, enabled: on } : other)));
99
+ await bench.packages.setPackageEnabled(pkg.origin === 'builtin' ? pkg.name : pkg.id, on);
100
+ await changed();
101
+ };
102
+ const remove = async (pkg) => {
103
+ await bench.packages.removePackage(pkg.id);
104
+ await changed();
105
+ };
106
+ return { packages, toggle, remove, read };
107
+ }
108
+ exports.SLOTS = Array.from({ length: navigation_1.NavigationUtil.MAX_SLOTS - navigation_1.NavigationUtil.MIN_SLOTS + 1 }, (_, index) => {
109
+ const value = String(navigation_1.NavigationUtil.MIN_SLOTS + index);
110
+ return { value, label: value };
111
+ });
112
+ /** The rows of the navigation: how many pages it shows, and where each page is. */
113
+ function navigationRows(navigation, t) {
114
+ const { setting } = navigation;
115
+ const where = (id, byDefault) => {
116
+ if (setting.pinned.includes(id) && navigation.nav.some(page => page.id === id)) {
117
+ return t('ta.settings.navigation.pinned');
118
+ }
119
+ if (navigation.nav.some(page => page.id === id)) {
120
+ return t('ta.settings.navigation.inNav');
121
+ }
122
+ return t(setting.discover.includes(id) || byDefault ? 'ta.settings.navigation.folded' : 'ta.settings.navigation.overflow');
123
+ };
124
+ return [
125
+ (0, settings_controls_1.row)('navigation-slots', [t('ta.settings.navigation.slots'), t('ta.settings.navigation.slotsHint'), t('ta.discover')], React.createElement(settings_controls_1.Row, { label: t('ta.settings.navigation.slots'), description: t('ta.settings.navigation.slotsHint'), stacked: true },
126
+ React.createElement(settings_controls_1.Segmented, { label: t('ta.settings.navigation.slots'), value: String(setting.slots), choices: exports.SLOTS, onChange: slots => navigation.update({ ...setting, slots: Number(slots) }) }))),
127
+ ...navigation.pages.map(page => {
128
+ const title = web_extension_protocol_1.WebLabelUtil.text(page.title);
129
+ const shown = navigation.nav.includes(page);
130
+ return (0, settings_controls_1.row)(`navigation:${page.id}`, [title, t('ta.settings.navigation')], React.createElement(settings_controls_1.Row, { label: title, description: where(page.id, page.discover) },
131
+ React.createElement(settings_controls_1.Switch, { label: `${t('ta.settings.navigation.show')} · ${title}`, checked: shown, onChange: on => (on ? navigation.pin(page.id) : navigation.fold(page.id)) })));
132
+ }),
133
+ ...(navigation.pages.length === 0
134
+ ? [(0, settings_controls_1.row)('navigation:none', [t('ta.settings.navigation.none')], React.createElement(settings_controls_1.EmptyRow, { title: t('ta.settings.navigation.none') }))]
135
+ : []),
136
+ ...(navigation_1.NavigationUtil.moved(setting)
137
+ ? [
138
+ (0, settings_controls_1.row)('navigation-reset', [t('ta.settings.navigation.reset')], React.createElement(settings_controls_1.Row, { label: t('ta.settings.navigation.reset'), description: t('ta.settings.navigation.resetHint') },
139
+ React.createElement("button", { type: "button", className: "ta-button", onClick: () => navigation.update(navigation_1.NavigationUtil.reset(setting)) },
140
+ React.createElement(icon_1.Icon, { icon: lucide_react_1.RefreshCw, size: 14 }),
141
+ " ",
142
+ t('ta.settings.navigation.resetButton')))),
143
+ ]
144
+ : []),
145
+ ];
146
+ }
147
+ /** How a package shows in a row: what it calls itself for people, else its name and the description of its package.json. */
148
+ function packageLabel(pkg, language) {
149
+ var _a, _b;
150
+ return {
151
+ title: (_a = ta_protocol_1.TaPackageTextUtil.pick(pkg.title, language)) !== null && _a !== void 0 ? _a : pkg.name,
152
+ summary: (_b = ta_protocol_1.TaPackageTextUtil.pick(pkg.summary, language)) !== null && _b !== void 0 ? _b : pkg.description,
153
+ icon: (pkg.icon && icons_1.WEB_ICONS[pkg.icon]) || lucide_react_1.Puzzle,
154
+ };
155
+ }
156
+ //# sourceMappingURL=settings-choices.js.map
@@ -0,0 +1,22 @@
1
+ import type { TaSettingsScope } from '@celljs/ta-protocol';
2
+ import * as React from 'react';
3
+ import { type Glyph } from './icon';
4
+ import { type RowEntry } from './settings-controls';
5
+ export interface SectionEntry {
6
+ id: string;
7
+ title: string;
8
+ icon: Glyph;
9
+ rows: RowEntry[];
10
+ }
11
+ export interface Part {
12
+ id: string;
13
+ title: string;
14
+ sections: SectionEntry[];
15
+ /** Drawn above its sections, whatever the search, and on a phone above each: the scope of the settings of ta. */
16
+ lead?: React.ReactNode;
17
+ }
18
+ /** What a row of the settings opens over them. */
19
+ export type SettingsDialog = 'accounts' | 'directory' | 'relay';
20
+ /** The sections of the page and of ta, by part, with their rows. */
21
+ export declare function useParts(scope: TaSettingsScope, onScope: (scope: TaSettingsScope) => void, onClose: () => void, onDialog: (dialog: SettingsDialog) => void): Part[];
22
+ //# sourceMappingURL=settings-parts.d.ts.map