@babylonjs/node-editor 5.26.1 → 5.27.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.
|
@@ -1371,7 +1371,7 @@ export class HexColor extends React.Component<IHexColorProps, {
|
|
|
1371
1371
|
|
|
1372
1372
|
}
|
|
1373
1373
|
declare module "@babylonjs/node-editor/components/bars/CommandBarComponent" {
|
|
1374
|
-
import
|
|
1374
|
+
import { FC } from "react";
|
|
1375
1375
|
export interface ICommandBarComponentProps {
|
|
1376
1376
|
onSaveButtonClicked?: () => void;
|
|
1377
1377
|
onSaveToSnippetButtonClicked?: () => void;
|
|
@@ -1382,8 +1382,11 @@ export interface ICommandBarComponentProps {
|
|
|
1382
1382
|
onPanButtonClicked?: () => void;
|
|
1383
1383
|
onZoomButtonClicked?: () => void;
|
|
1384
1384
|
onFitButtonClicked?: () => void;
|
|
1385
|
+
onArtboardColorChanged?: (newColor: string) => void;
|
|
1386
|
+
artboardColor?: string;
|
|
1387
|
+
artboardColorPickerColor?: string;
|
|
1385
1388
|
}
|
|
1386
|
-
export const CommandBarComponent:
|
|
1389
|
+
export const CommandBarComponent: FC<ICommandBarComponentProps>;
|
|
1387
1390
|
|
|
1388
1391
|
}
|
|
1389
1392
|
declare module "@babylonjs/node-editor/components/bars/CommandButtonComponent" {
|
|
@@ -1446,6 +1449,96 @@ declare module "@babylonjs/node-editor/components/classNames" {
|
|
|
1446
1449
|
export function ClassNames(names: any, styleObject: any): string;
|
|
1447
1450
|
export function JoinClassNames(styleObject: any, ...names: string[]): string;
|
|
1448
1451
|
|
|
1452
|
+
}
|
|
1453
|
+
declare module "@babylonjs/node-editor/components/colorPicker/ColorComponentEntry" {
|
|
1454
|
+
import * as React from "react";
|
|
1455
|
+
import { LockObject } from "@babylonjs/node-editor/tabs/propertyGrids/lockObject";
|
|
1456
|
+
export interface IColorComponentEntryProps {
|
|
1457
|
+
value: number;
|
|
1458
|
+
label: string;
|
|
1459
|
+
max?: number;
|
|
1460
|
+
min?: number;
|
|
1461
|
+
onChange: (value: number) => void;
|
|
1462
|
+
disabled?: boolean;
|
|
1463
|
+
lockObject: LockObject;
|
|
1464
|
+
}
|
|
1465
|
+
export class ColorComponentEntry extends React.Component<IColorComponentEntryProps> {
|
|
1466
|
+
constructor(props: IColorComponentEntryProps);
|
|
1467
|
+
updateValue(valueString: string): void;
|
|
1468
|
+
lock(): void;
|
|
1469
|
+
unlock(): void;
|
|
1470
|
+
render(): JSX.Element;
|
|
1471
|
+
}
|
|
1472
|
+
|
|
1473
|
+
}
|
|
1474
|
+
declare module "@babylonjs/node-editor/components/colorPicker/ColorPicker" {
|
|
1475
|
+
import * as React from "react";
|
|
1476
|
+
import { Color3, Color4 } from "@babylonjs/core/Maths/math.color";
|
|
1477
|
+
import { LockObject } from "@babylonjs/node-editor/tabs/propertyGrids/lockObject";
|
|
1478
|
+
/**
|
|
1479
|
+
* Interface used to specify creation options for color picker
|
|
1480
|
+
*/
|
|
1481
|
+
export interface IColorPickerProps {
|
|
1482
|
+
color: Color3 | Color4;
|
|
1483
|
+
linearhint?: boolean;
|
|
1484
|
+
debugMode?: boolean;
|
|
1485
|
+
onColorChanged?: (color: Color3 | Color4) => void;
|
|
1486
|
+
lockObject: LockObject;
|
|
1487
|
+
backgroundColor?: string;
|
|
1488
|
+
}
|
|
1489
|
+
/**
|
|
1490
|
+
* Interface used to specify creation options for color picker
|
|
1491
|
+
*/
|
|
1492
|
+
export interface IColorPickerState {
|
|
1493
|
+
color: Color3;
|
|
1494
|
+
alpha: number;
|
|
1495
|
+
}
|
|
1496
|
+
/**
|
|
1497
|
+
* Class used to create a color picker
|
|
1498
|
+
*/
|
|
1499
|
+
export class ColorPicker extends React.Component<IColorPickerProps, IColorPickerState> {
|
|
1500
|
+
private _saturationRef;
|
|
1501
|
+
private _hueRef;
|
|
1502
|
+
private _isSaturationPointerDown;
|
|
1503
|
+
private _isHuePointerDown;
|
|
1504
|
+
constructor(props: IColorPickerProps);
|
|
1505
|
+
shouldComponentUpdate(nextProps: IColorPickerProps, nextState: IColorPickerState): boolean;
|
|
1506
|
+
onSaturationPointerDown(evt: React.PointerEvent<HTMLDivElement>): void;
|
|
1507
|
+
onSaturationPointerUp(evt: React.PointerEvent<HTMLDivElement>): void;
|
|
1508
|
+
onSaturationPointerMove(evt: React.PointerEvent<HTMLDivElement>): void;
|
|
1509
|
+
onHuePointerDown(evt: React.PointerEvent<HTMLDivElement>): void;
|
|
1510
|
+
onHuePointerUp(evt: React.PointerEvent<HTMLDivElement>): void;
|
|
1511
|
+
onHuePointerMove(evt: React.PointerEvent<HTMLDivElement>): void;
|
|
1512
|
+
private _evaluateSaturation;
|
|
1513
|
+
private _evaluateHue;
|
|
1514
|
+
componentDidUpdate(): void;
|
|
1515
|
+
raiseOnColorChanged(): void;
|
|
1516
|
+
render(): JSX.Element;
|
|
1517
|
+
}
|
|
1518
|
+
|
|
1519
|
+
}
|
|
1520
|
+
declare module "@babylonjs/node-editor/components/colorPicker/HexColor" {
|
|
1521
|
+
import * as React from "react";
|
|
1522
|
+
import { LockObject } from "@babylonjs/node-editor/tabs/propertyGrids/lockObject";
|
|
1523
|
+
export interface IHexColorProps {
|
|
1524
|
+
value: string;
|
|
1525
|
+
expectedLength: number;
|
|
1526
|
+
onChange: (value: string) => void;
|
|
1527
|
+
lockObject: LockObject;
|
|
1528
|
+
}
|
|
1529
|
+
export class HexColor extends React.Component<IHexColorProps, {
|
|
1530
|
+
hex: string;
|
|
1531
|
+
}> {
|
|
1532
|
+
constructor(props: IHexColorProps);
|
|
1533
|
+
shouldComponentUpdate(nextProps: IHexColorProps, nextState: {
|
|
1534
|
+
hex: string;
|
|
1535
|
+
}): boolean;
|
|
1536
|
+
lock(): void;
|
|
1537
|
+
unlock(): void;
|
|
1538
|
+
updateHexValue(valueString: string): void;
|
|
1539
|
+
render(): JSX.Element;
|
|
1540
|
+
}
|
|
1541
|
+
|
|
1449
1542
|
}
|
|
1450
1543
|
declare module "@babylonjs/node-editor/components/Icon" {
|
|
1451
1544
|
/// <reference types="react" />
|
|
@@ -1465,6 +1558,85 @@ export type LabelProps = {
|
|
|
1465
1558
|
};
|
|
1466
1559
|
export const Label: React.FC<LabelProps>;
|
|
1467
1560
|
|
|
1561
|
+
}
|
|
1562
|
+
declare module "@babylonjs/node-editor/components/lines/ColorLineComponent" {
|
|
1563
|
+
import * as React from "react";
|
|
1564
|
+
import { Observable } from "@babylonjs/core/Misc/observable";
|
|
1565
|
+
import { Color4 } from "@babylonjs/core/Maths/math.color";
|
|
1566
|
+
import { PropertyChangedEvent } from "@babylonjs/node-editor/propertyChangedEvent";
|
|
1567
|
+
import { LockObject } from "@babylonjs/node-editor/tabs/propertyGrids/lockObject";
|
|
1568
|
+
export interface IColorLineComponentProps {
|
|
1569
|
+
label: string;
|
|
1570
|
+
target: any;
|
|
1571
|
+
propertyName: string;
|
|
1572
|
+
onPropertyChangedObservable: Observable<PropertyChangedEvent>;
|
|
1573
|
+
onChange?: () => void;
|
|
1574
|
+
isLinear?: boolean;
|
|
1575
|
+
icon?: string;
|
|
1576
|
+
iconLabel?: string;
|
|
1577
|
+
disableAlpha?: boolean;
|
|
1578
|
+
lockObject: LockObject;
|
|
1579
|
+
}
|
|
1580
|
+
interface IColorLineComponentState {
|
|
1581
|
+
isExpanded: boolean;
|
|
1582
|
+
color: Color4;
|
|
1583
|
+
}
|
|
1584
|
+
export class ColorLineComponent extends React.Component<IColorLineComponentProps, IColorLineComponentState> {
|
|
1585
|
+
constructor(props: IColorLineComponentProps);
|
|
1586
|
+
shouldComponentUpdate(nextProps: IColorLineComponentProps, nextState: IColorLineComponentState): boolean;
|
|
1587
|
+
getValue(props?: Readonly<IColorLineComponentProps> & Readonly<{
|
|
1588
|
+
children?: React.ReactNode;
|
|
1589
|
+
}>): Color4;
|
|
1590
|
+
setColorFromString(colorString: string): void;
|
|
1591
|
+
setColor(newColor: Color4): void;
|
|
1592
|
+
switchExpandState(): void;
|
|
1593
|
+
updateStateR(value: number): void;
|
|
1594
|
+
updateStateG(value: number): void;
|
|
1595
|
+
updateStateB(value: number): void;
|
|
1596
|
+
updateStateA(value: number): void;
|
|
1597
|
+
copyToClipboard(): void;
|
|
1598
|
+
private _convertToColor;
|
|
1599
|
+
private _toColor3;
|
|
1600
|
+
render(): JSX.Element;
|
|
1601
|
+
}
|
|
1602
|
+
export {};
|
|
1603
|
+
|
|
1604
|
+
}
|
|
1605
|
+
declare module "@babylonjs/node-editor/components/lines/ColorPickerLineComponent" {
|
|
1606
|
+
import * as React from "react";
|
|
1607
|
+
import { Color4, Color3 } from "@babylonjs/core/Maths/math.color";
|
|
1608
|
+
import { LockObject } from "@babylonjs/node-editor/tabs/propertyGrids/lockObject";
|
|
1609
|
+
export interface IColorPickerComponentProps {
|
|
1610
|
+
value: Color4 | Color3;
|
|
1611
|
+
linearHint?: boolean;
|
|
1612
|
+
onColorChanged: (newOne: string) => void;
|
|
1613
|
+
icon?: string;
|
|
1614
|
+
iconLabel?: string;
|
|
1615
|
+
shouldPopRight?: boolean;
|
|
1616
|
+
lockObject?: LockObject;
|
|
1617
|
+
backgroundColor?: string;
|
|
1618
|
+
}
|
|
1619
|
+
interface IColorPickerComponentState {
|
|
1620
|
+
pickerEnabled: boolean;
|
|
1621
|
+
color: Color3 | Color4;
|
|
1622
|
+
hex: string;
|
|
1623
|
+
}
|
|
1624
|
+
export class ColorPickerLineComponent extends React.Component<IColorPickerComponentProps, IColorPickerComponentState> {
|
|
1625
|
+
private _floatRef;
|
|
1626
|
+
private _floatHostRef;
|
|
1627
|
+
private _coverRef;
|
|
1628
|
+
constructor(props: IColorPickerComponentProps);
|
|
1629
|
+
syncPositions(): void;
|
|
1630
|
+
shouldComponentUpdate(nextProps: IColorPickerComponentProps, nextState: IColorPickerComponentState): boolean;
|
|
1631
|
+
getHexString(props?: Readonly<IColorPickerComponentProps> & Readonly<{
|
|
1632
|
+
children?: React.ReactNode;
|
|
1633
|
+
}>): string;
|
|
1634
|
+
componentDidUpdate(): void;
|
|
1635
|
+
componentDidMount(): void;
|
|
1636
|
+
render(): JSX.Element;
|
|
1637
|
+
}
|
|
1638
|
+
export {};
|
|
1639
|
+
|
|
1468
1640
|
}
|
|
1469
1641
|
declare module "@babylonjs/node-editor/components/lines/FileButtonLineComponent" {
|
|
1470
1642
|
import * as React from "react";
|
|
@@ -1484,6 +1656,40 @@ export class FileButtonLineComponent extends React.Component<IFileButtonLineComp
|
|
|
1484
1656
|
render(): JSX.Element;
|
|
1485
1657
|
}
|
|
1486
1658
|
|
|
1659
|
+
}
|
|
1660
|
+
declare module "@babylonjs/node-editor/components/lines/NumericInputComponent" {
|
|
1661
|
+
import * as React from "react";
|
|
1662
|
+
import { LockObject } from "@babylonjs/node-editor/tabs/propertyGrids/lockObject";
|
|
1663
|
+
interface INumericInputComponentProps {
|
|
1664
|
+
label: string;
|
|
1665
|
+
value: number;
|
|
1666
|
+
step?: number;
|
|
1667
|
+
onChange: (value: number) => void;
|
|
1668
|
+
precision?: number;
|
|
1669
|
+
icon?: string;
|
|
1670
|
+
iconLabel?: string;
|
|
1671
|
+
lockObject: LockObject;
|
|
1672
|
+
}
|
|
1673
|
+
export class NumericInputComponent extends React.Component<INumericInputComponentProps, {
|
|
1674
|
+
value: string;
|
|
1675
|
+
}> {
|
|
1676
|
+
static defaultProps: {
|
|
1677
|
+
step: number;
|
|
1678
|
+
};
|
|
1679
|
+
private _localChange;
|
|
1680
|
+
constructor(props: INumericInputComponentProps);
|
|
1681
|
+
componentWillUnmount(): void;
|
|
1682
|
+
shouldComponentUpdate(nextProps: INumericInputComponentProps, nextState: {
|
|
1683
|
+
value: string;
|
|
1684
|
+
}): boolean;
|
|
1685
|
+
updateValue(valueString: string): void;
|
|
1686
|
+
onBlur(): void;
|
|
1687
|
+
incrementValue(amount: number): void;
|
|
1688
|
+
onKeyDown(evt: React.KeyboardEvent<HTMLInputElement>): void;
|
|
1689
|
+
render(): JSX.Element;
|
|
1690
|
+
}
|
|
1691
|
+
export {};
|
|
1692
|
+
|
|
1487
1693
|
}
|
|
1488
1694
|
declare module "@babylonjs/node-editor/components/MessageDialog" {
|
|
1489
1695
|
import * as React from "react";
|
|
@@ -3096,6 +3302,11 @@ const _default: {
|
|
|
3096
3302
|
};
|
|
3097
3303
|
export default _default;
|
|
3098
3304
|
export const Default: {};
|
|
3305
|
+
export const WithArtboardColor: {
|
|
3306
|
+
parameters: {
|
|
3307
|
+
onArtboardColorChanged: (color: string) => void;
|
|
3308
|
+
};
|
|
3309
|
+
};
|
|
3099
3310
|
|
|
3100
3311
|
}
|
|
3101
3312
|
declare module "@babylonjs/node-editor/stories/bars/CommandButtonComponent.stories" {
|
|
@@ -3119,6 +3330,20 @@ export const Default: any;
|
|
|
3119
3330
|
export const Wide: any;
|
|
3120
3331
|
export const Small: any;
|
|
3121
3332
|
|
|
3333
|
+
}
|
|
3334
|
+
declare module "@babylonjs/node-editor/stories/colorPicker/ColorPicker.stories" {
|
|
3335
|
+
import { Color3 } from "@babylonjs/core/Maths/math.color";
|
|
3336
|
+
import { ColorPicker } from "@babylonjs/node-editor/components/colorPicker/ColorPicker";
|
|
3337
|
+
const _default: {
|
|
3338
|
+
component: typeof ColorPicker;
|
|
3339
|
+
};
|
|
3340
|
+
export default _default;
|
|
3341
|
+
export const Default: {
|
|
3342
|
+
args: {
|
|
3343
|
+
color: Color3;
|
|
3344
|
+
};
|
|
3345
|
+
};
|
|
3346
|
+
|
|
3122
3347
|
}
|
|
3123
3348
|
declare module "@babylonjs/node-editor/stories/Icon.stories" {
|
|
3124
3349
|
/// <reference types="react" />
|
|
@@ -3142,6 +3367,47 @@ const _default: {
|
|
|
3142
3367
|
export default _default;
|
|
3143
3368
|
export const Default: any;
|
|
3144
3369
|
|
|
3370
|
+
}
|
|
3371
|
+
declare module "@babylonjs/node-editor/stories/lines/ColorLineComponent.stories" {
|
|
3372
|
+
/// <reference types="react" />
|
|
3373
|
+
import { Observable } from "@babylonjs/core/Misc/observable";
|
|
3374
|
+
import { PropertyChangedEvent } from "@babylonjs/node-editor/propertyChangedEvent";
|
|
3375
|
+
import { IColorLineComponentProps } from "@babylonjs/node-editor/components/lines/ColorLineComponent";
|
|
3376
|
+
import { ColorLineComponent } from "@babylonjs/node-editor/components/lines/ColorLineComponent";
|
|
3377
|
+
const _default: {
|
|
3378
|
+
component: typeof ColorLineComponent;
|
|
3379
|
+
};
|
|
3380
|
+
export default _default;
|
|
3381
|
+
export const Default: {
|
|
3382
|
+
render: (args: IColorLineComponentProps) => JSX.Element;
|
|
3383
|
+
args: {
|
|
3384
|
+
target: {};
|
|
3385
|
+
label: string;
|
|
3386
|
+
propertyName: string;
|
|
3387
|
+
lockObject: {
|
|
3388
|
+
lock: boolean;
|
|
3389
|
+
};
|
|
3390
|
+
onPropertyChangedObservable: Observable<PropertyChangedEvent>;
|
|
3391
|
+
};
|
|
3392
|
+
};
|
|
3393
|
+
|
|
3394
|
+
}
|
|
3395
|
+
declare module "@babylonjs/node-editor/stories/lines/ColorPickerLineComponent.stories" {
|
|
3396
|
+
/// <reference types="react" />
|
|
3397
|
+
import { Color3 } from "@babylonjs/core/Maths/math.color";
|
|
3398
|
+
import { IColorPickerComponentProps } from "@babylonjs/node-editor/components/lines/ColorPickerLineComponent";
|
|
3399
|
+
import { ColorPickerLineComponent } from "@babylonjs/node-editor/components/lines/ColorPickerLineComponent";
|
|
3400
|
+
const _default: {
|
|
3401
|
+
component: typeof ColorPickerLineComponent;
|
|
3402
|
+
};
|
|
3403
|
+
export default _default;
|
|
3404
|
+
export const Default: {
|
|
3405
|
+
render: (args: IColorPickerComponentProps) => JSX.Element;
|
|
3406
|
+
args: {
|
|
3407
|
+
value: Color3;
|
|
3408
|
+
};
|
|
3409
|
+
};
|
|
3410
|
+
|
|
3145
3411
|
}
|
|
3146
3412
|
declare module "@babylonjs/node-editor/stories/lines/FileButtonLineComponent.stories" {
|
|
3147
3413
|
import { FileButtonLineComponent } from "@babylonjs/node-editor/components/lines/FileButtonLineComponent";
|
|
@@ -3151,6 +3417,20 @@ const _default: {
|
|
|
3151
3417
|
export default _default;
|
|
3152
3418
|
export const Default: {};
|
|
3153
3419
|
|
|
3420
|
+
}
|
|
3421
|
+
declare module "@babylonjs/node-editor/stories/lines/NumericInputComponent.stories" {
|
|
3422
|
+
import { NumericInputComponent } from "@babylonjs/node-editor/components/lines/NumericInputComponent";
|
|
3423
|
+
const _default: {
|
|
3424
|
+
component: typeof NumericInputComponent;
|
|
3425
|
+
};
|
|
3426
|
+
export default _default;
|
|
3427
|
+
export const Default: {
|
|
3428
|
+
args: {
|
|
3429
|
+
label: string;
|
|
3430
|
+
value: number;
|
|
3431
|
+
};
|
|
3432
|
+
};
|
|
3433
|
+
|
|
3154
3434
|
}
|
|
3155
3435
|
declare module "@babylonjs/node-editor/stories/MessageDialog.stories" {
|
|
3156
3436
|
/// <reference types="react" />
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@babylonjs/node-editor",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.27.1",
|
|
4
4
|
"main": "dist/babylon.nodeEditor.max.js",
|
|
5
5
|
"module": "dist/babylon.nodeEditor.max.js",
|
|
6
6
|
"esnext": "dist/babylon.nodeEditor.max.js",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"@types/react-dom": ">=16.0.9"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@babylonjs/core": "^5.
|
|
26
|
+
"@babylonjs/core": "^5.27.1",
|
|
27
27
|
"react": "^17.0.2",
|
|
28
28
|
"react-dom": "^17.0.2",
|
|
29
29
|
"rimraf": "^3.0.2",
|