flexlayout-react 0.7.15 → 0.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (252) hide show
  1. package/ChangeLog.txt +28 -0
  2. package/README.md +157 -330
  3. package/Screenshot_light.png +0 -0
  4. package/Screenshot_rounded.png +0 -0
  5. package/declarations/Attribute.d.ts +1 -1
  6. package/declarations/AttributeDefinitions.d.ts +1 -1
  7. package/declarations/DockLocation.d.ts +12 -12
  8. package/declarations/DropInfo.d.ts +12 -12
  9. package/declarations/I18nLabel.d.ts +12 -14
  10. package/declarations/Orientation.d.ts +7 -7
  11. package/declarations/PopupMenu.d.ts +1 -1
  12. package/declarations/Rect.d.ts +41 -28
  13. package/declarations/Types.d.ts +95 -79
  14. package/declarations/examples/demo/Utils.d.ts +4 -0
  15. package/declarations/index.d.ts +21 -22
  16. package/declarations/model/Action.d.ts +5 -5
  17. package/declarations/model/Actions.d.ts +127 -110
  18. package/declarations/model/BorderNode.d.ts +30 -34
  19. package/declarations/model/BorderSet.d.ts +3 -4
  20. package/declarations/model/ICloseType.d.ts +5 -5
  21. package/declarations/model/IDraggable.d.ts +2 -2
  22. package/declarations/model/IDropTarget.d.ts +2 -2
  23. package/declarations/model/IJsonModel.d.ts +811 -149
  24. package/declarations/model/LayoutWindow.d.ts +28 -0
  25. package/declarations/model/Model.d.ts +91 -86
  26. package/declarations/model/Node.d.ts +17 -17
  27. package/declarations/model/RowNode.d.ts +10 -11
  28. package/declarations/model/TabNode.d.ts +44 -37
  29. package/declarations/model/TabSetNode.d.ts +44 -41
  30. package/declarations/model/Utils.d.ts +1 -1
  31. package/declarations/model/WindowLayout.d.ts +24 -0
  32. package/declarations/src/Attribute.d.ts +1 -0
  33. package/declarations/src/AttributeDefinitions.d.ts +1 -0
  34. package/declarations/src/DockLocation.d.ts +12 -0
  35. package/declarations/src/DropInfo.d.ts +12 -0
  36. package/declarations/src/I18nLabel.d.ts +10 -0
  37. package/declarations/src/Orientation.d.ts +7 -0
  38. package/declarations/src/PopupMenu.d.ts +1 -0
  39. package/declarations/src/Rect.d.ts +31 -0
  40. package/declarations/src/Types.d.ts +92 -0
  41. package/declarations/src/index.d.ts +20 -0
  42. package/declarations/src/model/Action.d.ts +5 -0
  43. package/declarations/src/model/Actions.d.ts +110 -0
  44. package/declarations/src/model/BorderNode.d.ts +28 -0
  45. package/declarations/src/model/BorderSet.d.ts +3 -0
  46. package/declarations/src/model/ICloseType.d.ts +5 -0
  47. package/declarations/src/model/IDraggable.d.ts +2 -0
  48. package/declarations/src/model/IDropTarget.d.ts +2 -0
  49. package/declarations/src/model/IJsonModel.d.ts +153 -0
  50. package/declarations/src/model/Model.d.ts +98 -0
  51. package/declarations/src/model/Node.d.ts +16 -0
  52. package/declarations/src/model/RowNode.d.ts +11 -0
  53. package/declarations/src/model/TabNode.d.ts +36 -0
  54. package/declarations/src/model/TabSetNode.d.ts +37 -0
  55. package/declarations/src/model/Utils.d.ts +1 -0
  56. package/declarations/src/view/BorderButton.d.ts +1 -0
  57. package/declarations/src/view/BorderTab.d.ts +2 -0
  58. package/declarations/src/view/BorderTabSet.d.ts +1 -0
  59. package/declarations/src/view/DragContainer.d.ts +1 -0
  60. package/declarations/src/view/ErrorBoundary.d.ts +1 -0
  61. package/declarations/src/view/FloatingWindow.d.ts +1 -0
  62. package/declarations/src/view/Icons.d.ts +7 -0
  63. package/declarations/src/view/Layout.d.ts +113 -0
  64. package/declarations/src/view/Overlay.d.ts +1 -0
  65. package/declarations/src/view/PopupMenu.d.ts +1 -0
  66. package/declarations/src/view/Row.d.ts +1 -0
  67. package/declarations/src/view/Splitter.d.ts +1 -0
  68. package/declarations/src/view/Tab.d.ts +1 -0
  69. package/declarations/src/view/TabButton.d.ts +1 -0
  70. package/declarations/src/view/TabButtonStamp.d.ts +1 -0
  71. package/declarations/src/view/TabOverflowHook.d.ts +1 -0
  72. package/declarations/src/view/TabSet.d.ts +1 -0
  73. package/declarations/src/view/Utils.d.ts +4 -0
  74. package/declarations/view/BorderButton.d.ts +1 -1
  75. package/declarations/view/BorderTab.d.ts +2 -0
  76. package/declarations/view/BorderTabSet.d.ts +1 -1
  77. package/declarations/view/DragContainer.d.ts +1 -0
  78. package/declarations/view/ErrorBoundary.d.ts +1 -1
  79. package/declarations/view/ExtendedResizeObserver.d.ts +23 -0
  80. package/declarations/view/FloatingWindow.d.ts +1 -1
  81. package/declarations/view/Icons.d.ts +8 -7
  82. package/declarations/view/Layout.d.ts +140 -161
  83. package/declarations/view/Overlay.d.ts +1 -0
  84. package/declarations/view/PopoutWindow.d.ts +1 -0
  85. package/declarations/view/PopupMenu.d.ts +1 -0
  86. package/declarations/view/Row.d.ts +1 -0
  87. package/declarations/view/SizeTracker.d.ts +10 -0
  88. package/declarations/view/Splitter.d.ts +1 -1
  89. package/declarations/view/Tab.d.ts +1 -1
  90. package/declarations/view/TabButton.d.ts +1 -1
  91. package/declarations/view/TabButtonStamp.d.ts +1 -1
  92. package/declarations/view/TabOverflowHook.d.ts +1 -1
  93. package/declarations/view/TabSet.d.ts +1 -1
  94. package/declarations/view/Utils.d.ts +11 -1
  95. package/dist/bundles/demo.js +232052 -0
  96. package/dist/bundles/demo.js.map +1 -0
  97. package/dist/flexlayout.js +122 -92
  98. package/dist/flexlayout_min.js +1 -1
  99. package/lib/Attribute.js +42 -31
  100. package/lib/Attribute.js.map +1 -1
  101. package/lib/AttributeDefinitions.js +131 -108
  102. package/lib/AttributeDefinitions.js.map +1 -1
  103. package/lib/DockLocation.js +120 -124
  104. package/lib/DockLocation.js.map +1 -1
  105. package/lib/DropInfo.js +9 -13
  106. package/lib/DropInfo.js.map +1 -1
  107. package/lib/I18nLabel.js +13 -18
  108. package/lib/I18nLabel.js.map +1 -1
  109. package/lib/Orientation.js +22 -26
  110. package/lib/Orientation.js.map +1 -1
  111. package/lib/Rect.js +104 -72
  112. package/lib/Rect.js.map +1 -1
  113. package/lib/Types.js +96 -83
  114. package/lib/Types.js.map +1 -1
  115. package/lib/index.js +21 -38
  116. package/lib/index.js.map +1 -1
  117. package/lib/model/Action.js +6 -10
  118. package/lib/model/Action.js.map +1 -1
  119. package/lib/model/Actions.js +169 -155
  120. package/lib/model/Actions.js.map +1 -1
  121. package/lib/model/BorderNode.js +385 -406
  122. package/lib/model/BorderNode.js.map +1 -1
  123. package/lib/model/BorderSet.js +66 -121
  124. package/lib/model/BorderSet.js.map +1 -1
  125. package/lib/model/ICloseType.js +6 -9
  126. package/lib/model/ICloseType.js.map +1 -1
  127. package/lib/model/IDraggable.js +1 -2
  128. package/lib/model/IDropTarget.js +1 -2
  129. package/lib/model/IJsonModel.js +1 -2
  130. package/lib/model/LayoutWindow.js +83 -0
  131. package/lib/model/LayoutWindow.js.map +1 -0
  132. package/lib/model/Model.js +614 -496
  133. package/lib/model/Model.js.map +1 -1
  134. package/lib/model/Node.js +217 -228
  135. package/lib/model/Node.js.map +1 -1
  136. package/lib/model/RowNode.js +491 -504
  137. package/lib/model/RowNode.js.map +1 -1
  138. package/lib/model/TabNode.js +289 -184
  139. package/lib/model/TabNode.js.map +1 -1
  140. package/lib/model/TabSetNode.js +459 -446
  141. package/lib/model/TabSetNode.js.map +1 -1
  142. package/lib/model/Utils.js +47 -82
  143. package/lib/model/Utils.js.map +1 -1
  144. package/lib/view/BorderButton.js +129 -138
  145. package/lib/view/BorderButton.js.map +1 -1
  146. package/lib/view/BorderTab.js +47 -0
  147. package/lib/view/BorderTab.js.map +1 -0
  148. package/lib/view/BorderTabSet.js +134 -128
  149. package/lib/view/BorderTabSet.js.map +1 -1
  150. package/lib/view/DragContainer.js +16 -0
  151. package/lib/view/DragContainer.js.map +1 -0
  152. package/lib/view/ErrorBoundary.js +23 -27
  153. package/lib/view/ErrorBoundary.js.map +1 -1
  154. package/lib/view/Icons.js +40 -45
  155. package/lib/view/Icons.js.map +1 -1
  156. package/lib/view/Layout.js +919 -907
  157. package/lib/view/Layout.js.map +1 -1
  158. package/lib/view/Overlay.js +9 -0
  159. package/lib/view/Overlay.js.map +1 -0
  160. package/lib/view/PopoutWindow.js +129 -0
  161. package/lib/view/PopoutWindow.js.map +1 -0
  162. package/lib/view/PopupMenu.js +71 -0
  163. package/lib/view/PopupMenu.js.map +1 -0
  164. package/lib/view/Row.js +45 -0
  165. package/lib/view/Row.js.map +1 -0
  166. package/lib/view/SizeTracker.js +11 -0
  167. package/lib/view/SizeTracker.js.map +1 -0
  168. package/lib/view/Splitter.js +191 -147
  169. package/lib/view/Splitter.js.map +1 -1
  170. package/lib/view/Tab.js +86 -60
  171. package/lib/view/Tab.js.map +1 -1
  172. package/lib/view/TabButton.js +127 -135
  173. package/lib/view/TabButton.js.map +1 -1
  174. package/lib/view/TabButtonStamp.js +16 -21
  175. package/lib/view/TabButtonStamp.js.map +1 -1
  176. package/lib/view/TabOverflowHook.js +150 -149
  177. package/lib/view/TabOverflowHook.js.map +1 -1
  178. package/lib/view/TabSet.js +272 -234
  179. package/lib/view/TabSet.js.map +1 -1
  180. package/lib/view/Utils.js +126 -68
  181. package/lib/view/Utils.js.map +1 -1
  182. package/package.json +36 -30
  183. package/src/Attribute.ts +23 -0
  184. package/src/AttributeDefinitions.ts +38 -15
  185. package/src/DockLocation.ts +13 -13
  186. package/src/I18nLabel.ts +7 -9
  187. package/src/Rect.ts +53 -1
  188. package/src/Types.ts +16 -0
  189. package/src/index.ts +1 -2
  190. package/src/model/Actions.ts +49 -29
  191. package/src/model/BorderNode.ts +208 -214
  192. package/src/model/BorderSet.ts +42 -91
  193. package/src/model/IJsonModel.ts +883 -103
  194. package/src/model/LayoutWindow.ts +121 -0
  195. package/src/model/Model.ts +488 -366
  196. package/src/model/Node.ts +98 -111
  197. package/src/model/RowNode.ts +323 -319
  198. package/src/model/TabNode.ts +294 -110
  199. package/src/model/TabSetNode.ts +303 -242
  200. package/src/model/Utils.ts +6 -32
  201. package/src/view/BorderButton.tsx +36 -52
  202. package/src/view/BorderTab.tsx +70 -0
  203. package/src/view/BorderTabSet.tsx +64 -52
  204. package/src/view/DragContainer.tsx +32 -0
  205. package/src/view/Icons.tsx +6 -0
  206. package/src/view/Layout.tsx +1053 -1046
  207. package/src/view/Overlay.tsx +22 -0
  208. package/src/view/PopoutWindow.tsx +152 -0
  209. package/src/{PopupMenu.tsx → view/PopupMenu.tsx} +36 -31
  210. package/src/view/Row.tsx +68 -0
  211. package/src/view/SizeTracker.tsx +20 -0
  212. package/src/view/Splitter.tsx +167 -112
  213. package/src/view/Tab.tsx +76 -42
  214. package/src/view/TabButton.tsx +39 -54
  215. package/src/view/TabButtonStamp.tsx +5 -9
  216. package/src/view/TabOverflowHook.tsx +14 -9
  217. package/src/view/TabSet.tsx +221 -176
  218. package/src/view/Utils.tsx +119 -39
  219. package/style/_base.scss +140 -34
  220. package/style/dark.css +140 -35
  221. package/style/dark.css.map +1 -1
  222. package/style/dark.scss +3 -1
  223. package/style/gray.css +139 -34
  224. package/style/gray.css.map +1 -1
  225. package/style/gray.scss +2 -0
  226. package/style/light.css +141 -36
  227. package/style/light.css.map +1 -1
  228. package/style/light.scss +4 -2
  229. package/style/rounded.css +697 -0
  230. package/style/rounded.css.map +1 -0
  231. package/style/rounded.scss +194 -0
  232. package/style/underline.css +139 -34
  233. package/style/underline.css.map +1 -1
  234. package/style/underline.scss +2 -0
  235. package/cypress.config.ts +0 -16
  236. package/lib/DragDrop.js +0 -316
  237. package/lib/DragDrop.js.map +0 -1
  238. package/lib/PopupMenu.js +0 -68
  239. package/lib/PopupMenu.js.map +0 -1
  240. package/lib/model/SplitterNode.js +0 -72
  241. package/lib/model/SplitterNode.js.map +0 -1
  242. package/lib/view/FloatingWindow.js +0 -123
  243. package/lib/view/FloatingWindow.js.map +0 -1
  244. package/lib/view/FloatingWindowTab.js +0 -19
  245. package/lib/view/FloatingWindowTab.js.map +0 -1
  246. package/lib/view/TabFloating.js +0 -66
  247. package/lib/view/TabFloating.js.map +0 -1
  248. package/src/DragDrop.ts +0 -392
  249. package/src/model/SplitterNode.ts +0 -78
  250. package/src/view/FloatingWindow.tsx +0 -140
  251. package/src/view/FloatingWindowTab.tsx +0 -29
  252. package/src/view/TabFloating.tsx +0 -101
