babylonjs-node-editor 7.35.2 → 7.36.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1893,6 +1893,7 @@ import { NodeLink } from "babylonjs-node-editor/nodeGraphSystem/nodeLink";
1893
1893
  import { FramePortData } from "babylonjs-node-editor/nodeGraphSystem/types/framePortData";
1894
1894
  export const IsFramePortData: (variableToCheck: any) => variableToCheck is FramePortData;
1895
1895
  export const RefreshNode: (node: GraphNode, visitedNodes?: Set<GraphNode>, visitedLinks?: Set<NodeLink>, canvas?: GraphCanvasComponent) => void;
1896
+ export const BuildFloatUI: (container: HTMLDivElement, document: Document, displayName: string, isInteger: boolean, source: any, propertyName: string, onChange: () => void, min?: number, max?: number, visualPropertiesRefresh?: Array<() => void>) => void;
1896
1897
 
1897
1898
  }
1898
1899
  declare module "babylonjs-node-editor/nodeGraphSystem/stateManager" {
@@ -2008,7 +2009,7 @@ import { StateManager } from "babylonjs-node-editor/nodeGraphSystem/stateManager
2008
2009
  import { ISelectionChangedOptions } from "babylonjs-node-editor/nodeGraphSystem/interfaces/selectionChangedOptions";
2009
2010
  import { FrameNodePort } from "babylonjs-node-editor/nodeGraphSystem/frameNodePort";
2010
2011
  import { IDisplayManager } from "babylonjs-node-editor/nodeGraphSystem/interfaces/displayManager";
2011
- import { IPortData } from "babylonjs-node-editor/nodeGraphSystem/interfaces/portData";
2012
+ import { type IPortData } from "babylonjs-node-editor/nodeGraphSystem/interfaces/portData";
2012
2013
  export class NodePort {
2013
2014
  portData: IPortData;
2014
2015
  node: GraphNode;
@@ -2021,6 +2022,7 @@ export class NodePort {
2021
2022
  protected _onCandidateLinkMovedObserver: Nullable<Observer<Nullable<Vector2>>>;
2022
2023
  protected _onSelectionChangedObserver: Nullable<Observer<Nullable<ISelectionChangedOptions>>>;
2023
2024
  protected _exposedOnFrame: boolean;
2025
+ protected _portUIcontainer?: HTMLDivElement;
2024
2026
  delegatedPort: Nullable<FrameNodePort>;
2025
2027
  get element(): HTMLDivElement;
2026
2028
  get container(): HTMLElement;
@@ -2034,7 +2036,7 @@ export class NodePort {
2034
2036
  set exposedPortPosition(value: number);
2035
2037
  private _isConnectedToNodeOutsideOfFrame;
2036
2038
  refresh(): void;
2037
- constructor(portContainer: HTMLElement, portData: IPortData, node: GraphNode, stateManager: StateManager);
2039
+ constructor(portContainer: HTMLElement, portData: IPortData, node: GraphNode, stateManager: StateManager, portUIcontainer?: HTMLDivElement);
2038
2040
  dispose(): void;
2039
2041
  static CreatePortElement(portData: IPortData, node: GraphNode, root: HTMLElement, displayManager: Nullable<IDisplayManager>, stateManager: StateManager): NodePort;
2040
2042
  }
@@ -2093,6 +2095,7 @@ import { NodeLink } from "babylonjs-node-editor/nodeGraphSystem/nodeLink";
2093
2095
  import { StateManager } from "babylonjs-node-editor/nodeGraphSystem/stateManager";
2094
2096
  import { INodeData } from "babylonjs-node-editor/nodeGraphSystem/interfaces/nodeData";
2095
2097
  import { IPortData } from "babylonjs-node-editor/nodeGraphSystem/interfaces/portData";
2098
+ import { IEditablePropertyOption } from "babylonjs/Decorators/nodeDecorator";
2096
2099
  export class GraphNode {
2097
2100
  content: INodeData;
2098
2101
  private _visual;
@@ -2170,7 +2173,7 @@ export class GraphNode {
2170
2173
  private _onUp;
2171
2174
  private _onMove;
2172
2175
  renderProperties(): Nullable<JSX.Element>;
2173
- private _forceRebuild;
2176
+ _forceRebuild(source: any, propertyName: string, notifiers?: IEditablePropertyOption["notifiers"]): void;
2174
2177
  private _isCollapsed;
2175
2178
  /**
2176
2179
  * Collapse the node
@@ -2561,6 +2564,32 @@ export enum PortDataDirection {
2561
2564
  /** Output */
2562
2565
  Output = 1
2563
2566
  }
2567
+ export enum PortDirectValueTypes {
2568
+ Float = 0,
2569
+ Int = 1
2570
+ }
2571
+ export interface IPortDirectValueDefinition {
2572
+ /**
2573
+ * Gets the source object
2574
+ */
2575
+ source: any;
2576
+ /**
2577
+ * Gets the property name used to store the value
2578
+ */
2579
+ propertyName: string;
2580
+ /**
2581
+ * Gets or sets the min value accepted for this point if nothing is connected
2582
+ */
2583
+ valueMin: Nullable<any>;
2584
+ /**
2585
+ * Gets or sets the max value accepted for this point if nothing is connected
2586
+ */
2587
+ valueMax: Nullable<any>;
2588
+ /**
2589
+ * Gets or sets the type of the value
2590
+ */
2591
+ valueType: PortDirectValueTypes;
2592
+ }
2564
2593
  export interface IPortData {
2565
2594
  data: any;
2566
2595
  name: string;
@@ -2574,6 +2603,7 @@ export interface IPortData {
2574
2603
  needDualDirectionValidation: boolean;
2575
2604
  hasEndpoints: boolean;
2576
2605
  endpoints: Nullable<IPortData[]>;
2606
+ directValueDefinition?: IPortDirectValueDefinition;
2577
2607
  updateDisplayName: (newName: string) => void;
2578
2608
  canConnectTo: (port: IPortData) => boolean;
2579
2609
  connectTo: (port: IPortData) => void;
@@ -6261,6 +6291,7 @@ declare module BABYLON.NodeEditor {
6261
6291
  declare module BABYLON.NodeEditor.SharedUIComponents {
6262
6292
  export const IsFramePortData: (variableToCheck: any) => variableToCheck is BABYLON.NodeEditor.SharedUIComponents.FramePortData;
6263
6293
  export const RefreshNode: (node: BABYLON.NodeEditor.SharedUIComponents.GraphNode, visitedNodes?: Set<BABYLON.NodeEditor.SharedUIComponents.GraphNode>, visitedLinks?: Set<BABYLON.NodeEditor.SharedUIComponents.NodeLink>, canvas?: BABYLON.NodeEditor.SharedUIComponents.GraphCanvasComponent) => void;
6294
+ export const BuildFloatUI: (container: HTMLDivElement, document: Document, displayName: string, isInteger: boolean, source: any, propertyName: string, onChange: () => void, min?: number, max?: number, visualPropertiesRefresh?: Array<() => void>) => void;
6264
6295
 
6265
6296
 
6266
6297
 
@@ -6375,7 +6406,7 @@ declare module BABYLON.NodeEditor {
6375
6406
  }
6376
6407
  declare module BABYLON.NodeEditor.SharedUIComponents {
6377
6408
  export class NodePort {
6378
- portData: BABYLON.NodeEditor.SharedUIComponents.IPortData;
6409
+ portData: IPortData;
6379
6410
  node: BABYLON.NodeEditor.SharedUIComponents.GraphNode;
6380
6411
  protected _element: HTMLDivElement;
6381
6412
  protected _portContainer: HTMLElement;
@@ -6386,6 +6417,7 @@ declare module BABYLON.NodeEditor.SharedUIComponents {
6386
6417
  protected _onCandidateLinkMovedObserver: BABYLON.Nullable<BABYLON.Observer<BABYLON.Nullable<BABYLON.Vector2>>>;
6387
6418
  protected _onSelectionChangedObserver: BABYLON.Nullable<BABYLON.Observer<BABYLON.Nullable<BABYLON.NodeEditor.SharedUIComponents.ISelectionChangedOptions>>>;
6388
6419
  protected _exposedOnFrame: boolean;
6420
+ protected _portUIcontainer?: HTMLDivElement;
6389
6421
  delegatedPort: BABYLON.Nullable<BABYLON.NodeEditor.SharedUIComponents.FrameNodePort>;
6390
6422
  get element(): HTMLDivElement;
6391
6423
  get container(): HTMLElement;
@@ -6399,9 +6431,9 @@ declare module BABYLON.NodeEditor.SharedUIComponents {
6399
6431
  set exposedPortPosition(value: number);
6400
6432
  private _isConnectedToNodeOutsideOfFrame;
6401
6433
  refresh(): void;
6402
- constructor(portContainer: HTMLElement, portData: BABYLON.NodeEditor.SharedUIComponents.IPortData, node: BABYLON.NodeEditor.SharedUIComponents.GraphNode, stateManager: BABYLON.NodeEditor.SharedUIComponents.StateManager);
6434
+ constructor(portContainer: HTMLElement, portData: IPortData, node: BABYLON.NodeEditor.SharedUIComponents.GraphNode, stateManager: BABYLON.NodeEditor.SharedUIComponents.StateManager, portUIcontainer?: HTMLDivElement);
6403
6435
  dispose(): void;
6404
- static CreatePortElement(portData: BABYLON.NodeEditor.SharedUIComponents.IPortData, node: BABYLON.NodeEditor.SharedUIComponents.GraphNode, root: HTMLElement, displayManager: BABYLON.Nullable<BABYLON.NodeEditor.SharedUIComponents.IDisplayManager>, stateManager: BABYLON.NodeEditor.SharedUIComponents.StateManager): NodePort;
6436
+ static CreatePortElement(portData: IPortData, node: BABYLON.NodeEditor.SharedUIComponents.GraphNode, root: HTMLElement, displayManager: BABYLON.Nullable<BABYLON.NodeEditor.SharedUIComponents.IDisplayManager>, stateManager: BABYLON.NodeEditor.SharedUIComponents.StateManager): NodePort;
6405
6437
  }
6406
6438
 
6407
6439
 
@@ -6540,7 +6572,7 @@ declare module BABYLON.NodeEditor.SharedUIComponents {
6540
6572
  private _onUp;
6541
6573
  private _onMove;
6542
6574
  renderProperties(): BABYLON.Nullable<JSX.Element>;
6543
- private _forceRebuild;
6575
+ _forceRebuild(source: any, propertyName: string, notifiers?: BABYLON.IEditablePropertyOption["notifiers"]): void;
6544
6576
  private _isCollapsed;
6545
6577
  /**
6546
6578
  * Collapse the node
@@ -6945,6 +6977,32 @@ declare module BABYLON.NodeEditor.SharedUIComponents {
6945
6977
  /** Output */
6946
6978
  Output = 1
6947
6979
  }
6980
+ export enum PortDirectValueTypes {
6981
+ Float = 0,
6982
+ Int = 1
6983
+ }
6984
+ export interface IPortDirectValueDefinition {
6985
+ /**
6986
+ * Gets the source object
6987
+ */
6988
+ source: any;
6989
+ /**
6990
+ * Gets the property name used to store the value
6991
+ */
6992
+ propertyName: string;
6993
+ /**
6994
+ * Gets or sets the min value accepted for this point if nothing is connected
6995
+ */
6996
+ valueMin: BABYLON.Nullable<any>;
6997
+ /**
6998
+ * Gets or sets the max value accepted for this point if nothing is connected
6999
+ */
7000
+ valueMax: BABYLON.Nullable<any>;
7001
+ /**
7002
+ * Gets or sets the type of the value
7003
+ */
7004
+ valueType: PortDirectValueTypes;
7005
+ }
6948
7006
  export interface IPortData {
6949
7007
  data: any;
6950
7008
  name: string;
@@ -6958,6 +7016,7 @@ declare module BABYLON.NodeEditor.SharedUIComponents {
6958
7016
  needDualDirectionValidation: boolean;
6959
7017
  hasEndpoints: boolean;
6960
7018
  endpoints: BABYLON.Nullable<IPortData[]>;
7019
+ directValueDefinition?: IPortDirectValueDefinition;
6961
7020
  updateDisplayName: (newName: string) => void;
6962
7021
  canConnectTo: (port: IPortData) => boolean;
6963
7022
  connectTo: (port: IPortData) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "babylonjs-node-editor",
3
- "version": "7.35.2",
3
+ "version": "7.36.0",
4
4
  "main": "babylon.nodeEditor.js",
5
5
  "types": "babylon.nodeEditor.module.d.ts",
6
6
  "files": [
@@ -14,7 +14,7 @@
14
14
  "clean": "rimraf dist && rimraf babylon*.* -g"
15
15
  },
16
16
  "dependencies": {
17
- "babylonjs": "^7.35.2"
17
+ "babylonjs": "^7.36.0"
18
18
  },
19
19
  "devDependencies": {
20
20
  "@dev/build-tools": "1.0.0",