dockview-core 7.0.4 → 8.1.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 (380) hide show
  1. package/LICENCE.md +21 -0
  2. package/README.md +17 -86
  3. package/dist/cjs/api/component.api.d.ts +100 -9
  4. package/dist/cjs/api/dockviewGroupPanelApi.d.ts +45 -1
  5. package/dist/cjs/api/dockviewPanelApi.d.ts +21 -0
  6. package/dist/cjs/dismissableLayer.d.ts +57 -0
  7. package/dist/cjs/dnd/backend.d.ts +2 -2
  8. package/dist/cjs/dnd/dataTransfer.d.ts +1 -0
  9. package/dist/cjs/dnd/dropTargetAnchorContainer.d.ts +12 -0
  10. package/dist/cjs/dnd/droptarget.d.ts +94 -0
  11. package/dist/cjs/dnd/ghost.d.ts +1 -0
  12. package/dist/cjs/dnd/pointer/longPress.d.ts +2 -2
  13. package/dist/cjs/dnd/pointer/pointerDragController.d.ts +5 -2
  14. package/dist/cjs/dnd/pointer/pointerDragSource.d.ts +1 -1
  15. package/dist/cjs/dnd/pointer/pointerDropTarget.d.ts +30 -1
  16. package/dist/cjs/dnd/pointer/pointerGhost.d.ts +1 -1
  17. package/dist/cjs/dockview/accessibilityMessages.d.ts +6 -0
  18. package/dist/cjs/dockview/advancedDnDService.d.ts +31 -0
  19. package/dist/cjs/dockview/components/panel/content.d.ts +1 -1
  20. package/dist/cjs/dockview/components/tab/defaultTab.d.ts +2 -0
  21. package/dist/cjs/dockview/components/tab/tab.d.ts +2 -0
  22. package/dist/cjs/dockview/components/titlebar/floatingTitleBar.d.ts +2 -2
  23. package/dist/cjs/dockview/components/titlebar/groupDragSource.d.ts +1 -1
  24. package/dist/cjs/dockview/components/titlebar/tabGroupChip.d.ts +1 -1
  25. package/dist/cjs/dockview/components/titlebar/tabGroupIndicator.d.ts +73 -2
  26. package/dist/cjs/dockview/components/titlebar/tabGroups.d.ts +1 -1
  27. package/dist/cjs/dockview/components/titlebar/tabReorderController.d.ts +295 -0
  28. package/dist/cjs/dockview/components/titlebar/tabs.d.ts +120 -50
  29. package/dist/cjs/dockview/components/titlebar/tabsContainer.d.ts +48 -0
  30. package/dist/cjs/dockview/dndCapabilities.d.ts +1 -1
  31. package/dist/cjs/dockview/dockviewComponent.d.ts +307 -19
  32. package/dist/cjs/dockview/dockviewGroupPanel.d.ts +5 -0
  33. package/dist/cjs/dockview/dockviewGroupPanelModel.d.ts +76 -2
  34. package/dist/cjs/dockview/dockviewPanel.d.ts +12 -0
  35. package/dist/cjs/dockview/dockviewShell.d.ts +48 -24
  36. package/dist/cjs/dockview/edgeGroupService.d.ts +20 -0
  37. package/dist/cjs/dockview/events.d.ts +6 -0
  38. package/dist/cjs/dockview/liveRegionService.d.ts +18 -5
  39. package/dist/cjs/dockview/moduleContracts.d.ts +485 -14
  40. package/dist/cjs/dockview/modules.d.ts +101 -22
  41. package/dist/cjs/dockview/options.d.ts +336 -30
  42. package/dist/cjs/dockview/optionsModules.d.ts +73 -0
  43. package/dist/cjs/dockview/popoutWindowService.d.ts +15 -10
  44. package/dist/cjs/dockview/rootDropTargetService.d.ts +11 -0
  45. package/dist/cjs/dockview/tabGroup.d.ts +3 -0
  46. package/dist/cjs/dockview/tabGroupAccent.d.ts +1 -1
  47. package/dist/cjs/dockview/tabGroupChipsService.d.ts +10 -0
  48. package/dist/cjs/dockview/theme.d.ts +2 -2
  49. package/dist/cjs/dockview/types.d.ts +3 -0
  50. package/dist/cjs/dom.d.ts +9 -1
  51. package/dist/cjs/events.d.ts +1 -1
  52. package/dist/cjs/gridview/baseComponentGridview.d.ts +2 -2
  53. package/dist/cjs/gridview/branchNode.d.ts +16 -0
  54. package/dist/cjs/gridview/gridview.d.ts +2 -0
  55. package/dist/cjs/index.d.ts +35 -29
  56. package/dist/cjs/lifecycle.d.ts +1 -0
  57. package/dist/cjs/overlay/overlay.d.ts +4 -2
  58. package/dist/cjs/overlay/overlayRenderContainer.d.ts +8 -0
  59. package/dist/cjs/paneview/paneview.d.ts +2 -1
  60. package/dist/cjs/paneview/paneviewComponent.d.ts +3 -0
  61. package/dist/cjs/paneview/paneviewPanel.d.ts +5 -0
  62. package/dist/cjs/scrollbar.d.ts +10 -0
  63. package/dist/cjs/splitview/viewItem.d.ts +10 -0
  64. package/dist/cjs/svg.d.ts +1 -0
  65. package/dist/cjs/types.d.ts +8 -0
  66. package/dist/dockview-core.js +18513 -19679
  67. package/dist/dockview-core.min.js +4138 -6
  68. package/dist/dockview-core.min.noStyle.js +6 -7
  69. package/dist/dockview-core.noStyle.js +18512 -19656
  70. package/dist/package/main.cjs.js +18123 -19267
  71. package/dist/package/main.cjs.min.js +6 -6
  72. package/dist/package/main.esm.min.mjs +6 -6
  73. package/dist/package/main.esm.mjs +18081 -19260
  74. package/package.json +81 -77
  75. package/dist/cjs/api/component.api.js +0 -1242
  76. package/dist/cjs/api/dockviewGroupPanelApi.js +0 -200
  77. package/dist/cjs/api/dockviewPanelApi.js +0 -172
  78. package/dist/cjs/api/entryPoints.js +0 -27
  79. package/dist/cjs/api/gridviewPanelApi.js +0 -45
  80. package/dist/cjs/api/panelApi.js +0 -133
  81. package/dist/cjs/api/paneviewPanelApi.js +0 -57
  82. package/dist/cjs/api/splitviewPanelApi.js +0 -47
  83. package/dist/cjs/array.js +0 -66
  84. package/dist/cjs/constants.js +0 -11
  85. package/dist/cjs/dnd/backend.js +0 -171
  86. package/dist/cjs/dnd/dataTransfer.js +0 -100
  87. package/dist/cjs/dnd/dnd.js +0 -74
  88. package/dist/cjs/dnd/dropOverlay.js +0 -197
  89. package/dist/cjs/dnd/dropTargetAnchorContainer.js +0 -104
  90. package/dist/cjs/dnd/droptarget.js +0 -362
  91. package/dist/cjs/dnd/ghost.js +0 -17
  92. package/dist/cjs/dnd/pointer/index.js +0 -13
  93. package/dist/cjs/dnd/pointer/longPress.js +0 -151
  94. package/dist/cjs/dnd/pointer/pointerDragController.js +0 -243
  95. package/dist/cjs/dnd/pointer/pointerDragSource.js +0 -197
  96. package/dist/cjs/dnd/pointer/pointerDropTarget.js +0 -198
  97. package/dist/cjs/dnd/pointer/pointerGhost.js +0 -44
  98. package/dist/cjs/dnd/pointer/types.js +0 -2
  99. package/dist/cjs/dockview/accessibilityMessages.js +0 -51
  100. package/dist/cjs/dockview/allModules.js +0 -25
  101. package/dist/cjs/dockview/components/panel/content.js +0 -213
  102. package/dist/cjs/dockview/components/popupService.js +0 -132
  103. package/dist/cjs/dockview/components/tab/defaultTab.js +0 -70
  104. package/dist/cjs/dockview/components/tab/tab.js +0 -281
  105. package/dist/cjs/dockview/components/titlebar/floatingTitleBar.js +0 -95
  106. package/dist/cjs/dockview/components/titlebar/groupDragSource.js +0 -218
  107. package/dist/cjs/dockview/components/titlebar/tabGroupChip.js +0 -104
  108. package/dist/cjs/dockview/components/titlebar/tabGroupIndicator.js +0 -477
  109. package/dist/cjs/dockview/components/titlebar/tabGroups.js +0 -854
  110. package/dist/cjs/dockview/components/titlebar/tabOverflowControl.js +0 -19
  111. package/dist/cjs/dockview/components/titlebar/tabs.js +0 -2016
  112. package/dist/cjs/dockview/components/titlebar/tabsContainer.js +0 -458
  113. package/dist/cjs/dockview/components/titlebar/voidContainer.js +0 -120
  114. package/dist/cjs/dockview/components/watermark/watermark.js +0 -40
  115. package/dist/cjs/dockview/deserializer.js +0 -39
  116. package/dist/cjs/dockview/dndCapabilities.js +0 -39
  117. package/dist/cjs/dockview/dockviewComponent.js +0 -3896
  118. package/dist/cjs/dockview/dockviewFloatingGroupPanel.js +0 -70
  119. package/dist/cjs/dockview/dockviewGroupPanel.js +0 -204
  120. package/dist/cjs/dockview/dockviewGroupPanelModel.js +0 -1514
  121. package/dist/cjs/dockview/dockviewPanel.js +0 -265
  122. package/dist/cjs/dockview/dockviewPanelModel.js +0 -105
  123. package/dist/cjs/dockview/dockviewShell.js +0 -744
  124. package/dist/cjs/dockview/edgeGroupService.js +0 -128
  125. package/dist/cjs/dockview/events.js +0 -67
  126. package/dist/cjs/dockview/floatingGroupService.js +0 -231
  127. package/dist/cjs/dockview/framework.js +0 -2
  128. package/dist/cjs/dockview/headerActionsService.js +0 -149
  129. package/dist/cjs/dockview/liveRegionService.js +0 -185
  130. package/dist/cjs/dockview/moduleContracts.js +0 -2
  131. package/dist/cjs/dockview/modules.js +0 -304
  132. package/dist/cjs/dockview/options.js +0 -103
  133. package/dist/cjs/dockview/popoutWindowService.js +0 -261
  134. package/dist/cjs/dockview/rootDropTargetService.js +0 -87
  135. package/dist/cjs/dockview/strictEventsSequencing.js +0 -63
  136. package/dist/cjs/dockview/tabGroup.js +0 -219
  137. package/dist/cjs/dockview/tabGroupAccent.js +0 -126
  138. package/dist/cjs/dockview/theme.js +0 -139
  139. package/dist/cjs/dockview/types.js +0 -2
  140. package/dist/cjs/dockview/validate.js +0 -76
  141. package/dist/cjs/dockview/watermarkService.js +0 -61
  142. package/dist/cjs/dom.js +0 -543
  143. package/dist/cjs/events.js +0 -296
  144. package/dist/cjs/framwork.js +0 -2
  145. package/dist/cjs/gridview/baseComponentGridview.js +0 -330
  146. package/dist/cjs/gridview/basePanelView.js +0 -162
  147. package/dist/cjs/gridview/branchNode.js +0 -372
  148. package/dist/cjs/gridview/gridview.js +0 -776
  149. package/dist/cjs/gridview/gridviewComponent.js +0 -363
  150. package/dist/cjs/gridview/gridviewPanel.js +0 -249
  151. package/dist/cjs/gridview/leafNode.js +0 -169
  152. package/dist/cjs/gridview/options.js +0 -17
  153. package/dist/cjs/gridview/types.js +0 -2
  154. package/dist/cjs/index.js +0 -105
  155. package/dist/cjs/lifecycle.js +0 -80
  156. package/dist/cjs/math.js +0 -38
  157. package/dist/cjs/overlay/overlay.js +0 -602
  158. package/dist/cjs/overlay/overlayRenderContainer.js +0 -309
  159. package/dist/cjs/panel/types.js +0 -2
  160. package/dist/cjs/paneview/defaultPaneviewHeader.js +0 -92
  161. package/dist/cjs/paneview/draggablePaneviewPanel.js +0 -141
  162. package/dist/cjs/paneview/options.js +0 -44
  163. package/dist/cjs/paneview/paneview.js +0 -203
  164. package/dist/cjs/paneview/paneviewComponent.js +0 -430
  165. package/dist/cjs/paneview/paneviewPanel.js +0 -275
  166. package/dist/cjs/popoutWindow.js +0 -244
  167. package/dist/cjs/resizable.js +0 -97
  168. package/dist/cjs/scrollbar.js +0 -169
  169. package/dist/cjs/splitview/options.js +0 -19
  170. package/dist/cjs/splitview/splitview.js +0 -999
  171. package/dist/cjs/splitview/splitviewComponent.js +0 -401
  172. package/dist/cjs/splitview/splitviewPanel.js +0 -179
  173. package/dist/cjs/splitview/viewItem.js +0 -119
  174. package/dist/cjs/svg.js +0 -43
  175. package/dist/cjs/types.js +0 -2
  176. package/dist/dockview-core.min.js.map +0 -1
  177. package/dist/dockview-core.min.noStyle.js.map +0 -1
  178. package/dist/esm/api/component.api.d.ts +0 -640
  179. package/dist/esm/api/component.api.js +0 -887
  180. package/dist/esm/api/dockviewGroupPanelApi.d.ts +0 -109
  181. package/dist/esm/api/dockviewGroupPanelApi.js +0 -155
  182. package/dist/esm/api/dockviewPanelApi.d.ts +0 -84
  183. package/dist/esm/api/dockviewPanelApi.js +0 -124
  184. package/dist/esm/api/entryPoints.d.ts +0 -9
  185. package/dist/esm/api/entryPoints.js +0 -21
  186. package/dist/esm/api/gridviewPanelApi.d.ts +0 -37
  187. package/dist/esm/api/gridviewPanelApi.js +0 -23
  188. package/dist/esm/api/panelApi.d.ts +0 -100
  189. package/dist/esm/api/panelApi.js +0 -87
  190. package/dist/esm/api/paneviewPanelApi.d.ts +0 -26
  191. package/dist/esm/api/paneviewPanelApi.js +0 -27
  192. package/dist/esm/api/splitviewPanelApi.d.ts +0 -32
  193. package/dist/esm/api/splitviewPanelApi.js +0 -25
  194. package/dist/esm/array.d.ts +0 -13
  195. package/dist/esm/array.js +0 -57
  196. package/dist/esm/constants.d.ts +0 -8
  197. package/dist/esm/constants.js +0 -8
  198. package/dist/esm/dnd/backend.d.ts +0 -70
  199. package/dist/esm/dnd/backend.js +0 -148
  200. package/dist/esm/dnd/dataTransfer.d.ts +0 -31
  201. package/dist/esm/dnd/dataTransfer.js +0 -67
  202. package/dist/esm/dnd/dnd.d.ts +0 -32
  203. package/dist/esm/dnd/dnd.js +0 -51
  204. package/dist/esm/dnd/dropOverlay.d.ts +0 -20
  205. package/dist/esm/dnd/dropOverlay.js +0 -192
  206. package/dist/esm/dnd/dropTargetAnchorContainer.d.ts +0 -16
  207. package/dist/esm/dnd/dropTargetAnchorContainer.js +0 -73
  208. package/dist/esm/dnd/droptarget.d.ts +0 -116
  209. package/dist/esm/dnd/droptarget.js +0 -316
  210. package/dist/esm/dnd/ghost.d.ts +0 -4
  211. package/dist/esm/dnd/ghost.js +0 -14
  212. package/dist/esm/dnd/pointer/index.d.ts +0 -11
  213. package/dist/esm/dnd/pointer/index.js +0 -5
  214. package/dist/esm/dnd/pointer/longPress.d.ts +0 -32
  215. package/dist/esm/dnd/pointer/longPress.js +0 -127
  216. package/dist/esm/dnd/pointer/pointerDragController.d.ts +0 -60
  217. package/dist/esm/dnd/pointer/pointerDragController.js +0 -193
  218. package/dist/esm/dnd/pointer/pointerDragSource.d.ts +0 -61
  219. package/dist/esm/dnd/pointer/pointerDragSource.js +0 -173
  220. package/dist/esm/dnd/pointer/pointerDropTarget.d.ts +0 -39
  221. package/dist/esm/dnd/pointer/pointerDropTarget.js +0 -168
  222. package/dist/esm/dnd/pointer/pointerGhost.d.ts +0 -30
  223. package/dist/esm/dnd/pointer/pointerGhost.js +0 -39
  224. package/dist/esm/dnd/pointer/types.d.ts +0 -16
  225. package/dist/esm/dnd/pointer/types.js +0 -1
  226. package/dist/esm/dockview/accessibilityMessages.d.ts +0 -32
  227. package/dist/esm/dockview/accessibilityMessages.js +0 -30
  228. package/dist/esm/dockview/allModules.d.ts +0 -8
  229. package/dist/esm/dockview/allModules.js +0 -22
  230. package/dist/esm/dockview/components/panel/content.d.ts +0 -54
  231. package/dist/esm/dockview/components/panel/content.js +0 -185
  232. package/dist/esm/dockview/components/popupService.d.ts +0 -21
  233. package/dist/esm/dockview/components/popupService.js +0 -108
  234. package/dist/esm/dockview/components/tab/defaultTab.d.ts +0 -12
  235. package/dist/esm/dockview/components/tab/defaultTab.js +0 -43
  236. package/dist/esm/dockview/components/tab/tab.d.ts +0 -44
  237. package/dist/esm/dockview/components/tab/tab.js +0 -242
  238. package/dist/esm/dockview/components/titlebar/floatingTitleBar.d.ts +0 -34
  239. package/dist/esm/dockview/components/titlebar/floatingTitleBar.js +0 -65
  240. package/dist/esm/dockview/components/titlebar/groupDragSource.d.ts +0 -51
  241. package/dist/esm/dockview/components/titlebar/groupDragSource.js +0 -178
  242. package/dist/esm/dockview/components/titlebar/tabGroupChip.d.ts +0 -37
  243. package/dist/esm/dockview/components/titlebar/tabGroupChip.js +0 -77
  244. package/dist/esm/dockview/components/titlebar/tabGroupIndicator.d.ts +0 -72
  245. package/dist/esm/dockview/components/titlebar/tabGroupIndicator.js +0 -360
  246. package/dist/esm/dockview/components/titlebar/tabGroups.d.ts +0 -107
  247. package/dist/esm/dockview/components/titlebar/tabGroups.js +0 -621
  248. package/dist/esm/dockview/components/titlebar/tabOverflowControl.d.ts +0 -8
  249. package/dist/esm/dockview/components/titlebar/tabOverflowControl.js +0 -16
  250. package/dist/esm/dockview/components/titlebar/tabs.d.ts +0 -167
  251. package/dist/esm/dockview/components/titlebar/tabs.js +0 -1653
  252. package/dist/esm/dockview/components/titlebar/tabsContainer.d.ts +0 -104
  253. package/dist/esm/dockview/components/titlebar/tabsContainer.js +0 -359
  254. package/dist/esm/dockview/components/titlebar/voidContainer.d.ts +0 -21
  255. package/dist/esm/dockview/components/titlebar/voidContainer.js +0 -92
  256. package/dist/esm/dockview/components/watermark/watermark.d.ts +0 -8
  257. package/dist/esm/dockview/components/watermark/watermark.js +0 -14
  258. package/dist/esm/dockview/deserializer.d.ts +0 -12
  259. package/dist/esm/dockview/deserializer.js +0 -34
  260. package/dist/esm/dockview/dndCapabilities.d.ts +0 -19
  261. package/dist/esm/dockview/dndCapabilities.js +0 -36
  262. package/dist/esm/dockview/dockviewComponent.d.ts +0 -626
  263. package/dist/esm/dockview/dockviewComponent.js +0 -3214
  264. package/dist/esm/dockview/dockviewFloatingGroupPanel.d.ts +0 -45
  265. package/dist/esm/dockview/dockviewFloatingGroupPanel.js +0 -44
  266. package/dist/esm/dockview/dockviewGroupPanel.d.ts +0 -35
  267. package/dist/esm/dockview/dockviewGroupPanel.js +0 -142
  268. package/dist/esm/dockview/dockviewGroupPanelModel.d.ts +0 -358
  269. package/dist/esm/dockview/dockviewGroupPanelModel.js +0 -1180
  270. package/dist/esm/dockview/dockviewPanel.d.ts +0 -69
  271. package/dist/esm/dockview/dockviewPanel.js +0 -178
  272. package/dist/esm/dockview/dockviewPanelModel.d.ts +0 -37
  273. package/dist/esm/dockview/dockviewPanelModel.js +0 -81
  274. package/dist/esm/dockview/dockviewShell.d.ts +0 -150
  275. package/dist/esm/dockview/dockviewShell.js +0 -678
  276. package/dist/esm/dockview/edgeGroupService.d.ts +0 -38
  277. package/dist/esm/dockview/edgeGroupService.js +0 -63
  278. package/dist/esm/dockview/events.d.ts +0 -38
  279. package/dist/esm/dockview/events.js +0 -34
  280. package/dist/esm/dockview/floatingGroupService.d.ts +0 -37
  281. package/dist/esm/dockview/floatingGroupService.js +0 -150
  282. package/dist/esm/dockview/framework.d.ts +0 -65
  283. package/dist/esm/dockview/framework.js +0 -1
  284. package/dist/esm/dockview/headerActionsService.d.ts +0 -32
  285. package/dist/esm/dockview/headerActionsService.js +0 -86
  286. package/dist/esm/dockview/liveRegionService.d.ts +0 -53
  287. package/dist/esm/dockview/liveRegionService.js +0 -159
  288. package/dist/esm/dockview/moduleContracts.d.ts +0 -119
  289. package/dist/esm/dockview/moduleContracts.js +0 -1
  290. package/dist/esm/dockview/modules.d.ts +0 -110
  291. package/dist/esm/dockview/modules.js +0 -170
  292. package/dist/esm/dockview/options.d.ts +0 -474
  293. package/dist/esm/dockview/options.js +0 -77
  294. package/dist/esm/dockview/popoutWindowService.d.ts +0 -95
  295. package/dist/esm/dockview/popoutWindowService.js +0 -175
  296. package/dist/esm/dockview/rootDropTargetService.d.ts +0 -35
  297. package/dist/esm/dockview/rootDropTargetService.js +0 -82
  298. package/dist/esm/dockview/strictEventsSequencing.d.ts +0 -7
  299. package/dist/esm/dockview/strictEventsSequencing.js +0 -41
  300. package/dist/esm/dockview/tabGroup.d.ts +0 -99
  301. package/dist/esm/dockview/tabGroup.js +0 -144
  302. package/dist/esm/dockview/tabGroupAccent.d.ts +0 -65
  303. package/dist/esm/dockview/tabGroupAccent.js +0 -114
  304. package/dist/esm/dockview/theme.d.ts +0 -86
  305. package/dist/esm/dockview/theme.js +0 -136
  306. package/dist/esm/dockview/types.d.ts +0 -53
  307. package/dist/esm/dockview/types.js +0 -1
  308. package/dist/esm/dockview/validate.d.ts +0 -0
  309. package/dist/esm/dockview/validate.js +0 -76
  310. package/dist/esm/dockview/watermarkService.d.ts +0 -30
  311. package/dist/esm/dockview/watermarkService.js +0 -56
  312. package/dist/esm/dom.d.ts +0 -60
  313. package/dist/esm/dom.js +0 -375
  314. package/dist/esm/events.d.ts +0 -79
  315. package/dist/esm/events.js +0 -219
  316. package/dist/esm/framwork.d.ts +0 -4
  317. package/dist/esm/framwork.js +0 -1
  318. package/dist/esm/gridview/baseComponentGridview.d.ts +0 -111
  319. package/dist/esm/gridview/baseComponentGridview.js +0 -237
  320. package/dist/esm/gridview/basePanelView.d.ts +0 -40
  321. package/dist/esm/gridview/basePanelView.js +0 -91
  322. package/dist/esm/gridview/branchNode.d.ts +0 -57
  323. package/dist/esm/gridview/branchNode.js +0 -257
  324. package/dist/esm/gridview/gridview.d.ts +0 -158
  325. package/dist/esm/gridview/gridview.js +0 -681
  326. package/dist/esm/gridview/gridviewComponent.d.ts +0 -88
  327. package/dist/esm/gridview/gridviewComponent.js +0 -265
  328. package/dist/esm/gridview/gridviewPanel.d.ts +0 -77
  329. package/dist/esm/gridview/gridviewPanel.js +0 -182
  330. package/dist/esm/gridview/leafNode.d.ts +0 -34
  331. package/dist/esm/gridview/leafNode.js +0 -102
  332. package/dist/esm/gridview/options.d.ts +0 -15
  333. package/dist/esm/gridview/options.js +0 -14
  334. package/dist/esm/gridview/types.d.ts +0 -3
  335. package/dist/esm/gridview/types.js +0 -1
  336. package/dist/esm/index.d.ts +0 -58
  337. package/dist/esm/index.js +0 -44
  338. package/dist/esm/lifecycle.d.ts +0 -25
  339. package/dist/esm/lifecycle.js +0 -56
  340. package/dist/esm/math.d.ts +0 -5
  341. package/dist/esm/math.js +0 -32
  342. package/dist/esm/overlay/overlay.d.ts +0 -91
  343. package/dist/esm/overlay/overlay.js +0 -520
  344. package/dist/esm/overlay/overlayRenderContainer.d.ts +0 -24
  345. package/dist/esm/overlay/overlayRenderContainer.js +0 -249
  346. package/dist/esm/panel/types.d.ts +0 -33
  347. package/dist/esm/panel/types.js +0 -1
  348. package/dist/esm/paneview/defaultPaneviewHeader.d.ts +0 -21
  349. package/dist/esm/paneview/defaultPaneviewHeader.js +0 -65
  350. package/dist/esm/paneview/draggablePaneviewPanel.d.ts +0 -38
  351. package/dist/esm/paneview/draggablePaneviewPanel.js +0 -107
  352. package/dist/esm/paneview/options.d.ts +0 -30
  353. package/dist/esm/paneview/options.js +0 -22
  354. package/dist/esm/paneview/paneview.d.ts +0 -41
  355. package/dist/esm/paneview/paneview.js +0 -148
  356. package/dist/esm/paneview/paneviewComponent.d.ts +0 -133
  357. package/dist/esm/paneview/paneviewComponent.js +0 -306
  358. package/dist/esm/paneview/paneviewPanel.d.ts +0 -98
  359. package/dist/esm/paneview/paneviewPanel.js +0 -192
  360. package/dist/esm/popoutWindow.d.ts +0 -38
  361. package/dist/esm/popoutWindow.js +0 -170
  362. package/dist/esm/resizable.d.ts +0 -12
  363. package/dist/esm/resizable.js +0 -66
  364. package/dist/esm/scrollbar.d.ts +0 -15
  365. package/dist/esm/scrollbar.js +0 -139
  366. package/dist/esm/splitview/options.d.ts +0 -21
  367. package/dist/esm/splitview/options.js +0 -16
  368. package/dist/esm/splitview/splitview.d.ts +0 -145
  369. package/dist/esm/splitview/splitview.js +0 -770
  370. package/dist/esm/splitview/splitviewComponent.d.ts +0 -101
  371. package/dist/esm/splitview/splitviewComponent.js +0 -267
  372. package/dist/esm/splitview/splitviewPanel.d.ts +0 -45
  373. package/dist/esm/splitview/splitviewPanel.js +0 -108
  374. package/dist/esm/splitview/viewItem.d.ts +0 -25
  375. package/dist/esm/splitview/viewItem.js +0 -74
  376. package/dist/esm/svg.d.ts +0 -3
  377. package/dist/esm/svg.js +0 -31
  378. package/dist/esm/types.d.ts +0 -31
  379. package/dist/esm/types.js +0 -1
  380. package/dist/styles/dockview.css +0 -3436
