@tldraw/commenting 0.0.0-bootstrap → 5.3.0-canary.04044ed9e96d

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 (338) hide show
  1. package/README.md +0 -2
  2. package/commenting.css +1152 -350
  3. package/dist-cjs/canvas/anchor-lifecycle.js +148 -0
  4. package/dist-cjs/canvas/anchor-lifecycle.js.map +7 -0
  5. package/dist-cjs/{ui/avatar.js → canvas/canvas-events.js} +14 -22
  6. package/dist-cjs/canvas/canvas-events.js.map +7 -0
  7. package/dist-cjs/canvas/cluster-badge.js +121 -0
  8. package/dist-cjs/canvas/cluster-badge.js.map +7 -0
  9. package/dist-cjs/canvas/cluster-fade.js +85 -0
  10. package/dist-cjs/canvas/cluster-fade.js.map +7 -0
  11. package/dist-cjs/canvas/cluster-input.js +53 -3
  12. package/dist-cjs/canvas/cluster-input.js.map +2 -2
  13. package/dist-cjs/canvas/cluster-model.js +252 -0
  14. package/dist-cjs/canvas/cluster-model.js.map +7 -0
  15. package/dist-cjs/canvas/comment-body.js +1 -1
  16. package/dist-cjs/canvas/comment-body.js.map +2 -2
  17. package/dist-cjs/canvas/comment-drafts.js +54 -0
  18. package/dist-cjs/canvas/comment-drafts.js.map +7 -0
  19. package/dist-cjs/canvas/comment-mutations.js +152 -0
  20. package/dist-cjs/canvas/comment-mutations.js.map +7 -0
  21. package/dist-cjs/canvas/comment-reactions.js +160 -0
  22. package/dist-cjs/canvas/comment-reactions.js.map +7 -0
  23. package/dist-cjs/canvas/comment-render.js +9 -6
  24. package/dist-cjs/canvas/comment-render.js.map +2 -2
  25. package/dist-cjs/canvas/comment-store.js +19 -9
  26. package/dist-cjs/canvas/comment-store.js.map +2 -2
  27. package/dist-cjs/canvas/comment-tool.js +63 -14
  28. package/dist-cjs/canvas/comment-tool.js.map +2 -2
  29. package/dist-cjs/canvas/comments-filter-menu.js +17 -37
  30. package/dist-cjs/canvas/comments-filter-menu.js.map +2 -2
  31. package/dist-cjs/canvas/comments-overflow-menu.js +25 -22
  32. package/dist-cjs/canvas/comments-overflow-menu.js.map +2 -2
  33. package/dist-cjs/canvas/comments-overlay.js +151 -989
  34. package/dist-cjs/canvas/comments-overlay.js.map +3 -3
  35. package/dist-cjs/canvas/comments-sidebar.js +49 -41
  36. package/dist-cjs/canvas/comments-sidebar.js.map +2 -2
  37. package/dist-cjs/canvas/comments-visibility-toggle.js +45 -0
  38. package/dist-cjs/canvas/comments-visibility-toggle.js.map +7 -0
  39. package/dist-cjs/canvas/context.js +17 -0
  40. package/dist-cjs/canvas/context.js.map +7 -0
  41. package/dist-cjs/canvas/hooks.js +28 -3
  42. package/dist-cjs/canvas/hooks.js.map +2 -2
  43. package/dist-cjs/canvas/license.js.map +1 -1
  44. package/dist-cjs/canvas/mobile-placement.js +91 -0
  45. package/dist-cjs/canvas/mobile-placement.js.map +7 -0
  46. package/dist-cjs/canvas/options.js +57 -2
  47. package/dist-cjs/canvas/options.js.map +2 -2
  48. package/dist-cjs/canvas/pending-composer.js +134 -0
  49. package/dist-cjs/canvas/pending-composer.js.map +7 -0
  50. package/dist-cjs/canvas/pin-stacking.js +81 -0
  51. package/dist-cjs/canvas/pin-stacking.js.map +7 -0
  52. package/dist-cjs/canvas/region-box.js +113 -0
  53. package/dist-cjs/canvas/region-box.js.map +7 -0
  54. package/dist-cjs/canvas/sidebar-filters.js +2 -2
  55. package/dist-cjs/canvas/sidebar-filters.js.map +2 -2
  56. package/dist-cjs/canvas/state.js +28 -14
  57. package/dist-cjs/canvas/state.js.map +2 -2
  58. package/dist-cjs/canvas/thread-pin.js +304 -0
  59. package/dist-cjs/canvas/thread-pin.js.map +7 -0
  60. package/dist-cjs/canvas/thread-preview.js +177 -0
  61. package/dist-cjs/canvas/thread-preview.js.map +7 -0
  62. package/dist-cjs/canvas/thread-stack.js +199 -0
  63. package/dist-cjs/canvas/thread-stack.js.map +7 -0
  64. package/dist-cjs/canvas/thread-state.js +82 -21
  65. package/dist-cjs/canvas/thread-state.js.map +2 -2
  66. package/dist-cjs/canvas/thread-view.js +450 -0
  67. package/dist-cjs/canvas/thread-view.js.map +7 -0
  68. package/dist-cjs/clustering/computeClusterTable.js +6 -6
  69. package/dist-cjs/clustering/computeClusterTable.js.map +2 -2
  70. package/dist-cjs/clustering/replay.js +89 -22
  71. package/dist-cjs/clustering/replay.js.map +3 -3
  72. package/dist-cjs/clustering/runtime.js +126 -7
  73. package/dist-cjs/clustering/runtime.js.map +2 -2
  74. package/dist-cjs/clustering/types.js.map +1 -1
  75. package/dist-cjs/index.d.ts +904 -353
  76. package/dist-cjs/index.js +52 -28
  77. package/dist-cjs/index.js.map +2 -2
  78. package/dist-cjs/ui/byline.js +10 -6
  79. package/dist-cjs/ui/byline.js.map +2 -2
  80. package/dist-cjs/ui/comment-card.js +15 -8
  81. package/dist-cjs/ui/comment-card.js.map +2 -2
  82. package/dist-cjs/ui/comment-composer.js +124 -39
  83. package/dist-cjs/ui/comment-composer.js.map +2 -2
  84. package/dist-cjs/ui/comment-pin.js +11 -2
  85. package/dist-cjs/ui/comment-pin.js.map +2 -2
  86. package/dist-cjs/ui/comment-thread.js +9 -7
  87. package/dist-cjs/ui/comment-thread.js.map +2 -2
  88. package/dist-cjs/ui/comments-list.js +39 -40
  89. package/dist-cjs/ui/comments-list.js.map +2 -2
  90. package/dist-cjs/ui/count-badge.js +3 -2
  91. package/dist-cjs/ui/count-badge.js.map +2 -2
  92. package/dist-cjs/ui/emoji-picker.js +54 -0
  93. package/dist-cjs/ui/emoji-picker.js.map +7 -0
  94. package/dist-cjs/ui/empty-state.js +3 -3
  95. package/dist-cjs/ui/empty-state.js.map +2 -2
  96. package/dist-cjs/ui/format-time.js +16 -1
  97. package/dist-cjs/ui/format-time.js.map +2 -2
  98. package/dist-cjs/ui/icons.js +115 -0
  99. package/dist-cjs/ui/icons.js.map +7 -0
  100. package/dist-cjs/ui/reaction-picker.js +71 -0
  101. package/dist-cjs/ui/reaction-picker.js.map +7 -0
  102. package/dist-cjs/ui/reaction.js +58 -6
  103. package/dist-cjs/ui/reaction.js.map +2 -2
  104. package/dist-cjs/ui/reactions.js +20 -7
  105. package/dist-cjs/ui/reactions.js.map +2 -2
  106. package/dist-cjs/ui/{mention.js → reply-count.js} +9 -11
  107. package/dist-cjs/ui/reply-count.js.map +7 -0
  108. package/dist-cjs/ui/send-button.js +13 -1
  109. package/dist-cjs/ui/send-button.js.map +2 -2
  110. package/dist-cjs/ui/{comment-text.js → visual-viewport.js} +12 -9
  111. package/dist-cjs/ui/visual-viewport.js.map +7 -0
  112. package/dist-esm/canvas/anchor-lifecycle.mjs +128 -0
  113. package/dist-esm/canvas/anchor-lifecycle.mjs.map +7 -0
  114. package/dist-esm/canvas/canvas-events.mjs +15 -0
  115. package/dist-esm/canvas/canvas-events.mjs.map +7 -0
  116. package/dist-esm/canvas/cluster-badge.mjs +106 -0
  117. package/dist-esm/canvas/cluster-badge.mjs.map +7 -0
  118. package/dist-esm/canvas/cluster-fade.mjs +65 -0
  119. package/dist-esm/canvas/cluster-fade.mjs.map +7 -0
  120. package/dist-esm/canvas/cluster-input.mjs +54 -4
  121. package/dist-esm/canvas/cluster-input.mjs.map +2 -2
  122. package/dist-esm/canvas/cluster-model.mjs +236 -0
  123. package/dist-esm/canvas/cluster-model.mjs.map +7 -0
  124. package/dist-esm/canvas/comment-body.mjs +1 -1
  125. package/dist-esm/canvas/comment-body.mjs.map +2 -2
  126. package/dist-esm/canvas/comment-drafts.mjs +34 -0
  127. package/dist-esm/canvas/comment-drafts.mjs.map +7 -0
  128. package/dist-esm/canvas/comment-mutations.mjs +132 -0
  129. package/dist-esm/canvas/comment-mutations.mjs.map +7 -0
  130. package/dist-esm/canvas/comment-reactions.mjs +145 -0
  131. package/dist-esm/canvas/comment-reactions.mjs.map +7 -0
  132. package/dist-esm/canvas/comment-render.mjs +10 -7
  133. package/dist-esm/canvas/comment-render.mjs.map +2 -2
  134. package/dist-esm/canvas/comment-store.mjs +19 -9
  135. package/dist-esm/canvas/comment-store.mjs.map +2 -2
  136. package/dist-esm/canvas/comment-tool.mjs +66 -17
  137. package/dist-esm/canvas/comment-tool.mjs.map +2 -2
  138. package/dist-esm/canvas/comments-filter-menu.mjs +17 -36
  139. package/dist-esm/canvas/comments-filter-menu.mjs.map +2 -2
  140. package/dist-esm/canvas/comments-overflow-menu.mjs +27 -22
  141. package/dist-esm/canvas/comments-overflow-menu.mjs.map +2 -2
  142. package/dist-esm/canvas/comments-overlay.mjs +157 -1010
  143. package/dist-esm/canvas/comments-overlay.mjs.map +3 -3
  144. package/dist-esm/canvas/comments-sidebar.mjs +53 -46
  145. package/dist-esm/canvas/comments-sidebar.mjs.map +2 -2
  146. package/dist-esm/canvas/comments-visibility-toggle.mjs +25 -0
  147. package/dist-esm/canvas/comments-visibility-toggle.mjs.map +7 -0
  148. package/dist-esm/canvas/context.mjs +1 -0
  149. package/dist-esm/canvas/context.mjs.map +7 -0
  150. package/dist-esm/canvas/hooks.mjs +35 -5
  151. package/dist-esm/canvas/hooks.mjs.map +2 -2
  152. package/dist-esm/canvas/license.mjs.map +1 -1
  153. package/dist-esm/canvas/mobile-placement.mjs +71 -0
  154. package/dist-esm/canvas/mobile-placement.mjs.map +7 -0
  155. package/dist-esm/canvas/options.mjs +59 -3
  156. package/dist-esm/canvas/options.mjs.map +2 -2
  157. package/dist-esm/canvas/pending-composer.mjs +126 -0
  158. package/dist-esm/canvas/pending-composer.mjs.map +7 -0
  159. package/dist-esm/canvas/pin-stacking.mjs +61 -0
  160. package/dist-esm/canvas/pin-stacking.mjs.map +7 -0
  161. package/dist-esm/canvas/region-box.mjs +93 -0
  162. package/dist-esm/canvas/region-box.mjs.map +7 -0
  163. package/dist-esm/canvas/sidebar-filters.mjs +2 -2
  164. package/dist-esm/canvas/sidebar-filters.mjs.map +2 -2
  165. package/dist-esm/canvas/state.mjs +29 -19
  166. package/dist-esm/canvas/state.mjs.map +2 -2
  167. package/dist-esm/canvas/thread-pin.mjs +310 -0
  168. package/dist-esm/canvas/thread-pin.mjs.map +7 -0
  169. package/dist-esm/canvas/thread-preview.mjs +163 -0
  170. package/dist-esm/canvas/thread-preview.mjs.map +7 -0
  171. package/dist-esm/canvas/thread-stack.mjs +189 -0
  172. package/dist-esm/canvas/thread-stack.mjs.map +7 -0
  173. package/dist-esm/canvas/thread-state.mjs +86 -22
  174. package/dist-esm/canvas/thread-state.mjs.map +2 -2
  175. package/dist-esm/canvas/thread-view.mjs +461 -0
  176. package/dist-esm/canvas/thread-view.mjs.map +7 -0
  177. package/dist-esm/clustering/computeClusterTable.mjs +6 -6
  178. package/dist-esm/clustering/computeClusterTable.mjs.map +2 -2
  179. package/dist-esm/clustering/replay.mjs +89 -22
  180. package/dist-esm/clustering/replay.mjs.map +3 -3
  181. package/dist-esm/clustering/runtime.mjs +126 -7
  182. package/dist-esm/clustering/runtime.mjs.map +2 -2
  183. package/dist-esm/index.d.mts +904 -353
  184. package/dist-esm/index.mjs +102 -43
  185. package/dist-esm/index.mjs.map +2 -2
  186. package/dist-esm/ui/byline.mjs +11 -7
  187. package/dist-esm/ui/byline.mjs.map +2 -2
  188. package/dist-esm/ui/comment-card.mjs +15 -8
  189. package/dist-esm/ui/comment-card.mjs.map +2 -2
  190. package/dist-esm/ui/comment-composer.mjs +135 -39
  191. package/dist-esm/ui/comment-composer.mjs.map +2 -2
  192. package/dist-esm/ui/comment-pin.mjs +11 -2
  193. package/dist-esm/ui/comment-pin.mjs.map +2 -2
  194. package/dist-esm/ui/comment-thread.mjs +9 -7
  195. package/dist-esm/ui/comment-thread.mjs.map +2 -2
  196. package/dist-esm/ui/comments-list.mjs +51 -50
  197. package/dist-esm/ui/comments-list.mjs.map +2 -2
  198. package/dist-esm/ui/count-badge.mjs +3 -2
  199. package/dist-esm/ui/count-badge.mjs.map +2 -2
  200. package/dist-esm/ui/emoji-picker.mjs +34 -0
  201. package/dist-esm/ui/emoji-picker.mjs.map +7 -0
  202. package/dist-esm/ui/empty-state.mjs +3 -3
  203. package/dist-esm/ui/empty-state.mjs.map +2 -2
  204. package/dist-esm/ui/format-time.mjs +16 -1
  205. package/dist-esm/ui/format-time.mjs.map +2 -2
  206. package/dist-esm/ui/icons.mjs +95 -0
  207. package/dist-esm/ui/icons.mjs.map +7 -0
  208. package/dist-esm/ui/reaction-picker.mjs +59 -0
  209. package/dist-esm/ui/reaction-picker.mjs.map +7 -0
  210. package/dist-esm/ui/reaction.mjs +59 -7
  211. package/dist-esm/ui/reaction.mjs.map +2 -2
  212. package/dist-esm/ui/reactions.mjs +21 -8
  213. package/dist-esm/ui/reactions.mjs.map +2 -2
  214. package/dist-esm/ui/reply-count.mjs +9 -0
  215. package/dist-esm/ui/reply-count.mjs.map +7 -0
  216. package/dist-esm/ui/send-button.mjs +13 -1
  217. package/dist-esm/ui/send-button.mjs.map +2 -2
  218. package/dist-esm/ui/visual-viewport.mjs +12 -0
  219. package/dist-esm/ui/visual-viewport.mjs.map +7 -0
  220. package/package.json +6 -6
  221. package/src/canvas/anchor-lifecycle.test.ts +290 -0
  222. package/src/canvas/anchor-lifecycle.ts +191 -0
  223. package/src/canvas/canvas-events.ts +18 -0
  224. package/src/canvas/canvas.css +464 -55
  225. package/src/canvas/cluster-badge.tsx +133 -0
  226. package/src/canvas/cluster-fade.ts +102 -0
  227. package/src/canvas/cluster-input.test.ts +178 -36
  228. package/src/canvas/cluster-input.ts +95 -9
  229. package/src/canvas/cluster-model.ts +378 -0
  230. package/src/canvas/comment-body.tsx +1 -1
  231. package/src/canvas/comment-drafts.test.ts +55 -0
  232. package/src/canvas/comment-drafts.ts +46 -0
  233. package/src/canvas/comment-mutations.test.ts +452 -0
  234. package/src/canvas/comment-mutations.ts +299 -0
  235. package/src/canvas/comment-reactions.test.ts +154 -0
  236. package/src/canvas/comment-reactions.tsx +246 -0
  237. package/src/canvas/comment-render.test.ts +1 -1
  238. package/src/canvas/comment-render.ts +17 -13
  239. package/src/canvas/comment-store.ts +68 -33
  240. package/src/canvas/comment-tool.test.ts +162 -0
  241. package/src/canvas/comment-tool.tsx +103 -25
  242. package/src/canvas/comments-filter-menu.tsx +20 -36
  243. package/src/canvas/comments-overflow-menu.tsx +17 -19
  244. package/src/canvas/comments-overlay.tsx +252 -1369
  245. package/src/canvas/comments-sidebar.test.ts +45 -0
  246. package/src/canvas/comments-sidebar.tsx +112 -73
  247. package/src/canvas/comments-visibility-toggle.tsx +25 -0
  248. package/src/canvas/context.ts +48 -0
  249. package/src/canvas/hooks.test.ts +94 -0
  250. package/src/canvas/hooks.ts +66 -11
  251. package/src/canvas/license.ts +1 -1
  252. package/src/canvas/mobile-placement.ts +115 -0
  253. package/src/canvas/options.test.ts +176 -4
  254. package/src/canvas/options.ts +276 -18
  255. package/src/canvas/pending-composer.tsx +157 -0
  256. package/src/canvas/pin-stacking.test.ts +224 -0
  257. package/src/canvas/pin-stacking.ts +103 -0
  258. package/src/canvas/region-box.tsx +124 -0
  259. package/src/canvas/sidebar-filters.ts +4 -3
  260. package/src/canvas/state.ts +88 -39
  261. package/src/canvas/thread-pin.tsx +418 -0
  262. package/src/canvas/thread-preview.test.ts +91 -0
  263. package/src/canvas/thread-preview.tsx +294 -0
  264. package/src/canvas/thread-stack.tsx +242 -0
  265. package/src/canvas/thread-state.test.ts +260 -0
  266. package/src/canvas/thread-state.ts +171 -37
  267. package/src/canvas/thread-view.test.ts +72 -0
  268. package/src/canvas/thread-view.tsx +614 -0
  269. package/src/clustering/computeClusterTable.test.ts +24 -23
  270. package/src/clustering/computeClusterTable.ts +17 -8
  271. package/src/clustering/replay.test.ts +0 -7
  272. package/src/clustering/replay.ts +131 -32
  273. package/src/clustering/runtime.test.ts +267 -13
  274. package/src/clustering/runtime.ts +176 -19
  275. package/src/clustering/schedule.test.ts +0 -6
  276. package/src/clustering/screen-offsets.test.ts +171 -0
  277. package/src/clustering/types.ts +19 -9
  278. package/src/index.ts +91 -42
  279. package/src/ui/byline.tsx +21 -9
  280. package/src/ui/comment-card.tsx +20 -10
  281. package/src/ui/comment-composer.tsx +178 -56
  282. package/src/ui/comment-pin.tsx +13 -2
  283. package/src/ui/comment-thread.tsx +13 -6
  284. package/src/ui/comments-list.test.ts +31 -0
  285. package/src/ui/comments-list.tsx +82 -47
  286. package/src/ui/comments.css +577 -294
  287. package/src/ui/count-badge.tsx +9 -2
  288. package/src/ui/emoji-picker.test.ts +25 -0
  289. package/src/ui/emoji-picker.tsx +76 -0
  290. package/src/ui/empty-state.tsx +3 -3
  291. package/src/ui/format-time.test.ts +69 -0
  292. package/src/ui/format-time.ts +27 -2
  293. package/src/ui/icons.tsx +116 -0
  294. package/src/ui/reaction-picker.tsx +102 -0
  295. package/src/ui/reaction.tsx +125 -6
  296. package/src/ui/reactions.tsx +69 -10
  297. package/src/ui/reply-count.ts +16 -0
  298. package/src/ui/send-button.tsx +13 -3
  299. package/src/ui/visual-viewport.test.ts +36 -0
  300. package/src/ui/visual-viewport.ts +27 -0
  301. package/dist-cjs/canvas/region-options.js +0 -49
  302. package/dist-cjs/canvas/region-options.js.map +0 -7
  303. package/dist-cjs/ui/avatar.js.map +0 -7
  304. package/dist-cjs/ui/comment-mention.js +0 -42
  305. package/dist-cjs/ui/comment-mention.js.map +0 -7
  306. package/dist-cjs/ui/comment-text.js.map +0 -7
  307. package/dist-cjs/ui/mention-list.js +0 -70
  308. package/dist-cjs/ui/mention-list.js.map +0 -7
  309. package/dist-cjs/ui/mention-suggestion.js +0 -206
  310. package/dist-cjs/ui/mention-suggestion.js.map +0 -7
  311. package/dist-cjs/ui/mention.js.map +0 -7
  312. package/dist-cjs/ui/render-markdown.js +0 -63
  313. package/dist-cjs/ui/render-markdown.js.map +0 -7
  314. package/dist-esm/canvas/region-options.mjs +0 -29
  315. package/dist-esm/canvas/region-options.mjs.map +0 -7
  316. package/dist-esm/ui/avatar.mjs +0 -23
  317. package/dist-esm/ui/avatar.mjs.map +0 -7
  318. package/dist-esm/ui/comment-mention.mjs +0 -22
  319. package/dist-esm/ui/comment-mention.mjs.map +0 -7
  320. package/dist-esm/ui/comment-text.mjs +0 -9
  321. package/dist-esm/ui/comment-text.mjs.map +0 -7
  322. package/dist-esm/ui/mention-list.mjs +0 -50
  323. package/dist-esm/ui/mention-list.mjs.map +0 -7
  324. package/dist-esm/ui/mention-suggestion.mjs +0 -186
  325. package/dist-esm/ui/mention-suggestion.mjs.map +0 -7
  326. package/dist-esm/ui/mention.mjs +0 -11
  327. package/dist-esm/ui/mention.mjs.map +0 -7
  328. package/dist-esm/ui/render-markdown.mjs +0 -45
  329. package/dist-esm/ui/render-markdown.mjs.map +0 -7
  330. package/src/canvas/region-options.ts +0 -57
  331. package/src/ui/avatar.tsx +0 -31
  332. package/src/ui/comment-mention.ts +0 -47
  333. package/src/ui/comment-text.tsx +0 -12
  334. package/src/ui/mention-list.tsx +0 -106
  335. package/src/ui/mention-suggestion.test.ts +0 -18
  336. package/src/ui/mention-suggestion.tsx +0 -285
  337. package/src/ui/mention.tsx +0 -9
  338. package/src/ui/render-markdown.tsx +0 -72
