dockview-core 1.7.6 → 1.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.
- package/README.md +2 -1
- package/dist/cjs/api/component.api.d.ts +6 -1
- package/dist/cjs/api/component.api.d.ts.map +1 -1
- package/dist/cjs/api/component.api.js +6 -0
- package/dist/cjs/api/component.api.js.map +1 -1
- package/dist/cjs/api/dockviewGroupPanelApi.d.ts +30 -0
- package/dist/cjs/api/dockviewGroupPanelApi.d.ts.map +1 -0
- package/dist/cjs/api/dockviewGroupPanelApi.js +54 -0
- package/dist/cjs/api/dockviewGroupPanelApi.js.map +1 -0
- package/dist/cjs/api/dockviewPanelApi.d.ts +14 -1
- package/dist/cjs/api/dockviewPanelApi.d.ts.map +1 -1
- package/dist/cjs/api/dockviewPanelApi.js +6 -1
- package/dist/cjs/api/dockviewPanelApi.js.map +1 -1
- package/dist/cjs/array.d.ts +1 -0
- package/dist/cjs/array.d.ts.map +1 -1
- package/dist/cjs/array.js +10 -1
- package/dist/cjs/array.js.map +1 -1
- package/dist/cjs/dnd/abstractDragHandler.d.ts +1 -0
- package/dist/cjs/dnd/abstractDragHandler.d.ts.map +1 -1
- package/dist/cjs/dnd/abstractDragHandler.js +7 -0
- package/dist/cjs/dnd/abstractDragHandler.js.map +1 -1
- package/dist/cjs/dnd/droptarget.d.ts +11 -0
- package/dist/cjs/dnd/droptarget.d.ts.map +1 -1
- package/dist/cjs/dnd/droptarget.js +32 -9
- package/dist/cjs/dnd/droptarget.js.map +1 -1
- package/dist/cjs/dnd/groupDragHandler.d.ts +1 -0
- package/dist/cjs/dnd/groupDragHandler.d.ts.map +1 -1
- package/dist/cjs/dnd/groupDragHandler.js +18 -0
- package/dist/cjs/dnd/groupDragHandler.js.map +1 -1
- package/dist/cjs/dnd/overlay.d.ts +40 -0
- package/dist/cjs/dnd/overlay.d.ts.map +1 -0
- package/dist/cjs/dnd/overlay.js +382 -0
- package/dist/cjs/dnd/overlay.js.map +1 -0
- package/dist/cjs/dockview/components/tab/tab.d.ts +2 -2
- package/dist/cjs/dockview/components/tab/tab.d.ts.map +1 -1
- package/dist/cjs/dockview/components/tab/tab.js +0 -7
- package/dist/cjs/dockview/components/tab/tab.js.map +1 -1
- package/dist/cjs/dockview/components/titlebar/tabsContainer.d.ts +8 -4
- package/dist/cjs/dockview/components/titlebar/tabsContainer.d.ts.map +1 -1
- package/dist/cjs/dockview/components/titlebar/tabsContainer.js +54 -10
- package/dist/cjs/dockview/components/titlebar/tabsContainer.js.map +1 -1
- package/dist/cjs/dockview/deserializer.d.ts +2 -2
- package/dist/cjs/dockview/deserializer.d.ts.map +1 -1
- package/dist/cjs/dockview/deserializer.js.map +1 -1
- package/dist/cjs/dockview/dockviewComponent.d.ts +41 -9
- package/dist/cjs/dockview/dockviewComponent.d.ts.map +1 -1
- package/dist/cjs/dockview/dockviewComponent.js +285 -76
- package/dist/cjs/dockview/dockviewComponent.js.map +1 -1
- package/dist/cjs/dockview/dockviewFloatingGroupPanel.d.ts +24 -0
- package/dist/cjs/dockview/dockviewFloatingGroupPanel.d.ts.map +1 -0
- package/dist/cjs/dockview/dockviewFloatingGroupPanel.js +35 -0
- package/dist/cjs/dockview/dockviewFloatingGroupPanel.js.map +1 -0
- package/dist/cjs/dockview/dockviewGroupPanel.d.ts +5 -6
- package/dist/cjs/dockview/dockviewGroupPanel.d.ts.map +1 -1
- package/dist/cjs/dockview/dockviewGroupPanel.js +3 -2
- package/dist/cjs/dockview/dockviewGroupPanel.js.map +1 -1
- package/dist/cjs/dockview/dockviewGroupPanelModel.d.ts +5 -1
- package/dist/cjs/dockview/dockviewGroupPanelModel.d.ts.map +1 -1
- package/dist/cjs/dockview/dockviewGroupPanelModel.js +43 -12
- package/dist/cjs/dockview/dockviewGroupPanelModel.js.map +1 -1
- package/dist/cjs/dockview/dockviewPanel.d.ts +2 -2
- package/dist/cjs/dockview/dockviewPanel.d.ts.map +1 -1
- package/dist/cjs/dockview/dockviewPanel.js +1 -1
- package/dist/cjs/dockview/dockviewPanel.js.map +1 -1
- package/dist/cjs/dockview/options.d.ts +22 -6
- package/dist/cjs/dockview/options.d.ts.map +1 -1
- package/dist/cjs/dockview/options.js.map +1 -1
- package/dist/cjs/dom.d.ts +5 -3
- package/dist/cjs/dom.d.ts.map +1 -1
- package/dist/cjs/dom.js +13 -1
- package/dist/cjs/dom.js.map +1 -1
- package/dist/cjs/events.d.ts.map +1 -1
- package/dist/cjs/gridview/branchNode.js +2 -2
- package/dist/cjs/gridview/branchNode.js.map +1 -1
- package/dist/cjs/gridview/gridview.d.ts.map +1 -1
- package/dist/cjs/gridview/gridview.js +9 -7
- package/dist/cjs/gridview/gridview.js.map +1 -1
- package/dist/cjs/gridview/gridviewComponent.d.ts.map +1 -1
- package/dist/cjs/gridview/gridviewComponent.js +4 -1
- package/dist/cjs/gridview/gridviewComponent.js.map +1 -1
- package/dist/cjs/gridview/gridviewPanel.d.ts +3 -3
- package/dist/cjs/gridview/gridviewPanel.d.ts.map +1 -1
- package/dist/cjs/gridview/gridviewPanel.js +2 -2
- package/dist/cjs/gridview/gridviewPanel.js.map +1 -1
- package/dist/cjs/index.d.ts +1 -1
- package/dist/cjs/index.d.ts.map +1 -1
- package/dist/cjs/index.js +1 -3
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/math.d.ts.map +1 -1
- package/dist/cjs/paneview/paneviewComponent.d.ts.map +1 -1
- package/dist/cjs/paneview/paneviewComponent.js +4 -1
- package/dist/cjs/paneview/paneviewComponent.js.map +1 -1
- package/dist/cjs/splitview/splitviewComponent.d.ts.map +1 -1
- package/dist/cjs/splitview/splitviewComponent.js +4 -1
- package/dist/cjs/splitview/splitviewComponent.js.map +1 -1
- package/dist/dockview-core.amd.js +772 -133
- package/dist/dockview-core.amd.js.map +1 -0
- package/dist/dockview-core.amd.min.js +3 -2
- package/dist/dockview-core.amd.min.js.map +1 -0
- package/dist/dockview-core.amd.min.noStyle.js +3 -2
- package/dist/dockview-core.amd.min.noStyle.js.map +1 -0
- package/dist/dockview-core.amd.noStyle.js +771 -132
- package/dist/dockview-core.amd.noStyle.js.map +1 -0
- package/dist/dockview-core.cjs.js +772 -133
- package/dist/dockview-core.cjs.js.map +1 -0
- package/dist/dockview-core.esm.js +773 -133
- package/dist/dockview-core.esm.js.map +1 -0
- package/dist/dockview-core.esm.min.js +3 -2
- package/dist/dockview-core.esm.min.js.map +1 -0
- package/dist/dockview-core.js +772 -133
- package/dist/dockview-core.js.map +1 -0
- package/dist/dockview-core.min.js +3 -2
- package/dist/dockview-core.min.js.map +1 -0
- package/dist/dockview-core.min.noStyle.js +3 -2
- package/dist/dockview-core.min.noStyle.js.map +1 -0
- package/dist/dockview-core.noStyle.js +771 -132
- package/dist/dockview-core.noStyle.js.map +1 -0
- package/dist/esm/api/component.api.d.ts +6 -1
- package/dist/esm/api/component.api.d.ts.map +1 -1
- package/dist/esm/api/component.api.js +6 -0
- package/dist/esm/api/component.api.js.map +1 -1
- package/dist/esm/api/dockviewGroupPanelApi.d.ts +30 -0
- package/dist/esm/api/dockviewGroupPanelApi.d.ts.map +1 -0
- package/dist/esm/api/dockviewGroupPanelApi.js +28 -0
- package/dist/esm/api/dockviewGroupPanelApi.js.map +1 -0
- package/dist/esm/api/dockviewPanelApi.d.ts +14 -1
- package/dist/esm/api/dockviewPanelApi.d.ts.map +1 -1
- package/dist/esm/api/dockviewPanelApi.js +6 -1
- package/dist/esm/api/dockviewPanelApi.js.map +1 -1
- package/dist/esm/array.d.ts +1 -0
- package/dist/esm/array.d.ts.map +1 -1
- package/dist/esm/array.js +8 -0
- package/dist/esm/array.js.map +1 -1
- package/dist/esm/dnd/abstractDragHandler.d.ts +1 -0
- package/dist/esm/dnd/abstractDragHandler.d.ts.map +1 -1
- package/dist/esm/dnd/abstractDragHandler.js +7 -0
- package/dist/esm/dnd/abstractDragHandler.js.map +1 -1
- package/dist/esm/dnd/droptarget.d.ts +11 -0
- package/dist/esm/dnd/droptarget.d.ts.map +1 -1
- package/dist/esm/dnd/droptarget.js +32 -9
- package/dist/esm/dnd/droptarget.js.map +1 -1
- package/dist/esm/dnd/groupDragHandler.d.ts +1 -0
- package/dist/esm/dnd/groupDragHandler.d.ts.map +1 -1
- package/dist/esm/dnd/groupDragHandler.js +18 -0
- package/dist/esm/dnd/groupDragHandler.js.map +1 -1
- package/dist/esm/dnd/overlay.d.ts +40 -0
- package/dist/esm/dnd/overlay.d.ts.map +1 -0
- package/dist/esm/dnd/overlay.js +282 -0
- package/dist/esm/dnd/overlay.js.map +1 -0
- package/dist/esm/dockview/components/tab/tab.d.ts +2 -2
- package/dist/esm/dockview/components/tab/tab.d.ts.map +1 -1
- package/dist/esm/dockview/components/tab/tab.js +0 -7
- package/dist/esm/dockview/components/tab/tab.js.map +1 -1
- package/dist/esm/dockview/components/titlebar/tabsContainer.d.ts +8 -4
- package/dist/esm/dockview/components/titlebar/tabsContainer.d.ts.map +1 -1
- package/dist/esm/dockview/components/titlebar/tabsContainer.js +54 -10
- package/dist/esm/dockview/components/titlebar/tabsContainer.js.map +1 -1
- package/dist/esm/dockview/deserializer.d.ts +2 -2
- package/dist/esm/dockview/deserializer.d.ts.map +1 -1
- package/dist/esm/dockview/deserializer.js.map +1 -1
- package/dist/esm/dockview/dockviewComponent.d.ts +41 -9
- package/dist/esm/dockview/dockviewComponent.d.ts.map +1 -1
- package/dist/esm/dockview/dockviewComponent.js +231 -54
- package/dist/esm/dockview/dockviewComponent.js.map +1 -1
- package/dist/esm/dockview/dockviewFloatingGroupPanel.d.ts +24 -0
- package/dist/esm/dockview/dockviewFloatingGroupPanel.d.ts.map +1 -0
- package/dist/esm/dockview/dockviewFloatingGroupPanel.js +13 -0
- package/dist/esm/dockview/dockviewFloatingGroupPanel.js.map +1 -0
- package/dist/esm/dockview/dockviewGroupPanel.d.ts +5 -6
- package/dist/esm/dockview/dockviewGroupPanel.d.ts.map +1 -1
- package/dist/esm/dockview/dockviewGroupPanel.js +3 -2
- package/dist/esm/dockview/dockviewGroupPanel.js.map +1 -1
- package/dist/esm/dockview/dockviewGroupPanelModel.d.ts +5 -1
- package/dist/esm/dockview/dockviewGroupPanelModel.d.ts.map +1 -1
- package/dist/esm/dockview/dockviewGroupPanelModel.js +36 -9
- package/dist/esm/dockview/dockviewGroupPanelModel.js.map +1 -1
- package/dist/esm/dockview/dockviewPanel.d.ts +2 -2
- package/dist/esm/dockview/dockviewPanel.d.ts.map +1 -1
- package/dist/esm/dockview/dockviewPanel.js +1 -1
- package/dist/esm/dockview/dockviewPanel.js.map +1 -1
- package/dist/esm/dockview/options.d.ts +22 -6
- package/dist/esm/dockview/options.d.ts.map +1 -1
- package/dist/esm/dockview/options.js.map +1 -1
- package/dist/esm/dom.d.ts +5 -3
- package/dist/esm/dom.d.ts.map +1 -1
- package/dist/esm/dom.js +10 -0
- package/dist/esm/dom.js.map +1 -1
- package/dist/esm/events.d.ts.map +1 -1
- package/dist/esm/gridview/branchNode.js +2 -2
- package/dist/esm/gridview/branchNode.js.map +1 -1
- package/dist/esm/gridview/gridview.d.ts.map +1 -1
- package/dist/esm/gridview/gridview.js +9 -6
- package/dist/esm/gridview/gridview.js.map +1 -1
- package/dist/esm/gridview/gridviewComponent.d.ts.map +1 -1
- package/dist/esm/gridview/gridviewComponent.js +4 -1
- package/dist/esm/gridview/gridviewComponent.js.map +1 -1
- package/dist/esm/gridview/gridviewPanel.d.ts +3 -3
- package/dist/esm/gridview/gridviewPanel.d.ts.map +1 -1
- package/dist/esm/gridview/gridviewPanel.js +2 -2
- package/dist/esm/gridview/gridviewPanel.js.map +1 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js +0 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/math.d.ts.map +1 -1
- package/dist/esm/math.js.map +1 -1
- package/dist/esm/paneview/paneviewComponent.d.ts.map +1 -1
- package/dist/esm/paneview/paneviewComponent.js +4 -1
- package/dist/esm/paneview/paneviewComponent.js.map +1 -1
- package/dist/esm/splitview/splitviewComponent.d.ts.map +1 -1
- package/dist/esm/splitview/splitviewComponent.js +4 -1
- package/dist/esm/splitview/splitviewComponent.js.map +1 -1
- package/dist/styles/dockview.css +216 -1
- package/package.json +5 -5
package/dist/dockview-core.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* dockview-core
|
|
3
|
-
* @version 1.
|
|
3
|
+
* @version 1.8.1
|
|
4
4
|
* @link https://github.com/mathuo/dockview
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
39
|
|
|
40
|
-
var css_248z = ".dockview-svg {\n display: inline-block;\n fill: currentcolor;\n line-height: 1;\n stroke: currentcolor;\n stroke-width: 0;\n}\n.dockview-theme-dark {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-group-view-background-color: #1e1e1e;\n --dv-tabs-and-actions-container-background-color: #252526;\n --dv-activegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-activegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-inactivegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-tab-divider-color: #1e1e1e;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: #969696;\n --dv-inactivegroup-visiblepanel-tab-color: #8f8f8f;\n --dv-inactivegroup-hiddenpanel-tab-color: #626262;\n --dv-separator-border: rgb(68, 68, 68);\n --dv-paneview-header-border-color: rgba(204, 204, 204, 0.2);\n}\n\n.dockview-theme-light {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-group-view-background-color: white;\n --dv-tabs-and-actions-container-background-color: #f3f3f3;\n --dv-activegroup-visiblepanel-tab-background-color: white;\n --dv-activegroup-hiddenpanel-tab-background-color: #ececec;\n --dv-inactivegroup-visiblepanel-tab-background-color: white;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #ececec;\n --dv-tab-divider-color: white;\n --dv-activegroup-visiblepanel-tab-color: rgb(51, 51, 51);\n --dv-activegroup-hiddenpanel-tab-color: rgba(51, 51, 51, 0.7);\n --dv-inactivegroup-visiblepanel-tab-color: rgba(51, 51, 51, 0.7);\n --dv-inactivegroup-hiddenpanel-tab-color: rgba(51, 51, 51, 0.35);\n --dv-separator-border: rgba(128, 128, 128, 0.35);\n --dv-paneview-header-border-color: rgb(51, 51, 51);\n}\n\n.dockview-theme-vs {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-group-view-background-color: #1e1e1e;\n --dv-tabs-and-actions-container-background-color: #252526;\n --dv-activegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-activegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-inactivegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-tab-divider-color: #1e1e1e;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: #969696;\n --dv-inactivegroup-visiblepanel-tab-color: #8f8f8f;\n --dv-inactivegroup-hiddenpanel-tab-color: #626262;\n --dv-separator-border: rgb(68, 68, 68);\n --dv-paneview-header-border-color: rgba(204, 204, 204, 0.2);\n --dv-tabs-and-actions-container-background-color: #2d2d30;\n --dv-tabs-and-actions-container-height: 20px;\n --dv-tabs-and-actions-container-font-size: 11px;\n --dv-activegroup-visiblepanel-tab-background-color: #007acc;\n --dv-inactivegroup-visiblepanel-tab-background-color: #3f3f46;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: white;\n --dv-inactivegroup-visiblepanel-tab-color: white;\n --dv-inactivegroup-hiddenpanel-tab-color: white;\n}\n.dockview-theme-vs .groupview.active-group > .tabs-and-actions-container {\n box-sizing: content-box;\n border-bottom: 2px solid var(--dv-activegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.active-group > .tabs-and-actions-container .tab.active-tab {\n border-top: 2px solid var(--dv-activegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.active-group > .tabs-and-actions-container .tab.inactive-tab {\n border-top: 2px solid var(--dv-activegroup-hiddenpanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.inactive-group > .tabs-and-actions-container {\n box-sizing: content-box;\n border-bottom: 2px solid var(--dv-inactivegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.inactive-group > .tabs-and-actions-container .tab.active-tab {\n border-top: 2px solid var(--dv-inactivegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.inactive-group > .tabs-and-actions-container .tab.inactive-tab {\n border-top: 2px solid var(--dv-inactivegroup-hiddenpanel-tab-background-color);\n}\n\n.dockview-theme-abyss {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-group-view-background-color: #000c18;\n --dv-tabs-and-actions-container-background-color: #1c1c2a;\n --dv-activegroup-visiblepanel-tab-background-color: #000c18;\n --dv-activegroup-hiddenpanel-tab-background-color: #10192c;\n --dv-inactivegroup-visiblepanel-tab-background-color: #000c18;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #10192c;\n --dv-tab-divider-color: #2b2b4a;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: rgba(255, 255, 255, 0.5);\n --dv-inactivegroup-visiblepanel-tab-color: rgba(255, 255, 255, 0.5);\n --dv-inactivegroup-hiddenpanel-tab-color: rgba(255, 255, 255, 0.25);\n --dv-separator-border: #2b2b4a;\n --dv-paneview-header-border-color: #2b2b4a;\n --dv-paneview-active-outline-color: #596f99;\n}\n\n.dockview-theme-dracula {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-group-view-background-color: #282a36;\n --dv-tabs-and-actions-container-background-color: #191a21;\n --dv-activegroup-visiblepanel-tab-background-color: #282a36;\n --dv-activegroup-hiddenpanel-tab-background-color: #21222c;\n --dv-inactivegroup-visiblepanel-tab-background-color: #282a36;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #21222c;\n --dv-tab-divider-color: #191a21;\n --dv-activegroup-visiblepanel-tab-color: rgb(248, 248, 242);\n --dv-activegroup-hiddenpanel-tab-color: rgb(98, 114, 164);\n --dv-inactivegroup-visiblepanel-tab-color: rgba(248, 248, 242, 0.5);\n --dv-inactivegroup-hiddenpanel-tab-color: rgba(98, 114, 164, 0.5);\n --dv-separator-border: #bd93f9;\n --dv-paneview-header-border-color: #bd93f9;\n --dv-paneview-active-outline-color: #6272a4;\n}\n.dockview-theme-dracula .groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n position: relative;\n}\n.dockview-theme-dracula .groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab::after {\n position: absolute;\n left: 0px;\n top: 0px;\n content: \"\";\n width: 100%;\n height: 1px;\n background-color: #94527e;\n z-index: 999;\n}\n.dockview-theme-dracula .groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n position: relative;\n}\n.dockview-theme-dracula .groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab::after {\n position: absolute;\n left: 0px;\n bottom: 0px;\n content: \"\";\n width: 100%;\n height: 1px;\n background-color: #5e3d5a;\n z-index: 999;\n}\n.drop-target {\n position: relative;\n}\n.drop-target > .drop-target-dropzone {\n position: absolute;\n left: 0px;\n top: 0px;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection {\n position: relative;\n box-sizing: border-box;\n height: 100%;\n width: 100%;\n background-color: var(--dv-drag-over-background-color);\n transition: top 70ms ease-out, left 70ms ease-out, width 70ms ease-out, height 70ms ease-out, opacity 0.15s ease-out;\n will-change: transform;\n pointer-events: none;\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-top {\n border-top: 1px solid var(--dv-drag-over-border-color);\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-bottom {\n border-bottom: 1px solid var(--dv-drag-over-border-color);\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-left {\n border-left: 1px solid var(--dv-drag-over-border-color);\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-right {\n border-right: 1px solid var(--dv-drag-over-border-color);\n}\n.dv-dockview {\n position: relative;\n background-color: var(--dv-group-view-background-color);\n}\n.dv-dockview .dv-watermark-container {\n position: absolute;\n top: 0px;\n left: 0px;\n height: 100%;\n width: 100%;\n}\n\n.groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n background-color: var(--dv-activegroup-visiblepanel-tab-background-color);\n color: var(--dv-activegroup-visiblepanel-tab-color);\n}\n.groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.inactive-tab {\n background-color: var(--dv-activegroup-hiddenpanel-tab-background-color);\n color: var(--dv-activegroup-hiddenpanel-tab-color);\n}\n.groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n background-color: var(--dv-inactivegroup-visiblepanel-tab-background-color);\n color: var(--dv-inactivegroup-visiblepanel-tab-color);\n}\n.groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.inactive-tab {\n background-color: var(--dv-inactivegroup-hiddenpanel-tab-background-color);\n color: var(--dv-inactivegroup-hiddenpanel-tab-color);\n}\n\n/**\n * when a tab is dragged we lose the above stylings because they are conditional on parent elements\n * therefore we also set some stylings for the dragging event\n **/\n.tab.dv-tab-dragging {\n background-color: var(--dv-activegroup-visiblepanel-tab-background-color);\n color: var(--dv-activegroup-visiblepanel-tab-color);\n}\n.groupview {\n display: flex;\n flex-direction: column;\n height: 100%;\n background-color: var(--dv-group-view-background-color);\n overflow: hidden;\n}\n.groupview:focus {\n outline: none;\n}\n.groupview.empty > .tabs-and-actions-container {\n display: none;\n}\n.groupview > .content-container {\n flex-grow: 1;\n overflow: hidden;\n outline: none;\n}\n.grid-view,\n.branch-node {\n height: 100%;\n width: 100%;\n}\n.pane-container {\n height: 100%;\n width: 100%;\n}\n.pane-container.animated .view {\n transition-duration: 0.15s;\n transition-timing-function: ease-out;\n}\n.pane-container .view {\n overflow: hidden;\n display: flex;\n flex-direction: column;\n padding: 0px !important;\n}\n.pane-container .view:not(:first-child)::before {\n background-color: transparent !important;\n}\n.pane-container .view:not(:first-child) .pane > .pane-header {\n border-top: 1px solid var(--dv-paneview-header-border-color);\n}\n.pane-container .view .default-header {\n background-color: var(--dv-group-view-background-color);\n color: var(--dv-activegroup-visiblepanel-tab-color);\n display: flex;\n padding: 0px 8px;\n cursor: pointer;\n}\n.pane-container .view .default-header .dockview-pane-header-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.pane-container .view .default-header > span {\n padding-left: 8px;\n flex-grow: 1;\n}\n.pane-container:first-of-type > .pane > .pane-header {\n border-top: none !important;\n}\n.pane-container .pane {\n display: flex;\n flex-direction: column;\n overflow: hidden;\n height: 100%;\n}\n.pane-container .pane .pane-header {\n box-sizing: border-box;\n user-select: none;\n position: relative;\n outline: none;\n}\n.pane-container .pane .pane-header.pane-draggable {\n cursor: pointer;\n}\n.pane-container .pane .pane-header:focus:before, .pane-container .pane .pane-header:focus-within:before {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n z-index: 5;\n content: \"\";\n pointer-events: none;\n outline: 1px solid;\n outline-width: -1px;\n outline-style: solid;\n outline-offset: -1px;\n outline-color: var(--dv-paneview-active-outline-color);\n}\n.pane-container .pane .pane-body {\n overflow-y: auto;\n overflow-x: hidden;\n flex-grow: 1;\n position: relative;\n outline: none;\n}\n.pane-container .pane .pane-body:focus:before, .pane-container .pane .pane-body:focus-within:before {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n z-index: 5;\n content: \"\";\n pointer-events: none;\n outline: 1px solid;\n outline-width: -1px;\n outline-style: solid;\n outline-offset: -1px;\n outline-color: var(--dv-paneview-active-outline-color);\n}\n.split-view-container {\n position: relative;\n overflow: hidden;\n height: 100%;\n width: 100%;\n}\n.split-view-container.animation .view,\n.split-view-container.animation .sash {\n transition-duration: 0.15s;\n transition-timing-function: ease-out;\n}\n.split-view-container.horizontal {\n height: 100%;\n}\n.split-view-container.horizontal > .sash-container > .sash {\n height: 100%;\n width: 4px;\n}\n.split-view-container.horizontal > .sash-container > .sash.enabled {\n cursor: ew-resize;\n}\n.split-view-container.horizontal > .sash-container > .sash.disabled {\n cursor: default;\n}\n.split-view-container.horizontal > .sash-container > .sash.maximum {\n cursor: w-resize;\n}\n.split-view-container.horizontal > .sash-container > .sash.minimum {\n cursor: e-resize;\n}\n.split-view-container.horizontal > .view-container > .view:not(:first-child)::before {\n height: 100%;\n width: 1px;\n}\n.split-view-container.vertical {\n width: 100%;\n}\n.split-view-container.vertical > .sash-container > .sash {\n width: 100%;\n height: 4px;\n}\n.split-view-container.vertical > .sash-container > .sash.enabled {\n cursor: ns-resize;\n}\n.split-view-container.vertical > .sash-container > .sash.disabled {\n cursor: default;\n}\n.split-view-container.vertical > .sash-container > .sash.maximum {\n cursor: n-resize;\n}\n.split-view-container.vertical > .sash-container > .sash.minimum {\n cursor: s-resize;\n}\n.split-view-container.vertical > .view-container > .view {\n width: 100%;\n}\n.split-view-container.vertical > .view-container > .view:not(:first-child)::before {\n height: 1px;\n width: 100%;\n}\n.split-view-container .sash-container {\n height: 100%;\n width: 100%;\n position: absolute;\n}\n.split-view-container .sash-container .sash {\n position: absolute;\n z-index: 99;\n outline: none;\n user-select: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n touch-action: none;\n}\n.split-view-container .sash-container .sash:active {\n transition: background-color 0.1s ease-in-out;\n background-color: var(--dv-active-sash-color, transparent);\n}\n.split-view-container .sash-container .sash:hover {\n background-color: var(--dv-active-sash-color, transparent);\n transition: background-color 0.1s ease-in-out;\n transition-delay: 0.5s;\n}\n.split-view-container .view-container {\n position: relative;\n height: 100%;\n width: 100%;\n background-color: var(--dv-background-color);\n}\n.split-view-container .view-container .view {\n height: 100%;\n box-sizing: border-box;\n overflow: auto;\n position: absolute;\n}\n.split-view-container.separator-border .view:not(:first-child)::before {\n content: \" \";\n position: absolute;\n top: 0;\n left: 0;\n z-index: 5;\n pointer-events: none;\n background-color: var(--dv-separator-border);\n}\n.dv-dragged {\n transform: translate3d(0px, 0px, 0px); /* forces tab to be drawn on a separate layer (see https://github.com/microsoft/vscode/issues/18733) */\n}\n\n.tab {\n flex-shrink: 0;\n}\n.tab.dv-tab-dragging .tab-action {\n background-color: var(--dv-activegroup-visiblepanel-tab-color);\n}\n.tab.active-tab > .default-tab .tab-action {\n visibility: visible;\n}\n.tab.inactive-tab > .default-tab .tab-action {\n visibility: hidden;\n}\n.tab.inactive-tab > .default-tab:hover .tab-action {\n visibility: visible;\n}\n.tab .default-tab {\n position: relative;\n height: 100%;\n display: flex;\n min-width: 80px;\n align-items: center;\n padding: 0px 8px;\n white-space: nowrap;\n text-overflow: elipsis;\n}\n.tab .default-tab .tab-content {\n padding: 0px 8px;\n flex-grow: 1;\n}\n.tab .default-tab .action-container {\n text-align: right;\n display: flex;\n}\n.tab .default-tab .action-container .tab-list {\n display: flex;\n padding: 0px;\n margin: 0px;\n justify-content: flex-end;\n}\n.tab .default-tab .action-container .tab-list .tab-action {\n padding: 4px;\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n}\n.tab .default-tab .action-container .tab-list .tab-action:hover {\n border-radius: 2px;\n background-color: var(--dv-icon-hover-background-color);\n}\n.tabs-and-actions-container {\n display: flex;\n background-color: var(--dv-tabs-and-actions-container-background-color);\n flex-shrink: 0;\n box-sizing: border-box;\n height: var(--dv-tabs-and-actions-container-height);\n font-size: var(--dv-tabs-and-actions-container-font-size);\n}\n.tabs-and-actions-container.hidden {\n display: none;\n}\n.tabs-and-actions-container.dv-single-tab.dv-full-width-single-tab .tabs-container {\n flex-grow: 1;\n}\n.tabs-and-actions-container.dv-single-tab.dv-full-width-single-tab .tabs-container .tab {\n flex-grow: 1;\n}\n.tabs-and-actions-container.dv-single-tab.dv-full-width-single-tab .void-container {\n flex-grow: 0;\n}\n.tabs-and-actions-container .void-container {\n display: flex;\n flex-grow: 1;\n cursor: grab;\n}\n.tabs-and-actions-container .tabs-container {\n display: flex;\n overflow-x: overlay;\n overflow-y: hidden;\n scrollbar-width: thin;\n /* Track */\n /* Handle */\n}\n.tabs-and-actions-container .tabs-container::-webkit-scrollbar {\n height: 3px;\n}\n.tabs-and-actions-container .tabs-container::-webkit-scrollbar-track {\n background: transparent;\n}\n.tabs-and-actions-container .tabs-container::-webkit-scrollbar-thumb {\n background: var(--dv-tabs-container-scrollbar-color);\n}\n.tabs-and-actions-container .tabs-container .tab {\n -webkit-user-drag: element;\n outline: none;\n min-width: 75px;\n cursor: pointer;\n position: relative;\n box-sizing: border-box;\n}\n.tabs-and-actions-container .tabs-container .tab:not(:first-child)::before {\n content: \" \";\n position: absolute;\n top: 0;\n left: 0;\n z-index: 5;\n pointer-events: none;\n background-color: var(--dv-tab-divider-color);\n width: 1px;\n height: 100%;\n}\n.watermark {\n display: flex;\n width: 100%;\n}\n.watermark.has-actions .watermark-title .actions-container {\n display: none;\n}\n.watermark .watermark-title {\n height: 35px;\n width: 100%;\n display: flex;\n}\n.watermark .watermark-content {\n flex-grow: 1;\n}\n.watermark .actions-container {\n display: flex;\n align-items: center;\n padding: 0px 8px;\n}\n.watermark .actions-container .close-action {\n padding: 4px;\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n cursor: pointer;\n color: var(--dv-activegroup-hiddenpanel-tab-color);\n}\n.watermark .actions-container .close-action:hover {\n border-radius: 2px;\n background-color: var(--dv-icon-hover-background-color);\n}";
|
|
40
|
+
var css_248z = ".dockview-svg {\n display: inline-block;\n fill: currentcolor;\n line-height: 1;\n stroke: currentcolor;\n stroke-width: 0;\n}\n.dockview-theme-dark {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-floating-box-shadow: 8px 8px 8px 0px rgba(83, 89, 93, 0.5);\n --dv-group-view-background-color: #1e1e1e;\n --dv-tabs-and-actions-container-background-color: #252526;\n --dv-activegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-activegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-inactivegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-tab-divider-color: #1e1e1e;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: #969696;\n --dv-inactivegroup-visiblepanel-tab-color: #8f8f8f;\n --dv-inactivegroup-hiddenpanel-tab-color: #626262;\n --dv-separator-border: rgb(68, 68, 68);\n --dv-paneview-header-border-color: rgba(204, 204, 204, 0.2);\n}\n\n.dockview-theme-light {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-floating-box-shadow: 8px 8px 8px 0px rgba(83, 89, 93, 0.5);\n --dv-group-view-background-color: white;\n --dv-tabs-and-actions-container-background-color: #f3f3f3;\n --dv-activegroup-visiblepanel-tab-background-color: white;\n --dv-activegroup-hiddenpanel-tab-background-color: #ececec;\n --dv-inactivegroup-visiblepanel-tab-background-color: white;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #ececec;\n --dv-tab-divider-color: white;\n --dv-activegroup-visiblepanel-tab-color: rgb(51, 51, 51);\n --dv-activegroup-hiddenpanel-tab-color: rgba(51, 51, 51, 0.7);\n --dv-inactivegroup-visiblepanel-tab-color: rgba(51, 51, 51, 0.7);\n --dv-inactivegroup-hiddenpanel-tab-color: rgba(51, 51, 51, 0.35);\n --dv-separator-border: rgba(128, 128, 128, 0.35);\n --dv-paneview-header-border-color: rgb(51, 51, 51);\n}\n\n.dockview-theme-vs {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-floating-box-shadow: 8px 8px 8px 0px rgba(83, 89, 93, 0.5);\n --dv-group-view-background-color: #1e1e1e;\n --dv-tabs-and-actions-container-background-color: #252526;\n --dv-activegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-activegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-inactivegroup-visiblepanel-tab-background-color: #1e1e1e;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #2d2d2d;\n --dv-tab-divider-color: #1e1e1e;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: #969696;\n --dv-inactivegroup-visiblepanel-tab-color: #8f8f8f;\n --dv-inactivegroup-hiddenpanel-tab-color: #626262;\n --dv-separator-border: rgb(68, 68, 68);\n --dv-paneview-header-border-color: rgba(204, 204, 204, 0.2);\n --dv-tabs-and-actions-container-background-color: #2d2d30;\n --dv-tabs-and-actions-container-height: 20px;\n --dv-tabs-and-actions-container-font-size: 11px;\n --dv-activegroup-visiblepanel-tab-background-color: #007acc;\n --dv-inactivegroup-visiblepanel-tab-background-color: #3f3f46;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: white;\n --dv-inactivegroup-visiblepanel-tab-color: white;\n --dv-inactivegroup-hiddenpanel-tab-color: white;\n}\n.dockview-theme-vs .groupview.active-group > .tabs-and-actions-container {\n box-sizing: content-box;\n border-bottom: 2px solid var(--dv-activegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.active-group > .tabs-and-actions-container .tab.active-tab {\n border-top: 2px solid var(--dv-activegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.active-group > .tabs-and-actions-container .tab.inactive-tab {\n border-top: 2px solid var(--dv-activegroup-hiddenpanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.inactive-group > .tabs-and-actions-container {\n box-sizing: content-box;\n border-bottom: 2px solid var(--dv-inactivegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.inactive-group > .tabs-and-actions-container .tab.active-tab {\n border-top: 2px solid var(--dv-inactivegroup-visiblepanel-tab-background-color);\n}\n.dockview-theme-vs .groupview.inactive-group > .tabs-and-actions-container .tab.inactive-tab {\n border-top: 2px solid var(--dv-inactivegroup-hiddenpanel-tab-background-color);\n}\n\n.dockview-theme-abyss {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-floating-box-shadow: 8px 8px 8px 0px rgba(83, 89, 93, 0.5);\n --dv-group-view-background-color: #000c18;\n --dv-tabs-and-actions-container-background-color: #1c1c2a;\n --dv-activegroup-visiblepanel-tab-background-color: #000c18;\n --dv-activegroup-hiddenpanel-tab-background-color: #10192c;\n --dv-inactivegroup-visiblepanel-tab-background-color: #000c18;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #10192c;\n --dv-tab-divider-color: #2b2b4a;\n --dv-activegroup-visiblepanel-tab-color: white;\n --dv-activegroup-hiddenpanel-tab-color: rgba(255, 255, 255, 0.5);\n --dv-inactivegroup-visiblepanel-tab-color: rgba(255, 255, 255, 0.5);\n --dv-inactivegroup-hiddenpanel-tab-color: rgba(255, 255, 255, 0.25);\n --dv-separator-border: #2b2b4a;\n --dv-paneview-header-border-color: #2b2b4a;\n --dv-paneview-active-outline-color: #596f99;\n}\n\n.dockview-theme-dracula {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-floating-box-shadow: 8px 8px 8px 0px rgba(83, 89, 93, 0.5);\n --dv-group-view-background-color: #282a36;\n --dv-tabs-and-actions-container-background-color: #191a21;\n --dv-activegroup-visiblepanel-tab-background-color: #282a36;\n --dv-activegroup-hiddenpanel-tab-background-color: #21222c;\n --dv-inactivegroup-visiblepanel-tab-background-color: #282a36;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #21222c;\n --dv-tab-divider-color: #191a21;\n --dv-activegroup-visiblepanel-tab-color: rgb(248, 248, 242);\n --dv-activegroup-hiddenpanel-tab-color: rgb(98, 114, 164);\n --dv-inactivegroup-visiblepanel-tab-color: rgba(248, 248, 242, 0.5);\n --dv-inactivegroup-hiddenpanel-tab-color: rgba(98, 114, 164, 0.5);\n --dv-separator-border: #bd93f9;\n --dv-paneview-header-border-color: #bd93f9;\n --dv-paneview-active-outline-color: #6272a4;\n}\n.dockview-theme-dracula .groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n position: relative;\n}\n.dockview-theme-dracula .groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab::after {\n position: absolute;\n left: 0px;\n top: 0px;\n content: \"\";\n width: 100%;\n height: 1px;\n background-color: #94527e;\n z-index: 999;\n}\n.dockview-theme-dracula .groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n position: relative;\n}\n.dockview-theme-dracula .groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab::after {\n position: absolute;\n left: 0px;\n bottom: 0px;\n content: \"\";\n width: 100%;\n height: 1px;\n background-color: #5e3d5a;\n z-index: 999;\n}\n\n.dockview-theme-replit {\n --dv-background-color: black;\n --dv-paneview-active-outline-color: dodgerblue;\n --dv-tabs-and-actions-container-font-size: 13px;\n --dv-tabs-and-actions-container-height: 35px;\n --dv-drag-over-background-color: rgba(83, 89, 93, 0.5);\n --dv-drag-over-border-color: white;\n --dv-tabs-container-scrollbar-color: #888;\n --dv-icon-hover-background-color: rgba(90, 93, 94, 0.31);\n --dv-floating-box-shadow: 8px 8px 8px 0px rgba(83, 89, 93, 0.5);\n --dv-group-view-background-color: #ebeced;\n --dv-tabs-and-actions-container-background-color: #fcfcfc;\n --dv-activegroup-visiblepanel-tab-background-color: #f0f1f2;\n --dv-activegroup-hiddenpanel-tab-background-color: ##fcfcfc;\n --dv-inactivegroup-visiblepanel-tab-background-color: #f0f1f2;\n --dv-inactivegroup-hiddenpanel-tab-background-color: #fcfcfc;\n --dv-tab-divider-color: transparent;\n --dv-activegroup-visiblepanel-tab-color: rgb(51, 51, 51);\n --dv-activegroup-hiddenpanel-tab-color: rgb(51, 51, 51);\n --dv-inactivegroup-visiblepanel-tab-color: rgb(51, 51, 51);\n --dv-inactivegroup-hiddenpanel-tab-color: rgb(51, 51, 51);\n --dv-separator-border: transparent;\n --dv-paneview-header-border-color: rgb(51, 51, 51);\n --dv-background-color: #ebeced;\n --dv-separator-handle-background-color: #cfd1d3;\n --dv-separator-handle-hover-background-color: #babbbb;\n}\n.dockview-theme-replit.dv-dockview {\n padding: 3px;\n}\n.dockview-theme-replit .view:has(> .groupview) {\n padding: 3px;\n}\n.dockview-theme-replit .dv-resize-container:has(> .groupview) {\n border-radius: 8px;\n}\n.dockview-theme-replit .groupview {\n overflow: hidden;\n border-radius: 10px;\n}\n.dockview-theme-replit .groupview .tabs-and-actions-container {\n border-bottom: 1px solid rgba(128, 128, 128, 0.35);\n}\n.dockview-theme-replit .groupview .tabs-and-actions-container .tab {\n margin: 4px;\n border-radius: 8px;\n}\n.dockview-theme-replit .groupview .tabs-and-actions-container .tab .dockview-svg {\n height: 8px;\n width: 8px;\n}\n.dockview-theme-replit .groupview .tabs-and-actions-container .tab:hover {\n background-color: #e4e5e6 !important;\n}\n.dockview-theme-replit .groupview .content-container {\n background-color: #fcfcfc;\n}\n.dockview-theme-replit .groupview.active-group {\n border: 1px solid rgba(128, 128, 128, 0.35);\n}\n.dockview-theme-replit .groupview.inactive-group {\n border: 1px solid transparent;\n}\n.dockview-theme-replit .vertical > .sash-container > .sash::after {\n content: \"\";\n height: 4px;\n width: 40px;\n border-radius: 2px;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n background-color: var(--dv-separator-handle-background-color);\n position: absolute;\n}\n.dockview-theme-replit .vertical > .sash-container > .sash:hover::after {\n background-color: var(--dv-separator-handle-hover-background-color);\n}\n.dockview-theme-replit .horizontal > .sash-container > .sash::after {\n content: \"\";\n height: 40px;\n width: 4px;\n border-radius: 2px;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n background-color: var(--dv-separator-handle-background-color);\n position: absolute;\n}\n.dockview-theme-replit .horizontal > .sash-container > .sash:hover::after {\n background-color: var(--dv-separator-handle-hover-background-color);\n}\n.drop-target {\n position: relative;\n}\n.drop-target > .drop-target-dropzone {\n position: absolute;\n left: 0px;\n top: 0px;\n height: 100%;\n width: 100%;\n z-index: 1000;\n pointer-events: none;\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection {\n position: relative;\n box-sizing: border-box;\n height: 100%;\n width: 100%;\n background-color: var(--dv-drag-over-background-color);\n transition: top 70ms ease-out, left 70ms ease-out, width 70ms ease-out, height 70ms ease-out, opacity 0.15s ease-out;\n will-change: transform;\n pointer-events: none;\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-top {\n border-top: 1px solid var(--dv-drag-over-border-color);\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-bottom {\n border-bottom: 1px solid var(--dv-drag-over-border-color);\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-left {\n border-left: 1px solid var(--dv-drag-over-border-color);\n}\n.drop-target > .drop-target-dropzone > .drop-target-selection.small-right {\n border-right: 1px solid var(--dv-drag-over-border-color);\n}\n.dv-debug .dv-resize-container .dv-resize-handle-top {\n background-color: red;\n}\n.dv-debug .dv-resize-container .dv-resize-handle-bottom {\n background-color: green;\n}\n.dv-debug .dv-resize-container .dv-resize-handle-left {\n background-color: yellow;\n}\n.dv-debug .dv-resize-container .dv-resize-handle-right {\n background-color: blue;\n}\n.dv-debug .dv-resize-container .dv-resize-handle-topleft,\n.dv-debug .dv-resize-container .dv-resize-handle-topright,\n.dv-debug .dv-resize-container .dv-resize-handle-bottomleft,\n.dv-debug .dv-resize-container .dv-resize-handle-bottomright {\n background-color: cyan;\n}\n\n.dv-resize-container {\n position: absolute;\n z-index: 997;\n border: 1px solid var(--dv-tab-divider-color);\n box-shadow: var(--dv-floating-box-shadow);\n}\n.dv-resize-container.dv-bring-to-front {\n z-index: 998;\n}\n.dv-resize-container.dv-resize-container-dragging {\n opacity: 0.5;\n}\n.dv-resize-container .dv-resize-handle-top {\n height: 4px;\n width: calc(100% - 8px);\n left: 4px;\n top: -2px;\n z-index: 999;\n position: absolute;\n cursor: ns-resize;\n}\n.dv-resize-container .dv-resize-handle-bottom {\n height: 4px;\n width: calc(100% - 8px);\n left: 4px;\n bottom: -2px;\n z-index: 999;\n position: absolute;\n cursor: ns-resize;\n}\n.dv-resize-container .dv-resize-handle-left {\n height: calc(100% - 8px);\n width: 4px;\n left: -2px;\n top: 4px;\n z-index: 999;\n position: absolute;\n cursor: ew-resize;\n}\n.dv-resize-container .dv-resize-handle-right {\n height: calc(100% - 8px);\n width: 4px;\n right: -2px;\n top: 4px;\n z-index: 999;\n position: absolute;\n cursor: ew-resize;\n}\n.dv-resize-container .dv-resize-handle-topleft {\n height: 4px;\n width: 4px;\n top: -2px;\n left: -2px;\n z-index: 999;\n position: absolute;\n cursor: nw-resize;\n}\n.dv-resize-container .dv-resize-handle-topright {\n height: 4px;\n width: 4px;\n right: -2px;\n top: -2px;\n z-index: 999;\n position: absolute;\n cursor: ne-resize;\n}\n.dv-resize-container .dv-resize-handle-bottomleft {\n height: 4px;\n width: 4px;\n left: -2px;\n bottom: -2px;\n z-index: 999;\n position: absolute;\n cursor: sw-resize;\n}\n.dv-resize-container .dv-resize-handle-bottomright {\n height: 4px;\n width: 4px;\n right: -2px;\n bottom: -2px;\n z-index: 999;\n position: absolute;\n cursor: se-resize;\n}\n.dv-dockview {\n position: relative;\n background-color: var(--dv-group-view-background-color);\n}\n.dv-dockview .dv-watermark-container {\n position: absolute;\n top: 0px;\n left: 0px;\n height: 100%;\n width: 100%;\n z-index: 1;\n}\n\n.groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n background-color: var(--dv-activegroup-visiblepanel-tab-background-color);\n color: var(--dv-activegroup-visiblepanel-tab-color);\n}\n.groupview.active-group > .tabs-and-actions-container > .tabs-container > .tab.inactive-tab {\n background-color: var(--dv-activegroup-hiddenpanel-tab-background-color);\n color: var(--dv-activegroup-hiddenpanel-tab-color);\n}\n.groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.active-tab {\n background-color: var(--dv-inactivegroup-visiblepanel-tab-background-color);\n color: var(--dv-inactivegroup-visiblepanel-tab-color);\n}\n.groupview.inactive-group > .tabs-and-actions-container > .tabs-container > .tab.inactive-tab {\n background-color: var(--dv-inactivegroup-hiddenpanel-tab-background-color);\n color: var(--dv-inactivegroup-hiddenpanel-tab-color);\n}\n\n/**\n * when a tab is dragged we lose the above stylings because they are conditional on parent elements\n * therefore we also set some stylings for the dragging event\n **/\n.tab.dv-tab-dragging {\n background-color: var(--dv-activegroup-visiblepanel-tab-background-color);\n color: var(--dv-activegroup-visiblepanel-tab-color);\n}\n.groupview {\n display: flex;\n flex-direction: column;\n height: 100%;\n background-color: var(--dv-group-view-background-color);\n overflow: hidden;\n}\n.groupview:focus {\n outline: none;\n}\n.groupview.empty > .tabs-and-actions-container {\n display: none;\n}\n.groupview > .content-container {\n flex-grow: 1;\n overflow: hidden;\n outline: none;\n}\n.grid-view,\n.branch-node {\n height: 100%;\n width: 100%;\n}\n.pane-container {\n height: 100%;\n width: 100%;\n}\n.pane-container.animated .view {\n transition-duration: 0.15s;\n transition-timing-function: ease-out;\n}\n.pane-container .view {\n overflow: hidden;\n display: flex;\n flex-direction: column;\n padding: 0px !important;\n}\n.pane-container .view:not(:first-child)::before {\n background-color: transparent !important;\n}\n.pane-container .view:not(:first-child) .pane > .pane-header {\n border-top: 1px solid var(--dv-paneview-header-border-color);\n}\n.pane-container .view .default-header {\n background-color: var(--dv-group-view-background-color);\n color: var(--dv-activegroup-visiblepanel-tab-color);\n display: flex;\n padding: 0px 8px;\n cursor: pointer;\n}\n.pane-container .view .default-header .dockview-pane-header-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n.pane-container .view .default-header > span {\n padding-left: 8px;\n flex-grow: 1;\n}\n.pane-container:first-of-type > .pane > .pane-header {\n border-top: none !important;\n}\n.pane-container .pane {\n display: flex;\n flex-direction: column;\n overflow: hidden;\n height: 100%;\n}\n.pane-container .pane .pane-header {\n box-sizing: border-box;\n user-select: none;\n position: relative;\n outline: none;\n}\n.pane-container .pane .pane-header.pane-draggable {\n cursor: pointer;\n}\n.pane-container .pane .pane-header:focus:before, .pane-container .pane .pane-header:focus-within:before {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n z-index: 5;\n content: \"\";\n pointer-events: none;\n outline: 1px solid;\n outline-width: -1px;\n outline-style: solid;\n outline-offset: -1px;\n outline-color: var(--dv-paneview-active-outline-color);\n}\n.pane-container .pane .pane-body {\n overflow-y: auto;\n overflow-x: hidden;\n flex-grow: 1;\n position: relative;\n outline: none;\n}\n.pane-container .pane .pane-body:focus:before, .pane-container .pane .pane-body:focus-within:before {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n z-index: 5;\n content: \"\";\n pointer-events: none;\n outline: 1px solid;\n outline-width: -1px;\n outline-style: solid;\n outline-offset: -1px;\n outline-color: var(--dv-paneview-active-outline-color);\n}\n.dv-debug .split-view-container .sash-container .sash.enabled {\n background-color: black;\n}\n.dv-debug .split-view-container .sash-container .sash.disabled {\n background-color: orange;\n}\n.dv-debug .split-view-container .sash-container .sash.maximum {\n background-color: green;\n}\n.dv-debug .split-view-container .sash-container .sash.minimum {\n background-color: red;\n}\n\n.split-view-container {\n position: relative;\n overflow: hidden;\n height: 100%;\n width: 100%;\n}\n.split-view-container.animation .view,\n.split-view-container.animation .sash {\n transition-duration: 0.15s;\n transition-timing-function: ease-out;\n}\n.split-view-container.horizontal {\n height: 100%;\n}\n.split-view-container.horizontal > .sash-container > .sash {\n height: 100%;\n width: 4px;\n}\n.split-view-container.horizontal > .sash-container > .sash.enabled {\n cursor: ew-resize;\n}\n.split-view-container.horizontal > .sash-container > .sash.disabled {\n cursor: default;\n}\n.split-view-container.horizontal > .sash-container > .sash.maximum {\n cursor: w-resize;\n}\n.split-view-container.horizontal > .sash-container > .sash.minimum {\n cursor: e-resize;\n}\n.split-view-container.horizontal > .view-container > .view:not(:first-child)::before {\n height: 100%;\n width: 1px;\n}\n.split-view-container.vertical {\n width: 100%;\n}\n.split-view-container.vertical > .sash-container > .sash {\n width: 100%;\n height: 4px;\n}\n.split-view-container.vertical > .sash-container > .sash.enabled {\n cursor: ns-resize;\n}\n.split-view-container.vertical > .sash-container > .sash.disabled {\n cursor: default;\n}\n.split-view-container.vertical > .sash-container > .sash.maximum {\n cursor: n-resize;\n}\n.split-view-container.vertical > .sash-container > .sash.minimum {\n cursor: s-resize;\n}\n.split-view-container.vertical > .view-container > .view {\n width: 100%;\n}\n.split-view-container.vertical > .view-container > .view:not(:first-child)::before {\n height: 1px;\n width: 100%;\n}\n.split-view-container .sash-container {\n height: 100%;\n width: 100%;\n position: absolute;\n}\n.split-view-container .sash-container .sash {\n position: absolute;\n z-index: 99;\n outline: none;\n user-select: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n touch-action: none;\n}\n.split-view-container .sash-container .sash:active {\n transition: background-color 0.1s ease-in-out;\n background-color: var(--dv-active-sash-color, transparent);\n}\n.split-view-container .sash-container .sash:hover {\n background-color: var(--dv-active-sash-color, transparent);\n transition: background-color 0.1s ease-in-out;\n transition-delay: 0.5s;\n}\n.split-view-container .view-container {\n position: relative;\n height: 100%;\n width: 100%;\n background-color: var(--dv-background-color);\n}\n.split-view-container .view-container .view {\n height: 100%;\n box-sizing: border-box;\n overflow: auto;\n position: absolute;\n}\n.split-view-container.separator-border .view:not(:first-child)::before {\n content: \" \";\n position: absolute;\n top: 0;\n left: 0;\n z-index: 5;\n pointer-events: none;\n background-color: var(--dv-separator-border);\n}\n.dv-dragged {\n transform: translate3d(0px, 0px, 0px); /* forces tab to be drawn on a separate layer (see https://github.com/microsoft/vscode/issues/18733) */\n}\n\n.tab {\n flex-shrink: 0;\n}\n.tab.dv-tab-dragging .tab-action {\n background-color: var(--dv-activegroup-visiblepanel-tab-color);\n}\n.tab.active-tab > .default-tab .tab-action {\n visibility: visible;\n}\n.tab.inactive-tab > .default-tab .tab-action {\n visibility: hidden;\n}\n.tab.inactive-tab > .default-tab:hover .tab-action {\n visibility: visible;\n}\n.tab .default-tab {\n position: relative;\n height: 100%;\n display: flex;\n min-width: 80px;\n align-items: center;\n padding: 0px 8px;\n white-space: nowrap;\n text-overflow: elipsis;\n}\n.tab .default-tab .tab-content {\n padding: 0px 8px;\n flex-grow: 1;\n}\n.tab .default-tab .action-container {\n text-align: right;\n display: flex;\n}\n.tab .default-tab .action-container .tab-list {\n display: flex;\n padding: 0px;\n margin: 0px;\n justify-content: flex-end;\n}\n.tab .default-tab .action-container .tab-list .tab-action {\n padding: 4px;\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n}\n.tab .default-tab .action-container .tab-list .tab-action:hover {\n border-radius: 2px;\n background-color: var(--dv-icon-hover-background-color);\n}\n.tabs-and-actions-container {\n display: flex;\n background-color: var(--dv-tabs-and-actions-container-background-color);\n flex-shrink: 0;\n box-sizing: border-box;\n height: var(--dv-tabs-and-actions-container-height);\n font-size: var(--dv-tabs-and-actions-container-font-size);\n}\n.tabs-and-actions-container.hidden {\n display: none;\n}\n.tabs-and-actions-container.dv-single-tab.dv-full-width-single-tab .tabs-container {\n flex-grow: 1;\n}\n.tabs-and-actions-container.dv-single-tab.dv-full-width-single-tab .tabs-container .tab {\n flex-grow: 1;\n}\n.tabs-and-actions-container.dv-single-tab.dv-full-width-single-tab .void-container {\n flex-grow: 0;\n}\n.tabs-and-actions-container .void-container {\n display: flex;\n flex-grow: 1;\n cursor: grab;\n}\n.tabs-and-actions-container .tabs-container {\n display: flex;\n overflow-x: overlay;\n overflow-y: hidden;\n scrollbar-width: thin;\n /* Track */\n /* Handle */\n}\n.tabs-and-actions-container .tabs-container::-webkit-scrollbar {\n height: 3px;\n}\n.tabs-and-actions-container .tabs-container::-webkit-scrollbar-track {\n background: transparent;\n}\n.tabs-and-actions-container .tabs-container::-webkit-scrollbar-thumb {\n background: var(--dv-tabs-container-scrollbar-color);\n}\n.tabs-and-actions-container .tabs-container .tab {\n -webkit-user-drag: element;\n outline: none;\n min-width: 75px;\n cursor: pointer;\n position: relative;\n box-sizing: border-box;\n}\n.tabs-and-actions-container .tabs-container .tab:not(:first-child)::before {\n content: \" \";\n position: absolute;\n top: 0;\n left: 0;\n z-index: 5;\n pointer-events: none;\n background-color: var(--dv-tab-divider-color);\n width: 1px;\n height: 100%;\n}\n.watermark {\n display: flex;\n width: 100%;\n}\n.watermark.has-actions .watermark-title .actions-container {\n display: none;\n}\n.watermark .watermark-title {\n height: 35px;\n width: 100%;\n display: flex;\n}\n.watermark .watermark-content {\n flex-grow: 1;\n}\n.watermark .actions-container {\n display: flex;\n align-items: center;\n padding: 0px 8px;\n}\n.watermark .actions-container .close-action {\n padding: 4px;\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n cursor: pointer;\n color: var(--dv-activegroup-hiddenpanel-tab-color);\n}\n.watermark .actions-container .close-action:hover {\n border-radius: 2px;\n background-color: var(--dv-icon-hover-background-color);\n}";
|
|
41
41
|
styleInject(css_248z);
|
|
42
42
|
|
|
43
43
|
class TransferObject {
|
|
@@ -307,6 +307,31 @@
|
|
|
307
307
|
}
|
|
308
308
|
}
|
|
309
309
|
|
|
310
|
+
function createComponent(id, componentName, components = {}, frameworkComponents = {}, createFrameworkComponent, fallback) {
|
|
311
|
+
const Component = typeof componentName === 'string'
|
|
312
|
+
? components[componentName]
|
|
313
|
+
: undefined;
|
|
314
|
+
const FrameworkComponent = typeof componentName === 'string'
|
|
315
|
+
? frameworkComponents[componentName]
|
|
316
|
+
: undefined;
|
|
317
|
+
if (Component && FrameworkComponent) {
|
|
318
|
+
throw new Error(`Cannot create '${id}'. component '${componentName}' registered as both a component and frameworkComponent`);
|
|
319
|
+
}
|
|
320
|
+
if (FrameworkComponent) {
|
|
321
|
+
if (!createFrameworkComponent) {
|
|
322
|
+
throw new Error(`Cannot create '${id}' for framework component '${componentName}'. you must register a frameworkPanelWrapper to use framework components`);
|
|
323
|
+
}
|
|
324
|
+
return createFrameworkComponent.createComponent(id, componentName, FrameworkComponent);
|
|
325
|
+
}
|
|
326
|
+
if (!Component) {
|
|
327
|
+
if (fallback) {
|
|
328
|
+
return fallback();
|
|
329
|
+
}
|
|
330
|
+
throw new Error(`Cannot create '${id}', no component '${componentName}' provided`);
|
|
331
|
+
}
|
|
332
|
+
return new Component(id, componentName);
|
|
333
|
+
}
|
|
334
|
+
|
|
310
335
|
function watchElementResize(element, cb) {
|
|
311
336
|
const observer = new ResizeObserver((entires) => {
|
|
312
337
|
/**
|
|
@@ -420,31 +445,16 @@
|
|
|
420
445
|
refreshState() {
|
|
421
446
|
this._refreshStateHandler();
|
|
422
447
|
}
|
|
423
|
-
}
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
throw new Error(`Cannot create '${id}'. component '${componentName}' registered as both a component and frameworkComponent`);
|
|
434
|
-
}
|
|
435
|
-
if (FrameworkComponent) {
|
|
436
|
-
if (!createFrameworkComponent) {
|
|
437
|
-
throw new Error(`Cannot create '${id}' for framework component '${componentName}'. you must register a frameworkPanelWrapper to use framework components`);
|
|
438
|
-
}
|
|
439
|
-
return createFrameworkComponent.createComponent(id, componentName, FrameworkComponent);
|
|
440
|
-
}
|
|
441
|
-
if (!Component) {
|
|
442
|
-
if (fallback) {
|
|
443
|
-
return fallback();
|
|
444
|
-
}
|
|
445
|
-
throw new Error(`Cannot create '${id}', no component '${componentName}' provided`);
|
|
446
|
-
}
|
|
447
|
-
return new Component(id, componentName);
|
|
448
|
+
}
|
|
449
|
+
// quasi: apparently, but not really; seemingly
|
|
450
|
+
const QUASI_PREVENT_DEFAULT_KEY = 'dv-quasiPreventDefault';
|
|
451
|
+
// mark an event directly for other listeners to check
|
|
452
|
+
function quasiPreventDefault(event) {
|
|
453
|
+
event[QUASI_PREVENT_DEFAULT_KEY] = true;
|
|
454
|
+
}
|
|
455
|
+
// check if this event has been marked
|
|
456
|
+
function quasiDefaultPrevented(event) {
|
|
457
|
+
return event[QUASI_PREVENT_DEFAULT_KEY];
|
|
448
458
|
}
|
|
449
459
|
|
|
450
460
|
function tail(arr) {
|
|
@@ -495,6 +505,14 @@
|
|
|
495
505
|
}
|
|
496
506
|
}
|
|
497
507
|
return -1;
|
|
508
|
+
}
|
|
509
|
+
function remove(array, value) {
|
|
510
|
+
const index = array.findIndex((t) => t === value);
|
|
511
|
+
if (index > -1) {
|
|
512
|
+
array.splice(index, 1);
|
|
513
|
+
return true;
|
|
514
|
+
}
|
|
515
|
+
return false;
|
|
498
516
|
}
|
|
499
517
|
|
|
500
518
|
const clamp = (value, min, max) => {
|
|
@@ -1637,7 +1655,7 @@
|
|
|
1637
1655
|
: true,
|
|
1638
1656
|
};
|
|
1639
1657
|
}),
|
|
1640
|
-
size: this.
|
|
1658
|
+
size: this.orthogonalSize,
|
|
1641
1659
|
};
|
|
1642
1660
|
this.children = childDescriptors.map((c) => c.node);
|
|
1643
1661
|
this.splitview = new Splitview(this.element, {
|
|
@@ -1700,7 +1718,7 @@
|
|
|
1700
1718
|
layout(size, orthogonalSize) {
|
|
1701
1719
|
this._size = orthogonalSize;
|
|
1702
1720
|
this._orthogonalSize = size;
|
|
1703
|
-
this.splitview.layout(
|
|
1721
|
+
this.splitview.layout(orthogonalSize, size);
|
|
1704
1722
|
}
|
|
1705
1723
|
addChild(node, size, index, skipLayout) {
|
|
1706
1724
|
if (index < 0 || index > this.children.length) {
|
|
@@ -1925,9 +1943,9 @@
|
|
|
1925
1943
|
this._deserialize(json.root, orientation, deserializer, height);
|
|
1926
1944
|
}
|
|
1927
1945
|
_deserialize(root, orientation, deserializer, orthogonalSize) {
|
|
1928
|
-
this.root = this._deserializeNode(root, orientation, deserializer, orthogonalSize
|
|
1946
|
+
this.root = this._deserializeNode(root, orientation, deserializer, orthogonalSize);
|
|
1929
1947
|
}
|
|
1930
|
-
_deserializeNode(node, orientation, deserializer, orthogonalSize
|
|
1948
|
+
_deserializeNode(node, orientation, deserializer, orthogonalSize) {
|
|
1931
1949
|
let result;
|
|
1932
1950
|
if (node.type === 'branch') {
|
|
1933
1951
|
const serializedChildren = node.data;
|
|
@@ -1937,9 +1955,9 @@
|
|
|
1937
1955
|
visible: serializedChild.visible,
|
|
1938
1956
|
};
|
|
1939
1957
|
});
|
|
1940
|
-
//
|
|
1941
|
-
//
|
|
1942
|
-
|
|
1958
|
+
result = new BranchNode(orientation, this.proportionalLayout, this.styles, node.size, // <- orthogonal size - flips at each depth
|
|
1959
|
+
orthogonalSize, // <- size - flips at each depth
|
|
1960
|
+
children);
|
|
1943
1961
|
}
|
|
1944
1962
|
else {
|
|
1945
1963
|
result = new LeafNode(deserializer.fromJSON(node), orientation, orthogonalSize, node.size);
|
|
@@ -1972,7 +1990,8 @@
|
|
|
1972
1990
|
const oldRoot = this.root;
|
|
1973
1991
|
oldRoot.element.remove();
|
|
1974
1992
|
this._root = new BranchNode(orthogonal(oldRoot.orientation), this.proportionalLayout, this.styles, this.root.orthogonalSize, this.root.size);
|
|
1975
|
-
if (oldRoot.children.length ===
|
|
1993
|
+
if (oldRoot.children.length === 0) ;
|
|
1994
|
+
else if (oldRoot.children.length === 1) {
|
|
1976
1995
|
// can remove one level of redundant branching if there is only a single child
|
|
1977
1996
|
const childReference = oldRoot.children[0];
|
|
1978
1997
|
const child = oldRoot.removeChild(0); // remove to prevent disposal when disposing of unwanted root
|
|
@@ -2488,6 +2507,9 @@
|
|
|
2488
2507
|
addPanel(options) {
|
|
2489
2508
|
return this.component.addPanel(options);
|
|
2490
2509
|
}
|
|
2510
|
+
removePanel(panel) {
|
|
2511
|
+
this.component.removePanel(panel);
|
|
2512
|
+
}
|
|
2491
2513
|
addGroup(options) {
|
|
2492
2514
|
return this.component.addGroup(options);
|
|
2493
2515
|
}
|
|
@@ -2506,6 +2528,9 @@
|
|
|
2506
2528
|
getGroup(id) {
|
|
2507
2529
|
return this.component.getPanel(id);
|
|
2508
2530
|
}
|
|
2531
|
+
addFloatingGroup(item, coord) {
|
|
2532
|
+
return this.component.addFloatingGroup(item, coord);
|
|
2533
|
+
}
|
|
2509
2534
|
fromJSON(data) {
|
|
2510
2535
|
this.component.fromJSON(data);
|
|
2511
2536
|
}
|
|
@@ -2598,10 +2623,14 @@
|
|
|
2598
2623
|
this._onDrop = new Emitter();
|
|
2599
2624
|
this.onDrop = this._onDrop.event;
|
|
2600
2625
|
// use a set to take advantage of #<set>.has
|
|
2601
|
-
|
|
2626
|
+
this._acceptedTargetZonesSet = new Set(this.options.acceptedTargetZones);
|
|
2602
2627
|
this.addDisposables(this._onDrop, new DragAndDropObserver(this.element, {
|
|
2603
2628
|
onDragEnter: () => undefined,
|
|
2604
2629
|
onDragOver: (e) => {
|
|
2630
|
+
if (this._acceptedTargetZonesSet.size === 0) {
|
|
2631
|
+
this.removeDropTarget();
|
|
2632
|
+
return;
|
|
2633
|
+
}
|
|
2605
2634
|
const width = this.element.clientWidth;
|
|
2606
2635
|
const height = this.element.clientHeight;
|
|
2607
2636
|
if (width === 0 || height === 0) {
|
|
@@ -2610,20 +2639,28 @@
|
|
|
2610
2639
|
const rect = e.currentTarget.getBoundingClientRect();
|
|
2611
2640
|
const x = e.clientX - rect.left;
|
|
2612
2641
|
const y = e.clientY - rect.top;
|
|
2613
|
-
const quadrant = this.calculateQuadrant(
|
|
2614
|
-
|
|
2642
|
+
const quadrant = this.calculateQuadrant(this._acceptedTargetZonesSet, x, y, width, height);
|
|
2643
|
+
/**
|
|
2644
|
+
* If the event has already been used by another DropTarget instance
|
|
2645
|
+
* then don't show a second drop target, only one target should be
|
|
2646
|
+
* active at any one time
|
|
2647
|
+
*/
|
|
2648
|
+
if (this.isAlreadyUsed(e) || quadrant === null) {
|
|
2615
2649
|
// no drop target should be displayed
|
|
2616
2650
|
this.removeDropTarget();
|
|
2617
2651
|
return;
|
|
2618
2652
|
}
|
|
2619
2653
|
if (typeof this.options.canDisplayOverlay === 'boolean') {
|
|
2620
2654
|
if (!this.options.canDisplayOverlay) {
|
|
2655
|
+
this.removeDropTarget();
|
|
2621
2656
|
return;
|
|
2622
2657
|
}
|
|
2623
2658
|
}
|
|
2624
2659
|
else if (!this.options.canDisplayOverlay(e, quadrant)) {
|
|
2660
|
+
this.removeDropTarget();
|
|
2625
2661
|
return;
|
|
2626
2662
|
}
|
|
2663
|
+
this.markAsUsed(e);
|
|
2627
2664
|
if (!this.targetElement) {
|
|
2628
2665
|
this.targetElement = document.createElement('div');
|
|
2629
2666
|
this.targetElement.className = 'drop-target-dropzone';
|
|
@@ -2634,12 +2671,6 @@
|
|
|
2634
2671
|
this.element.classList.add('drop-target');
|
|
2635
2672
|
this.element.append(this.targetElement);
|
|
2636
2673
|
}
|
|
2637
|
-
if (this.options.acceptedTargetZones.length === 0) {
|
|
2638
|
-
return;
|
|
2639
|
-
}
|
|
2640
|
-
if (!this.targetElement || !this.overlayElement) {
|
|
2641
|
-
return;
|
|
2642
|
-
}
|
|
2643
2674
|
this.toggleClasses(quadrant, width, height);
|
|
2644
2675
|
this.setState(quadrant);
|
|
2645
2676
|
},
|
|
@@ -2662,10 +2693,26 @@
|
|
|
2662
2693
|
},
|
|
2663
2694
|
}));
|
|
2664
2695
|
}
|
|
2696
|
+
setTargetZones(acceptedTargetZones) {
|
|
2697
|
+
this._acceptedTargetZonesSet = new Set(acceptedTargetZones);
|
|
2698
|
+
}
|
|
2665
2699
|
dispose() {
|
|
2666
2700
|
this.removeDropTarget();
|
|
2667
2701
|
super.dispose();
|
|
2668
2702
|
}
|
|
2703
|
+
/**
|
|
2704
|
+
* Add a property to the event object for other potential listeners to check
|
|
2705
|
+
*/
|
|
2706
|
+
markAsUsed(event) {
|
|
2707
|
+
event[Droptarget.USED_EVENT_ID] = true;
|
|
2708
|
+
}
|
|
2709
|
+
/**
|
|
2710
|
+
* Check is the event has already been used by another instance od DropTarget
|
|
2711
|
+
*/
|
|
2712
|
+
isAlreadyUsed(event) {
|
|
2713
|
+
const value = event[Droptarget.USED_EVENT_ID];
|
|
2714
|
+
return typeof value === 'boolean' && value;
|
|
2715
|
+
}
|
|
2669
2716
|
toggleClasses(quadrant, width, height) {
|
|
2670
2717
|
var _a, _b, _c, _d;
|
|
2671
2718
|
if (!this.overlayElement) {
|
|
@@ -2760,6 +2807,7 @@
|
|
|
2760
2807
|
}
|
|
2761
2808
|
}
|
|
2762
2809
|
}
|
|
2810
|
+
Droptarget.USED_EVENT_ID = '__dockview_droptarget_event_is_used__';
|
|
2763
2811
|
function calculateQuadrantAsPercentage(overlayType, x, y, width, height, threshold) {
|
|
2764
2812
|
const xp = (100 * x) / width;
|
|
2765
2813
|
const yp = (100 * y) / height;
|
|
@@ -2889,8 +2937,15 @@
|
|
|
2889
2937
|
this.addDisposables(this._onDragStart, this.dataDisposable, this.pointerEventsDisposable);
|
|
2890
2938
|
this.configure();
|
|
2891
2939
|
}
|
|
2940
|
+
isCancelled(_event) {
|
|
2941
|
+
return false;
|
|
2942
|
+
}
|
|
2892
2943
|
configure() {
|
|
2893
2944
|
this.addDisposables(this._onDragStart, addDisposableListener(this.el, 'dragstart', (event) => {
|
|
2945
|
+
if (this.isCancelled(event)) {
|
|
2946
|
+
event.preventDefault();
|
|
2947
|
+
return;
|
|
2948
|
+
}
|
|
2894
2949
|
const iframes = [
|
|
2895
2950
|
...getElementsByTagName('iframe'),
|
|
2896
2951
|
...getElementsByTagName('webview'),
|
|
@@ -2964,13 +3019,6 @@
|
|
|
2964
3019
|
if (event.defaultPrevented) {
|
|
2965
3020
|
return;
|
|
2966
3021
|
}
|
|
2967
|
-
/**
|
|
2968
|
-
* TODO: alternative to stopPropagation
|
|
2969
|
-
*
|
|
2970
|
-
* I need to stop the event propagation here since otherwise it'll be intercepted by event handlers
|
|
2971
|
-
* on the tabs-container. I cannot use event.preventDefault() since I need the on DragStart event to occur
|
|
2972
|
-
*/
|
|
2973
|
-
event.stopPropagation();
|
|
2974
3022
|
this._onChanged.fire(event);
|
|
2975
3023
|
}));
|
|
2976
3024
|
this.droptarget = new Droptarget(this._element, {
|
|
@@ -3028,6 +3076,22 @@
|
|
|
3028
3076
|
this.accessorId = accessorId;
|
|
3029
3077
|
this.group = group;
|
|
3030
3078
|
this.panelTransfer = LocalSelectionTransfer.getInstance();
|
|
3079
|
+
this.addDisposables(addDisposableListener(element, 'mousedown', (e) => {
|
|
3080
|
+
if (e.shiftKey) {
|
|
3081
|
+
/**
|
|
3082
|
+
* You cannot call e.preventDefault() because that will prevent drag events from firing
|
|
3083
|
+
* but we also need to stop any group overlay drag events from occuring
|
|
3084
|
+
* Use a custom event marker that can be checked by the overlay drag events
|
|
3085
|
+
*/
|
|
3086
|
+
quasiPreventDefault(e);
|
|
3087
|
+
}
|
|
3088
|
+
}, true));
|
|
3089
|
+
}
|
|
3090
|
+
isCancelled(_event) {
|
|
3091
|
+
if (this.group.api.isFloating && !_event.shiftKey) {
|
|
3092
|
+
return true;
|
|
3093
|
+
}
|
|
3094
|
+
return false;
|
|
3031
3095
|
}
|
|
3032
3096
|
getData(dataTransfer) {
|
|
3033
3097
|
this.panelTransfer.setData([new PanelTransfer(this.accessorId, this.group.id, null)], PanelTransfer.prototype);
|
|
@@ -3118,17 +3182,30 @@
|
|
|
3118
3182
|
hide() {
|
|
3119
3183
|
this._element.style.display = 'none';
|
|
3120
3184
|
}
|
|
3121
|
-
|
|
3122
|
-
if (this.
|
|
3185
|
+
setRightActionsElement(element) {
|
|
3186
|
+
if (this.rightActions === element) {
|
|
3123
3187
|
return;
|
|
3124
3188
|
}
|
|
3125
|
-
if (this.
|
|
3126
|
-
this.
|
|
3127
|
-
this.
|
|
3189
|
+
if (this.rightActions) {
|
|
3190
|
+
this.rightActions.remove();
|
|
3191
|
+
this.rightActions = undefined;
|
|
3128
3192
|
}
|
|
3129
3193
|
if (element) {
|
|
3130
|
-
this.
|
|
3131
|
-
this.
|
|
3194
|
+
this.rightActionsContainer.appendChild(element);
|
|
3195
|
+
this.rightActions = element;
|
|
3196
|
+
}
|
|
3197
|
+
}
|
|
3198
|
+
setLeftActionsElement(element) {
|
|
3199
|
+
if (this.leftActions === element) {
|
|
3200
|
+
return;
|
|
3201
|
+
}
|
|
3202
|
+
if (this.leftActions) {
|
|
3203
|
+
this.leftActions.remove();
|
|
3204
|
+
this.leftActions = undefined;
|
|
3205
|
+
}
|
|
3206
|
+
if (element) {
|
|
3207
|
+
this.leftActionsContainer.appendChild(element);
|
|
3208
|
+
this.leftActions = element;
|
|
3132
3209
|
}
|
|
3133
3210
|
}
|
|
3134
3211
|
get element() {
|
|
@@ -3163,19 +3240,35 @@
|
|
|
3163
3240
|
toggleClass(this._element, 'dv-single-tab', this.size === 1);
|
|
3164
3241
|
}
|
|
3165
3242
|
}));
|
|
3166
|
-
this.
|
|
3167
|
-
this.
|
|
3243
|
+
this.rightActionsContainer = document.createElement('div');
|
|
3244
|
+
this.rightActionsContainer.className = 'right-actions-container';
|
|
3245
|
+
this.leftActionsContainer = document.createElement('div');
|
|
3246
|
+
this.leftActionsContainer.className = 'left-actions-container';
|
|
3168
3247
|
this.tabContainer = document.createElement('div');
|
|
3169
3248
|
this.tabContainer.className = 'tabs-container';
|
|
3170
3249
|
this.voidContainer = new VoidContainer(this.accessor, this.group);
|
|
3171
3250
|
this._element.appendChild(this.tabContainer);
|
|
3251
|
+
this._element.appendChild(this.leftActionsContainer);
|
|
3172
3252
|
this._element.appendChild(this.voidContainer.element);
|
|
3173
|
-
this._element.appendChild(this.
|
|
3253
|
+
this._element.appendChild(this.rightActionsContainer);
|
|
3174
3254
|
this.addDisposables(this.voidContainer, this.voidContainer.onDrop((event) => {
|
|
3175
3255
|
this._onDrop.fire({
|
|
3176
3256
|
event: event.nativeEvent,
|
|
3177
3257
|
index: this.tabs.length,
|
|
3178
3258
|
});
|
|
3259
|
+
}), addDisposableListener(this.voidContainer.element, 'mousedown', (event) => {
|
|
3260
|
+
const isFloatingGroupsEnabled = !this.accessor.options.disableFloatingGroups;
|
|
3261
|
+
if (isFloatingGroupsEnabled &&
|
|
3262
|
+
event.shiftKey &&
|
|
3263
|
+
!this.group.api.isFloating) {
|
|
3264
|
+
event.preventDefault();
|
|
3265
|
+
const { top, left } = this.element.getBoundingClientRect();
|
|
3266
|
+
const { top: rootTop, left: rootLeft } = this.accessor.element.getBoundingClientRect();
|
|
3267
|
+
this.accessor.addFloatingGroup(this.group, {
|
|
3268
|
+
x: left - rootLeft + 20,
|
|
3269
|
+
y: top - rootTop + 20,
|
|
3270
|
+
}, { inDragMode: true });
|
|
3271
|
+
}
|
|
3179
3272
|
}), addDisposableListener(this.tabContainer, 'mousedown', (event) => {
|
|
3180
3273
|
if (event.defaultPrevented) {
|
|
3181
3274
|
return;
|
|
@@ -3229,6 +3322,21 @@
|
|
|
3229
3322
|
tabToAdd.setContent(panel.view.tab);
|
|
3230
3323
|
const disposable = CompositeDisposable.from(tabToAdd.onChanged((event) => {
|
|
3231
3324
|
var _a;
|
|
3325
|
+
const isFloatingGroupsEnabled = !this.accessor.options.disableFloatingGroups;
|
|
3326
|
+
const isFloatingWithOnePanel = this.group.api.isFloating && this.size === 1;
|
|
3327
|
+
if (isFloatingGroupsEnabled &&
|
|
3328
|
+
!isFloatingWithOnePanel &&
|
|
3329
|
+
event.shiftKey) {
|
|
3330
|
+
event.preventDefault();
|
|
3331
|
+
const panel = this.accessor.getGroupPanel(tabToAdd.panelId);
|
|
3332
|
+
const { top, left } = tabToAdd.element.getBoundingClientRect();
|
|
3333
|
+
const { top: rootTop, left: rootLeft } = this.accessor.element.getBoundingClientRect();
|
|
3334
|
+
this.accessor.addFloatingGroup(panel, {
|
|
3335
|
+
x: left - rootLeft,
|
|
3336
|
+
y: top - rootTop,
|
|
3337
|
+
}, { inDragMode: true });
|
|
3338
|
+
return;
|
|
3339
|
+
}
|
|
3232
3340
|
const alreadyFocused = panel.id === ((_a = this.group.model.activePanel) === null || _a === void 0 ? void 0 : _a.id) &&
|
|
3233
3341
|
this.group.model.isContentFocused;
|
|
3234
3342
|
const isLeftClick = event.button === 0;
|
|
@@ -3298,6 +3406,17 @@
|
|
|
3298
3406
|
}
|
|
3299
3407
|
return isAncestor(document.activeElement, this.contentContainer.element);
|
|
3300
3408
|
}
|
|
3409
|
+
get isFloating() {
|
|
3410
|
+
return this._isFloating;
|
|
3411
|
+
}
|
|
3412
|
+
set isFloating(value) {
|
|
3413
|
+
this._isFloating = value;
|
|
3414
|
+
this.dropTarget.setTargetZones(value ? ['center'] : ['top', 'bottom', 'left', 'right', 'center']);
|
|
3415
|
+
toggleClass(this.container, 'dv-groupview-floating', value);
|
|
3416
|
+
this.groupPanel.api._onDidFloatingStateChange.fire({
|
|
3417
|
+
isFloating: this.isFloating,
|
|
3418
|
+
});
|
|
3419
|
+
}
|
|
3301
3420
|
constructor(container, accessor, id, options, groupPanel) {
|
|
3302
3421
|
super();
|
|
3303
3422
|
this.container = container;
|
|
@@ -3307,6 +3426,7 @@
|
|
|
3307
3426
|
this.groupPanel = groupPanel;
|
|
3308
3427
|
this._isGroupActive = false;
|
|
3309
3428
|
this._locked = false;
|
|
3429
|
+
this._isFloating = false;
|
|
3310
3430
|
this.mostRecentlyUsed = [];
|
|
3311
3431
|
this._onDidChange = new Emitter();
|
|
3312
3432
|
this.onDidChange = this._onDidChange.event;
|
|
@@ -3323,7 +3443,7 @@
|
|
|
3323
3443
|
this.onDidRemovePanel = this._onDidRemovePanel.event;
|
|
3324
3444
|
this._onDidActivePanelChange = new Emitter();
|
|
3325
3445
|
this.onDidActivePanelChange = this._onDidActivePanelChange.event;
|
|
3326
|
-
this.container
|
|
3446
|
+
toggleClass(this.container, 'groupview', true);
|
|
3327
3447
|
this.tabsContainer = new TabsContainer(this.accessor, this.groupPanel);
|
|
3328
3448
|
this.contentContainer = new ContentContainer();
|
|
3329
3449
|
this.dropTarget = new Droptarget(this.contentContainer.element, {
|
|
@@ -3333,6 +3453,9 @@
|
|
|
3333
3453
|
return false;
|
|
3334
3454
|
}
|
|
3335
3455
|
const data = getPanelData();
|
|
3456
|
+
if (!data && event.shiftKey && !this.isFloating) {
|
|
3457
|
+
return false;
|
|
3458
|
+
}
|
|
3336
3459
|
if (data && data.viewId === this.accessor.id) {
|
|
3337
3460
|
if (data.groupId === this.id) {
|
|
3338
3461
|
if (position === 'center') {
|
|
@@ -3377,14 +3500,25 @@
|
|
|
3377
3500
|
// correctly initialized
|
|
3378
3501
|
this.setActive(this.isActive, true, true);
|
|
3379
3502
|
this.updateContainer();
|
|
3380
|
-
if (this.accessor.options.
|
|
3381
|
-
this.
|
|
3382
|
-
|
|
3383
|
-
this.
|
|
3503
|
+
if (this.accessor.options.createRightHeaderActionsElement) {
|
|
3504
|
+
this._rightHeaderActions =
|
|
3505
|
+
this.accessor.options.createRightHeaderActionsElement(this.groupPanel);
|
|
3506
|
+
this.addDisposables(this._rightHeaderActions);
|
|
3507
|
+
this._rightHeaderActions.init({
|
|
3508
|
+
containerApi: new DockviewApi(this.accessor),
|
|
3509
|
+
api: this.groupPanel.api,
|
|
3510
|
+
});
|
|
3511
|
+
this.tabsContainer.setRightActionsElement(this._rightHeaderActions.element);
|
|
3512
|
+
}
|
|
3513
|
+
if (this.accessor.options.createLeftHeaderActionsElement) {
|
|
3514
|
+
this._leftHeaderActions =
|
|
3515
|
+
this.accessor.options.createLeftHeaderActionsElement(this.groupPanel);
|
|
3516
|
+
this.addDisposables(this._leftHeaderActions);
|
|
3517
|
+
this._leftHeaderActions.init({
|
|
3384
3518
|
containerApi: new DockviewApi(this.accessor),
|
|
3385
3519
|
api: this.groupPanel.api,
|
|
3386
3520
|
});
|
|
3387
|
-
this.tabsContainer.
|
|
3521
|
+
this.tabsContainer.setLeftActionsElement(this._leftHeaderActions.element);
|
|
3388
3522
|
}
|
|
3389
3523
|
}
|
|
3390
3524
|
indexOf(panel) {
|
|
@@ -3517,7 +3651,7 @@
|
|
|
3517
3651
|
return this._activePanel === panel;
|
|
3518
3652
|
}
|
|
3519
3653
|
updateActions(element) {
|
|
3520
|
-
this.tabsContainer.
|
|
3654
|
+
this.tabsContainer.setRightActionsElement(element);
|
|
3521
3655
|
}
|
|
3522
3656
|
setActive(isGroupActive, skipFocus = false, force = false) {
|
|
3523
3657
|
var _a, _b, _c, _d;
|
|
@@ -3689,9 +3823,10 @@
|
|
|
3689
3823
|
}
|
|
3690
3824
|
}
|
|
3691
3825
|
dispose() {
|
|
3692
|
-
var _a, _b;
|
|
3826
|
+
var _a, _b, _c;
|
|
3693
3827
|
super.dispose();
|
|
3694
|
-
(
|
|
3828
|
+
(_a = this.watermark) === null || _a === void 0 ? void 0 : _a.element.remove();
|
|
3829
|
+
(_c = (_b = this.watermark) === null || _b === void 0 ? void 0 : _b.dispose) === null || _c === void 0 ? void 0 : _c.call(_b);
|
|
3695
3830
|
for (const panel of this.panels) {
|
|
3696
3831
|
panel.dispose();
|
|
3697
3832
|
}
|
|
@@ -4485,8 +4620,8 @@
|
|
|
4485
4620
|
get isActive() {
|
|
4486
4621
|
return this.api.isActive;
|
|
4487
4622
|
}
|
|
4488
|
-
constructor(id, component, options) {
|
|
4489
|
-
super(id, component, new GridviewPanelApiImpl(id));
|
|
4623
|
+
constructor(id, component, options, api) {
|
|
4624
|
+
super(id, component, api !== null && api !== void 0 ? api : new GridviewPanelApiImpl(id));
|
|
4490
4625
|
this._evaluatedMinimumWidth = 0;
|
|
4491
4626
|
this._evaluatedMaximumWidth = Number.MAX_SAFE_INTEGER;
|
|
4492
4627
|
this._evaluatedMinimumHeight = 0;
|
|
@@ -4584,6 +4719,32 @@
|
|
|
4584
4719
|
}
|
|
4585
4720
|
}
|
|
4586
4721
|
|
|
4722
|
+
class DockviewGroupPanelApiImpl extends GridviewPanelApiImpl {
|
|
4723
|
+
get isFloating() {
|
|
4724
|
+
if (!this._group) {
|
|
4725
|
+
throw new Error(`DockviewGroupPanelApiImpl not initialized`);
|
|
4726
|
+
}
|
|
4727
|
+
return this._group.model.isFloating;
|
|
4728
|
+
}
|
|
4729
|
+
constructor(id, accessor) {
|
|
4730
|
+
super(id);
|
|
4731
|
+
this.accessor = accessor;
|
|
4732
|
+
this._onDidFloatingStateChange = new Emitter();
|
|
4733
|
+
this.onDidFloatingStateChange = this._onDidFloatingStateChange.event;
|
|
4734
|
+
this.addDisposables(this._onDidFloatingStateChange);
|
|
4735
|
+
}
|
|
4736
|
+
moveTo(options) {
|
|
4737
|
+
var _a;
|
|
4738
|
+
if (!this._group) {
|
|
4739
|
+
throw new Error(`DockviewGroupPanelApiImpl not initialized`);
|
|
4740
|
+
}
|
|
4741
|
+
this.accessor.moveGroupOrPanel(options.group, this._group.id, undefined, (_a = options.position) !== null && _a !== void 0 ? _a : 'center');
|
|
4742
|
+
}
|
|
4743
|
+
initialize(group) {
|
|
4744
|
+
this._group = group;
|
|
4745
|
+
}
|
|
4746
|
+
}
|
|
4747
|
+
|
|
4587
4748
|
class DockviewGroupPanel extends GridviewPanel {
|
|
4588
4749
|
get panels() {
|
|
4589
4750
|
return this._model.panels;
|
|
@@ -4610,7 +4771,8 @@
|
|
|
4610
4771
|
super(id, 'groupview_default', {
|
|
4611
4772
|
minimumHeight: 100,
|
|
4612
4773
|
minimumWidth: 100,
|
|
4613
|
-
});
|
|
4774
|
+
}, new DockviewGroupPanelApiImpl(id, accessor));
|
|
4775
|
+
this.api.initialize(this); // cannot use 'this' after after 'super' call
|
|
4614
4776
|
this._model = new DockviewGroupPanelModel(this.element, accessor, id, options, this);
|
|
4615
4777
|
}
|
|
4616
4778
|
initialize() {
|
|
@@ -4628,7 +4790,6 @@
|
|
|
4628
4790
|
return this._model;
|
|
4629
4791
|
}
|
|
4630
4792
|
toJSON() {
|
|
4631
|
-
// TODO fix typing
|
|
4632
4793
|
return this.model.toJSON();
|
|
4633
4794
|
}
|
|
4634
4795
|
}
|
|
@@ -4682,9 +4843,10 @@
|
|
|
4682
4843
|
get group() {
|
|
4683
4844
|
return this._group;
|
|
4684
4845
|
}
|
|
4685
|
-
constructor(panel, group) {
|
|
4846
|
+
constructor(panel, group, accessor) {
|
|
4686
4847
|
super(panel.id);
|
|
4687
4848
|
this.panel = panel;
|
|
4849
|
+
this.accessor = accessor;
|
|
4688
4850
|
this._onDidTitleChange = new Emitter();
|
|
4689
4851
|
this.onDidTitleChange = this._onDidTitleChange.event;
|
|
4690
4852
|
this._onDidActiveGroupChange = new Emitter();
|
|
@@ -4696,6 +4858,10 @@
|
|
|
4696
4858
|
this._group = group;
|
|
4697
4859
|
this.addDisposables(this.disposable, this._onDidTitleChange, this._onDidGroupChange, this._onDidActiveGroupChange);
|
|
4698
4860
|
}
|
|
4861
|
+
moveTo(options) {
|
|
4862
|
+
var _a;
|
|
4863
|
+
this.accessor.moveGroupOrPanel(options.group, this._group.id, this.panel.id, (_a = options.position) !== null && _a !== void 0 ? _a : 'center', options.index);
|
|
4864
|
+
}
|
|
4699
4865
|
setTitle(title) {
|
|
4700
4866
|
this.panel.setTitle(title);
|
|
4701
4867
|
}
|
|
@@ -4720,7 +4886,7 @@
|
|
|
4720
4886
|
this.containerApi = containerApi;
|
|
4721
4887
|
this.view = view;
|
|
4722
4888
|
this._group = group;
|
|
4723
|
-
this.api = new DockviewPanelApiImpl(this, this._group);
|
|
4889
|
+
this.api = new DockviewPanelApiImpl(this, this._group, accessor);
|
|
4724
4890
|
this.addDisposables(this.api.onActiveChange(() => {
|
|
4725
4891
|
accessor.setActivePanel(this);
|
|
4726
4892
|
}), this.api.onDidSizeChange((event) => {
|
|
@@ -5061,6 +5227,296 @@
|
|
|
5061
5227
|
}
|
|
5062
5228
|
}
|
|
5063
5229
|
|
|
5230
|
+
const bringElementToFront = (() => {
|
|
5231
|
+
let previous = null;
|
|
5232
|
+
function pushToTop(element) {
|
|
5233
|
+
if (previous !== element && previous !== null) {
|
|
5234
|
+
toggleClass(previous, 'dv-bring-to-front', false);
|
|
5235
|
+
}
|
|
5236
|
+
toggleClass(element, 'dv-bring-to-front', true);
|
|
5237
|
+
previous = element;
|
|
5238
|
+
}
|
|
5239
|
+
return pushToTop;
|
|
5240
|
+
})();
|
|
5241
|
+
class Overlay extends CompositeDisposable {
|
|
5242
|
+
constructor(options) {
|
|
5243
|
+
super();
|
|
5244
|
+
this.options = options;
|
|
5245
|
+
this._element = document.createElement('div');
|
|
5246
|
+
this._onDidChange = new Emitter();
|
|
5247
|
+
this.onDidChange = this._onDidChange.event;
|
|
5248
|
+
this._onDidChangeEnd = new Emitter();
|
|
5249
|
+
this.onDidChangeEnd = this._onDidChangeEnd.event;
|
|
5250
|
+
this.addDisposables(this._onDidChange, this._onDidChangeEnd);
|
|
5251
|
+
this._element.className = 'dv-resize-container';
|
|
5252
|
+
this.setupResize('top');
|
|
5253
|
+
this.setupResize('bottom');
|
|
5254
|
+
this.setupResize('left');
|
|
5255
|
+
this.setupResize('right');
|
|
5256
|
+
this.setupResize('topleft');
|
|
5257
|
+
this.setupResize('topright');
|
|
5258
|
+
this.setupResize('bottomleft');
|
|
5259
|
+
this.setupResize('bottomright');
|
|
5260
|
+
this._element.appendChild(this.options.content);
|
|
5261
|
+
this.options.container.appendChild(this._element);
|
|
5262
|
+
// if input bad resize within acceptable boundaries
|
|
5263
|
+
this.setBounds({
|
|
5264
|
+
height: this.options.height,
|
|
5265
|
+
width: this.options.width,
|
|
5266
|
+
top: this.options.top,
|
|
5267
|
+
left: this.options.left,
|
|
5268
|
+
});
|
|
5269
|
+
}
|
|
5270
|
+
setBounds(bounds = {}) {
|
|
5271
|
+
if (typeof bounds.height === 'number') {
|
|
5272
|
+
this._element.style.height = `${bounds.height}px`;
|
|
5273
|
+
}
|
|
5274
|
+
if (typeof bounds.width === 'number') {
|
|
5275
|
+
this._element.style.width = `${bounds.width}px`;
|
|
5276
|
+
}
|
|
5277
|
+
if (typeof bounds.top === 'number') {
|
|
5278
|
+
this._element.style.top = `${bounds.top}px`;
|
|
5279
|
+
}
|
|
5280
|
+
if (typeof bounds.left === 'number') {
|
|
5281
|
+
this._element.style.left = `${bounds.left}px`;
|
|
5282
|
+
}
|
|
5283
|
+
const containerRect = this.options.container.getBoundingClientRect();
|
|
5284
|
+
const overlayRect = this._element.getBoundingClientRect();
|
|
5285
|
+
// region: ensure bounds within allowable limits
|
|
5286
|
+
// a minimum width of minimumViewportWidth must be inside the viewport
|
|
5287
|
+
const xOffset = Math.max(0, overlayRect.width - this.options.minimumInViewportWidth);
|
|
5288
|
+
// a minimum height of minimumViewportHeight must be inside the viewport
|
|
5289
|
+
const yOffset = Math.max(0, overlayRect.height - this.options.minimumInViewportHeight);
|
|
5290
|
+
const left = clamp(overlayRect.left - containerRect.left, -xOffset, Math.max(0, containerRect.width - overlayRect.width + xOffset));
|
|
5291
|
+
const top = clamp(overlayRect.top - containerRect.top, -yOffset, Math.max(0, containerRect.height - overlayRect.height + yOffset));
|
|
5292
|
+
this._element.style.left = `${left}px`;
|
|
5293
|
+
this._element.style.top = `${top}px`;
|
|
5294
|
+
this._onDidChange.fire();
|
|
5295
|
+
}
|
|
5296
|
+
toJSON() {
|
|
5297
|
+
const container = this.options.container.getBoundingClientRect();
|
|
5298
|
+
const element = this._element.getBoundingClientRect();
|
|
5299
|
+
return {
|
|
5300
|
+
top: element.top - container.top,
|
|
5301
|
+
left: element.left - container.left,
|
|
5302
|
+
width: element.width,
|
|
5303
|
+
height: element.height,
|
|
5304
|
+
};
|
|
5305
|
+
}
|
|
5306
|
+
setupDrag(dragTarget, options = { inDragMode: false }) {
|
|
5307
|
+
const move = new MutableDisposable();
|
|
5308
|
+
const track = () => {
|
|
5309
|
+
let offset = null;
|
|
5310
|
+
const iframes = [
|
|
5311
|
+
...getElementsByTagName('iframe'),
|
|
5312
|
+
...getElementsByTagName('webview'),
|
|
5313
|
+
];
|
|
5314
|
+
for (const iframe of iframes) {
|
|
5315
|
+
iframe.style.pointerEvents = 'none';
|
|
5316
|
+
}
|
|
5317
|
+
move.value = new CompositeDisposable({
|
|
5318
|
+
dispose: () => {
|
|
5319
|
+
for (const iframe of iframes) {
|
|
5320
|
+
iframe.style.pointerEvents = 'auto';
|
|
5321
|
+
}
|
|
5322
|
+
},
|
|
5323
|
+
}, addDisposableWindowListener(window, 'mousemove', (e) => {
|
|
5324
|
+
const containerRect = this.options.container.getBoundingClientRect();
|
|
5325
|
+
const x = e.clientX - containerRect.left;
|
|
5326
|
+
const y = e.clientY - containerRect.top;
|
|
5327
|
+
toggleClass(this._element, 'dv-resize-container-dragging', true);
|
|
5328
|
+
const overlayRect = this._element.getBoundingClientRect();
|
|
5329
|
+
if (offset === null) {
|
|
5330
|
+
offset = {
|
|
5331
|
+
x: e.clientX - overlayRect.left,
|
|
5332
|
+
y: e.clientY - overlayRect.top,
|
|
5333
|
+
};
|
|
5334
|
+
}
|
|
5335
|
+
const xOffset = Math.max(0, overlayRect.width - this.options.minimumInViewportWidth);
|
|
5336
|
+
const yOffset = Math.max(0, overlayRect.height -
|
|
5337
|
+
this.options.minimumInViewportHeight);
|
|
5338
|
+
const left = clamp(x - offset.x, -xOffset, Math.max(0, containerRect.width - overlayRect.width + xOffset));
|
|
5339
|
+
const top = clamp(y - offset.y, -yOffset, Math.max(0, containerRect.height - overlayRect.height + yOffset));
|
|
5340
|
+
this.setBounds({ top, left });
|
|
5341
|
+
}), addDisposableWindowListener(window, 'mouseup', () => {
|
|
5342
|
+
toggleClass(this._element, 'dv-resize-container-dragging', false);
|
|
5343
|
+
move.dispose();
|
|
5344
|
+
this._onDidChangeEnd.fire();
|
|
5345
|
+
}));
|
|
5346
|
+
};
|
|
5347
|
+
this.addDisposables(move, addDisposableListener(dragTarget, 'mousedown', (event) => {
|
|
5348
|
+
if (event.defaultPrevented) {
|
|
5349
|
+
event.preventDefault();
|
|
5350
|
+
return;
|
|
5351
|
+
}
|
|
5352
|
+
// if somebody has marked this event then treat as a defaultPrevented
|
|
5353
|
+
// without actually calling event.preventDefault()
|
|
5354
|
+
if (quasiDefaultPrevented(event)) {
|
|
5355
|
+
return;
|
|
5356
|
+
}
|
|
5357
|
+
track();
|
|
5358
|
+
}), addDisposableListener(this.options.content, 'mousedown', (event) => {
|
|
5359
|
+
if (event.defaultPrevented) {
|
|
5360
|
+
return;
|
|
5361
|
+
}
|
|
5362
|
+
// if somebody has marked this event then treat as a defaultPrevented
|
|
5363
|
+
// without actually calling event.preventDefault()
|
|
5364
|
+
if (quasiDefaultPrevented(event)) {
|
|
5365
|
+
return;
|
|
5366
|
+
}
|
|
5367
|
+
if (event.shiftKey) {
|
|
5368
|
+
track();
|
|
5369
|
+
}
|
|
5370
|
+
}), addDisposableListener(this.options.content, 'mousedown', () => {
|
|
5371
|
+
bringElementToFront(this._element);
|
|
5372
|
+
}, true));
|
|
5373
|
+
bringElementToFront(this._element);
|
|
5374
|
+
if (options.inDragMode) {
|
|
5375
|
+
track();
|
|
5376
|
+
}
|
|
5377
|
+
}
|
|
5378
|
+
setupResize(direction) {
|
|
5379
|
+
const resizeHandleElement = document.createElement('div');
|
|
5380
|
+
resizeHandleElement.className = `dv-resize-handle-${direction}`;
|
|
5381
|
+
this._element.appendChild(resizeHandleElement);
|
|
5382
|
+
const move = new MutableDisposable();
|
|
5383
|
+
this.addDisposables(move, addDisposableListener(resizeHandleElement, 'mousedown', (e) => {
|
|
5384
|
+
e.preventDefault();
|
|
5385
|
+
let startPosition = null;
|
|
5386
|
+
const iframes = [
|
|
5387
|
+
...getElementsByTagName('iframe'),
|
|
5388
|
+
...getElementsByTagName('webview'),
|
|
5389
|
+
];
|
|
5390
|
+
for (const iframe of iframes) {
|
|
5391
|
+
iframe.style.pointerEvents = 'none';
|
|
5392
|
+
}
|
|
5393
|
+
move.value = new CompositeDisposable(addDisposableWindowListener(window, 'mousemove', (e) => {
|
|
5394
|
+
const containerRect = this.options.container.getBoundingClientRect();
|
|
5395
|
+
const overlayRect = this._element.getBoundingClientRect();
|
|
5396
|
+
const y = e.clientY - containerRect.top;
|
|
5397
|
+
const x = e.clientX - containerRect.left;
|
|
5398
|
+
if (startPosition === null) {
|
|
5399
|
+
// record the initial dimensions since as all subsequence moves are relative to this
|
|
5400
|
+
startPosition = {
|
|
5401
|
+
originalY: y,
|
|
5402
|
+
originalHeight: overlayRect.height,
|
|
5403
|
+
originalX: x,
|
|
5404
|
+
originalWidth: overlayRect.width,
|
|
5405
|
+
};
|
|
5406
|
+
}
|
|
5407
|
+
let top = undefined;
|
|
5408
|
+
let height = undefined;
|
|
5409
|
+
let left = undefined;
|
|
5410
|
+
let width = undefined;
|
|
5411
|
+
const minimumInViewportHeight = this.options.minimumInViewportHeight;
|
|
5412
|
+
const minimumInViewportWidth = this.options.minimumInViewportWidth;
|
|
5413
|
+
function moveTop() {
|
|
5414
|
+
top = clamp(y, -Number.MAX_VALUE, startPosition.originalY +
|
|
5415
|
+
startPosition.originalHeight >
|
|
5416
|
+
containerRect.height
|
|
5417
|
+
? containerRect.height -
|
|
5418
|
+
minimumInViewportHeight
|
|
5419
|
+
: Math.max(0, startPosition.originalY +
|
|
5420
|
+
startPosition.originalHeight -
|
|
5421
|
+
Overlay.MINIMUM_HEIGHT));
|
|
5422
|
+
height =
|
|
5423
|
+
startPosition.originalY +
|
|
5424
|
+
startPosition.originalHeight -
|
|
5425
|
+
top;
|
|
5426
|
+
}
|
|
5427
|
+
function moveBottom() {
|
|
5428
|
+
top =
|
|
5429
|
+
startPosition.originalY -
|
|
5430
|
+
startPosition.originalHeight;
|
|
5431
|
+
height = clamp(y - top, top < 0
|
|
5432
|
+
? -top + minimumInViewportHeight
|
|
5433
|
+
: Overlay.MINIMUM_HEIGHT, Number.MAX_VALUE);
|
|
5434
|
+
}
|
|
5435
|
+
function moveLeft() {
|
|
5436
|
+
left = clamp(x, -Number.MAX_VALUE, startPosition.originalX +
|
|
5437
|
+
startPosition.originalWidth >
|
|
5438
|
+
containerRect.width
|
|
5439
|
+
? containerRect.width -
|
|
5440
|
+
minimumInViewportWidth
|
|
5441
|
+
: Math.max(0, startPosition.originalX +
|
|
5442
|
+
startPosition.originalWidth -
|
|
5443
|
+
Overlay.MINIMUM_WIDTH));
|
|
5444
|
+
width =
|
|
5445
|
+
startPosition.originalX +
|
|
5446
|
+
startPosition.originalWidth -
|
|
5447
|
+
left;
|
|
5448
|
+
}
|
|
5449
|
+
function moveRight() {
|
|
5450
|
+
left =
|
|
5451
|
+
startPosition.originalX -
|
|
5452
|
+
startPosition.originalWidth;
|
|
5453
|
+
width = clamp(x - left, left < 0
|
|
5454
|
+
? -left + minimumInViewportWidth
|
|
5455
|
+
: Overlay.MINIMUM_WIDTH, Number.MAX_VALUE);
|
|
5456
|
+
}
|
|
5457
|
+
switch (direction) {
|
|
5458
|
+
case 'top':
|
|
5459
|
+
moveTop();
|
|
5460
|
+
break;
|
|
5461
|
+
case 'bottom':
|
|
5462
|
+
moveBottom();
|
|
5463
|
+
break;
|
|
5464
|
+
case 'left':
|
|
5465
|
+
moveLeft();
|
|
5466
|
+
break;
|
|
5467
|
+
case 'right':
|
|
5468
|
+
moveRight();
|
|
5469
|
+
break;
|
|
5470
|
+
case 'topleft':
|
|
5471
|
+
moveTop();
|
|
5472
|
+
moveLeft();
|
|
5473
|
+
break;
|
|
5474
|
+
case 'topright':
|
|
5475
|
+
moveTop();
|
|
5476
|
+
moveRight();
|
|
5477
|
+
break;
|
|
5478
|
+
case 'bottomleft':
|
|
5479
|
+
moveBottom();
|
|
5480
|
+
moveLeft();
|
|
5481
|
+
break;
|
|
5482
|
+
case 'bottomright':
|
|
5483
|
+
moveBottom();
|
|
5484
|
+
moveRight();
|
|
5485
|
+
break;
|
|
5486
|
+
}
|
|
5487
|
+
this.setBounds({ height, width, top, left });
|
|
5488
|
+
}), {
|
|
5489
|
+
dispose: () => {
|
|
5490
|
+
for (const iframe of iframes) {
|
|
5491
|
+
iframe.style.pointerEvents = 'auto';
|
|
5492
|
+
}
|
|
5493
|
+
},
|
|
5494
|
+
}, addDisposableWindowListener(window, 'mouseup', () => {
|
|
5495
|
+
move.dispose();
|
|
5496
|
+
this._onDidChangeEnd.fire();
|
|
5497
|
+
}));
|
|
5498
|
+
}));
|
|
5499
|
+
}
|
|
5500
|
+
dispose() {
|
|
5501
|
+
this._element.remove();
|
|
5502
|
+
super.dispose();
|
|
5503
|
+
}
|
|
5504
|
+
}
|
|
5505
|
+
Overlay.MINIMUM_HEIGHT = 20;
|
|
5506
|
+
Overlay.MINIMUM_WIDTH = 20;
|
|
5507
|
+
|
|
5508
|
+
class DockviewFloatingGroupPanel extends CompositeDisposable {
|
|
5509
|
+
constructor(group, overlay) {
|
|
5510
|
+
super();
|
|
5511
|
+
this.group = group;
|
|
5512
|
+
this.overlay = overlay;
|
|
5513
|
+
this.addDisposables(overlay);
|
|
5514
|
+
}
|
|
5515
|
+
position(bounds) {
|
|
5516
|
+
this.overlay.setBounds(bounds);
|
|
5517
|
+
}
|
|
5518
|
+
}
|
|
5519
|
+
|
|
5064
5520
|
class DockviewComponent extends BaseGrid {
|
|
5065
5521
|
get orientation() {
|
|
5066
5522
|
return this.gridview.orientation;
|
|
@@ -5101,7 +5557,8 @@
|
|
|
5101
5557
|
this.onDidLayoutFromJSON = this._onDidLayoutFromJSON.event;
|
|
5102
5558
|
this._onDidActivePanelChange = new Emitter();
|
|
5103
5559
|
this.onDidActivePanelChange = this._onDidActivePanelChange.event;
|
|
5104
|
-
this.
|
|
5560
|
+
this.floatingGroups = [];
|
|
5561
|
+
toggleClass(this.gridview.element, 'dv-dockview', true);
|
|
5105
5562
|
this.addDisposables(this._onDidDrop, exports.DockviewEvent.any(this.onDidAddGroup, this.onDidRemoveGroup)(() => {
|
|
5106
5563
|
this.updateWatermark();
|
|
5107
5564
|
}), exports.DockviewEvent.any(this.onDidAddPanel, this.onDidRemovePanel, this.onDidActivePanelChange)(() => {
|
|
@@ -5131,9 +5588,22 @@
|
|
|
5131
5588
|
if (data.viewId !== this.id) {
|
|
5132
5589
|
return false;
|
|
5133
5590
|
}
|
|
5591
|
+
if (position === 'center') {
|
|
5592
|
+
// center drop target is only allowed if there are no panels in the grid
|
|
5593
|
+
// floating panels are allowed
|
|
5594
|
+
return this.gridview.length === 0;
|
|
5595
|
+
}
|
|
5134
5596
|
return true;
|
|
5135
5597
|
}
|
|
5136
5598
|
if (this.options.showDndOverlay) {
|
|
5599
|
+
if (position === 'center') {
|
|
5600
|
+
/**
|
|
5601
|
+
* for external events only show the four-corner drag overlays, disable
|
|
5602
|
+
* the center position so that external drag events can fall through to the group
|
|
5603
|
+
* and panel drop target handlers
|
|
5604
|
+
*/
|
|
5605
|
+
return false;
|
|
5606
|
+
}
|
|
5137
5607
|
return this.options.showDndOverlay({
|
|
5138
5608
|
nativeEvent: event,
|
|
5139
5609
|
position: position,
|
|
@@ -5143,7 +5613,7 @@
|
|
|
5143
5613
|
}
|
|
5144
5614
|
return false;
|
|
5145
5615
|
},
|
|
5146
|
-
acceptedTargetZones: ['top', 'bottom', 'left', 'right'],
|
|
5616
|
+
acceptedTargetZones: ['top', 'bottom', 'left', 'right', 'center'],
|
|
5147
5617
|
overlayModel: {
|
|
5148
5618
|
activationSize: { type: 'pixels', value: 10 },
|
|
5149
5619
|
size: { type: 'pixels', value: 20 },
|
|
@@ -5161,6 +5631,75 @@
|
|
|
5161
5631
|
this._api = new DockviewApi(this);
|
|
5162
5632
|
this.updateWatermark();
|
|
5163
5633
|
}
|
|
5634
|
+
addFloatingGroup(item, coord, options) {
|
|
5635
|
+
var _a, _b;
|
|
5636
|
+
let group;
|
|
5637
|
+
if (item instanceof DockviewPanel) {
|
|
5638
|
+
group = this.createGroup();
|
|
5639
|
+
this.removePanel(item, {
|
|
5640
|
+
removeEmptyGroup: true,
|
|
5641
|
+
skipDispose: true,
|
|
5642
|
+
});
|
|
5643
|
+
group.model.openPanel(item);
|
|
5644
|
+
}
|
|
5645
|
+
else {
|
|
5646
|
+
group = item;
|
|
5647
|
+
const skip = typeof (options === null || options === void 0 ? void 0 : options.skipRemoveGroup) === 'boolean' &&
|
|
5648
|
+
options.skipRemoveGroup;
|
|
5649
|
+
if (!skip) {
|
|
5650
|
+
this.doRemoveGroup(item, { skipDispose: true });
|
|
5651
|
+
}
|
|
5652
|
+
}
|
|
5653
|
+
group.model.isFloating = true;
|
|
5654
|
+
const overlayLeft = typeof (coord === null || coord === void 0 ? void 0 : coord.x) === 'number' ? Math.max(coord.x, 0) : 100;
|
|
5655
|
+
const overlayTop = typeof (coord === null || coord === void 0 ? void 0 : coord.y) === 'number' ? Math.max(coord.y, 0) : 100;
|
|
5656
|
+
const overlay = new Overlay({
|
|
5657
|
+
container: this.gridview.element,
|
|
5658
|
+
content: group.element,
|
|
5659
|
+
height: (_a = coord === null || coord === void 0 ? void 0 : coord.height) !== null && _a !== void 0 ? _a : 300,
|
|
5660
|
+
width: (_b = coord === null || coord === void 0 ? void 0 : coord.width) !== null && _b !== void 0 ? _b : 300,
|
|
5661
|
+
left: overlayLeft,
|
|
5662
|
+
top: overlayTop,
|
|
5663
|
+
minimumInViewportWidth: 100,
|
|
5664
|
+
minimumInViewportHeight: 100,
|
|
5665
|
+
});
|
|
5666
|
+
const el = group.element.querySelector('.void-container');
|
|
5667
|
+
if (!el) {
|
|
5668
|
+
throw new Error('failed to find drag handle');
|
|
5669
|
+
}
|
|
5670
|
+
overlay.setupDrag(el, {
|
|
5671
|
+
inDragMode: typeof (options === null || options === void 0 ? void 0 : options.inDragMode) === 'boolean'
|
|
5672
|
+
? options.inDragMode
|
|
5673
|
+
: false,
|
|
5674
|
+
});
|
|
5675
|
+
const floatingGroupPanel = new DockviewFloatingGroupPanel(group, overlay);
|
|
5676
|
+
const disposable = watchElementResize(group.element, (entry) => {
|
|
5677
|
+
const { width, height } = entry.contentRect;
|
|
5678
|
+
group.layout(width, height); // let the group know it's size is changing so it can fire events to the panel
|
|
5679
|
+
});
|
|
5680
|
+
floatingGroupPanel.addDisposables(overlay.onDidChange(() => {
|
|
5681
|
+
// this is either a resize or a move
|
|
5682
|
+
// to inform the panels .layout(...) the group with it's current size
|
|
5683
|
+
// don't care about resize since the above watcher handles that
|
|
5684
|
+
group.layout(group.height, group.width);
|
|
5685
|
+
}), overlay.onDidChangeEnd(() => {
|
|
5686
|
+
this._bufferOnDidLayoutChange.fire();
|
|
5687
|
+
}), group.onDidChange((event) => {
|
|
5688
|
+
overlay.setBounds({
|
|
5689
|
+
height: event === null || event === void 0 ? void 0 : event.height,
|
|
5690
|
+
width: event === null || event === void 0 ? void 0 : event.width,
|
|
5691
|
+
});
|
|
5692
|
+
}), {
|
|
5693
|
+
dispose: () => {
|
|
5694
|
+
disposable.dispose();
|
|
5695
|
+
group.model.isFloating = false;
|
|
5696
|
+
remove(this.floatingGroups, floatingGroupPanel);
|
|
5697
|
+
this.updateWatermark();
|
|
5698
|
+
},
|
|
5699
|
+
});
|
|
5700
|
+
this.floatingGroups.push(floatingGroupPanel);
|
|
5701
|
+
this.updateWatermark();
|
|
5702
|
+
}
|
|
5164
5703
|
orthogonalize(position) {
|
|
5165
5704
|
switch (position) {
|
|
5166
5705
|
case 'top':
|
|
@@ -5183,6 +5722,7 @@
|
|
|
5183
5722
|
switch (position) {
|
|
5184
5723
|
case 'top':
|
|
5185
5724
|
case 'left':
|
|
5725
|
+
case 'center':
|
|
5186
5726
|
return this.createGroupAtLocation([0]); // insert into first position
|
|
5187
5727
|
case 'bottom':
|
|
5188
5728
|
case 'right':
|
|
@@ -5200,6 +5740,15 @@
|
|
|
5200
5740
|
}
|
|
5201
5741
|
this.layout(this.gridview.width, this.gridview.height, true);
|
|
5202
5742
|
}
|
|
5743
|
+
layout(width, height, forceResize) {
|
|
5744
|
+
super.layout(width, height, forceResize);
|
|
5745
|
+
if (this.floatingGroups) {
|
|
5746
|
+
for (const floating of this.floatingGroups) {
|
|
5747
|
+
// ensure floting groups stay within visible boundaries
|
|
5748
|
+
floating.overlay.setBounds();
|
|
5749
|
+
}
|
|
5750
|
+
}
|
|
5751
|
+
}
|
|
5203
5752
|
focus() {
|
|
5204
5753
|
var _a;
|
|
5205
5754
|
(_a = this.activeGroup) === null || _a === void 0 ? void 0 : _a.focus();
|
|
@@ -5262,51 +5811,81 @@
|
|
|
5262
5811
|
collection[panel.id] = panel.toJSON();
|
|
5263
5812
|
return collection;
|
|
5264
5813
|
}, {});
|
|
5265
|
-
|
|
5814
|
+
const floats = this.floatingGroups.map((floatingGroup) => {
|
|
5815
|
+
return {
|
|
5816
|
+
data: floatingGroup.group.toJSON(),
|
|
5817
|
+
position: floatingGroup.overlay.toJSON(),
|
|
5818
|
+
};
|
|
5819
|
+
});
|
|
5820
|
+
const result = {
|
|
5266
5821
|
grid: data,
|
|
5267
5822
|
panels,
|
|
5268
5823
|
activeGroup: (_a = this.activeGroup) === null || _a === void 0 ? void 0 : _a.id,
|
|
5269
5824
|
};
|
|
5825
|
+
if (floats.length > 0) {
|
|
5826
|
+
result.floatingGroups = floats;
|
|
5827
|
+
}
|
|
5828
|
+
return result;
|
|
5270
5829
|
}
|
|
5271
5830
|
fromJSON(data) {
|
|
5831
|
+
var _a;
|
|
5272
5832
|
this.clear();
|
|
5273
5833
|
const { grid, panels, activeGroup } = data;
|
|
5274
5834
|
if (grid.root.type !== 'branch' || !Array.isArray(grid.root.data)) {
|
|
5275
5835
|
throw new Error('root must be of type branch');
|
|
5276
5836
|
}
|
|
5837
|
+
// take note of the existing dimensions
|
|
5838
|
+
const width = this.width;
|
|
5839
|
+
const height = this.height;
|
|
5840
|
+
const createGroupFromSerializedState = (data) => {
|
|
5841
|
+
const { id, locked, hideHeader, views, activeView } = data;
|
|
5842
|
+
const group = this.createGroup({
|
|
5843
|
+
id,
|
|
5844
|
+
locked: !!locked,
|
|
5845
|
+
hideHeader: !!hideHeader,
|
|
5846
|
+
});
|
|
5847
|
+
this._onDidAddGroup.fire(group);
|
|
5848
|
+
for (const child of views) {
|
|
5849
|
+
const panel = this._deserializer.fromJSON(panels[child], group);
|
|
5850
|
+
const isActive = typeof activeView === 'string' && activeView === panel.id;
|
|
5851
|
+
group.model.openPanel(panel, {
|
|
5852
|
+
skipSetPanelActive: !isActive,
|
|
5853
|
+
skipSetGroupActive: true,
|
|
5854
|
+
});
|
|
5855
|
+
}
|
|
5856
|
+
if (!group.activePanel && group.panels.length > 0) {
|
|
5857
|
+
group.model.openPanel(group.panels[group.panels.length - 1], {
|
|
5858
|
+
skipSetGroupActive: true,
|
|
5859
|
+
});
|
|
5860
|
+
}
|
|
5861
|
+
return group;
|
|
5862
|
+
};
|
|
5277
5863
|
this.gridview.deserialize(grid, {
|
|
5278
5864
|
fromJSON: (node) => {
|
|
5279
|
-
|
|
5280
|
-
const group = this.createGroup({
|
|
5281
|
-
id,
|
|
5282
|
-
locked: !!locked,
|
|
5283
|
-
hideHeader: !!hideHeader,
|
|
5284
|
-
});
|
|
5285
|
-
this._onDidAddGroup.fire(group);
|
|
5286
|
-
for (const child of views) {
|
|
5287
|
-
const panel = this._deserializer.fromJSON(panels[child], group);
|
|
5288
|
-
const isActive = typeof activeView === 'string' &&
|
|
5289
|
-
activeView === panel.id;
|
|
5290
|
-
group.model.openPanel(panel, {
|
|
5291
|
-
skipSetPanelActive: !isActive,
|
|
5292
|
-
skipSetGroupActive: true,
|
|
5293
|
-
});
|
|
5294
|
-
}
|
|
5295
|
-
if (!group.activePanel && group.panels.length > 0) {
|
|
5296
|
-
group.model.openPanel(group.panels[group.panels.length - 1], {
|
|
5297
|
-
skipSetGroupActive: true,
|
|
5298
|
-
});
|
|
5299
|
-
}
|
|
5300
|
-
return group;
|
|
5865
|
+
return createGroupFromSerializedState(node.data);
|
|
5301
5866
|
},
|
|
5302
5867
|
});
|
|
5868
|
+
this.layout(width, height, true);
|
|
5869
|
+
const serializedFloatingGroups = (_a = data.floatingGroups) !== null && _a !== void 0 ? _a : [];
|
|
5870
|
+
for (const serializedFloatingGroup of serializedFloatingGroups) {
|
|
5871
|
+
const { data, position } = serializedFloatingGroup;
|
|
5872
|
+
const group = createGroupFromSerializedState(data);
|
|
5873
|
+
this.addFloatingGroup(group, {
|
|
5874
|
+
x: position.left,
|
|
5875
|
+
y: position.top,
|
|
5876
|
+
height: position.height,
|
|
5877
|
+
width: position.width,
|
|
5878
|
+
}, { skipRemoveGroup: true, inDragMode: false });
|
|
5879
|
+
}
|
|
5880
|
+
for (const floatingGroup of this.floatingGroups) {
|
|
5881
|
+
floatingGroup.overlay.setBounds();
|
|
5882
|
+
}
|
|
5303
5883
|
if (typeof activeGroup === 'string') {
|
|
5304
5884
|
const panel = this.getPanel(activeGroup);
|
|
5305
5885
|
if (panel) {
|
|
5306
5886
|
this.doSetGroupActive(panel);
|
|
5307
5887
|
}
|
|
5308
5888
|
}
|
|
5309
|
-
this.gridview.layout(this.width, this.height);
|
|
5310
5889
|
this._onDidLayoutFromJSON.fire();
|
|
5311
5890
|
}
|
|
5312
5891
|
clear() {
|
|
@@ -5315,7 +5894,7 @@
|
|
|
5315
5894
|
const hasActivePanel = !!this.activePanel;
|
|
5316
5895
|
for (const group of groups) {
|
|
5317
5896
|
// remove the group will automatically remove the panels
|
|
5318
|
-
this.removeGroup(group, true);
|
|
5897
|
+
this.removeGroup(group, { skipActive: true });
|
|
5319
5898
|
}
|
|
5320
5899
|
if (hasActiveGroup) {
|
|
5321
5900
|
this.doSetGroupActive(undefined);
|
|
@@ -5337,6 +5916,9 @@
|
|
|
5337
5916
|
throw new Error(`panel with id ${options.id} already exists`);
|
|
5338
5917
|
}
|
|
5339
5918
|
let referenceGroup;
|
|
5919
|
+
if (options.position && options.floating) {
|
|
5920
|
+
throw new Error('you can only provide one of: position, floating as arguments to .addPanel(...)');
|
|
5921
|
+
}
|
|
5340
5922
|
if (options.position) {
|
|
5341
5923
|
if (isPanelOptionsWithPanel(options.position)) {
|
|
5342
5924
|
const referencePanel = typeof options.position.referencePanel === 'string'
|
|
@@ -5369,7 +5951,20 @@
|
|
|
5369
5951
|
let panel;
|
|
5370
5952
|
if (referenceGroup) {
|
|
5371
5953
|
const target = toTarget(((_b = options.position) === null || _b === void 0 ? void 0 : _b.direction) || 'within');
|
|
5372
|
-
if (
|
|
5954
|
+
if (options.floating) {
|
|
5955
|
+
const group = this.createGroup();
|
|
5956
|
+
panel = this.createPanel(options, group);
|
|
5957
|
+
group.model.openPanel(panel);
|
|
5958
|
+
const o = typeof options.floating === 'object' &&
|
|
5959
|
+
options.floating !== null
|
|
5960
|
+
? options.floating
|
|
5961
|
+
: {};
|
|
5962
|
+
this.addFloatingGroup(group, o, {
|
|
5963
|
+
inDragMode: false,
|
|
5964
|
+
skipRemoveGroup: true,
|
|
5965
|
+
});
|
|
5966
|
+
}
|
|
5967
|
+
else if (referenceGroup.api.isFloating || target === 'center') {
|
|
5373
5968
|
panel = this.createPanel(options, referenceGroup);
|
|
5374
5969
|
referenceGroup.model.openPanel(panel);
|
|
5375
5970
|
}
|
|
@@ -5381,6 +5976,19 @@
|
|
|
5381
5976
|
group.model.openPanel(panel);
|
|
5382
5977
|
}
|
|
5383
5978
|
}
|
|
5979
|
+
else if (options.floating) {
|
|
5980
|
+
const group = this.createGroup();
|
|
5981
|
+
panel = this.createPanel(options, group);
|
|
5982
|
+
group.model.openPanel(panel);
|
|
5983
|
+
const o = typeof options.floating === 'object' &&
|
|
5984
|
+
options.floating !== null
|
|
5985
|
+
? options.floating
|
|
5986
|
+
: {};
|
|
5987
|
+
this.addFloatingGroup(group, o, {
|
|
5988
|
+
inDragMode: false,
|
|
5989
|
+
skipRemoveGroup: true,
|
|
5990
|
+
});
|
|
5991
|
+
}
|
|
5384
5992
|
else {
|
|
5385
5993
|
const group = this.createGroupAtLocation();
|
|
5386
5994
|
panel = this.createPanel(options, group);
|
|
@@ -5397,7 +6005,9 @@
|
|
|
5397
6005
|
throw new Error(`cannot remove panel ${panel.id}. it's missing a group.`);
|
|
5398
6006
|
}
|
|
5399
6007
|
group.model.removePanel(panel);
|
|
5400
|
-
|
|
6008
|
+
if (!options.skipDispose) {
|
|
6009
|
+
panel.dispose();
|
|
6010
|
+
}
|
|
5401
6011
|
if (group.size === 0 && options.removeEmptyGroup) {
|
|
5402
6012
|
this.removeGroup(group);
|
|
5403
6013
|
}
|
|
@@ -5412,7 +6022,7 @@
|
|
|
5412
6022
|
}
|
|
5413
6023
|
updateWatermark() {
|
|
5414
6024
|
var _a, _b;
|
|
5415
|
-
if (this.groups.length === 0) {
|
|
6025
|
+
if (this.groups.filter((x) => !x.api.isFloating).length === 0) {
|
|
5416
6026
|
if (!this.watermark) {
|
|
5417
6027
|
this.watermark = this.createWatermarkComponent();
|
|
5418
6028
|
this.watermark.init({
|
|
@@ -5421,7 +6031,7 @@
|
|
|
5421
6031
|
const watermarkContainer = document.createElement('div');
|
|
5422
6032
|
watermarkContainer.className = 'dv-watermark-container';
|
|
5423
6033
|
watermarkContainer.appendChild(this.watermark.element);
|
|
5424
|
-
this.element.appendChild(watermarkContainer);
|
|
6034
|
+
this.gridview.element.appendChild(watermarkContainer);
|
|
5425
6035
|
}
|
|
5426
6036
|
}
|
|
5427
6037
|
else if (this.watermark) {
|
|
@@ -5471,15 +6081,28 @@
|
|
|
5471
6081
|
return group;
|
|
5472
6082
|
}
|
|
5473
6083
|
}
|
|
5474
|
-
removeGroup(group,
|
|
6084
|
+
removeGroup(group, options) {
|
|
6085
|
+
var _a;
|
|
5475
6086
|
const panels = [...group.panels]; // reassign since group panels will mutate
|
|
5476
6087
|
for (const panel of panels) {
|
|
5477
6088
|
this.removePanel(panel, {
|
|
5478
6089
|
removeEmptyGroup: false,
|
|
5479
|
-
skipDispose: false,
|
|
6090
|
+
skipDispose: (_a = options === null || options === void 0 ? void 0 : options.skipDispose) !== null && _a !== void 0 ? _a : false,
|
|
5480
6091
|
});
|
|
5481
6092
|
}
|
|
5482
|
-
|
|
6093
|
+
this.doRemoveGroup(group, options);
|
|
6094
|
+
}
|
|
6095
|
+
doRemoveGroup(group, options) {
|
|
6096
|
+
const floatingGroup = this.floatingGroups.find((_) => _.group === group);
|
|
6097
|
+
if (floatingGroup) {
|
|
6098
|
+
if (!(options === null || options === void 0 ? void 0 : options.skipDispose)) {
|
|
6099
|
+
floatingGroup.group.dispose();
|
|
6100
|
+
this._groups.delete(group.id);
|
|
6101
|
+
}
|
|
6102
|
+
floatingGroup.dispose();
|
|
6103
|
+
return floatingGroup.group;
|
|
6104
|
+
}
|
|
6105
|
+
return super.doRemoveGroup(group, options);
|
|
5483
6106
|
}
|
|
5484
6107
|
moveGroupOrPanel(destinationGroup, sourceGroupId, sourceItemId, destinationTarget, destinationIndex) {
|
|
5485
6108
|
var _a;
|
|
@@ -5510,25 +6133,26 @@
|
|
|
5510
6133
|
const targetLocation = getRelativeLocation(this.gridview.orientation, referenceLocation, destinationTarget);
|
|
5511
6134
|
if (sourceGroup && sourceGroup.size < 2) {
|
|
5512
6135
|
const [targetParentLocation, to] = tail(targetLocation);
|
|
5513
|
-
const
|
|
5514
|
-
|
|
5515
|
-
|
|
5516
|
-
|
|
5517
|
-
|
|
5518
|
-
|
|
5519
|
-
|
|
5520
|
-
|
|
5521
|
-
|
|
5522
|
-
|
|
5523
|
-
const targetGroup = this.doRemoveGroup(sourceGroup, {
|
|
5524
|
-
skipActive: true,
|
|
5525
|
-
skipDispose: true,
|
|
5526
|
-
});
|
|
5527
|
-
// after deleting the group we need to re-evaulate the ref location
|
|
5528
|
-
const updatedReferenceLocation = getGridLocation(destinationGroup.element);
|
|
5529
|
-
const location = getRelativeLocation(this.gridview.orientation, updatedReferenceLocation, destinationTarget);
|
|
5530
|
-
this.doAddGroup(targetGroup, location);
|
|
6136
|
+
const isFloating = this.floatingGroups.find((x) => x.group === sourceGroup);
|
|
6137
|
+
if (!isFloating) {
|
|
6138
|
+
const sourceLocation = getGridLocation(sourceGroup.element);
|
|
6139
|
+
const [sourceParentLocation, from] = tail(sourceLocation);
|
|
6140
|
+
if (sequenceEquals(sourceParentLocation, targetParentLocation)) {
|
|
6141
|
+
// special case when 'swapping' two views within same grid location
|
|
6142
|
+
// if a group has one tab - we are essentially moving the 'group'
|
|
6143
|
+
// which is equivalent to swapping two views in this case
|
|
6144
|
+
this.gridview.moveView(sourceParentLocation, from, to);
|
|
6145
|
+
}
|
|
5531
6146
|
}
|
|
6147
|
+
// source group will become empty so delete the group
|
|
6148
|
+
const targetGroup = this.doRemoveGroup(sourceGroup, {
|
|
6149
|
+
skipActive: true,
|
|
6150
|
+
skipDispose: true,
|
|
6151
|
+
});
|
|
6152
|
+
// after deleting the group we need to re-evaulate the ref location
|
|
6153
|
+
const updatedReferenceLocation = getGridLocation(destinationGroup.element);
|
|
6154
|
+
const location = getRelativeLocation(this.gridview.orientation, updatedReferenceLocation, destinationTarget);
|
|
6155
|
+
this.doAddGroup(targetGroup, location);
|
|
5532
6156
|
}
|
|
5533
6157
|
else {
|
|
5534
6158
|
const groupItem = (sourceGroup === null || sourceGroup === void 0 ? void 0 : sourceGroup.model.removePanel(sourceItemId)) ||
|
|
@@ -5557,7 +6181,13 @@
|
|
|
5557
6181
|
}
|
|
5558
6182
|
}
|
|
5559
6183
|
else {
|
|
5560
|
-
this.
|
|
6184
|
+
const floatingGroup = this.floatingGroups.find((x) => x.group === sourceGroup);
|
|
6185
|
+
if (floatingGroup) {
|
|
6186
|
+
floatingGroup.dispose();
|
|
6187
|
+
}
|
|
6188
|
+
else {
|
|
6189
|
+
this.gridview.removeView(getGridLocation(sourceGroup.element));
|
|
6190
|
+
}
|
|
5561
6191
|
const referenceLocation = getGridLocation(referenceGroup.element);
|
|
5562
6192
|
const dropLocation = getRelativeLocation(this.gridview.orientation, referenceLocation, target);
|
|
5563
6193
|
this.gridview.addView(sourceGroup, exports.Sizing.Distribute, dropLocation);
|
|
@@ -5712,6 +6342,9 @@
|
|
|
5712
6342
|
this.clear();
|
|
5713
6343
|
const { grid, activePanel } = serializedGridview;
|
|
5714
6344
|
const queue = [];
|
|
6345
|
+
// take note of the existing dimensions
|
|
6346
|
+
const width = this.width;
|
|
6347
|
+
const height = this.height;
|
|
5715
6348
|
this.gridview.deserialize(grid, {
|
|
5716
6349
|
fromJSON: (node) => {
|
|
5717
6350
|
const { data } = node;
|
|
@@ -5737,7 +6370,7 @@
|
|
|
5737
6370
|
return view;
|
|
5738
6371
|
},
|
|
5739
6372
|
});
|
|
5740
|
-
this.layout(
|
|
6373
|
+
this.layout(width, height, true);
|
|
5741
6374
|
queue.forEach((f) => f());
|
|
5742
6375
|
if (typeof activePanel === 'string') {
|
|
5743
6376
|
const panel = this.getPanel(activePanel);
|
|
@@ -6051,6 +6684,9 @@
|
|
|
6051
6684
|
this.clear();
|
|
6052
6685
|
const { views, orientation, size, activeView } = serializedSplitview;
|
|
6053
6686
|
const queue = [];
|
|
6687
|
+
// take note of the existing dimensions
|
|
6688
|
+
const width = this.width;
|
|
6689
|
+
const height = this.height;
|
|
6054
6690
|
this.splitview = new Splitview(this.element, {
|
|
6055
6691
|
orientation,
|
|
6056
6692
|
proportionalLayout: this.options.proportionalLayout,
|
|
@@ -6087,7 +6723,7 @@
|
|
|
6087
6723
|
}),
|
|
6088
6724
|
},
|
|
6089
6725
|
});
|
|
6090
|
-
this.layout(
|
|
6726
|
+
this.layout(width, height);
|
|
6091
6727
|
queue.forEach((f) => f());
|
|
6092
6728
|
if (typeof activeView === 'string') {
|
|
6093
6729
|
const panel = this.getPanel(activeView);
|
|
@@ -6354,6 +6990,9 @@
|
|
|
6354
6990
|
this.clear();
|
|
6355
6991
|
const { views, size } = serializedPaneview;
|
|
6356
6992
|
const queue = [];
|
|
6993
|
+
// take note of the existing dimensions
|
|
6994
|
+
const width = this.width;
|
|
6995
|
+
const height = this.height;
|
|
6357
6996
|
this.paneview = new Paneview(this.element, {
|
|
6358
6997
|
orientation: exports.Orientation.VERTICAL,
|
|
6359
6998
|
descriptor: {
|
|
@@ -6409,7 +7048,7 @@
|
|
|
6409
7048
|
}),
|
|
6410
7049
|
},
|
|
6411
7050
|
});
|
|
6412
|
-
this.layout(
|
|
7051
|
+
this.layout(width, height);
|
|
6413
7052
|
queue.forEach((f) => f());
|
|
6414
7053
|
this._onDidLayoutfromJSON.fire();
|
|
6415
7054
|
}
|
|
@@ -6595,6 +7234,6 @@
|
|
|
6595
7234
|
exports.orthogonal = orthogonal;
|
|
6596
7235
|
exports.positionToDirection = positionToDirection;
|
|
6597
7236
|
exports.toTarget = toTarget;
|
|
6598
|
-
exports.watchElementResize = watchElementResize;
|
|
6599
7237
|
|
|
6600
7238
|
}));
|
|
7239
|
+
//# sourceMappingURL=dockview-core.js.map
|