@@ -1,104 +0,0 @@
1
- "use strict";
2
- var __extends = (this && this.__extends) || (function () {
3
- var extendStatics = function (d, b) {
4
- extendStatics = Object.setPrototypeOf ||
5
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
- return extendStatics(d, b);
8
- };
9
- return function (d, b) {
10
- if (typeof b !== "function" && b !== null)
11
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
- extendStatics(d, b);
13
- function __() { this.constructor = d; }
14
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
- };
16
- })();
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- exports.TabGroupChip = void 0;
19
- var events_1 = require("../../../events");
20
- var lifecycle_1 = require("../../../lifecycle");
21
- var dom_1 = require("../../../dom");
22
- var tabGroupAccent_1 = require("../../tabGroupAccent");
23
- var longPress_1 = require("../../../dnd/pointer/longPress");
24
- /**
25
- * Visual chip for a tab group. Owns the DOM element, label, click /
26
- * context-menu interactions, and exposes a long-press gesture as a
27
- * second `onContextMenu` source. Drag-and-drop wiring lives in
28
- * `TabGroupManager` — the manager constructs the drag sources on this
29
- * chip's element so it can include tabs-list context (custom group
30
- * drag image, tab-group transfer payload).
31
- */
32
- var TabGroupChip = /** @class */ (function (_super) {
33
- __extends(TabGroupChip, _super);
34
- function TabGroupChip(_palette) {
35
- var _this = _super.call(this) || this;
36
- _this._palette = _palette;
37
- _this._onClick = new events_1.Emitter();
38
- _this.onClick = _this._onClick.event;
39
- _this._onContextMenu = new events_1.Emitter();
40
- /** Fires on right-click and on touch long-press. */
41
- _this.onContextMenu = _this._onContextMenu.event;
42
- _this._element = document.createElement('div');
43
- _this._element.className = 'dv-tab-group-chip';
44
- _this._element.tabIndex = 0;
45
- _this._label = document.createElement('span');
46
- _this._label.className = 'dv-tab-group-chip-label';
47
- _this._element.appendChild(_this._label);
48
- _this.addDisposables(_this._onClick, _this._onContextMenu, new longPress_1.LongPressDetector(_this._element, {
49
- onLongPress: function (event) {
50
- _this._onContextMenu.fire(event);
51
- },
52
- }), (0, events_1.addDisposableListener)(_this._element, 'click', function (event) {
53
- _this._onClick.fire(event);
54
- }), (0, events_1.addDisposableListener)(_this._element, 'contextmenu', function (event) {
55
- _this._onContextMenu.fire(event);
56
- }));
57
- return _this;
58
- }
59
- Object.defineProperty(TabGroupChip.prototype, "element", {
60
- get: function () {
61
- return this._element;
62
- },
63
- enumerable: false,
64
- configurable: true
65
- });
66
- TabGroupChip.prototype.init = function (params) {
67
- var _this = this;
68
- this._tabGroup = params.tabGroup;
69
- this.updateColor(params.tabGroup.color);
70
- this.updateLabel(params.tabGroup.label);
71
- this.updateCollapsed(params.tabGroup.collapsed);
72
- this.addDisposables(params.tabGroup.onDidChange(function () {
73
- if (_this._tabGroup) {
74
- _this.updateColor(_this._tabGroup.color);
75
- _this.updateLabel(_this._tabGroup.label);
76
- }
77
- }), params.tabGroup.onDidCollapseChange(function (collapsed) {
78
- _this.updateCollapsed(collapsed);
79
- }), this._onClick.event(function () {
80
- var _a;
81
- (_a = _this._tabGroup) === null || _a === void 0 ? void 0 : _a.toggle();
82
- }));
83
- };
84
- TabGroupChip.prototype.update = function (params) {
85
- this._tabGroup = params.tabGroup;
86
- this.updateColor(params.tabGroup.color);
87
- this.updateLabel(params.tabGroup.label);
88
- this.updateCollapsed(params.tabGroup.collapsed);
89
- };
90
- TabGroupChip.prototype.updateColor = function (color) {
91
- var _a;
92
- (0, tabGroupAccent_1.applyTabGroupAccent)(this._element, color, this._palette);
93
- (0, dom_1.toggleClass)(this._element, 'dv-tab-group-chip--accent-off', ((_a = this._palette) === null || _a === void 0 ? void 0 : _a.enabled) === false);
94
- };
95
- TabGroupChip.prototype.updateLabel = function (label) {
96
- this._label.textContent = label;
97
- (0, dom_1.toggleClass)(this._label, 'dv-tab-group-chip-label--empty', !label);
98
- };
99
- TabGroupChip.prototype.updateCollapsed = function (collapsed) {
100
- (0, dom_1.toggleClass)(this._element, 'dv-tab-group-chip--collapsed', collapsed);
101
- };
102
- return TabGroupChip;
103
- }(lifecycle_1.CompositeDisposable));
104
- exports.TabGroupChip = TabGroupChip;
@@ -1,477 +0,0 @@
1
- "use strict";
2
- var __extends = (this && this.__extends) || (function () {
3
- var extendStatics = function (d, b) {
4
- extendStatics = Object.setPrototypeOf ||
5
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
- return extendStatics(d, b);
8
- };
9
- return function (d, b) {
10
- if (typeof b !== "function" && b !== null)
11
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
- extendStatics(d, b);
13
- function __() { this.constructor = d; }
14
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
- };
16
- })();
17
- var __values = (this && this.__values) || function(o) {
18
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
19
- if (m) return m.call(o);
20
- if (o && typeof o.length === "number") return {
21
- next: function () {
22
- if (o && i >= o.length) o = void 0;
23
- return { value: o && o[i++], done: !o };
24
- }
25
- };
26
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
27
- };
28
- var __read = (this && this.__read) || function (o, n) {
29
- var m = typeof Symbol === "function" && o[Symbol.iterator];
30
- if (!m) return o;
31
- var i = m.call(o), r, ar = [], e;
32
- try {
33
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
34
- }
35
- catch (error) { e = { error: error }; }
36
- finally {
37
- try {
38
- if (r && !r.done && (m = i["return"])) m.call(i);
39
- }
40
- finally { if (e) throw e.error; }
41
- }
42
- return ar;
43
- };
44
- Object.defineProperty(exports, "__esModule", { value: true });
45
- exports.NoneTabGroupIndicator = exports.WrapTabGroupIndicator = void 0;
46
- var tabGroupAccent_1 = require("../../tabGroupAccent");
47
- /**
48
- * Shared positioning logic for tab group indicators.
49
- * Subclasses implement `applyShape` to control the visual output.
50
- */
51
- var BaseTabGroupIndicator = /** @class */ (function () {
52
- function BaseTabGroupIndicator(_ctx) {
53
- this._ctx = _ctx;
54
- this._underlines = new Map();
55
- this._rafId = null;
56
- }
57
- Object.defineProperty(BaseTabGroupIndicator.prototype, "underlines", {
58
- get: function () {
59
- return this._underlines;
60
- },
61
- enumerable: false,
62
- configurable: true
63
- });
64
- BaseTabGroupIndicator.prototype.positionUnderlines = function () {
65
- var _this = this;
66
- requestAnimationFrame(function () {
67
- _this._positionUnderlinesSync();
68
- });
69
- };
70
- /**
71
- * Continuously reposition underlines every frame for the duration
72
- * of a tab transition (~200ms), so the underline tracks tab sizes.
73
- */
74
- BaseTabGroupIndicator.prototype.trackUnderlines = function () {
75
- var _this = this;
76
- if (this._rafId !== null) {
77
- cancelAnimationFrame(this._rafId);
78
- }
79
- var start = performance.now();
80
- var duration = 250; // slightly longer than transition to ensure we catch the end
81
- var tick = function () {
82
- _this._positionUnderlinesSync();
83
- if (performance.now() - start < duration) {
84
- _this._rafId = requestAnimationFrame(tick);
85
- }
86
- else {
87
- _this._rafId = null;
88
- }
89
- };
90
- this._rafId = requestAnimationFrame(tick);
91
- };
92
- BaseTabGroupIndicator.prototype.syncUnderlineElements = function (activeGroupIds) {
93
- var e_1, _a, e_2, _b;
94
- try {
95
- // Ensure underline elements exist for active groups
96
- for (var activeGroupIds_1 = __values(activeGroupIds), activeGroupIds_1_1 = activeGroupIds_1.next(); !activeGroupIds_1_1.done; activeGroupIds_1_1 = activeGroupIds_1.next()) {
97
- var groupId = activeGroupIds_1_1.value;
98
- if (!this._underlines.has(groupId)) {
99
- var underline = document.createElement('div');
100
- underline.className = 'dv-tab-group-underline';
101
- this._ctx.tabsList.appendChild(underline);
102
- this._underlines.set(groupId, underline);
103
- }
104
- }
105
- }
106
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
107
- finally {
108
- try {
109
- if (activeGroupIds_1_1 && !activeGroupIds_1_1.done && (_a = activeGroupIds_1.return)) _a.call(activeGroupIds_1);
110
- }
111
- finally { if (e_1) throw e_1.error; }
112
- }
113
- try {
114
- // Remove underlines for dissolved groups
115
- for (var _c = __values(this._underlines), _d = _c.next(); !_d.done; _d = _c.next()) {
116
- var _e = __read(_d.value, 2), groupId = _e[0], el = _e[1];
117
- if (!activeGroupIds.has(groupId)) {
118
- el.remove();
119
- this._underlines.delete(groupId);
120
- }
121
- }
122
- }
123
- catch (e_2_1) { e_2 = { error: e_2_1 }; }
124
- finally {
125
- try {
126
- if (_d && !_d.done && (_b = _c.return)) _b.call(_c);
127
- }
128
- finally { if (e_2) throw e_2.error; }
129
- }
130
- };
131
- BaseTabGroupIndicator.prototype.getUnderline = function (groupId) {
132
- return this._underlines.get(groupId);
133
- };
134
- BaseTabGroupIndicator.prototype.dispose = function () {
135
- var e_3, _a;
136
- if (this._rafId !== null) {
137
- cancelAnimationFrame(this._rafId);
138
- this._rafId = null;
139
- }
140
- try {
141
- for (var _b = __values(this._underlines), _c = _b.next(); !_c.done; _c = _b.next()) {
142
- var _d = __read(_c.value, 2), el = _d[1];
143
- el.remove();
144
- }
145
- }
146
- catch (e_3_1) { e_3 = { error: e_3_1 }; }
147
- finally {
148
- try {
149
- if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
150
- }
151
- finally { if (e_3) throw e_3.error; }
152
- }
153
- this._underlines.clear();
154
- };
155
- BaseTabGroupIndicator.prototype._positionUnderlinesSync = function () {
156
- var e_4, _a, e_5, _b;
157
- var containerRect = this._ctx.tabsList.getBoundingClientRect();
158
- var tabGroups = this._ctx.getTabGroups();
159
- var isVertical = this._ctx.getDirection() === 'vertical';
160
- var containerCrossSize = isVertical
161
- ? containerRect.width
162
- : containerRect.height;
163
- var activePanelId = this._ctx.getActivePanelId();
164
- var tabMap = this._ctx.getTabMap();
165
- try {
166
- for (var tabGroups_1 = __values(tabGroups), tabGroups_1_1 = tabGroups_1.next(); !tabGroups_1_1.done; tabGroups_1_1 = tabGroups_1.next()) {
167
- var tg = tabGroups_1_1.value;
168
- var underline = this._underlines.get(tg.id);
169
- if (!underline) {
170
- continue;
171
- }
172
- var panelIds = tg.panelIds;
173
- if (panelIds.length === 0) {
174
- underline.style.display = 'none';
175
- continue;
176
- }
177
- underline.style.display = '';
178
- var chipEl = this._ctx.getChipElement(tg.id);
179
- // In vertical mode, compute top/bottom edges; in horizontal, left/right.
180
- var startEdge = void 0;
181
- if (chipEl) {
182
- var chipRect = chipEl.getBoundingClientRect();
183
- var chipStyle = getComputedStyle(chipEl);
184
- var leadingMargin = isVertical
185
- ? Number.parseFloat(chipStyle.marginTop) || 0
186
- : Number.parseFloat(chipStyle.marginLeft) || 0;
187
- startEdge = isVertical
188
- ? chipRect.top - containerRect.top - leadingMargin
189
- : chipRect.left - containerRect.left - leadingMargin;
190
- }
191
- else {
192
- var firstPanelId = panelIds[0];
193
- var firstTabEntry = tabMap.get(firstPanelId);
194
- if (firstTabEntry) {
195
- var firstRect = firstTabEntry.value.element.getBoundingClientRect();
196
- startEdge = isVertical
197
- ? firstRect.top - containerRect.top
198
- : firstRect.left - containerRect.left;
199
- }
200
- else {
201
- startEdge = 0;
202
- }
203
- }
204
- // Measure the actual last tab position (follows CSS transitions in real-time)
205
- var lastPanelId = panelIds[panelIds.length - 1];
206
- var lastTabEntry = tabMap.get(lastPanelId);
207
- if (!lastTabEntry) {
208
- if (isVertical) {
209
- underline.style.top = "".concat(startEdge, "px");
210
- underline.style.height = '0px';
211
- underline.style.left = '';
212
- underline.style.width = '';
213
- }
214
- else {
215
- underline.style.left = "".concat(startEdge, "px");
216
- underline.style.width = '0px';
217
- underline.style.top = '';
218
- underline.style.height = '';
219
- }
220
- continue;
221
- }
222
- var lastTabRect = lastTabEntry.value.element.getBoundingClientRect();
223
- var endEdge = isVertical
224
- ? lastTabRect.bottom - containerRect.top
225
- : lastTabRect.right - containerRect.left;
226
- var span = endEdge - startEdge;
227
- // During collapse or expand: converge both edges toward chip center
228
- var isAnimating = tg.collapsed ||
229
- tg.panelIds.some(function (pid) {
230
- var te = tabMap.get(pid);
231
- return te === null || te === void 0 ? void 0 : te.value.element.classList.contains('dv-tab--group-expanding');
232
- });
233
- if (isAnimating && chipEl) {
234
- var chipRect = chipEl.getBoundingClientRect();
235
- var chipCenter = isVertical
236
- ? chipRect.top + chipRect.height / 2 - containerRect.top
237
- : chipRect.left + chipRect.width / 2 - containerRect.left;
238
- // Sum of current visible tab sizes (shrinking or growing)
239
- var currentTabSize = 0;
240
- var fullTabSize = 0;
241
- try {
242
- for (var _c = (e_5 = void 0, __values(tg.panelIds)), _d = _c.next(); !_d.done; _d = _c.next()) {
243
- var pid = _d.value;
244
- var te = tabMap.get(pid);
245
- if (!te)
246
- continue;
247
- var el = te.value.element;
248
- if (isVertical) {
249
- currentTabSize += el.getBoundingClientRect().height;
250
- fullTabSize += el.scrollHeight;
251
- }
252
- else {
253
- currentTabSize += el.getBoundingClientRect().width;
254
- fullTabSize += el.scrollWidth;
255
- }
256
- }
257
- }
258
- catch (e_5_1) { e_5 = { error: e_5_1 }; }
259
- finally {
260
- try {
261
- if (_d && !_d.done && (_b = _c.return)) _b.call(_c);
262
- }
263
- finally { if (e_5) throw e_5.error; }
264
- }
265
- // progress: 0 when tabs at 0 size, 1 when fully open
266
- var progress = fullTabSize > 0
267
- ? Math.min(1, currentTabSize / fullTabSize)
268
- : 0;
269
- // Interpolate start and end edges toward chip center
270
- startEdge = chipCenter + (startEdge - chipCenter) * progress;
271
- endEdge = chipCenter + (endEdge - chipCenter) * progress;
272
- span = Math.max(0, endEdge - startEdge);
273
- }
274
- if (isVertical) {
275
- underline.style.top = "".concat(startEdge, "px");
276
- underline.style.height = "".concat(Math.max(0, span), "px");
277
- // Clear horizontal properties
278
- underline.style.left = '';
279
- underline.style.width = '';
280
- }
281
- else {
282
- underline.style.left = "".concat(startEdge, "px");
283
- underline.style.width = "".concat(Math.max(0, span), "px");
284
- // Clear vertical properties
285
- underline.style.top = '';
286
- underline.style.height = '';
287
- }
288
- this.applyShape(underline, tg, startEdge, span, containerCrossSize, activePanelId, containerRect, isVertical);
289
- }
290
- }
291
- catch (e_4_1) { e_4 = { error: e_4_1 }; }
292
- finally {
293
- try {
294
- if (tabGroups_1_1 && !tabGroups_1_1.done && (_a = tabGroups_1.return)) _a.call(tabGroups_1);
295
- }
296
- finally { if (e_4) throw e_4.error; }
297
- }
298
- };
299
- return BaseTabGroupIndicator;
300
- }());
301
- /**
302
- * Chrome-style wrap-around indicator using SVG paths.
303
- */
304
- var WrapTabGroupIndicator = /** @class */ (function (_super) {
305
- __extends(WrapTabGroupIndicator, _super);
306
- function WrapTabGroupIndicator() {
307
- return _super !== null && _super.apply(this, arguments) || this;
308
- }
309
- WrapTabGroupIndicator.prototype._applyStraightLine = function (svg, path, underline, t, mainSize, isVertical) {
310
- if (isVertical) {
311
- svg.setAttribute('width', String(t));
312
- svg.setAttribute('height', String(mainSize));
313
- underline.style.width = "".concat(t, "px");
314
- underline.style.height = "".concat(mainSize, "px");
315
- path.setAttribute('d', "M ".concat(t / 2, ",0 L ").concat(t / 2, ",").concat(mainSize));
316
- }
317
- else {
318
- svg.setAttribute('width', String(mainSize));
319
- svg.setAttribute('height', String(t));
320
- underline.style.width = "".concat(mainSize, "px");
321
- underline.style.height = "".concat(t, "px");
322
- path.setAttribute('d', "M 0,".concat(t / 2, " L ").concat(mainSize, ",").concat(t / 2));
323
- }
324
- };
325
- /**
326
- * Chrome-style wrap-around underline: a stroked SVG path that runs
327
- * along the bottom (or left edge in vertical mode), curving up and
328
- * over the active tab with rounded corners.
329
- *
330
- * The SVG and path elements are created once per underline and reused;
331
- * only the `d`, `stroke`, and viewport attributes are updated each frame.
332
- */
333
- WrapTabGroupIndicator.prototype.applyShape = function (underline, tg, groupStart, groupSpan, containerCrossSize, activePanelId, containerRect, isVertical) {
334
- var t = 2; // line thickness in px
335
- var crossSize = containerCrossSize;
336
- var mainSize = groupSpan;
337
- var color = (0, tabGroupAccent_1.resolveTabGroupAccent)(tg.color, this._ctx.getColorPalette());
338
- if (mainSize <= 0 || crossSize <= 0 || color === undefined) {
339
- underline.style.display = 'none';
340
- return;
341
- }
342
- underline.style.display = '';
343
- // Find the active tab within this group
344
- var activeTabEntry;
345
- if (activePanelId && tg.panelIds.includes(activePanelId)) {
346
- activeTabEntry = this._ctx.getTabMap().get(activePanelId);
347
- }
348
- // Ensure SVG + path child exists (created once, reused)
349
- var svg = underline.firstElementChild;
350
- var path;
351
- if ((svg === null || svg === void 0 ? void 0 : svg.tagName) === 'svg') {
352
- path = svg.firstElementChild;
353
- }
354
- else {
355
- underline.replaceChildren();
356
- svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg');
357
- svg.style.display = 'block';
358
- path = document.createElementNS('http://www.w3.org/2000/svg', 'path');
359
- path.setAttribute('fill', 'none');
360
- svg.appendChild(path);
361
- underline.appendChild(svg);
362
- }
363
- path.setAttribute('stroke', color);
364
- path.setAttribute('stroke-width', String(t));
365
- if (!activeTabEntry) {
366
- this._applyStraightLine(svg, path, underline, t, mainSize, isVertical);
367
- return;
368
- }
369
- var activeRect = activeTabEntry.value.element.getBoundingClientRect();
370
- // Compute active tab start/end relative to the group start
371
- var aStart;
372
- var aEnd;
373
- if (isVertical) {
374
- aStart = Math.max(0, activeRect.top - containerRect.top - groupStart);
375
- aEnd = Math.min(mainSize, activeRect.bottom - containerRect.top - groupStart);
376
- }
377
- else {
378
- aStart = Math.max(0, activeRect.left - containerRect.left - groupStart);
379
- aEnd = Math.min(mainSize, activeRect.right - containerRect.left - groupStart);
380
- }
381
- if (aEnd <= aStart) {
382
- this._applyStraightLine(svg, path, underline, t, mainSize, isVertical);
383
- return;
384
- }
385
- var r = 6; // corner radius
386
- var half = t / 2;
387
- var headerPosition = this._ctx.getHeaderPosition();
388
- if (isVertical) {
389
- var svgW = crossSize;
390
- var svgH = mainSize;
391
- svg.setAttribute('width', String(svgW));
392
- svg.setAttribute('height', String(svgH));
393
- underline.style.width = "".concat(svgW, "px");
394
- underline.style.height = "".concat(svgH, "px");
395
- // right header: indicator on the left edge (invert x sides)
396
- var isRightHeader = headerPosition === 'right';
397
- var xNear = isRightHeader ? svgW - half : half;
398
- var xFar = isRightHeader ? half : svgW - half;
399
- var cd = isRightHeader ? -1 : 1; // curve direction
400
- var d = [
401
- "M ".concat(xNear, ",0"),
402
- "L ".concat(xNear, ",").concat(aStart - r),
403
- "Q ".concat(xNear, ",").concat(aStart, " ").concat(xNear + cd * r, ",").concat(aStart),
404
- "L ".concat(xFar - cd * r, ",").concat(aStart),
405
- "Q ".concat(xFar, ",").concat(aStart, " ").concat(xFar, ",").concat(aStart + r),
406
- "L ".concat(xFar, ",").concat(aEnd - r),
407
- "Q ".concat(xFar, ",").concat(aEnd, " ").concat(xFar - cd * r, ",").concat(aEnd),
408
- "L ".concat(xNear + cd * r, ",").concat(aEnd),
409
- "Q ".concat(xNear, ",").concat(aEnd, " ").concat(xNear, ",").concat(aEnd + r),
410
- "L ".concat(xNear, ",").concat(svgH),
411
- ].join(' ');
412
- path.setAttribute('d', d);
413
- }
414
- else {
415
- var svgW = mainSize;
416
- var svgH = crossSize;
417
- svg.setAttribute('width', String(svgW));
418
- svg.setAttribute('height', String(svgH));
419
- underline.style.width = "".concat(svgW, "px");
420
- underline.style.height = "".concat(svgH, "px");
421
- // bottom header: indicator on the top edge (invert y sides)
422
- var isBottomHeader = headerPosition === 'bottom';
423
- var yNear = isBottomHeader ? half : svgH - half;
424
- var yFar = isBottomHeader ? svgH - half : half;
425
- var cd = isBottomHeader ? 1 : -1; // curve direction
426
- var d = [
427
- "M 0,".concat(yNear),
428
- "L ".concat(aStart - r, ",").concat(yNear),
429
- "Q ".concat(aStart, ",").concat(yNear, " ").concat(aStart, ",").concat(yNear + cd * r),
430
- "L ".concat(aStart, ",").concat(yFar - cd * r),
431
- "Q ".concat(aStart, ",").concat(yFar, " ").concat(aStart + r, ",").concat(yFar),
432
- "L ".concat(aEnd - r, ",").concat(yFar),
433
- "Q ".concat(aEnd, ",").concat(yFar, " ").concat(aEnd, ",").concat(yFar - cd * r),
434
- "L ".concat(aEnd, ",").concat(yNear + cd * r),
435
- "Q ".concat(aEnd, ",").concat(yNear, " ").concat(aEnd + r, ",").concat(yNear),
436
- "L ".concat(svgW, ",").concat(yNear),
437
- ].join(' ');
438
- path.setAttribute('d', d);
439
- }
440
- };
441
- return WrapTabGroupIndicator;
442
- }(BaseTabGroupIndicator));
443
- exports.WrapTabGroupIndicator = WrapTabGroupIndicator;
444
- /**
445
- * Flat continuous bar indicator — no wrap-around, just a colored line
446
- * spanning the full tab group width.
447
- */
448
- var NoneTabGroupIndicator = /** @class */ (function (_super) {
449
- __extends(NoneTabGroupIndicator, _super);
450
- function NoneTabGroupIndicator() {
451
- return _super !== null && _super.apply(this, arguments) || this;
452
- }
453
- NoneTabGroupIndicator.prototype.applyShape = function (underline, tg, _startEdge, span, _containerCrossSize, _activePanelId, _containerRect, isVertical) {
454
- var t = 2; // line thickness in px
455
- var color = (0, tabGroupAccent_1.resolveTabGroupAccent)(tg.color, this._ctx.getColorPalette());
456
- if (span <= 0 || color === undefined) {
457
- underline.style.display = 'none';
458
- return;
459
- }
460
- underline.style.display = '';
461
- // Clear any SVG content left over from a mode switch
462
- if (underline.firstElementChild) {
463
- underline.replaceChildren();
464
- }
465
- underline.style.backgroundColor = color;
466
- if (isVertical) {
467
- underline.style.width = "".concat(t, "px");
468
- underline.style.height = "".concat(span, "px");
469
- }
470
- else {
471
- underline.style.width = "".concat(span, "px");
472
- underline.style.height = "".concat(t, "px");
473
- }
474
- };
475
- return NoneTabGroupIndicator;
476
- }(BaseTabGroupIndicator));
477
- exports.NoneTabGroupIndicator = NoneTabGroupIndicator;