@@ -1,69 +1,344 @@
1
- /* The comments layer is portaled into the editor container. Pins live in the canvas-in-front layer
2
- (beneath the UI panels at z-index 300), so the toolbar and style panel draw over them; the open
3
- thread's popover portals up to the menus layer separately (`.cmt-canvas-popover`) so it isn't
4
- clipped. Click-through except on its own children. */
5
- .cmt-canvas-layer {
1
+ /* The comments layer renders through `EditorPortal`, so its pieces can pick their own layer rather
2
+ than the one the component is mounted in. Pins live in the canvas-in-front layer (beneath the UI
3
+ panels at z-index 300), so the toolbar and style panel draw over them; the open thread's popover
4
+ goes to the menus layer instead (`.tlui-cmt-canvas-popover`) so it isn't clipped. Click-through
5
+ except on its own children. */
6
+ .tlui-cmt-canvas-layer {
6
7
  position: absolute;
7
8
  inset: 0;
8
- z-index: var(--tl-layer-canvas-in-front);
9
+ /* Just below the collaborator cursor layer, so cursors ride over the pins — and below the
10
+ in-front content (250), so active tool UI covers both. Derived, not a literal, so the
11
+ ordering can't silently drift if the cursor slot moves. */
12
+ z-index: calc(var(--tl-layer-collaborators) - 5);
9
13
  pointer-events: none;
10
14
  }
11
15
 
12
- .cmt-canvas-pin,
13
- .cmt-canvas-cluster,
14
- .cmt-canvas-composer {
16
+ .tlui-cmt-canvas-pin,
17
+ .tlui-cmt-canvas-cluster,
18
+ .tlui-cmt-canvas-composer {
15
19
  position: absolute;
16
20
  }
17
21
 
18
- .cmt-canvas-pin,
19
- .cmt-canvas-composer {
22
+ .tlui-cmt-canvas-composer {
20
23
  pointer-events: auto;
21
24
  }
22
25
 
23
- /* Badges are clickable (zoom to the cluster's first split). */
24
- .cmt-canvas-cluster {
25
- transform: translate(-50%, -50%);
26
+ /* The pin's only interactive surface is the square hit layer below — the wrapper itself is
27
+ inert. Its box sits at the anchor point, not over the (translated) visual, so letting it take
28
+ events would put a phantom hit zone beside the pin. */
29
+ .tlui-cmt-canvas-pin {
30
+ pointer-events: none;
31
+ }
32
+
33
+ .tlui-cmt-button {
34
+ appearance: none;
35
+ margin: 0;
36
+ padding: 0;
37
+ border: none;
38
+ background: none;
39
+ color: inherit;
40
+ font: inherit;
41
+ }
42
+
43
+ /* Anchored by its bottom-left corner like a pin, so the badge sits up-and-right of the cluster's
44
+ centroid — the same visual-to-anchor relationship a single comment pin has. */
45
+ .tlui-cmt-canvas-cluster {
46
+ transform: translate(0, -100%);
26
47
  pointer-events: auto;
27
48
  cursor: pointer;
28
49
  }
29
50
 
30
- .cmt-cluster-fade {
51
+ /* Keyboard focus has to be visible on the canvas, where there's no surrounding chrome to imply
52
+ it. The ring goes on the marker visual (the rounded pin/badge), not the button box, so it
53
+ traces the shape rather than a rectangle around it; the button's own outline is suppressed
54
+ because its box is offset from what you see. */
55
+ .tlui-cmt-canvas-pin__marker:focus-visible,
56
+ .tlui-cmt-canvas-cluster:focus-visible {
57
+ outline: none;
58
+ }
59
+ .tlui-cmt-canvas-pin__marker:focus-visible .tlui-cmt-marker,
60
+ .tlui-cmt-canvas-cluster:focus-visible .tlui-cmt-marker {
61
+ outline: 2px solid var(--tl-color-selected);
62
+ outline-offset: 2px;
63
+ }
64
+ /* Focus should read like hover, so the pin lifts the same way when tabbed to. */
65
+ .tlui-cmt-canvas-pin__marker:focus-visible .tlui-cmt-marker {
66
+ transform: scale(var(--tlui-cmt-marker-hover-scale));
67
+ }
68
+
69
+ .tlui-cmt-cluster-fade {
31
70
  opacity: 1;
32
71
  transition: opacity 150ms ease;
33
72
  }
34
73
 
35
- .cmt-cluster-fade--entering {
74
+ .tlui-cmt-cluster-fade--entering {
36
75
  opacity: 0;
37
76
  }
38
77
 
39
- .cmt-cluster-fade--present {
78
+ .tlui-cmt-cluster-fade--present {
40
79
  opacity: 1;
41
80
  }
42
81
 
43
- .cmt-cluster-fade--exiting {
82
+ .tlui-cmt-cluster-fade--exiting {
44
83
  opacity: 0;
45
84
  }
46
85
 
47
- .cmt-cluster-fade--entering *,
48
- .cmt-cluster-fade--exiting * {
86
+ .tlui-cmt-cluster-fade--entering *,
87
+ .tlui-cmt-cluster-fade--exiting * {
49
88
  pointer-events: none !important;
50
89
  }
51
90
 
52
91
  @media (prefers-reduced-motion: reduce) {
53
- .cmt-cluster-fade {
92
+ .tlui-cmt-cluster-fade {
54
93
  transition: none;
55
94
  }
56
95
  }
57
96
 
58
97
  /* The open thread (its pin + popover) sits above the other pins, so nearby markers don't
59
98
  overlap its popover — they tuck behind it. */
60
- .cmt-canvas-pin--open {
99
+ .tlui-cmt-canvas-pin--open {
61
100
  z-index: 1;
62
101
  }
63
102
 
103
+ /* The count badge standing in for a stack of coincident pins — same face as a cluster badge,
104
+ but clicking opens the stack's thread list rather than zooming (no zoom can separate them).
105
+ Re-enables pointer events: the badge lives inside `.tlui-cmt-canvas-pin`, which is inert
106
+ (`pointer-events: none`) so its box doesn't shadow the canvas — without this the badge renders
107
+ but can't be hovered or clicked, like the cluster badge's own `pointer-events: auto`. */
108
+ .tlui-cmt-canvas-stack-badge {
109
+ /* Bottom-left anchored like the pins it stands in for, and like the cluster badge. */
110
+ transform: translate(0, -100%);
111
+ width: max-content;
112
+ pointer-events: auto;
113
+ cursor: pointer;
114
+ }
115
+
116
+ .tlui-cmt-canvas-stack-badge:focus-visible {
117
+ outline: none;
118
+ }
119
+ .tlui-cmt-canvas-stack-badge:focus-visible .tlui-cmt-marker {
120
+ outline: 2px solid var(--tl-color-selected);
121
+ outline-offset: 2px;
122
+ transform: scale(var(--tlui-cmt-marker-hover-scale));
123
+ }
124
+
125
+ /* The stack's popover content: one card per thread, the expanded thread inline among them. */
126
+ .tlui-cmt-stack-list {
127
+ display: flex;
128
+ flex-direction: column;
129
+ gap: 10px;
130
+ }
131
+
132
+ /* The expanded thread is the only entry with pills floating above its panel — its header actions,
133
+ and its first comment's hover actions. Those reach ~15px up, past the list's 10px gap, so give
134
+ this one entry extra room: without it the pills land on the card above, and against the scroll
135
+ box's clip edge. Collapsed cards keep their own actions inside, so they need none of this. */
136
+ .tlui-cmt-stack-list__thread {
137
+ margin-top: 8px;
138
+ }
139
+
140
+ /* Collapsed entries match the expanded thread's surface (same width, panel, elevation) so the
141
+ list reads as one column of cards with one of them opened up. */
142
+ .tlui-cmt-stack-list__card {
143
+ box-sizing: border-box;
144
+ position: relative;
145
+ width: 300px;
146
+ background: var(--tl-color-panel);
147
+ border-radius: 12px;
148
+ box-shadow: var(--tl-shadow-3);
149
+ padding: 2px 12px 10px;
150
+ cursor: pointer;
151
+ text-align: left;
152
+ display: block;
153
+ }
154
+
155
+ /* The card's keyboard affordance, covering the whole surface so it's one target rather than a
156
+ control tucked in a corner. It's laid under the card's content instead of wrapping it: a comment
157
+ body renders its links as anchors, which can't be nested inside a button (see the note in
158
+ `StackThreadCard`). Pointer clicks anywhere still reach the card's own handler by bubbling. */
159
+ .tlui-cmt-stack-list__card-action {
160
+ position: absolute;
161
+ inset: 0;
162
+ border-radius: inherit;
163
+ cursor: pointer;
164
+ }
165
+
166
+ .tlui-cmt-stack-list__card-action:focus-visible {
167
+ outline: 2px solid var(--tl-color-selected);
168
+ outline-offset: 2px;
169
+ }
170
+
171
+ /* The wrapper is the card's surface — inside it the comment is plain content, mirroring how the
172
+ thread panel flattens its own cards. Stacked above the action overlay so the body's links stay
173
+ clickable. */
174
+ .tlui-cmt-stack-list__card .tlui-cmt-card {
175
+ position: relative;
176
+ width: 100%;
177
+ gap: 0;
178
+ padding: 0;
179
+ background: transparent;
180
+ border: none;
181
+ }
182
+
183
+ /* The hover preview, shown for any marker — a pin, a coincident stack, or a cluster badge. Live,
184
+ not a tooltip: the pointer travels into it to hover and click the cards.
185
+
186
+ Two elements, deliberately: this root is the hover *region* (it reaches back over the marker via
187
+ the bridge below), and `__panel` inside it is the visible surface. A pseudo-element's hover
188
+ counts as its host's, so a surface on this root would light up whenever the pointer was on the
189
+ marker — the pin would appear pressed just for being hovered. */
190
+ .tlui-cmt-canvas-preview {
191
+ position: absolute;
192
+ z-index: var(--tl-layer-menus);
193
+ pointer-events: auto;
194
+ }
195
+
196
+ /* The bridge over the gap between the marker and the panel. Moving right off the pin would
197
+ otherwise cross bare canvas, and that leave would retract the panel before the pointer arrived.
198
+ Invisible, part of the panel's hover region, and only present while the panel is.
199
+
200
+ It spans the gap and stops there. Reaching any further would put it over the marker itself, and
201
+ since it sits in the menus layer — above the pins — it would take the marker's hover and clicks:
202
+ the pin would go dead exactly where it looks most alive. The marker needs no covering anyway, as
203
+ it carries the same hover handlers.
204
+
205
+ The gap is the panel's own offset (`--tlui-cmt-preview-offset`, set from `POPOVER_OFFSET` so
206
+ there's one source) less however far the marker reaches toward it, per variant below. */
207
+ .tlui-cmt-canvas-preview::before {
208
+ content: '';
209
+ position: absolute;
210
+ top: 0;
211
+ bottom: 0;
212
+ right: 100%;
213
+ width: max(0px, var(--tlui-cmt-preview-bridge, 0px));
214
+ }
215
+
216
+ /* A pin is anchored at its bottom-left corner, so its full width lies between anchor and panel.
217
+ The popover and preview share a first-comment position now that the actions float outside the
218
+ panel rather than reserving a header row, so no vertical shift is needed. */
219
+ .tlui-cmt-canvas-preview--thread {
220
+ --tlui-cmt-preview-bridge: calc(var(--tlui-cmt-preview-offset) - var(--tlui-cmt-pin-size));
221
+ }
222
+
223
+ /* A badge is anchored at its bottom-left corner like a pin, so its full width does too. */
224
+ .tlui-cmt-canvas-preview--list {
225
+ --tlui-cmt-preview-bridge: calc(var(--tlui-cmt-preview-offset) - var(--tlui-cmt-marker-size));
226
+ }
227
+
228
+ .tlui-cmt-canvas-preview__panel {
229
+ display: flex;
230
+ flex-direction: column;
231
+ }
232
+
233
+ /* Previewing a single pin: the thread panel itself, minus the header — the same surface, width,
234
+ and flattened comment (see `.tlui-cmt-thread .tlui-cmt-card`), so the hover shows exactly what
235
+ the click opens. */
236
+ .tlui-cmt-canvas-preview__panel--thread {
237
+ box-sizing: border-box;
238
+ width: 300px;
239
+ gap: var(--tlui-cmt-thread-gap);
240
+ /* Top/bottom only — the card pads its own sides now (12px), matching the expanded thread. A
241
+ little extra below so the (often truncated) last line doesn't sit against the rounded edge. */
242
+ padding: 4px 0 8px;
243
+ background: var(--tl-color-panel);
244
+ border-radius: var(--tl-radius-4);
245
+ box-shadow: var(--tl-shadow-3);
246
+ }
247
+ /* The reply count is a short line that sits closer to the edge than a wrapped comment does, so give
248
+ it more room below when it's the panel's last line. */
249
+ .tlui-cmt-canvas-preview__panel--thread:has(.tlui-cmt-card__replies) {
250
+ padding-bottom: 12px;
251
+ }
252
+
253
+ /* Previewing a stack or cluster: one card per thread, matching the card list a click opens. */
254
+ .tlui-cmt-canvas-preview__panel--list {
255
+ gap: 8px;
256
+ padding: 4px 0 8px;
257
+ }
258
+
259
+ /* Matches the stack list's card surface, so a preview and the list it previews read as the same
260
+ object seen twice — once on hover, once opened. */
261
+ .tlui-cmt-preview-card {
262
+ box-sizing: border-box;
263
+ width: 300px;
264
+ background: var(--tl-color-panel);
265
+ border-radius: 12px;
266
+ box-shadow: var(--tl-shadow-3);
267
+ /* A 2px nudge above the byline's centring — a boxed card reads a touch better with it than the
268
+ single preview's flat card, which pads 0 vertically and leans on the panel + byline. */
269
+ padding: 2px 12px 10px;
270
+ }
271
+
272
+ .tlui-cmt-preview-card--selectable {
273
+ cursor: pointer;
274
+ }
275
+
276
+ /* Every card surface that tints on hover — a collapsed thread in a stack list, a preview card, and
277
+ the single-comment preview panel. One rule, because they're the same object to the eye.
278
+
279
+ The opaque low-surface token, not a translucent muted one: these float directly over the canvas,
280
+ where a translucent fill would let shapes show through.
281
+
282
+ The second line is why this isn't a one-liner. `--tl-shadow-3` ends with a 1px *inset* ring in
283
+ `--tl-color-panel-contrast` — pure white in light mode — and an inset shadow paints over the
284
+ background. At rest that's invisible (the panel is 99% white under a 100% white ring), but tint
285
+ the background to grey and the ring stays white, hugging the edge as a pale outline. Re-tinting
286
+ `--tl-color-panel-contrast` here wouldn't reach it: `--tl-shadow-3` is declared on the container,
287
+ so its var() was already substituted there and the white is baked into what we inherit. Instead
288
+ lay a ring of the new surface over the old one — first shadow in the list paints on top. */
289
+ .tlui-cmt-stack-list__card:hover,
290
+ .tlui-cmt-preview-card--selectable:hover,
291
+ .tlui-cmt-canvas-preview__panel--thread.tlui-cmt-canvas-preview__panel--selectable:hover {
292
+ --tlui-cmt-preview-hover-surface: color-mix(
293
+ in srgb,
294
+ var(--tl-color-low) 50%,
295
+ var(--tl-color-panel)
296
+ );
297
+ background: var(--tlui-cmt-preview-hover-surface);
298
+ box-shadow:
299
+ inset 0 0 0 1px var(--tlui-cmt-preview-hover-surface),
300
+ var(--tl-shadow-3);
301
+ cursor: pointer;
302
+ }
303
+
304
+ .tlui-cmt-preview-card .tlui-cmt-card {
305
+ width: 100%;
306
+ gap: 0;
307
+ padding: 0;
308
+ background: transparent;
309
+ border: none;
310
+ }
311
+
312
+ /* A preview is a glance, not a list — past a few cards it says how many were left out rather than
313
+ growing to the height of the cluster. */
314
+ .tlui-cmt-preview-more {
315
+ box-sizing: border-box;
316
+ width: 300px;
317
+ padding: 6px 14px;
318
+ border-radius: 12px;
319
+ background: var(--tl-color-panel);
320
+ box-shadow: var(--tl-shadow-3);
321
+ color: var(--tl-color-text-3);
322
+ font-size: 12px;
323
+ }
324
+
325
+ @media (prefers-reduced-motion: no-preference) {
326
+ .tlui-cmt-canvas-preview {
327
+ animation: tlui-cmt-preview-in 120ms ease;
328
+ }
329
+ @keyframes tlui-cmt-preview-in {
330
+ from {
331
+ opacity: 0;
332
+ }
333
+ to {
334
+ opacity: 1;
335
+ }
336
+ }
337
+ }
338
+
64
339
  /* A region anchor's area: a dashed box under the pins, non-interactive so canvas events pass
65
340
  through. Drawn for the live drag draft and for a region thread while hovered or open. */
66
- .cmt-canvas-region {
341
+ .tlui-cmt-canvas-region {
67
342
  position: absolute;
68
343
  pointer-events: none;
69
344
  border: 2px dashed var(--tl-color-selected);
@@ -71,15 +346,8 @@
71
346
  background: color-mix(in srgb, var(--tl-color-selected) 10%, transparent);
72
347
  }
73
348
 
74
- /* A movable region body (the 'body'/'both' move modes): draggable to translate the whole region.
75
- Interactive, so it captures the interior while shown — the tradeoff of dragging the body. */
76
- .cmt-canvas-region--movable {
77
- pointer-events: auto;
78
- cursor: move;
79
- }
80
-
81
349
  /* Corner resize handles on a region box (three corners; the pin corner is the move handle). */
82
- .cmt-canvas-region-handle {
350
+ .tlui-cmt-canvas-region-handle {
83
351
  position: absolute;
84
352
  width: 9px;
85
353
  height: 9px;
@@ -91,58 +359,199 @@
91
359
  touch-action: none;
92
360
  }
93
361
 
94
- /* Centre the pin marker on its anchor point. */
95
- .cmt-canvas-pin__marker {
362
+ /* Anchor the pin by its bottom-left corner, so the marker's one sharp corner (the pin shape's
363
+ 3px bottom-left) points at the exact anchor point. */
364
+ .tlui-cmt-canvas-pin__marker {
365
+ position: relative;
96
366
  width: max-content;
97
- transform: translate(-50%, -50%);
98
- cursor: grab;
367
+ transform: translate(0, -100%);
368
+ /* Default at rest, like hovering a shape; the editor's move cursor while dragging (below). */
369
+ cursor: var(--tl-cursor-default);
99
370
  touch-action: none;
371
+ pointer-events: none;
372
+ }
373
+
374
+ /* Dragging a pin shows the same move cursor as dragging a shape. */
375
+ .tlui-cmt-canvas-pin--dragging .tlui-cmt-canvas-pin__marker {
376
+ cursor: var(--tl-cursor-move);
377
+ }
378
+
379
+ /* The predictable hit area: a fixed square over the marker's box, and the only part of the pin
380
+ that takes pointer events. Events over it target the marker (a pseudo-element's events report
381
+ its originating element), so the marker's handlers and :hover keep working — but the hit area
382
+ no longer stretches with pin content or scales with the hover transform. */
383
+ .tlui-cmt-canvas-pin__marker::after {
384
+ content: '';
385
+ position: absolute;
386
+ inset: 0;
387
+ pointer-events: auto;
100
388
  }
101
- .cmt-canvas-pin__marker:active {
102
- cursor: grabbing;
389
+
390
+ /* With the hit layer targeting the marker, the pin visual is never the hovered element itself
391
+ (`:hover` matches the target and its ancestors, and the pin is the marker's child) — so the
392
+ canvas pin's hover has to key off the hit layer instead of the marker's own `:hover`. Only the
393
+ selector differs: the values come from the same tokens the shared rule uses, so a pin on the
394
+ canvas and a badge (which is hovered directly) lift by exactly the same amount. */
395
+ .tlui-cmt-canvas-pin__marker:hover .tlui-cmt-marker {
396
+ transform: scale(var(--tlui-cmt-marker-hover-scale));
397
+ }
398
+ .tlui-cmt-canvas-pin__marker:hover .tlui-cmt-marker:not(.tlui-cmt-marker--open) {
399
+ box-shadow: var(--tlui-cmt-marker-shadow-hover);
400
+ }
401
+ /* The comment pin doesn't scale on hover — only the shadow lifts (badges still scale). */
402
+ .tlui-cmt-canvas-pin__marker:hover .tlui-cmt-pin {
403
+ transform: none;
103
404
  }
104
405
 
105
406
  /* The open thread's popover — portaled to the menus layer (above the UI), positioned at the pin. */
106
- .cmt-canvas-popover {
407
+ .tlui-cmt-canvas-popover {
107
408
  position: absolute;
108
409
  z-index: var(--tl-layer-menus);
109
410
  pointer-events: auto;
110
411
  }
111
412
 
112
413
  /* The placement composer — a distinct floating view (portaled to the menus layer, below the click
113
- point): a pencil "draft" avatar beside a pill field that is itself the surface (no wrapping
114
- panel). Scoped here so the in-thread reply composer keeps its own squarer look. */
115
- .cmt-canvas-composer {
414
+ point): a draft avatar pin beside a pill field that is itself the surface (no wrapping panel).
415
+ Scoped here so the in-thread reply composer keeps its own squarer look. */
416
+ .tlui-cmt-canvas-composer {
116
417
  position: absolute;
117
418
  z-index: var(--tl-layer-menus);
118
419
  pointer-events: auto;
119
- transform: translateY(8px);
120
- /* The rich-text editor has no intrinsic width (unlike the old <input>), so give the floating
121
- placement composer a definite width or it collapses to nothing. */
122
- width: 280px;
420
+ /* Anchor the draft avatar bottom-left like the pins it becomes: it is a pin wide and sits 4px
421
+ into the row, so its bottom-left corner is 4px right of and 4px + a pin below the composer's
422
+ top-left corner. */
423
+ transform: translate(-4px, calc(-4px - var(--tlui-cmt-pin-size)));
123
424
  }
124
- .cmt-canvas-composer .cmt-composer__field {
425
+
426
+ /* A region placement centres the draft avatar on the region's pin corner — the pin it becomes
427
+ straddles that corner. The avatar's centre sits 4px + half a pin into the composer. */
428
+ .tlui-cmt-canvas-composer--region {
429
+ --tlui-cmt-draft-avatar-centre: calc(4px + var(--tlui-cmt-pin-size) / 2);
430
+ transform: translate(
431
+ calc(-1 * var(--tlui-cmt-draft-avatar-centre)),
432
+ calc(-1 * var(--tlui-cmt-draft-avatar-centre))
433
+ );
434
+ }
435
+
436
+ /* Fallback placement (no composer to show): no draft avatar to anchor by, so no offset — a small
437
+ panel hanging off the click point, sized to its content (e.g. the host's sign-in prompt). */
438
+ .tlui-cmt-canvas-composer--fallback {
439
+ transform: none;
440
+ width: auto;
441
+ display: flex;
442
+ flex-direction: column;
443
+ padding: 8px;
125
444
  background: var(--tl-color-panel);
126
- border-color: transparent;
127
445
  border-radius: var(--tl-radius-4);
446
+ box-shadow: var(--tl-shadow-3);
447
+ }
448
+ .tlui-cmt-canvas-composer .tlui-cmt-composer {
449
+ gap: 6px;
450
+ }
451
+ /* The card: a fixed 300×42 surface whose uniform 3px padding derives the 294×36 focusable input. */
452
+ .tlui-cmt-canvas-composer .tlui-cmt-composer__field {
453
+ position: relative;
454
+ flex: none;
455
+ width: 300px;
456
+ min-height: 42px;
457
+ padding: 3px;
458
+ border: none;
459
+ background: var(--tl-color-panel);
460
+ border-radius: var(--tl-radius-3);
128
461
  box-shadow: var(--tl-shadow-2);
462
+ /* The pin is anchored by its bottom corner at the click point and can't move; raise the taller
463
+ card onto the shorter pin's centre instead. */
464
+ margin-top: -6px;
465
+ }
466
+ /* Focused (the placement composer autofocuses on mount): a selection-blue ring inset 3px from the
467
+ card edge, so the card frames a bordered input rather than the border sitting on the card edge. */
468
+ .tlui-cmt-canvas-composer .tlui-cmt-composer__field:focus-within::before {
469
+ content: '';
470
+ position: absolute;
471
+ inset: 3px;
472
+ border: 1px solid var(--tl-color-selected);
473
+ border-radius: var(--tl-radius-2);
474
+ pointer-events: none;
475
+ }
476
+ /* The text sits 12px in from the focus ring rather than against it. The placeholder is absolutely
477
+ positioned (it ignores the wrap's padding), so it carries the same offset itself. */
478
+ .tlui-cmt-canvas-composer .tlui-cmt-composer__input-wrap {
479
+ padding: 4.5px 12px;
480
+ }
481
+ .tlui-cmt-canvas-composer .tlui-cmt-composer__field--expanded .tlui-cmt-composer__input-wrap {
482
+ /* The base expanded rule re-pads the right edge for the squarer composer's geometry; here the
483
+ 12px is already symmetric. */
484
+ padding-right: 12px;
485
+ }
486
+ .tlui-cmt-canvas-composer .tlui-cmt-input__placeholder {
487
+ left: 12px;
488
+ }
489
+ /* The draft avatar previews the pin it becomes — a white 28px pin holding the author's 22px avatar
490
+ circle — sharing the composer's lift. Not interactive: it drops the pin's pointer cursor and
491
+ hover affordances (scale + shadow bump), but keeps a 40×40 hit area (the ::after below). */
492
+ .tlui-cmt-canvas-composer .tlui-cmt-pin {
493
+ position: relative;
494
+ box-shadow: var(--tl-shadow-2);
495
+ cursor: default;
496
+ }
497
+ .tlui-cmt-canvas-composer .tlui-cmt-pin::after {
498
+ content: '';
499
+ position: absolute;
500
+ inset: -6px;
501
+ }
502
+ .tlui-cmt-canvas-composer .tlui-cmt-pin:hover {
503
+ transform: none;
504
+ box-shadow: var(--tl-shadow-2);
505
+ }
506
+ /* The placement composer's send button — a bare arrow, no pill: grey while empty, black once
507
+ there's something to send. A 28px square centred in the 36px input height, so its hover wash
508
+ clears the focus ring rather than butting against it; the ::after keeps a 40×40 hit area. */
509
+ .tlui-cmt-canvas-composer .tlui-cmt-send {
510
+ position: relative;
511
+ width: 28px;
512
+ height: 28px;
513
+ margin-right: 4px;
514
+ background: transparent;
515
+ border-radius: var(--tl-radius-2);
516
+ color: var(--tl-color-text-3);
517
+ }
518
+ .tlui-cmt-canvas-composer .tlui-cmt-send::after {
519
+ content: '';
520
+ position: absolute;
521
+ inset: -6px;
522
+ }
523
+ .tlui-cmt-canvas-composer .tlui-cmt-send:not(:disabled) {
524
+ color: var(--tl-color-text-1);
525
+ }
526
+ /* Hover and press wash grey behind the bare arrow (the same treatment as the thread actions),
527
+ overriding the base button's blue fill. */
528
+ .tlui-cmt-canvas-composer .tlui-cmt-send:hover:not(:disabled) {
529
+ background: var(--tl-color-muted-2);
530
+ }
531
+ .tlui-cmt-canvas-composer .tlui-cmt-send:active:not(:disabled) {
532
+ background: var(--tl-color-muted-1);
533
+ }
534
+ /* In the expanded (multi-line) layout the send drops to the bottom-right corner; give it the same
535
+ 4px gap from the focus ring on the bottom that it already keeps on the right. */
536
+ .tlui-cmt-canvas-composer .tlui-cmt-composer__field--expanded .tlui-cmt-send {
537
+ margin-bottom: 4px;
129
538
  }
130
539
 
131
- /* The comments list panel — a right-side surface shown while the comment tool is active. Below
132
- the popover layer, so an open thread still draws over it. Sits under the top-right share panel
133
- (top offset clears its ~48px height) and sizes to its content, scrolling past max-height rather
134
- than stretching the full canvas height. */
135
- .cmt-canvas-sidebar {
540
+ /* The comments list panel — a right-side surface shown while the comments sidebar is open. Below
541
+ the popover layer, so an open thread still draws over it. Its top aligns flush with the style
542
+ panel (48px from the top, clearing the share panel) and it sizes to its content, scrolling past
543
+ max-height rather than stretching the full canvas height. */
544
+ .tlui-cmt-canvas-sidebar {
136
545
  position: absolute;
137
- top: 56px;
546
+ top: 48px;
138
547
  right: 8px;
139
548
  width: 280px;
140
- max-height: calc(100% - 64px);
549
+ max-height: calc(100% - 56px);
141
550
  z-index: var(--tl-layer-panels);
142
551
  pointer-events: auto;
143
552
  display: flex;
144
553
  background: var(--tl-color-panel);
145
554
  border-radius: var(--tl-radius-4);
146
- box-shadow: var(--tl-shadow-2);
555
+ box-shadow: var(--tl-shadow-3);
147
556
  overflow: hidden;
148
557
  }