@@ -0,0 +1,92 @@
1
+ export declare enum CLASSES {
2
+ FLEXLAYOUT__BORDER = "flexlayout__border",
3
+ FLEXLAYOUT__BORDER_ = "flexlayout__border_",
4
+ FLEXLAYOUT__BORDER_TAB_CONTENTS = "flexlayout__border_tab_contents",
5
+ FLEXLAYOUT__BORDER_BUTTON = "flexlayout__border_button",
6
+ FLEXLAYOUT__BORDER_BUTTON_ = "flexlayout__border_button_",
7
+ FLEXLAYOUT__BORDER_BUTTON_CONTENT = "flexlayout__border_button_content",
8
+ FLEXLAYOUT__BORDER_BUTTON_LEADING = "flexlayout__border_button_leading",
9
+ FLEXLAYOUT__BORDER_BUTTON_TRAILING = "flexlayout__border_button_trailing",
10
+ FLEXLAYOUT__BORDER_BUTTON__SELECTED = "flexlayout__border_button--selected",
11
+ FLEXLAYOUT__BORDER_BUTTON__UNSELECTED = "flexlayout__border_button--unselected",
12
+ FLEXLAYOUT__BORDER_TOOLBAR_BUTTON_OVERFLOW = "flexlayout__border_toolbar_button_overflow",
13
+ FLEXLAYOUT__BORDER_TOOLBAR_BUTTON_OVERFLOW_ = "flexlayout__border_toolbar_button_overflow_",
14
+ FLEXLAYOUT__BORDER_INNER = "flexlayout__border_inner",
15
+ FLEXLAYOUT__BORDER_INNER_ = "flexlayout__border_inner_",
16
+ FLEXLAYOUT__BORDER_INNER_TAB_CONTAINER = "flexlayout__border_inner_tab_container",
17
+ FLEXLAYOUT__BORDER_INNER_TAB_CONTAINER_ = "flexlayout__border_inner_tab_container_",
18
+ FLEXLAYOUT__BORDER_TAB_DIVIDER = "flexlayout__border_tab_divider",
19
+ FLEXLAYOUT__BORDER_SIZER = "flexlayout__border_sizer",
20
+ FLEXLAYOUT__BORDER_TOOLBAR = "flexlayout__border_toolbar",
21
+ FLEXLAYOUT__BORDER_TOOLBAR_ = "flexlayout__border_toolbar_",
22
+ FLEXLAYOUT__BORDER_TOOLBAR_BUTTON = "flexlayout__border_toolbar_button",
23
+ FLEXLAYOUT__BORDER_TOOLBAR_BUTTON_FLOAT = "flexlayout__border_toolbar_button-float",
24
+ FLEXLAYOUT__DRAG_RECT = "flexlayout__drag_rect",
25
+ FLEXLAYOUT__EDGE_RECT = "flexlayout__edge_rect",
26
+ FLEXLAYOUT__EDGE_RECT_TOP = "flexlayout__edge_rect_top",
27
+ FLEXLAYOUT__EDGE_RECT_LEFT = "flexlayout__edge_rect_left",
28
+ FLEXLAYOUT__EDGE_RECT_BOTTOM = "flexlayout__edge_rect_bottom",
29
+ FLEXLAYOUT__EDGE_RECT_RIGHT = "flexlayout__edge_rect_right",
30
+ FLEXLAYOUT__ERROR_BOUNDARY_CONTAINER = "flexlayout__error_boundary_container",
31
+ FLEXLAYOUT__ERROR_BOUNDARY_CONTENT = "flexlayout__error_boundary_content",
32
+ FLEXLAYOUT__FLOATING_WINDOW_CONTENT = "flexlayout__floating_window_content",
33
+ FLEXLAYOUT__FLOATING_WINDOW_TAB = "flexlayout__floating_window_tab",
34
+ FLEXLAYOUT__LAYOUT = "flexlayout__layout",
35
+ FLEXLAYOUT__LAYOUT_PORTALS = "flexlayout__layout_portals",
36
+ FLEXLAYOUT__LAYOUT_OVERLAY = "flexlayout__layout_overlay",
37
+ FLEXLAYOUT__LAYOUT_TAB_STAMPS = "flexlayout__layout_tab_stamps",
38
+ FLEXLAYOUT__LAYOUT_MAIN = "flexlayout__layout_main",
39
+ FLEXLAYOUT__LAYOUT_BORDER_CONTAINER = "flexlayout__layout_border_container",
40
+ FLEXLAYOUT__LAYOUT_BORDER_CONTAINER_INNER = "flexlayout__layout_border_container_inner",
41
+ FLEXLAYOUT__OUTLINE_RECT = "flexlayout__outline_rect",
42
+ FLEXLAYOUT__OUTLINE_RECT_EDGE = "flexlayout__outline_rect_edge",
43
+ FLEXLAYOUT__SPLITTER = "flexlayout__splitter",
44
+ FLEXLAYOUT__SPLITTER_EXTRA = "flexlayout__splitter_extra",
45
+ FLEXLAYOUT__SPLITTER_ = "flexlayout__splitter_",
46
+ FLEXLAYOUT__SPLITTER_BORDER = "flexlayout__splitter_border",
47
+ FLEXLAYOUT__SPLITTER_DRAG = "flexlayout__splitter_drag",
48
+ FLEXLAYOUT__SPLITTER_HANDLE = "flexlayout__splitter_handle",
49
+ FLEXLAYOUT__SPLITTER_HANDLE_HORZ = "flexlayout__splitter_handle_horz",
50
+ FLEXLAYOUT__SPLITTER_HANDLE_VERT = "flexlayout__splitter_handle_vert",
51
+ FLEXLAYOUT__ROW = "flexlayout__row",
52
+ FLEXLAYOUT__TAB = "flexlayout__tab",
53
+ FLEXLAYOUT__TAB_POSITION = "flexlayout__tab_position",
54
+ FLEXLAYOUT__TAB_MOVEABLE = "flexlayout__tab_moveable",
55
+ FLEXLAYOUT__TABSET = "flexlayout__tabset",
56
+ FLEXLAYOUT__TABSET_HEADER = "flexlayout__tabset_header",
57
+ FLEXLAYOUT__TABSET_HEADER_SIZER = "flexlayout__tabset_header_sizer",
58
+ FLEXLAYOUT__TABSET_HEADER_CONTENT = "flexlayout__tabset_header_content",
59
+ FLEXLAYOUT__TABSET_MAXIMIZED = "flexlayout__tabset-maximized",
60
+ FLEXLAYOUT__TABSET_SELECTED = "flexlayout__tabset-selected",
61
+ FLEXLAYOUT__TABSET_SIZER = "flexlayout__tabset_sizer",
62
+ FLEXLAYOUT__TABSET_TAB_DIVIDER = "flexlayout__tabset_tab_divider",
63
+ FLEXLAYOUT__TABSET_CONTENT = "flexlayout__tabset_content",
64
+ FLEXLAYOUT__TABSET_TABBAR_INNER = "flexlayout__tabset_tabbar_inner",
65
+ FLEXLAYOUT__TABSET_TABBAR_INNER_ = "flexlayout__tabset_tabbar_inner_",
66
+ FLEXLAYOUT__TABSET_TABBAR_INNER_TAB_CONTAINER = "flexlayout__tabset_tabbar_inner_tab_container",
67
+ FLEXLAYOUT__TABSET_TABBAR_INNER_TAB_CONTAINER_ = "flexlayout__tabset_tabbar_inner_tab_container_",
68
+ FLEXLAYOUT__TABSET_TABBAR_OUTER = "flexlayout__tabset_tabbar_outer",
69
+ FLEXLAYOUT__TABSET_TABBAR_OUTER_ = "flexlayout__tabset_tabbar_outer_",
70
+ FLEXLAYOUT__TAB_BORDER = "flexlayout__tab_border",
71
+ FLEXLAYOUT__TAB_BORDER_ = "flexlayout__tab_border_",
72
+ FLEXLAYOUT__TAB_BUTTON = "flexlayout__tab_button",
73
+ FLEXLAYOUT__TAB_BUTTON_STRETCH = "flexlayout__tab_button_stretch",
74
+ FLEXLAYOUT__TAB_BUTTON_CONTENT = "flexlayout__tab_button_content",
75
+ FLEXLAYOUT__TAB_BUTTON_LEADING = "flexlayout__tab_button_leading",
76
+ FLEXLAYOUT__TAB_BUTTON_OVERFLOW = "flexlayout__tab_button_overflow",
77
+ FLEXLAYOUT__TAB_BUTTON_OVERFLOW_COUNT = "flexlayout__tab_button_overflow_count",
78
+ FLEXLAYOUT__TAB_BUTTON_TEXTBOX = "flexlayout__tab_button_textbox",
79
+ FLEXLAYOUT__TAB_BUTTON_TRAILING = "flexlayout__tab_button_trailing",
80
+ FLEXLAYOUT__TAB_BUTTON_STAMP = "flexlayout__tab_button_stamp",
81
+ FLEXLAYOUT__TAB_FLOATING = "flexlayout__tab_floating",
82
+ FLEXLAYOUT__TAB_FLOATING_INNER = "flexlayout__tab_floating_inner",
83
+ FLEXLAYOUT__TAB_TOOLBAR = "flexlayout__tab_toolbar",
84
+ FLEXLAYOUT__TAB_TOOLBAR_BUTTON = "flexlayout__tab_toolbar_button",
85
+ FLEXLAYOUT__TAB_TOOLBAR_BUTTON_ = "flexlayout__tab_toolbar_button-",
86
+ FLEXLAYOUT__TAB_TOOLBAR_BUTTON_FLOAT = "flexlayout__tab_toolbar_button-float",
87
+ FLEXLAYOUT__TAB_TOOLBAR_STICKY_BUTTONS_CONTAINER = "flexlayout__tab_toolbar_sticky_buttons_container",
88
+ FLEXLAYOUT__TAB_TOOLBAR_BUTTON_CLOSE = "flexlayout__tab_toolbar_button-close",
89
+ FLEXLAYOUT__POPUP_MENU_CONTAINER = "flexlayout__popup_menu_container",
90
+ FLEXLAYOUT__POPUP_MENU_ITEM = "flexlayout__popup_menu_item",
91
+ FLEXLAYOUT__POPUP_MENU = "flexlayout__popup_menu"
92
+ }
@@ -0,0 +1,20 @@
1
+ export * from './view/Layout';
2
+ export * from './model/Action';
3
+ export * from './model/Actions';
4
+ export * from './model/BorderNode';
5
+ export * from './model/BorderSet';
6
+ export * from './model/ICloseType';
7
+ export * from './model/IDraggable';
8
+ export * from './model/IDropTarget';
9
+ export * from './model/IJsonModel';
10
+ export * from './model/Model';
11
+ export * from './model/Node';
12
+ export * from './model/RowNode';
13
+ export * from './model/TabNode';
14
+ export * from './model/TabSetNode';
15
+ export * from './DockLocation';
16
+ export * from './DropInfo';
17
+ export * from './I18nLabel';
18
+ export * from './Orientation';
19
+ export * from './Rect';
20
+ export * from './Types';
@@ -0,0 +1,5 @@
1
+ export declare class Action {
2
+ type: string;
3
+ data: Record<string, any>;
4
+ constructor(type: string, data: Record<string, any>);
5
+ }
@@ -0,0 +1,110 @@
1
+ import { DockLocation } from "../DockLocation";
2
+ import { Action } from "./Action";
3
+ /**
4
+ * The Action creator class for FlexLayout model actions
5
+ */
6
+ export declare class Actions {
7
+ static ADD_NODE: string;
8
+ static MOVE_NODE: string;
9
+ static DELETE_TAB: string;
10
+ static DELETE_TABSET: string;
11
+ static RENAME_TAB: string;
12
+ static SELECT_TAB: string;
13
+ static SET_ACTIVE_TABSET: string;
14
+ static ADJUST_SPLIT: string;
15
+ static ADJUST_BORDER_SPLIT: string;
16
+ static MAXIMIZE_TOGGLE: string;
17
+ static UPDATE_MODEL_ATTRIBUTES: string;
18
+ static UPDATE_NODE_ATTRIBUTES: string;
19
+ static POPOUT_TAB: string;
20
+ static CLOSE_WINDOW: string;
21
+ /**
22
+ * Adds a tab node to the given tabset node
23
+ * @param json the json for the new tab node e.g {type:"tab", component:"table"}
24
+ * @param toNodeId the new tab node will be added to the tabset with this node id
25
+ * @param location the location where the new tab will be added, one of the DockLocation enum values.
26
+ * @param index for docking to the center this value is the index of the tab, use -1 to add to the end.
27
+ * @param select (optional) whether to select the new tab, overriding autoSelectTab
28
+ * @returns {Action} the action
29
+ */
30
+ static addNode(json: any, toNodeId: string, location: DockLocation, index: number, select?: boolean): Action;
31
+ /**
32
+ * Moves a node (tab or tabset) from one location to another
33
+ * @param fromNodeId the id of the node to move
34
+ * @param toNodeId the id of the node to receive the moved node
35
+ * @param location the location where the moved node will be added, one of the DockLocation enum values.
36
+ * @param index for docking to the center this value is the index of the tab, use -1 to add to the end.
37
+ * @param select (optional) whether to select the moved tab(s) in new tabset, overriding autoSelectTab
38
+ * @returns {Action} the action
39
+ */
40
+ static moveNode(fromNodeId: string, toNodeId: string, location: DockLocation, index: number, select?: boolean): Action;
41
+ /**
42
+ * Deletes a tab node from the layout
43
+ * @param tabsetNodeId the id of the tab node to delete
44
+ * @returns {Action} the action
45
+ */
46
+ static deleteTab(tabNodeId: string): Action;
47
+ /**
48
+ * Deletes a tabset node and all it's child tab nodes from the layout
49
+ * @param tabsetNodeId the id of the tabset node to delete
50
+ * @returns {Action} the action
51
+ */
52
+ static deleteTabset(tabsetNodeId: string): Action;
53
+ /**
54
+ * Change the given nodes tab text
55
+ * @param tabNodeId the id of the node to rename
56
+ * @param text the test of the tab
57
+ * @returns {Action} the action
58
+ */
59
+ static renameTab(tabNodeId: string, text: string): Action;
60
+ /**
61
+ * Selects the given tab in its parent tabset
62
+ * @param tabNodeId the id of the node to set selected
63
+ * @returns {Action} the action
64
+ */
65
+ static selectTab(tabNodeId: string): Action;
66
+ /**
67
+ * Set the given tabset node as the active tabset
68
+ * @param tabsetNodeId the id of the tabset node to set as active
69
+ * @returns {Action} the action
70
+ */
71
+ static setActiveTabset(tabsetNodeId: string | undefined, windowId?: string | undefined): Action;
72
+ /**
73
+ * Adjust the splitter between two tabsets
74
+ * @example
75
+ * Actions.adjustSplit({node1: "1", weight1:30, pixelWidth1:300, node2: "2", weight2:70, pixelWidth2:700});
76
+ *
77
+ * @param splitSpec an object the defines the new split between two tabsets, see example below.
78
+ * @returns {Action} the action
79
+ */
80
+ static adjustSplit(splitSpec: {
81
+ node1Id: string;
82
+ weight1: number;
83
+ pixelWidth1: number;
84
+ node2Id: string;
85
+ weight2: number;
86
+ pixelWidth2: number;
87
+ }): Action;
88
+ static adjustBorderSplit(nodeId: string, pos: number): Action;
89
+ /**
90
+ * Maximizes the given tabset
91
+ * @param tabsetNodeId the id of the tabset to maximize
92
+ * @returns {Action} the action
93
+ */
94
+ static maximizeToggle(tabsetNodeId: string, windowId?: string | undefined): Action;
95
+ /**
96
+ * Updates the global model jsone attributes
97
+ * @param attributes the json for the model attributes to update (merge into the existing attributes)
98
+ * @returns {Action} the action
99
+ */
100
+ static updateModelAttributes(attributes: any): Action;
101
+ /**
102
+ * Updates the given nodes json attributes
103
+ * @param nodeId the id of the node to update
104
+ * @param attributes the json attributes to update (merge with the existing attributes)
105
+ * @returns {Action} the action
106
+ */
107
+ static updateNodeAttributes(nodeId: string, attributes: any): Action;
108
+ static popoutTab(nodeId: string): Action;
109
+ static closeWindow(windowId: string): Action;
110
+ }
@@ -0,0 +1,28 @@
1
+ import { DockLocation } from "../DockLocation";
2
+ import { Orientation } from "../Orientation";
3
+ import { IDropTarget } from "./IDropTarget";
4
+ import { IJsonBorderNode } from "./IJsonModel";
5
+ import { Node } from "./Node";
6
+ import { TabNode } from "./TabNode";
7
+ export declare class BorderNode extends Node implements IDropTarget {
8
+ static readonly TYPE = "border";
9
+ getLocation(): DockLocation;
10
+ getClassName(): string | undefined;
11
+ getBorderBarSize(): number;
12
+ getSize(): any;
13
+ getMinSize(): number;
14
+ getSelected(): number;
15
+ getSelectedNode(): TabNode | undefined;
16
+ getOrientation(): Orientation;
17
+ /**
18
+ * Returns the config attribute that can be used to store node specific data that
19
+ * WILL be saved to the json. The config attribute should be changed via the action Actions.updateNodeAttributes rather
20
+ * than directly, for example:
21
+ * this.state.model.doAction(
22
+ * FlexLayout.Actions.updateNodeAttributes(node.getId(), {config:myConfigObject}));
23
+ */
24
+ getConfig(): any;
25
+ isMaximized(): boolean;
26
+ isShowing(): boolean;
27
+ toJson(): IJsonBorderNode;
28
+ }
@@ -0,0 +1,3 @@
1
+ export declare class BorderSet {
2
+ toJson(): import("./IJsonModel").IJsonBorderNode[];
3
+ }
@@ -0,0 +1,5 @@
1
+ export declare enum ICloseType {
2
+ Visible = 1,
3
+ Always = 2,
4
+ Selected = 3
5
+ }
@@ -0,0 +1,2 @@
1
+ export interface IDraggable {
2
+ }
@@ -0,0 +1,2 @@
1
+ export interface IDropTarget {
2
+ }
@@ -0,0 +1,153 @@
1
+ import { ICloseType } from './ICloseType';
2
+ export type IBorderLocation = "top" | "bottom" | "left" | "right";
3
+ export type ITabLocation = "top" | "bottom";
4
+ export type IInsets = {
5
+ "top": number;
6
+ "right": number;
7
+ "bottom": number;
8
+ "left": number;
9
+ };
10
+ export interface IJsonModel {
11
+ global?: IGlobalAttributes;
12
+ borders?: IJsonBorderNode[];
13
+ layout: IJsonRowNode;
14
+ popouts: Record<string, IJsonPopout>;
15
+ }
16
+ export interface IJsonPopout {
17
+ layout: IJsonRowNode;
18
+ }
19
+ export interface IJsonBorderNode extends IBorderAttributes {
20
+ location: IBorderLocation;
21
+ children: IJsonTabNode[];
22
+ }
23
+ export interface IJsonRowNode extends IRowAttributes {
24
+ children: (IJsonRowNode | IJsonTabSetNode)[];
25
+ }
26
+ export interface IJsonTabSetNode extends ITabSetAttributes {
27
+ active?: boolean;
28
+ maximized?: boolean;
29
+ children: IJsonTabNode[];
30
+ }
31
+ export interface IJsonTabNode extends ITabAttributes {
32
+ }
33
+ export interface IGlobalAttributes {
34
+ borderAutoSelectTabWhenClosed?: boolean;
35
+ borderAutoSelectTabWhenOpen?: boolean;
36
+ borderBarSize?: number;
37
+ borderClassName?: string;
38
+ borderEnableAutoHide?: boolean;
39
+ borderEnableDrop?: boolean;
40
+ borderMinSize?: number;
41
+ borderSize?: number;
42
+ enableEdgeDock?: boolean;
43
+ enableRotateBorderIcons?: boolean;
44
+ enableUseVisibility?: boolean;
45
+ legacyOverflowMenu?: boolean;
46
+ marginInsets?: IInsets;
47
+ rootOrientationVertical?: boolean;
48
+ splitterExtra?: number;
49
+ splitterSize?: number;
50
+ tabBorderHeight?: number;
51
+ tabBorderWidth?: number;
52
+ tabClassName?: string;
53
+ tabCloseType?: ICloseType;
54
+ tabContentClassName?: string;
55
+ tabDragSpeed?: number;
56
+ tabEnableClose?: boolean;
57
+ tabEnableDrag?: boolean;
58
+ tabEnableFloat?: boolean;
59
+ tabEnableRename?: boolean;
60
+ tabEnableRenderOnDemand?: boolean;
61
+ tabIcon?: string;
62
+ tabSetAutoSelectTab?: boolean;
63
+ tabSetBorderInsets?: IInsets;
64
+ tabSetClassNameHeader?: string;
65
+ tabSetClassNameTabStrip?: string;
66
+ tabSetEnableClose?: boolean;
67
+ tabSetEnableDeleteWhenEmpty?: boolean;
68
+ tabSetEnableDivide?: boolean;
69
+ tabSetEnableDrag?: boolean;
70
+ tabSetEnableDrop?: boolean;
71
+ tabSetEnableMaximize?: boolean;
72
+ tabSetEnableSingleTabStretch?: boolean;
73
+ tabSetEnableTabStrip?: boolean;
74
+ tabSetHeaderHeight?: number;
75
+ tabSetMarginInsets?: IInsets;
76
+ tabSetMinHeight?: number;
77
+ tabSetMinWidth?: number;
78
+ tabSetTabLocation?: ITabLocation;
79
+ tabSetTabStripHeight?: number;
80
+ }
81
+ export interface IRowAttributes {
82
+ height?: number;
83
+ id?: string;
84
+ type: "row";
85
+ weight?: number;
86
+ width?: number;
87
+ }
88
+ export interface ITabSetAttributes {
89
+ autoSelectTab?: boolean;
90
+ borderInsets?: IInsets;
91
+ classNameHeader?: string;
92
+ classNameTabStrip?: string;
93
+ config?: any;
94
+ enableClose?: boolean;
95
+ enableDeleteWhenEmpty?: boolean;
96
+ enableDivide?: boolean;
97
+ enableDrag?: boolean;
98
+ enableDrop?: boolean;
99
+ enableMaximize?: boolean;
100
+ enableSingleTabStretch?: boolean;
101
+ enableTabStrip?: boolean;
102
+ headerHeight?: number;
103
+ height?: number;
104
+ id?: string;
105
+ marginInsets?: IInsets;
106
+ minHeight?: number;
107
+ minWidth?: number;
108
+ name?: string;
109
+ selected?: number;
110
+ tabLocation?: ITabLocation;
111
+ tabStripHeight?: number;
112
+ type: "tabset";
113
+ weight?: number;
114
+ width?: number;
115
+ maximized?: boolean;
116
+ active?: boolean;
117
+ }
118
+ export interface ITabAttributes {
119
+ altName?: string;
120
+ borderHeight?: number;
121
+ borderWidth?: number;
122
+ className?: string;
123
+ closeType?: ICloseType;
124
+ component?: string;
125
+ config?: any;
126
+ contentClassName?: string;
127
+ tabsetClassName?: string;
128
+ enableClose?: boolean;
129
+ enableDrag?: boolean;
130
+ enableFloat?: boolean;
131
+ enableRename?: boolean;
132
+ enableRenderOnDemand?: boolean;
133
+ floating?: boolean;
134
+ helpText?: string;
135
+ icon?: string;
136
+ id?: string;
137
+ name?: string;
138
+ type?: string;
139
+ }
140
+ export interface IBorderAttributes {
141
+ autoSelectTabWhenClosed?: boolean;
142
+ autoSelectTabWhenOpen?: boolean;
143
+ barSize?: number;
144
+ className?: string;
145
+ config?: any;
146
+ enableAutoHide?: boolean;
147
+ enableDrop?: boolean;
148
+ minSize?: number;
149
+ selected?: number;
150
+ show?: boolean;
151
+ size?: number;
152
+ type: "border";
153
+ }
@@ -0,0 +1,98 @@
1
+ import { DropInfo } from "../DropInfo";
2
+ import { Action } from "./Action";
3
+ import { BorderSet } from "./BorderSet";
4
+ import { IJsonModel, IJsonPopout, ITabSetAttributes } from "./IJsonModel";
5
+ import { Node } from "./Node";
6
+ import { RowNode } from "./RowNode";
7
+ import { TabNode } from "./TabNode";
8
+ import { TabSetNode } from "./TabSetNode";
9
+ export declare class WindowLayout {
10
+ windowId: string;
11
+ window?: Window;
12
+ root?: RowNode;
13
+ maximizedTabSet?: TabSetNode;
14
+ activeTabSet?: TabSetNode;
15
+ constructor(windowId: string);
16
+ visitNodes(fn: (node: Node, level: number) => void): void;
17
+ toJson(): IJsonPopout;
18
+ static fromJson(windowJson: IJsonPopout, model: Model, windowId: string): WindowLayout;
19
+ }
20
+ /**
21
+ * Class containing the Tree of Nodes used by the FlexLayout component
22
+ */
23
+ export declare class Model {
24
+ static ROOT_WINDOW_ID: string;
25
+ /**
26
+ * Loads the model from the given json object
27
+ * @param json the json model to load
28
+ * @returns {Model} a new Model object
29
+ */
30
+ static fromJson(json: IJsonModel): Model;
31
+ /**
32
+ * Get the currently active tabset node
33
+ */
34
+ getActiveTabset(windowId: string): TabSetNode | undefined;
35
+ /**
36
+ * Get the currently maximized tabset node
37
+ */
38
+ getMaximizedTabset(windowId: string): TabSetNode | undefined;
39
+ /**
40
+ * Gets the root RowNode of the model
41
+ * @returns {RowNode}
42
+ */
43
+ getRoot(windowId: string): RowNode;
44
+ isRootOrientationVertical(): boolean;
45
+ isEnableRotateBorderIcons(): boolean;
46
+ /**
47
+ * Gets the
48
+ * @returns {BorderSet|*}
49
+ */
50
+ getBorderSet(): BorderSet;
51
+ getwindowsMap(): Map<string, WindowLayout>;
52
+ /**
53
+ * Visits all the nodes in the model and calls the given function for each
54
+ * @param fn a function that takes visited node and a integer level as parameters
55
+ */
56
+ visitNodes(fn: (node: Node, level: number) => void): void;
57
+ /**
58
+ * Gets a node by its id
59
+ * @param id the id to find
60
+ */
61
+ getNodeById(id: string): Node | undefined;
62
+ /**
63
+ * Finds the first/top left tab set of the given node.
64
+ * @param node The top node you want to begin searching from, deafults to the root node
65
+ * @returns The first Tab Set
66
+ */
67
+ getFirstTabSet(node?: Node): Node;
68
+ /**
69
+ * Update the node tree by performing the given action,
70
+ * Actions should be generated via static methods on the Actions class
71
+ * @param action the action to perform
72
+ * @returns added Node for Actions.addNode; undefined otherwise
73
+ */
74
+ doAction(action: Action): Node | undefined;
75
+ /**
76
+ * Converts the model to a json object
77
+ * @returns {IJsonModel} json object that represents this model
78
+ */
79
+ toJson(): IJsonModel;
80
+ getSplitterSize(): number;
81
+ isLegacyOverflowMenu(): boolean;
82
+ getSplitterExtra(): number;
83
+ isEnableEdgeDock(): boolean;
84
+ /**
85
+ * Sets a function to allow/deny dropping a node
86
+ * @param onAllowDrop function that takes the drag node and DropInfo and returns true if the drop is allowed
87
+ */
88
+ setOnAllowDrop(onAllowDrop: (dragNode: Node, dropInfo: DropInfo) => boolean): void;
89
+ /**
90
+ * set callback called when a new TabSet is created.
91
+ * The tabNode can be undefined if it's the auto created first tabset in the root row (when the last
92
+ * tab is deleted, the root tabset can be recreated)
93
+ * @param onCreateTabSet
94
+ */
95
+ setOnCreateTabSet(onCreateTabSet: (tabNode?: TabNode) => ITabSetAttributes): void;
96
+ static toTypescriptInterfaces(): void;
97
+ toString(): string;
98
+ }
@@ -0,0 +1,16 @@
1
+ import { Orientation } from "../Orientation";
2
+ import { Rect } from "../Rect";
3
+ import { IJsonBorderNode, IJsonRowNode, IJsonTabNode, IJsonTabSetNode } from "./IJsonModel";
4
+ import { Model } from "./Model";
5
+ export declare abstract class Node {
6
+ getId(): string;
7
+ getModel(): Model;
8
+ getType(): string;
9
+ getParent(): Node | undefined;
10
+ getChildren(): Node[];
11
+ getRect(): Rect;
12
+ getOrientation(): Orientation;
13
+ setEventListener(event: string, callback: (params: any) => void): void;
14
+ removeEventListener(event: string): void;
15
+ abstract toJson(): IJsonRowNode | IJsonBorderNode | IJsonTabSetNode | IJsonTabNode | undefined;
16
+ }
@@ -0,0 +1,11 @@
1
+ import { IDropTarget } from "./IDropTarget";
2
+ import { IJsonRowNode } from "./IJsonModel";
3
+ import { Node } from "./Node";
4
+ export declare class RowNode extends Node implements IDropTarget {
5
+ static readonly TYPE = "row";
6
+ getWeight(): number;
7
+ getWidth(): number | undefined;
8
+ getHeight(): number | undefined;
9
+ toJson(): IJsonRowNode;
10
+ setWindowId(windowId: string): void;
11
+ }
@@ -0,0 +1,36 @@
1
+ import { IDraggable } from "./IDraggable";
2
+ import { IJsonTabNode } from "./IJsonModel";
3
+ import { Node } from "./Node";
4
+ export declare class TabNode extends Node implements IDraggable {
5
+ static readonly TYPE = "tab";
6
+ getName(): string;
7
+ isHoisted(): boolean;
8
+ getHelpText(): string | undefined;
9
+ getComponent(): string | undefined;
10
+ /**
11
+ * Returns the config attribute that can be used to store node specific data that
12
+ * WILL be saved to the json. The config attribute should be changed via the action Actions.updateNodeAttributes rather
13
+ * than directly, for example:
14
+ * this.state.model.doAction(
15
+ * FlexLayout.Actions.updateNodeAttributes(node.getId(), {config:myConfigObject}));
16
+ */
17
+ getConfig(): any;
18
+ /**
19
+ * Returns an object that can be used to store transient node specific data that will
20
+ * NOT be saved in the json.
21
+ */
22
+ getExtraData(): Record<string, any>;
23
+ isPoppedOut(): boolean;
24
+ isSelected(): boolean;
25
+ getIcon(): string | undefined;
26
+ isEnableClose(): boolean;
27
+ getCloseType(): number;
28
+ isEnablePopout(): boolean;
29
+ isEnableDrag(): boolean;
30
+ isEnableRename(): boolean;
31
+ getClassName(): string | undefined;
32
+ getContentClassName(): string | undefined;
33
+ getTabSetClassName(): string | undefined;
34
+ isEnableRenderOnDemand(): boolean;
35
+ toJson(): IJsonTabNode;
36
+ }
@@ -0,0 +1,37 @@
1
+ import { IDraggable } from "./IDraggable";
2
+ import { IDropTarget } from "./IDropTarget";
3
+ import { IJsonTabSetNode } from "./IJsonModel";
4
+ import { Node } from "./Node";
5
+ export declare class TabSetNode extends Node implements IDraggable, IDropTarget {
6
+ static readonly TYPE = "tabset";
7
+ getName(): string | undefined;
8
+ getSelected(): number;
9
+ getSelectedNode(): Node | undefined;
10
+ getWeight(): number;
11
+ getWidth(): number | undefined;
12
+ getMinWidth(): number;
13
+ getHeight(): number | undefined;
14
+ getMinHeight(): number;
15
+ /**
16
+ * Returns the config attribute that can be used to store node specific data that
17
+ * WILL be saved to the json. The config attribute should be changed via the action Actions.updateNodeAttributes rather
18
+ * than directly, for example:
19
+ * this.state.model.doAction(
20
+ * FlexLayout.Actions.updateNodeAttributes(node.getId(), {config:myConfigObject}));
21
+ */
22
+ getConfig(): any;
23
+ isMaximized(): boolean;
24
+ isActive(): boolean;
25
+ isEnableDeleteWhenEmpty(): boolean;
26
+ isEnableDrop(): boolean;
27
+ isEnableDrag(): boolean;
28
+ isEnableDivide(): boolean;
29
+ isEnableMaximize(): boolean;
30
+ isEnableClose(): boolean;
31
+ isEnableSingleTabStretch(): boolean;
32
+ isEnableTabStrip(): boolean;
33
+ isAutoSelectTab(): boolean;
34
+ getClassNameTabStrip(): string | undefined;
35
+ getTabLocation(): string;
36
+ toJson(): IJsonTabSetNode;
37
+ }
@@ -0,0 +1 @@
1
+ export declare function randomUUID(): any;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,2 @@
1
+ import * as React from "react";
2
+ export declare function BorderTab(props: IBorderTabProps): React.JSX.Element;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,7 @@
1
+ import * as React from "react";
2
+ export declare const CloseIcon: () => React.JSX.Element;
3
+ export declare const MaximizeIcon: () => React.JSX.Element;
4
+ export declare const OverflowIcon: () => React.JSX.Element;
5
+ export declare const EdgeIcon: () => React.JSX.Element;
6
+ export declare const PopoutIcon: () => React.JSX.Element;
7
+ export declare const RestoreIcon: () => React.JSX.Element;