babylonjs-gui-editor 7.34.2 → 7.34.3
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/babylon.guiEditor.d.ts +205 -15
- package/babylon.guiEditor.js +1 -1
- package/babylon.guiEditor.js.map +1 -1
- package/babylon.guiEditor.max.js +120 -161
- package/babylon.guiEditor.module.d.ts +382 -24
- package/package.json +3 -3
package/babylon.guiEditor.d.ts
CHANGED
|
@@ -29,8 +29,6 @@ declare module BABYLON {
|
|
|
29
29
|
buildColumnLayout(): string;
|
|
30
30
|
handlePopUp: () => void;
|
|
31
31
|
handleClosingPopUp: () => void;
|
|
32
|
-
createPopupWindow: (title: string, windowVariableName: string, width?: number, height?: number) => Window | null;
|
|
33
|
-
copyStyles: (sourceDoc: HTMLDocument, targetDoc: HTMLDocument) => void;
|
|
34
32
|
switchExpandedState(): void;
|
|
35
33
|
render(): import("react/jsx-runtime").JSX.Element;
|
|
36
34
|
onCreate(value: string): BABYLON.GUI.Control;
|
|
@@ -137,6 +135,8 @@ declare module BABYLON {
|
|
|
137
135
|
*/
|
|
138
136
|
export class GUIEditor {
|
|
139
137
|
private static _CurrentState;
|
|
138
|
+
/** @internal */
|
|
139
|
+
static _PopupWindow: Window | null;
|
|
140
140
|
/**
|
|
141
141
|
* Show the gui editor
|
|
142
142
|
* @param options defines the options to use to configure the gui editor
|
|
@@ -1175,6 +1175,21 @@ declare module BABYLON {
|
|
|
1175
1175
|
|
|
1176
1176
|
|
|
1177
1177
|
|
|
1178
|
+
}
|
|
1179
|
+
declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
1180
|
+
/**
|
|
1181
|
+
* Copy all styles from a document to another document or shadow root
|
|
1182
|
+
* @param source document to copy styles from
|
|
1183
|
+
* @param target document or shadow root to copy styles to
|
|
1184
|
+
*/
|
|
1185
|
+
export function CopyStyles(source: Document, target: Document): void;
|
|
1186
|
+
|
|
1187
|
+
|
|
1188
|
+
|
|
1189
|
+
}
|
|
1190
|
+
declare module BABYLON {
|
|
1191
|
+
|
|
1192
|
+
|
|
1178
1193
|
}
|
|
1179
1194
|
declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
1180
1195
|
export class StringTools {
|
|
@@ -1207,6 +1222,27 @@ declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
|
1207
1222
|
|
|
1208
1223
|
|
|
1209
1224
|
|
|
1225
|
+
}
|
|
1226
|
+
declare module BABYLON {
|
|
1227
|
+
|
|
1228
|
+
|
|
1229
|
+
}
|
|
1230
|
+
declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
1231
|
+
/**
|
|
1232
|
+
* Create a popup window
|
|
1233
|
+
* @param title default title for the popup
|
|
1234
|
+
* @param options options for the popup
|
|
1235
|
+
* @returns the parent control of the popup
|
|
1236
|
+
*/
|
|
1237
|
+
export function CreatePopup(title: string, options: Partial<{
|
|
1238
|
+
onParentControlCreateCallback?: (parentControl: HTMLDivElement) => void;
|
|
1239
|
+
onWindowCreateCallback?: (newWindow: Window) => void;
|
|
1240
|
+
width?: number;
|
|
1241
|
+
height?: number;
|
|
1242
|
+
}>): HTMLDivElement | null;
|
|
1243
|
+
|
|
1244
|
+
|
|
1245
|
+
|
|
1210
1246
|
}
|
|
1211
1247
|
declare module BABYLON {
|
|
1212
1248
|
|
|
@@ -1596,6 +1632,173 @@ declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
|
1596
1632
|
|
|
1597
1633
|
|
|
1598
1634
|
|
|
1635
|
+
}
|
|
1636
|
+
declare module BABYLON {
|
|
1637
|
+
|
|
1638
|
+
|
|
1639
|
+
}
|
|
1640
|
+
declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
1641
|
+
/// <reference types="react" />
|
|
1642
|
+
/**
|
|
1643
|
+
* Splitter component properties
|
|
1644
|
+
*/
|
|
1645
|
+
export interface ISplitterProps {
|
|
1646
|
+
/**
|
|
1647
|
+
* Unique identifier
|
|
1648
|
+
*/
|
|
1649
|
+
id?: string;
|
|
1650
|
+
/**
|
|
1651
|
+
* Splitter size
|
|
1652
|
+
*/
|
|
1653
|
+
size: number;
|
|
1654
|
+
/**
|
|
1655
|
+
* Minimum size for the controlled element
|
|
1656
|
+
*/
|
|
1657
|
+
minSize?: number;
|
|
1658
|
+
/**
|
|
1659
|
+
* Maximum size for the controlled element
|
|
1660
|
+
*/
|
|
1661
|
+
maxSize?: number;
|
|
1662
|
+
/**
|
|
1663
|
+
* Initial size for the controlled element
|
|
1664
|
+
*/
|
|
1665
|
+
initialSize?: number;
|
|
1666
|
+
/**
|
|
1667
|
+
* Defines the controlled side
|
|
1668
|
+
*/
|
|
1669
|
+
controlledSide: BABYLON.GuiEditor.SharedUIComponents.ControlledSize;
|
|
1670
|
+
/**
|
|
1671
|
+
* refObject to the splitter element
|
|
1672
|
+
*/
|
|
1673
|
+
refObject?: React.RefObject<HTMLDivElement>;
|
|
1674
|
+
}
|
|
1675
|
+
/**
|
|
1676
|
+
* Creates a splitter component
|
|
1677
|
+
* @param props defines the splitter properties
|
|
1678
|
+
* @returns the splitter component
|
|
1679
|
+
*/
|
|
1680
|
+
export var Splitter: React.FC<ISplitterProps>;
|
|
1681
|
+
|
|
1682
|
+
|
|
1683
|
+
|
|
1684
|
+
}
|
|
1685
|
+
declare module BABYLON {
|
|
1686
|
+
|
|
1687
|
+
|
|
1688
|
+
}
|
|
1689
|
+
declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
1690
|
+
/// <reference types="react" />
|
|
1691
|
+
export enum ControlledSize {
|
|
1692
|
+
First = 0,
|
|
1693
|
+
Second = 1
|
|
1694
|
+
}
|
|
1695
|
+
export enum SplitDirection {
|
|
1696
|
+
Horizontal = 0,
|
|
1697
|
+
Vertical = 1
|
|
1698
|
+
}
|
|
1699
|
+
/**
|
|
1700
|
+
* Context used to share data with splitters
|
|
1701
|
+
*/
|
|
1702
|
+
export interface ISplitContext {
|
|
1703
|
+
/**
|
|
1704
|
+
* Split direction
|
|
1705
|
+
*/
|
|
1706
|
+
direction: SplitDirection;
|
|
1707
|
+
/**
|
|
1708
|
+
* Function called by splitters to update the offset
|
|
1709
|
+
* @param offset new offet
|
|
1710
|
+
* @param source source element
|
|
1711
|
+
* @param controlledSide defined controlled element
|
|
1712
|
+
*/
|
|
1713
|
+
drag: (offset: number, source: HTMLElement, controlledSide: ControlledSize) => void;
|
|
1714
|
+
/**
|
|
1715
|
+
* Function called by splitters to begin dragging
|
|
1716
|
+
*/
|
|
1717
|
+
beginDrag: () => void;
|
|
1718
|
+
/**
|
|
1719
|
+
* Function called by splitters to end dragging
|
|
1720
|
+
*/
|
|
1721
|
+
endDrag: () => void;
|
|
1722
|
+
/**
|
|
1723
|
+
* Sync sizes for the elements
|
|
1724
|
+
* @param source source element
|
|
1725
|
+
* @param controlledSide defined controlled element
|
|
1726
|
+
* @param size size of the controlled element
|
|
1727
|
+
* @param minSize minimum size for the controlled element
|
|
1728
|
+
* @param maxSize maximum size for the controlled element
|
|
1729
|
+
*/
|
|
1730
|
+
sync: (source: HTMLElement, controlledSide: ControlledSize, size?: number, minSize?: number, maxSize?: number) => void;
|
|
1731
|
+
}
|
|
1732
|
+
export var SplitContext: import("react").Context<ISplitContext>;
|
|
1733
|
+
|
|
1734
|
+
|
|
1735
|
+
|
|
1736
|
+
}
|
|
1737
|
+
declare module BABYLON {
|
|
1738
|
+
|
|
1739
|
+
|
|
1740
|
+
}
|
|
1741
|
+
declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
1742
|
+
/// <reference types="react" />
|
|
1743
|
+
/**
|
|
1744
|
+
* Split container properties
|
|
1745
|
+
*/
|
|
1746
|
+
export interface ISplitContainerProps {
|
|
1747
|
+
/**
|
|
1748
|
+
* Unique identifier
|
|
1749
|
+
*/
|
|
1750
|
+
id?: string;
|
|
1751
|
+
/**
|
|
1752
|
+
* Split direction
|
|
1753
|
+
*/
|
|
1754
|
+
direction: BABYLON.GuiEditor.SharedUIComponents.SplitDirection;
|
|
1755
|
+
/**
|
|
1756
|
+
* Minimum size for the floating elements
|
|
1757
|
+
*/
|
|
1758
|
+
floatingMinSize?: number;
|
|
1759
|
+
/**
|
|
1760
|
+
* RefObject to the root div element
|
|
1761
|
+
*/
|
|
1762
|
+
containerRef?: React.RefObject<HTMLDivElement>;
|
|
1763
|
+
/**
|
|
1764
|
+
* Optional class name
|
|
1765
|
+
*/
|
|
1766
|
+
className?: string;
|
|
1767
|
+
/**
|
|
1768
|
+
* Pointer down
|
|
1769
|
+
* @param event pointer events
|
|
1770
|
+
*/
|
|
1771
|
+
onPointerDown?: (event: React.PointerEvent) => void;
|
|
1772
|
+
/**
|
|
1773
|
+
* Pointer move
|
|
1774
|
+
* @param event pointer events
|
|
1775
|
+
*/
|
|
1776
|
+
onPointerMove?: (event: React.PointerEvent) => void;
|
|
1777
|
+
/**
|
|
1778
|
+
* Pointer up
|
|
1779
|
+
* @param event pointer events
|
|
1780
|
+
*/
|
|
1781
|
+
onPointerUp?: (event: React.PointerEvent) => void;
|
|
1782
|
+
/**
|
|
1783
|
+
* Drop
|
|
1784
|
+
* @param event drag events
|
|
1785
|
+
*/
|
|
1786
|
+
onDrop?: (event: React.DragEvent<HTMLDivElement>) => void;
|
|
1787
|
+
/**
|
|
1788
|
+
* Drag over
|
|
1789
|
+
* @param event drag events
|
|
1790
|
+
*/
|
|
1791
|
+
onDragOver?: (event: React.DragEvent<HTMLDivElement>) => void;
|
|
1792
|
+
}
|
|
1793
|
+
/**
|
|
1794
|
+
* Creates a split container component
|
|
1795
|
+
* @param props defines the split container properties
|
|
1796
|
+
* @returns the split container component
|
|
1797
|
+
*/
|
|
1798
|
+
export var SplitContainer: React.FC<ISplitContainerProps>;
|
|
1799
|
+
|
|
1800
|
+
|
|
1801
|
+
|
|
1599
1802
|
}
|
|
1600
1803
|
declare module BABYLON {
|
|
1601
1804
|
|
|
@@ -2758,19 +2961,6 @@ declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
|
2758
2961
|
|
|
2759
2962
|
|
|
2760
2963
|
|
|
2761
|
-
}
|
|
2762
|
-
declare module BABYLON {
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
}
|
|
2766
|
-
declare module BABYLON.GuiEditor.SharedUIComponents {
|
|
2767
|
-
export class Popup {
|
|
2768
|
-
static CreatePopup(title: string, windowVariableName: string, width?: number, height?: number): HTMLDivElement | null;
|
|
2769
|
-
private static _CopyStyles;
|
|
2770
|
-
}
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
2964
|
}
|
|
2775
2965
|
declare module BABYLON {
|
|
2776
2966
|
|